CN101295250A - Method and device for calling software module - Google Patents
Method and device for calling software module Download PDFInfo
- Publication number
- CN101295250A CN101295250A CNA2008101262241A CN200810126224A CN101295250A CN 101295250 A CN101295250 A CN 101295250A CN A2008101262241 A CNA2008101262241 A CN A2008101262241A CN 200810126224 A CN200810126224 A CN 200810126224A CN 101295250 A CN101295250 A CN 101295250A
- Authority
- CN
- China
- Prior art keywords
- expansion
- extension point
- interface
- person
- extension
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Landscapes
- Stored Programmes (AREA)
Abstract
The embodiment of the invention discloses a method and a device used for realizing software module invoking. The method comprises the following steps: an extension center is arranged; corresponding relationship between extension point identification ID and extension point interfaces is memorized in the extension center; an extension point carrier and an extender respectively hitch the extension points; the extension point carrier obtains the extension center interface, searches the extension point interfaces in the extension center corresponding to the extension point ID of the extension point carrier and invokes the extender which hitches the extension points by the extension point interfaces. By the invention, the invoked module can recognise and trigger the meaning of the invoked event by invoking the interfaces.
Description
Technical field
The present invention relates to field of computer technology, relate in particular to a kind of method and apparatus of realizing calling software module.
Background technology
Computer software comprises a plurality of modules usually, can call mutually between these modules.In technology in the past, when triggering scheduled event, each module adopts the mode of directly calling to call other modules, and wherein, the module of sending described call action is called event source, and invoked module is called the take over party.This mode of directly calling makes that the degree of coupling between event source and the take over party is higher, is unfavorable for software upgrading.
For reducing the degree of coupling between event source and the take over party, introduced the incident Center Scheme in the prior art and realized calling of software module.
In the event center scheme, event source is by the event center trigger event, and the take over party is articulated to event center by same interface, and after event center had incident to be triggered, event center called the take over party.Wherein, the event source of corresponding same event center can have a plurality of, and the take over party who is articulated to same event center also can have a plurality of, after event center receives Event triggered, determine to trigger the event source of described incident,, call corresponding take over party by the administrative mechanism of described event center self.
As seen,, can reduce event source and take over party's the degree of coupling, but simultaneously, also there is following deficiency in this event center scheme by event center is set:
Because the take over party is articulated to event center by same interface, therefore, the take over party can't cause the meaning of the invoked incident of this take over party by this interface identification, and promptly the take over party can't determine which event source trigger event makes this take over party be called.
Summary of the invention
In view of this, the purpose of the embodiment of the invention is to provide a kind of method and apparatus of realizing calling software module, so that invoked module can trigger the described incident meaning of calling by calling interface identification.
For achieving the above object, the technical scheme of the embodiment of the invention specifically is achieved in that
A kind of method that realizes calling software module, this method comprises:
The expansion center is set, and at the corresponding relation of expanding central store extension point sign ID and extension point interface, extension point carrier and expansion person articulate extension point respectively;
The extension point carrier obtains the expansion hub-interface, searches extension point interface corresponding with the extension point ID of described extension point carrier in the expansion in the heart, articulates the expansion person of described extension point by described extension point interface interchange.
A kind of device of realizing calling software module, this device comprises expansion center, extension point carrier and expansion person;
Described expansion center stores the corresponding relation of extension point ID and extension point interface;
Described extension point carrier is mounted with extension point, is used to obtain the expansion hub-interface, searches extension point interface corresponding with the extension point ID of described extension point carrier in the expansion in the heart, articulates the expansion person of described extension point by described extension point interface interchange;
Described expansion person is mounted with extension point, responds calling of described extension point carrier.
In the embodiment of the invention, be provided with the expansion center, wherein store extension point sign (Identity, ID) with the corresponding relation of extension point interface, extension point carrier and expansion person articulate extension point respectively, the extension point carrier obtains the expansion hub-interface, searches extension point interface corresponding with the extension point ID of described extension point carrier in the expansion in the heart, articulates the expansion person of described extension point by described extension point interface interchange.As seen, because extension point carrier and expansion person can be articulated to the expansion center by the extension point interface, and the extension point interface is corresponding with extension point, the different meaning of different extension point representatives, therefore, expansion person can be by extension point interface identification extension point carrier invoke extensions person's meaning.
Description of drawings
Fig. 1 is the method flow diagram that " main panel " articulates " contact data variation " this extension point;
Fig. 2 is the method flow diagram that " contact management's module " passes through this expansion person of extension point interface interchange " main panel " of " contact data variation ";
Fig. 3 is the method flow diagram that " marketing management module " articulates " system message incident " this extension point;
Fig. 4 is " system message administration module " this expansion person's of extension point interface interchange " marketing management module " of passing through " system message incident " this extension point a method flow diagram;
Fig. 5 is the method flow diagram of extension point carrier invoke extensions person among the method embodiment three;
Fig. 6 is a structure drawing of device of realizing calling software module.
Embodiment
In the embodiment of the invention, the expansion center is set, wherein store the corresponding relation of extension point sign ID and extension point interface, extension point carrier and expansion person articulate extension point respectively, the extension point carrier obtains the expansion hub-interface, search extension point interface corresponding with the extension point ID of described extension point carrier in the expansion in the heart, articulate the expansion person of described extension point by described extension point interface interchange.
For making purpose of the present invention, technical scheme and advantage clearer, below with reference to the accompanying drawing embodiment that develops simultaneously, the present invention is described in more detail.
Articulate the different modes of extension point below according to expansion person, the present invention will be described for embodiment respectively.
Method embodiment one
In the present embodiment, the mode that expansion person articulates extension point is: obtain the expansion hub-interface, described expansion person's self interface is registered to waits to articulate in the expansion interface tabulation of extension point.
Below with " main panel " in the immediate communication tool as expansion person, " contact management's module " as the extension point carrier, introduces method that expansion person adopts method embodiment one in detail and articulates extension point and the extension point carrier concrete grammar by extension point interface interchange expansion person.
Fig. 1 is the method flow diagram that " main panel " articulates " contact data variation " this extension point, and as shown in Figure 1, this method specifically comprises:
In this step, " main panel " invoke extensions hub-interface, the ID by " contact data variation " this extension point obtains the extension point interface of described ID correspondence.
In this step, the registration spread function of " main panel " invoke extensions point interface is registered to the interface of self in the expansion interface tabulation of described extension point interface.
Fig. 2 is the method flow diagram that " contact management's module " passes through this expansion person of extension point interface interchange " main panel " of " contact data variation ", and as shown in Figure 2, this method comprises:
Step 201, " contact management's module " obtains the expansion hub-interface.
Step 202, " contact management's module " obtains the extension point interface.
In this step, " contact management's module " invoke extensions hub-interface, the ID by " contact data variation " this extension point obtains the extension point interface of described ID correspondence.
Step 203, the tabulation that " contact management's module " obtains expansion interface.
In this step, " contact management's module " invoke extensions point interface obtain expansion interface function, the tabulation of obtaining expansion interface.
Step 204, " contact management's module " are searched the expansion interface of " main panel " in described expansion interface tabulation.
Step 205, " contact management's module " calls " main panel " by described expansion interface.
Step 206, " main panel " refreshes the interface after receiving described calling.
Method embodiment two
In the present embodiment, the mode that expansion person articulates extension point is: expansion person obtains the expansion hub-interface, described expansion person's self module information is registered to the expansion person supplier who waits to articulate extension point.
Below with " marketing management module " in the immediate communication tool as expansion person, " system message administration module " as the extension point carrier, introduces method that expansion person adopts method embodiment two in detail and articulates extension point and the extension point carrier concrete grammar by extension point interface interchange expansion person.
Fig. 3 is the method flow diagram that " marketing management module " articulates " system message incident " this extension point, and as shown in Figure 3, this method specifically comprises:
In this step, " marketing management module " describes concern in configuration file " the system message incident " extension point, and the information such as class (class) ID at the expansion person supplier assembly place of " marketing management module " are described in described configuration file.
In this step, when initialization expansion center, by the configuration file in the expansion center read step 301, and a module information of " marketing management module " is stored to the expansion person supplier of described extension point, like this, expansion person supplier can generate the interface of " marketing management module " according to this module information.
Fig. 4 is " system message administration module " this expansion person's of extension point interface interchange " marketing management module " of passing through " system message incident " this extension point a method flow diagram, and as shown in Figure 4, this method comprises:
In this step, " system message administration module " invoke extensions hub-interface is by " ID of " system message incident " this extension point obtains the extension point interface of described ID correspondence.
In this step, " system message administration module " invoke extensions point interface obtain expansion person supplier function, obtain the expansion person supplier of " marketing management module ".
Step 406 after " marketing management module " receives described calling, ejects the marketing interface.
Method embodiment three
In the present embodiment, the mode that expansion person articulates extension point had both comprised method embodiment one described mode, also comprised method embodiment two described methods, at this moment, the corresponding expansion person agency of each extension point interface stores expansion person's interface list and expansion person supplier tabulation among this expansion person agency.
The following describes in method embodiment three extension point carrier invoke extensions person's concrete grammar.
Fig. 5 is the method flow diagram of extension point carrier invoke extensions person among the method embodiment three, and as shown in Figure 5, this method specifically comprises:
In this step, the extension point carrier obtains the extension point interface of described ID correspondence by the ID of described extension point.
Step 505 is generated expansion person's interface by the expansion person supplier who articulates described expansion person
Step 506 is by expansion person's interface interchange expansion person.
Above-mentioned three method embodiment have provided the concrete grammar of extension point carrier by extension point interface interchange expansion person, and expansion person can be by extension point interface identification extension point carrier invoke extensions person's meaning.
The extension point that relates among three method embodiment for example is provided with the extension point interface of new extension point and this new extension point by expansion center unified management, destroys the extension point out of date and the expansion interface of this extension point, has made things convenient for the management to extension point.
When needs expanding software function, when new intermodule call relation perhaps is set, only need extension point carrier and expansion person only need be articulated the respective extension point, can the extension point interface by this extension point realize that the extension point carrier to the calling of expansion person, makes the expansion of software function become convenient.
Provide device embodiment of the present invention below.
Fig. 6 is a structure drawing of device of realizing calling software module, and as shown in Figure 6, this device comprises expansion center 601, extension point carrier 602 and expansion person 603.
This device also can further comprise the expansion interface tabulation.
Described expansion interface is tabulated, and stores expansion person 603 interface.
This device further comprises expansion person supplier.
Described expansion person supplier stores expansion person's module information, is used for generating according to expansion person's module information expansion person 602 interface.
As seen from the above technical solution, the extension point carrier is by extension point interface interchange expansion person, and therefore, expansion person can be by extension point interface identification extension point carrier invoke extensions person's meaning.
Because extension point by expansion center unified management, therefore, makes to the management of extension point convenient efficient.
Because when needing the expanding software function or new intermodule call relation being set, only need extension point carrier and expansion person only need be articulated the respective extension point, can realize extension point carrier calling by the extension point interface of this extension point to expansion person, therefore, the expansion of software function becomes convenient.
The above is preferred embodiment of the present invention only, is not to be used to limit protection scope of the present invention, all any modifications of being made within the spirit and principles in the present invention, is equal to replacement, improvement etc., all should be included within protection scope of the present invention.
Claims (8)
1, a kind of method that realizes calling software module is characterized in that, this method comprises:
The expansion center is set, and at the corresponding relation of expanding central store extension point sign ID and extension point interface, extension point carrier and expansion person articulate extension point respectively;
The extension point carrier obtains the expansion hub-interface, searches extension point interface corresponding with the extension point ID of described extension point carrier in the expansion in the heart, articulates the expansion person of described extension point by described extension point interface interchange.
2, the method for claim 1 is characterized in that, described expansion person articulates extension point and comprises:
Expansion person obtains the expansion hub-interface, described expansion person's self interface is registered to waits to articulate in the expansion interface tabulation of extension point.
3, the method for claim 1 is characterized in that, described expansion person articulates extension point and comprises:
The expansion center obtains described expansion person's self module information, described module information is stored to the expansion person supplier of described extension point.
4, method as claimed in claim 2 is characterized in that, the method that articulates expansion person's module of described extension point by described extension point interface interchange comprises:
The invoke extensions point interface obtain the expansion interface function, obtain the expansion interface tabulation of described extension point, in described expansion interface tabulation, search the current invoke extensions person's for the treatment of expansion interface, call described expansion person by described expansion interface.
5, method as claimed in claim 3 is characterized in that, the method that articulates expansion person's module of described extension point by described extension point interface interchange comprises:
The invoke extensions point interface obtain the expansion interface function, obtain the expansion person supplier of described extension point, generate expansion person's expansion interface according to expansion person's module information of storing among the expansion person supplier.
6, a kind of device of realizing calling software module is characterized in that, this device comprises expansion center, extension point carrier and expansion person;
Described expansion center stores the corresponding relation of extension point ID and extension point interface;
Described extension point carrier is mounted with extension point, is used to obtain the expansion hub-interface, searches extension point interface corresponding with the extension point ID of described extension point carrier in the expansion in the heart, articulates the expansion person of described extension point by described extension point interface interchange;
Described expansion person is mounted with extension point, responds calling of described extension point carrier.
7, device as claimed in claim 6 is characterized in that, this device further comprises the expansion interface tabulation;
Described expansion interface is tabulated, and stores expansion person's interface;
Described expansion person is further used for, and obtains the expansion hub-interface, described expansion person's self interface is registered to waits to articulate in the expansion interface tabulation of extension point.
8, device as claimed in claim 6 is characterized in that, this device further comprises expansion person supplier;
Described expansion person supplier stores expansion person's module information, is used for generating according to expansion person's module information described expansion person's interface;
Described expansion person is further used for, and obtains the expansion hub-interface, described expansion person's self module information is registered to the expansion person supplier who waits to articulate extension point.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2008101262241A CN101295250B (en) | 2008-06-26 | 2008-06-26 | Method and device for calling software module |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2008101262241A CN101295250B (en) | 2008-06-26 | 2008-06-26 | Method and device for calling software module |
Publications (2)
Publication Number | Publication Date |
---|---|
CN101295250A true CN101295250A (en) | 2008-10-29 |
CN101295250B CN101295250B (en) | 2010-09-08 |
Family
ID=40065551
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN2008101262241A Active CN101295250B (en) | 2008-06-26 | 2008-06-26 | Method and device for calling software module |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101295250B (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108363614A (en) * | 2018-03-07 | 2018-08-03 | 北京恒华伟业科技股份有限公司 | A kind of business module management method, device and the server of application |
-
2008
- 2008-06-26 CN CN2008101262241A patent/CN101295250B/en active Active
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108363614A (en) * | 2018-03-07 | 2018-08-03 | 北京恒华伟业科技股份有限公司 | A kind of business module management method, device and the server of application |
CN108363614B (en) * | 2018-03-07 | 2022-04-12 | 北京恒华伟业科技股份有限公司 | Application service module management method and device and server |
Also Published As
Publication number | Publication date |
---|---|
CN101295250B (en) | 2010-09-08 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US20230018598A1 (en) | Fault detection method and device | |
KR100880536B1 (en) | Open framework system for heterogeneous computing and service integration | |
CN101286953A (en) | Medical system information integration platform | |
CN110417646A (en) | The method and device for subscribing to message are pushed based on RPC application program | |
CN102437921B (en) | Memory method and network device of configuration information | |
CN102005089A (en) | Method and system for remotely controlling intelligent card | |
CN102736578A (en) | Multifunctional intelligent home terminal system | |
CN101295250B (en) | Method and device for calling software module | |
Enugala et al. | Internet of Things—based Smart Classroom Environment | |
CN105389748A (en) | Public service system | |
CN102902574A (en) | Cooperative processing method and device of multiple information flow nodes | |
US7289027B2 (en) | Network management using suppressible RFID tags | |
CN112711396A (en) | Micro-service layered structure supporting flexible expansion | |
CN101924768A (en) | Communication control method for distribution type RFID (Radio Frequency Identification Technology) middleware | |
CN110059516A (en) | Stranger's interaction and personal belongings management system based on label technique | |
US20220037041A1 (en) | Enterprise iot system for onboarding and maintaining peripheral devices | |
US20200322293A1 (en) | Information processing system and method | |
CN108769587A (en) | A kind of calculator room equipment safety monitoring system | |
CN100531059C (en) | State synchronous system and method | |
CN109129512A (en) | The awakening method and device of chat robots | |
CN112633770A (en) | Asset state judgment method and device, storage medium and electronic equipment | |
US20070232356A1 (en) | Plagiarization-proof function for a SIM card | |
US20090210361A1 (en) | Multi-platform control system for controlling machines | |
CN104104432B (en) | A kind of optical power monitoring device and monitoring method based on ZigBee technology | |
CN112187698B (en) | Communication method, service system, electronic equipment and host MCU (micro control Unit) of electronic equipment |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant |