Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Plug-in calling method and device based on a micro-kernel architecture

A microkernel and plug-in technology, applied in the computer field, can solve problems such as poor versatility, achieve the effect of less repetition, improve experience and efficiency, and improve versatility

Active Publication Date: 2019-05-31
WUHAN JINGLI ELECTRONICS TECH +1
View PDF9 Cites 2 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0006] In view of this, the embodiment of the present invention provides a plug-in calling method and device based on microkernel architecture, to solve or at least partly solve the technical problem of poor versatility existing in the prior art

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Plug-in calling method and device based on a micro-kernel architecture
  • Plug-in calling method and device based on a micro-kernel architecture
  • Plug-in calling method and device based on a micro-kernel architecture

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0050] This embodiment provides a method for invoking a plug-in based on a microkernel architecture. The microkernel architecture includes a plug-in module and a core system. Please refer to figure 2 , the method includes:

[0051] Step S1: inheriting all the plug-ins in the plug-in module from a preset parent class, and setting a type judgment method in the preset parent class, and the type judgment method is used to judge whether a specific object is an object of a certain class.

[0052] Specifically, all plugins inherit the default parent class, that is, the default parent class IPlugin is the parent class of the plugin class corresponding to all plugins. The type judgment method isPlugin is specifically used to judge whether a specific object is an object of a certain class.

[0053] In the specific implementation process, the implementation of isPlugin is as follows:

[0054] virtual bool isPlugin(const char*className)

[0055] Among them, isPlugin is the method name...

Embodiment 2

[0088] This embodiment provides a plug-in invocation device based on a microkernel architecture, where the microkernel architecture includes a plug-in module and a core system. Please refer to image 3 , the device includes:

[0089] The preset parent class setting module 301 is used to inherit all the plugins in the plugin module from the preset parent class, and set a type judgment method in the preset parent class, and the type judgment method is used to judge whether a specific object is a certain object. an object of a class;

[0090] The source code analysis module 302 is used to analyze the source codes of all the plug-ins, and obtain the inheritance relationship between the plug-ins;

[0091] The code automatic generation module 303 is used to generate the implementation code of the type judgment method corresponding to each plug-in according to the inheritance relationship between the plug-ins;

[0092] The security conversion module 304 is used to perform security ...

Embodiment 3

[0105] This embodiment provides a computer-readable storage medium 300 on which a computer program 311 is stored, and when the program is executed, implements the method described in the first embodiment.

[0106] Since the computer-readable storage medium introduced in the third embodiment of the present invention is a computer device used to implement the method for invoking a plug-in based on the microkernel architecture in the first embodiment of the present invention, the method based on the first embodiment of the present invention is well known in the art. Those who belong to it can understand the specific structure and deformation of the computer-readable storage medium, so it is not repeated here. All computer-readable storage media used in the method in Embodiment 1 of the present invention belong to the scope of protection of the present invention.

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention provides a plug-in calling method and device based on a micro-kernel architecture. The method comprises the steps that firstly, all plugins in a plugin module inherit a preset parent class, a type judgment method is set in the preset parent class, source codes of all the plugins are analyzed, the inheritance relation among the plugins is obtained, and then implementation codes of thetype judgment method corresponding to the plugins are generated according to the inheritance relation among the plugins; And when plug-in calling is carried out, a type judgment method correspondingto the target plug-in is called through the core system to carry out safety judgment, if the type judgment method is safe, conversion from the parent class to the sub-class is carried out, and then the target plug-in is called based on a conversion result. According to the method and the device, the technical effects of calling the universal plug-in independent of the RTTI and improving the calling efficiency are achieved.

Description

technical field [0001] The present invention relates to the technical field of computers, in particular to a method and device for invoking a plug-in based on a microkernel architecture. Background technique [0002] The microkernel architecture, sometimes referred to as the plug-in architecture pattern, consists of two components: the core system and plug-in modules. Application logic is split into independent plug-in modules and core systems, providing scalability, flexibility, functional isolation, and custom processing logic features. The microkernel architecture is widely used, and the more famous plug-in architecture products are Eclipse and Firefox. [0003] During the software development process, a plug-in inevitably needs to call the function of another plug-in, so it needs to obtain the object of the other plug-in. For example, as figure 1 As shown, it is a schematic diagram of the inheritance relationship between plugins. IPlugin is the parent class of CameraP...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
IPC IPC(8): G06F9/445
Inventor 郭治军刘银森郜鹏肖威
Owner WUHAN JINGLI ELECTRONICS TECH
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products