Method and device for integrating multiple engineering tools

By encapsulating engineering tools as plug-ins and implementing a task flow mechanism, the problem of difficult tool reuse between different projects is solved, seamless reuse and multiple execution methods are achieved, and the research and development cycle and cost are reduced.

CN114661373BActive Publication Date: 2024-08-27WIRELESS LIFE (HANGZHOU) INFORMATION TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210233452.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-10
Publication Date
2024-08-27
Estimated Expiration
2042-03-10

AI Technical Summary

Technical Problem

In the existing technology, engineering tools cannot be seamlessly reused between different projects, resulting in the need to copy code and modify the calling method, which increases the research and development cycle and labor costs.

Method used

By encapsulating engineering tools as plug-ins and implementing a task flow mechanism, it allows seamless reuse of tools between different projects, provides concurrent and serial execution methods, and solves the problems of tool replacement and calling method modification.

Benefits of technology

It achieves seamless reuse of tools between different projects, reduces secondary transformation and development costs, improves flexibility and efficiency, and meets the execution requirements of different links.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114661373B
    Figure CN114661373B
Patent Text Reader

Abstract

The present disclosure is about a method and device for integrating multiple engineering tools. The method includes: adding a plug-in configured in a project; the plug-in is formed by encapsulating an engineering tool; initializing the plug-in; obtaining a task flow name; the task flow includes multiple tasks, wherein each function implemented by the engineering tool is called a task; obtaining all task functions corresponding to the task flow from a task flow queue according to the task flow name; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow; and executing the task function according to a preset execution method. Among them, the engineering tool can be encapsulated as a plug-in, integrating and standardizing a variety of different engineering tools, and can realize seamless reuse of tools between different projects without the need for secondary transformation and development, with high flexibility.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the technical field of project development, and in particular to a method and device for integrating multiple engineering tools. Background Art

[0002] There are many links in the front-end project development process, such as project construction, detection, testing, release, etc. Each link requires the use of a variety of different engineering tools, such as webapack tools in the construction link, eslint tools in the detection link, jest tools in the testing link, less tools in the style encoding link, etc. Engineering tools are used to process the corresponding functional requirements of each link, use tools to solve the needs in the development process, and improve project development efficiency.

[0003] The commonly used solution at present is to use the calling method provided by the engineering tool to execute separately when implementing the functional requirements of the R&D stage. The calling method is the interface provided by the tool or the command line method. For example, when using eslint to detect the code, you can call the command line command "eslint--fix" provided by eslint. Different tools are required for the same stage due to different functional requirements. For example, webpack or rollup will be selected for the construction stage, and jest or mocha will be selected for testing. At present, the tool is replaced with other tools by modifying the calling method. At this time, the code that depends on the original tool needs to be modified. The same tool has the need to be reused in other projects. At present, it is achieved by copying the calling code to another project and then modifying the calling method of the corresponding stage.

[0004] The above solution has the problem that the same tools cannot be reused well between different projects. The code logic needs to be copied to another project, and the calling method and code of the corresponding link need to be modified at the same time, which wastes manpower and increases the project development cycle. Summary of the invention

[0005] In order to overcome the problems existing in the related art, the embodiments of the present disclosure provide a method and device for integrating multiple engineering tools. The technical solution is as follows:

[0006] According to a first aspect of an embodiment of the present disclosure, a method for integrating multiple engineering tools is provided, comprising:

[0007] Add the plug-in configured in the project; the plug-in is formed by encapsulating the engineering tool;

[0008] Initializing the plugin;

[0009] Obtaining a task flow name; the task flow includes a plurality of tasks, wherein each function implemented by the engineering tool is referred to as the task;

[0010] According to the task flow name, all task functions corresponding to the task flow are obtained from the task flow queue; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow;

[0011] Execute the task function according to the preset execution mode.

[0012] The technical solution provided by the embodiments of the present disclosure may include the following beneficial effects: The present disclosure provides a method for integrating multiple engineering tools, including: adding a plug-in configured in a project; the plug-in is formed by encapsulating an engineering tool; initializing the plug-in; obtaining a task flow name; the task flow includes multiple tasks, wherein each function implemented by the engineering tool is called a task; obtaining all task functions corresponding to the task flow from the task flow queue according to the task flow name; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow; and executing the task function according to a preset execution method. Among them, the engineering tool can be encapsulated as a plug-in, integrating and standardizing a variety of different engineering tools, and can realize seamless reuse of tools between different projects without the need for secondary transformation and development, with high flexibility.

[0013] In one embodiment, the adding of the plug-in configured in the project includes:

[0014] Load the plug-in configuration file, which is used to configure the plug-in registered in the project and the corresponding configuration items of the plug-in;

[0015] Serialize the configuration file to obtain the registered plug-in and parameters corresponding to the plug-in;

[0016] According to the parameters corresponding to the plug-in and the preset adding method, the plug-in is inserted into the plug-in array.

[0017] In one embodiment, the method further comprises:

[0018] Receive a task registration instruction, wherein the task registration instruction includes: a task flow name to be registered and a task function to be registered;

[0019] Detect whether the task flow queue corresponding to the task flow name to be registered already exists;

[0020] If it does not exist, create a new task flow queue;

[0021] Establishing a mapping relationship between the task flow name to be registered and the new task flow queue;

[0022] Inserting the task function to be registered into the new task flow queue;

[0023] If it exists, insert the task function to be registered into the task flow queue corresponding to the task flow name to be registered.

[0024] In one embodiment, the method further comprises:

[0025] Receive a task deletion instruction, wherein the task deletion instruction includes: a task flow name to be deleted and a task function to be deleted;

[0026] The task flow name to be deleted and the task function to be deleted are deleted from the registered task flow queue.

[0027] In one embodiment, the method further comprises:

[0028] Receive a plug-in deletion instruction, wherein the plug-in deletion instruction includes: a name of the plug-in to be deleted;

[0029] Delete the plug-in corresponding to the plug-in name to be deleted from the plug-in array.

[0030] In one embodiment, the preset execution mode includes:

[0031] Parallel execution, serial execution, or waterfall execution.

[0032] In one embodiment, creating a new task flow queue includes:

[0033] Create at the head of an existing task flow queue;

[0034] or,

[0035] Create at the end of the existing task flow queue;

[0036] or,

[0037] Created before the preset task flow queue;

[0038] or,

[0039] Created after the task flow queue is preset.

[0040] According to a second aspect of an embodiment of the present disclosure, a fusion device for multiple engineering tools is provided, comprising:

[0041] Add module, used to add plug-ins configured in the project; the plug-ins are formed by encapsulating engineering tools;

[0042] An initialization module, used to initialize the plug-in;

[0043] A name acquisition module, used to acquire a task flow name; the task flow includes a plurality of tasks, wherein each function implemented by the engineering tool is called the task;

[0044] A function acquisition module, used to acquire all task functions corresponding to the task flow from a task flow queue according to the task flow name; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow;

[0045] The execution module is used to execute the task function according to a preset execution mode.

[0046] In one embodiment, the adding module includes:

[0047] The loading submodule is used to load the plug-in configuration file, which is used to configure the plug-in registered in the project and the configuration items corresponding to the plug-in;

[0048] A serialization submodule, used to serialize the configuration file to obtain the registered plug-in and the parameters corresponding to the plug-in;

[0049] The plug-in inserting submodule is used to insert the plug-in into the plug-in array according to the parameters corresponding to the plug-in and the preset adding method.

[0050] In one embodiment, the apparatus further comprises:

[0051] The task registration instruction receiving module is used to receive the task registration instruction, wherein the task registration instruction includes: the task flow name to be registered and the task function to be registered;

[0052] A detection module, used to detect whether the task flow queue corresponding to the task flow name to be registered already exists;

[0053] A creation module, configured to create a new task flow queue when the detection module detects that the task flow queue corresponding to the task flow name to be registered does not exist;

[0054] An establishing module, used to establish a mapping relationship between the task flow name to be registered and the new task flow queue;

[0055] A first function insertion module, used for inserting the task function to be registered into the new task flow queue;

[0056] The second function insertion module is used to insert the task function to be registered into the task flow queue corresponding to the task flow name to be registered when the detection module detects that the task flow queue corresponding to the task flow name to be registered exists.

[0057] In one embodiment, the apparatus further comprises:

[0058] The task deletion instruction receiving module is used to receive the task deletion instruction, wherein the task deletion instruction includes: the name of the task flow to be deleted and the task function to be deleted;

[0059] The deleting module is used to delete the task flow name to be deleted and the task function to be deleted in the registered task flow queue.

[0060] In one embodiment, the apparatus further comprises:

[0061] A plug-in deletion instruction receiving module, used to receive a plug-in deletion instruction, wherein the plug-in deletion instruction includes: a name of the plug-in to be deleted;

[0062] The plug-in deletion module is used to delete the plug-in corresponding to the plug-in name to be deleted in the plug-in array.

[0063] In one embodiment, the preset execution mode includes:

[0064] Parallel execution, serial execution, or waterfall execution.

[0065] In one embodiment, the creation module includes: a first creation submodule;

[0066] The first creation submodule is used to create at the head of an existing task flow queue;

[0067] or,

[0068] The first creation submodule is used to create at the tail of the existing task flow queue;

[0069] or,

[0070] The first creation submodule is used to create before the preset task flow queue;

[0071] or,

[0072] The first creation submodule is used to create after the task flow queue is preset.

[0073] According to a third aspect of an embodiment of the present disclosure, a fusion device for multiple engineering tools is provided, comprising:

[0074] processor;

[0075] a memory for storing processor-executable instructions;

[0076] Wherein, the processor is configured to:

[0077] Add the plug-in configured in the project; the plug-in is formed by encapsulating the engineering tool;

[0078] Initializing the plugin;

[0079] Obtaining a task flow name; the task flow includes a plurality of tasks, wherein each function implemented by the engineering tool is referred to as the task;

[0080] According to the task flow name, all task functions corresponding to the task flow are obtained from the task flow queue; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow;

[0081] Execute the task function according to the preset execution mode.

[0082] According to a fourth aspect of an embodiment of the present disclosure, there is provided a computer-readable storage medium on which computer instructions are stored, and when the instructions are executed by a processor, the steps of any one of the methods described in the first aspect are implemented.

[0083] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0084] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.

[0085] Figure 1 The figure is a flow chart of a method for integrating multiple engineering tools according to an exemplary embodiment.

[0086] Figure 2 It is a flowchart of step S101 in the method for integrating multiple engineering tools according to an exemplary embodiment.

[0087] Figure 3 It is a module diagram of an application of an embodiment of the present disclosure according to an exemplary embodiment.

[0088] Figure 4 The figure is a flowchart of a registration task according to an exemplary embodiment.

[0089] Figure 5 The figure is a flowchart of performing a task according to an exemplary embodiment.

[0090] Figure 6 is a flowchart of a registration part according to an exemplary embodiment.

[0091] Figure 7 is a flowchart of an initialization part according to an exemplary embodiment.

[0092] Figure 8 It is a flowchart showing an execution part according to an exemplary embodiment.

[0093] Fig. 9 It is a block diagram of a device for fusing multiple engineering tools according to an exemplary embodiment.

[0094] Fig.10 It is a block diagram of adding a module in a fusion device of multiple engineering tools according to an exemplary embodiment.

[0095] Fig.11 is a block diagram showing a fusion 90 of multiple engineering tools according to an exemplary embodiment. DETAILED DESCRIPTION

[0096] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Instead, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.

[0097] Figure 1 is a flow chart of a method for integrating multiple engineering tools according to an exemplary embodiment. Figure 1 As shown, the following steps S101-S105 are included:

[0098] In step S101, add the plug-in configured in the project; the plug-in is formed by encapsulating the engineering tool;

[0099] The method in the present disclosure can be implemented through different modules (service module, task flow module, plug-in and plug-in management module), which is described in detail in the following embodiments.

[0100] In this step, the service module can add the plug-ins configured in the project.

[0101] In one embodiment, Figure 2 As shown, the above step S101 includes the following sub-steps S1011-1013:

[0102] In step S1011, a plug-in configuration file is loaded, where the configuration file is used to configure the plug-in registered in the project and the configuration items corresponding to the plug-in;

[0103] In step S1012, the configuration file is serialized to obtain the registered plug-in and the parameters corresponding to the plug-in;

[0104] In step S1013, the plug-in is inserted into the plug-in array according to the parameters corresponding to the plug-in and the preset adding method.

[0105] Specifically, the service module first loads the plug-in configuration file, which is used to configure the plug-ins registered in the project and the corresponding configuration items of the plug-ins. After the service module serializes the configuration file, it obtains the registered plug-ins and corresponding parameters. The service module initializes the task flow module and the plug-in management module in turn, and injects the service module instance into the two modules as initialization parameters. The service module binds the two module instances to the service module instance. The service module traverses the registered plug-ins and calls the add method of the plug-in management module in turn, adding the plug-in to the plug-in array of the plug-in manager.

[0106] Specifically, the plug-in management module will pass in the plug-in configuration parameters and the service module instance, instantiate the plug-in, obtain the plug-in instance, and the plug-in management module will insert the plug-in instance into the plug-in array.

[0107] In step S102, the plug-in is initialized;

[0108] Continuing with the above example, the service module calls the initialization method of the plug-in management module to initialize all plug-ins.

[0109] Specifically, the service module traverses the registered plug-ins and calls the initialization method of the plug-in management module in turn. The plug-in management module traverses all instances in the plug-in array and executes the initialization method of the plug-in instance in turn. Then, the plug-in obtains the task flow module instance through the service module instance, calls the registration method, and registers the task.

[0110] In step S103, a task flow name is obtained; the task flow includes multiple tasks, wherein each function implemented by the engineering tool is called a task;

[0111] The service module obtains the name of the task flow to be executed based on the command line parameters called by the developer.

[0112] In step S104, all task functions corresponding to the task flow are obtained from the task flow queue according to the task flow name; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow.

[0113] The service module calls the task function of the task flow module according to the task flow name.

[0114] In step S105, the task function is executed according to a preset execution mode.

[0115] In one implementation, the task functions may be executed in parallel, serially, or in a waterfall flow.

[0116] In the related technology, there is also a need to execute multiple tools in the same link. For example, the detection link needs to execute eslint and stylelint at the same time. Currently, the command lines are executed in sequence or the code is called in sequence. The present invention can implement a task flow mechanism to provide concurrent and serial execution methods. The engineering tool subscribes to the corresponding task flow, so that the same task flow can execute multiple engineering tools concurrently or serially, which solves the problem that the code needs to be modified and the calling method needs to be changed when executing multiple tasks in the same link. At the same time, it provides multiple execution methods to meet the different execution requirements of different links.

[0117] The present disclosure provides a method for integrating multiple engineering tools, including: adding a plug-in configured in a project; the plug-in is formed by encapsulating an engineering tool; initializing the plug-in; obtaining a task flow name; the task flow includes multiple tasks, wherein each function implemented by the engineering tool is called a task; obtaining all task functions corresponding to the task flow from a task flow queue according to the task flow name; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow; and executing the task function according to a preset execution method. Among them, the engineering tool can be encapsulated as a plug-in, integrating and standardizing a variety of different engineering tools, and can realize seamless reuse of tools between different projects without the need for secondary transformation and development, with high flexibility.

[0118] In the present disclosure, it is also necessary to register a task. When registering a task, a unique name and a task queue are defined for each task flow. When registering a task, the task flow name and task function are passed in, and the task function is placed in the task queue. Specifically, registering a task includes the following steps A1-A6:

[0119] A1. Receive a task registration instruction, which includes: the name of the task flow to be registered and the task function to be registered;

[0120] A2. Check whether the task flow queue corresponding to the task flow name to be registered already exists;

[0121] A3. If it does not exist, create a new task flow queue;

[0122] A4. Establish a mapping relationship between the task flow name to be registered and the new task flow queue;

[0123] A5. Insert the task function to be registered into the new task flow queue;

[0124] A6. If it exists, insert the task function to be registered into the task flow queue corresponding to the task flow name to be registered.

[0125] Among them, creating a new task flow queue includes:

[0126] Create at the head of an existing task flow queue;

[0127] or,

[0128] Create at the end of the existing task flow queue;

[0129] or,

[0130] Created before the preset task flow queue;

[0131] or,

[0132] Created after the task flow queue is preset.

[0133] When a task flow does not need to be registered, the delete task method can be called, and the task flow name and task function can be passed in to delete the registered task. In one embodiment, deleting a task includes the following steps B1-B2:

[0134] B1. Receive a task deletion instruction, which includes: the name of the task flow to be deleted and the task function to be deleted;

[0135] B2. Delete the task flow name and task function to be deleted from the registered task flow queue.

[0136] In one embodiment, the method further comprises C1-C2:

[0137] C1. Receive a plug-in deletion instruction, where the plug-in deletion instruction includes: the name of the plug-in to be deleted;

[0138] C2. Delete the plug-in corresponding to the plug-in name to be deleted in the plug-in array.

[0139] Pass in the plug-in name, find the corresponding plug-in instance according to the plug-in name, and delete the plug-in instance from the plug-in array.

[0140] The implementation process is described in detail below through several embodiments.

[0141] Figure 3 is a module diagram of an application of an embodiment of the present disclosure according to an exemplary embodiment, such as Figure 3 As shown, the technical solution is divided into three modules from the functional module, namely, task flow module, plug-in and plug-in management module, and service module. The task flow module is responsible for the registration and execution of tasks; the plug-in and plug-in management module is responsible for defining the plug-in specifications and managing the addition, deletion and execution of plug-ins; the service module is responsible for connecting the task flow module and the plug-in management module and controlling the execution timing of the plug-in, etc. The following is a detailed description of the three modules:

[0142] 1. Task flow module

[0143] The engineering tools in the R&D stage are executed in sequence. Each function implemented by the engineering tools is called a task, which corresponds to a function in the code implementation. The execution of multiple tasks in sequence is called a task flow. A name is defined for each task flow. For example, the construction task flow is build, and the detection task flow is lint. Multiple tasks can be executed concurrently or serially in a task flow. For example, the detection task flow can execute eslint, stylelint and other detection tasks serially.

[0144] The task flow module is responsible for managing the process of adding and executing tasks. The task flow module defines three methods: registering tasks, deleting tasks, and executing tasks. The service module is responsible for instantiating the module and executing tasks. After instantiation, the task flow module instance is mounted in the current instance of the service module. Finally, the service module instance will be injected into the plug-in. The plug-in can call the registration task method to register the corresponding task flow. The following is a detailed description of the three methods:

[0145] 1. Register tasks: define a unique name and task queue for each task flow. When registering a task, pass in the task flow name and task function. The task function is placed in the task queue. The registration methods include registering at the head of the queue, registering at the tail of the queue, registering before a task, and registering after a task. For example, Figure 4 shown.

[0146] 2. Delete task: When you do not need to register to a task flow, you can call the delete task method, pass in the task flow name and task function, and then you can delete the registered task.

[0147] 3. Execute tasks: Pass in the task flow name to execute all the task functions of the task flow. The execution modes include parallel execution, serial execution, and waterfall execution (the next task depends on the return result of the previous task), such as Figure 5 shown.

[0148] 2. Plug-ins and plug-in management module

[0149] The plug-in module defines an abstract plug-in class, which encapsulates various engineering tools as plug-ins. For example, the eslint tool is encapsulated as an eslint plug-in. The abstract plug-in class standardizes the plug-in specification and defines the initialization abstract method. The service module instance is injected into the plug-in class as a parameter, and the plug-in can call the relevant methods on the service module instance. The plug-in must inherit the abstract plug-in class and implement the initialization abstract method. In the initialization method, the plug-in can obtain the registration method on the task flow module instance through the service module instance to register the task.

[0150] The plugin management module includes methods for adding plugins, deleting plugins, and initializing plugins. The plugin management module is instantiated in the service module. During instantiation, the current instance of the service module will be injected into the plugin management module. The plugin management module will eventually inject the service module instance into the plugin. The following is a detailed description of the three methods:

[0151] 1. Add plug-in method: pass in the plug-in module and corresponding configuration parameters, inject the service module instance into the plug-in as a parameter, instantiate the plug-in to get the plug-in instance, and insert it into the plug-in array.

[0152] 2. Delete plug-in method: pass in the plug-in name, find the corresponding instance according to the name, and delete the instance from the plug-in array.

[0153] 3. Initialize plugin method: Initialize all plugins. This method is called by the service module. The specific steps are as follows:

[0154] a) Traverse all instances in the plugin array and execute the initialization method of the plugin instance in turn.

[0155] b) In the plug-in initialization method, the registration method on the task flow module instance can be obtained through the service module instance to register the task.

[0156] 3. Service Module

[0157] The service module is used to initialize the task flow module and the plug-in management module and execute plug-ins. It is mainly divided into three parts: registration, initialization, and execution. The following is a detailed introduction to the three parts:

[0158] 1. The registration part is used to add the plug-ins configured in the project. The specific steps are as follows. The overall process is as follows Figure 6 As shown:

[0159] a) First load the plug-in configuration file, which is used to configure the plug-in registered in the project and the corresponding configuration items of the plug-in.

[0160] b) After serializing the configuration file, get the registered plug-ins and corresponding parameters.

[0161] c) Initialize the task flow module and the plug-in management module in sequence, and inject the service module instance into the two modules as initialization parameters.

[0162] d) Bind the two module instances to the service module instance.

[0163] e) Traverse the registered plug-ins and call the add method of the plug-in management module in turn to add the plug-in to the plug-in manager.

[0164] 2. The initialization part calls the initialization method of the plug-in management module to initialize all plug-ins. The overall process is as follows Figure 7 shown.

[0165] 3. The execution part is used to execute the task flow. The specific steps are as follows. The overall process is as follows Figure 8 As shown:

[0166] a) Get the name of the task flow to be executed based on the command line parameters called by the developer;

[0167] b) Call the execution method of the task flow module according to the task flow name.

[0168] The present disclosure defines an abstract plug-in that standardizes a variety of different engineering tools, which can integrate different engineering tools and achieve seamless reuse of tools between different projects without the need for secondary transformation and development, with high flexibility. Further, the present disclosure implements a set of task flow mechanisms, in which each link corresponds to a different task flow in turn, and the engineering tool registers the corresponding task flow. Multiple engineering tools can be executed concurrently or serially under the same task flow, and the same function in the same task flow can also be implemented using different tools, which can realize the pluggability of engineering tools.

[0169] The main advantages of the present invention are as follows:

[0170] 1. Define a plug-in model, encapsulate engineering tools into corresponding plug-ins, integrate and standardize a variety of different engineering tools, and achieve seamless reuse of tools between different projects without the need for secondary transformation and development, with high flexibility.

[0171] 2. The plug-in configuration file can be used to conveniently define the engineering tools required for the project. To add, delete, or adjust the execution order, you only need to modify the configuration file, and the modification cost is low.

[0172] 3. Implement a task flow mechanism to provide concurrent and serial execution modes. Engineering tools can subscribe to the corresponding task flow to implement the same task flow for multiple engineering tools to execute concurrently or serially. This solves the problem of having to modify the code and change the calling method to execute multiple tasks in the same link. At the same time, it provides multiple execution modes to meet the different execution needs of different links.

[0173] The following are embodiments of the apparatus of the present disclosure, which can be used to execute embodiments of the method of the present disclosure.

[0174] Fig. 9 is a block diagram of a device for integrating multiple engineering tools according to an exemplary embodiment. The device can be implemented as part or all of an electronic device through software, hardware, or a combination of both. Fig. 9 As shown, the fusion device of the multiple engineering tools includes:

[0175] An adding module 11 is used to add a plug-in configured in the project; the plug-in is formed by encapsulating an engineering tool;

[0176] An initialization module 12, used to initialize the plug-in;

[0177] A name acquisition module 13 is used to acquire a task flow name; the task flow includes a plurality of tasks, wherein each function implemented by the engineering tool is called a task;

[0178] The function acquisition module 14 is used to acquire all task functions corresponding to the task flow from the task flow queue according to the task flow name; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow;

[0179] The execution module 15 is used to execute the task function according to a preset execution mode.

[0180] In one embodiment, Fig.10 As shown, the adding module 11 includes:

[0181] The loading submodule 111 is used to load a plug-in configuration file, wherein the configuration file is used to configure the plug-in registered in the project and the configuration items corresponding to the plug-in;

[0182] The serialization submodule 112 is used to serialize the configuration file to obtain the registered plug-in and the parameters corresponding to the plug-in;

[0183] The plug-in inserting submodule 113 is used to insert the plug-in into the plug-in array according to the parameters corresponding to the plug-in and the preset adding method.

[0184] In one embodiment, the apparatus further comprises:

[0185] The task registration instruction receiving module is used to receive the task registration instruction, wherein the task registration instruction includes: the task flow name to be registered and the task function to be registered;

[0186] A detection module, used to detect whether the task flow queue corresponding to the task flow name to be registered already exists;

[0187] A creation module, configured to create a new task flow queue when the detection module detects that the task flow queue corresponding to the task flow name to be registered does not exist;

[0188] An establishing module, used to establish a mapping relationship between the task flow name to be registered and the new task flow queue;

[0189] A first function insertion module, used for inserting the task function to be registered into the new task flow queue;

[0190] The second function insertion module is used to insert the task function to be registered into the task flow queue corresponding to the task flow name to be registered when the detection module detects that the task flow queue corresponding to the task flow name to be registered exists.

[0191] In one embodiment, the apparatus further comprises:

[0192] The task deletion instruction receiving module is used to receive the task deletion instruction, wherein the task deletion instruction includes: the name of the task flow to be deleted and the task function to be deleted;

[0193] The deleting module is used to delete the task flow name to be deleted and the task function to be deleted in the registered task flow queue.

[0194] In one embodiment, the apparatus further comprises:

[0195] A plug-in deletion instruction receiving module, used to receive a plug-in deletion instruction, wherein the plug-in deletion instruction includes: a name of the plug-in to be deleted;

[0196] The plug-in deletion module is used to delete the plug-in corresponding to the plug-in name to be deleted in the plug-in array.

[0197] In one embodiment, the preset execution mode includes:

[0198] Parallel execution, serial execution, or waterfall execution.

[0199] In one embodiment, the creation module includes: a first creation submodule;

[0200] The first creation submodule is used to create at the head of an existing task flow queue;

[0201] or,

[0202] The first creation submodule is used to create at the tail of the existing task flow queue;

[0203] or,

[0204] The first creation submodule is used to create before the preset task flow queue;

[0205] or,

[0206] The first creation submodule is used to create after the task flow queue is preset.

[0207] According to a third aspect of an embodiment of the present disclosure, a fusion device for multiple engineering tools is provided, comprising:

[0208] processor;

[0209] a memory for storing processor-executable instructions;

[0210] The processor is configured as follows:

[0211] Add the plug-in configured in the project; the plug-in is formed by encapsulating the engineering tool;

[0212] Initializing the plugin;

[0213] Obtaining a task flow name; the task flow includes a plurality of tasks, wherein each function implemented by the engineering tool is referred to as the task;

[0214] According to the task flow name, all task functions corresponding to the task flow are obtained from the task flow queue; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow;

[0215] Execute the task function according to the preset execution mode.

[0216] The above processor may also be configured to:

[0217] The plugins configured in the added project include:

[0218] Load the plug-in configuration file, which is used to configure the plug-in registered in the project and the corresponding configuration items of the plug-in;

[0219] Serialize the configuration file to obtain the registered plug-in and parameters corresponding to the plug-in;

[0220] According to the parameters corresponding to the plug-in and the preset adding method, the plug-in is inserted into the plug-in array.

[0221] In one embodiment, the processor may be further configured to:

[0222] Receive a task registration instruction, wherein the task registration instruction includes: a task flow name to be registered and a task function to be registered;

[0223] Detect whether the task flow queue corresponding to the task flow name to be registered already exists;

[0224] If it does not exist, create a new task flow queue;

[0225] Establishing a mapping relationship between the task flow name to be registered and the new task flow queue;

[0226] Inserting the task function to be registered into the new task flow queue;

[0227] If it exists, insert the task function to be registered into the task flow queue corresponding to the task flow name to be registered.

[0228] In one embodiment, the processor may be further configured to:

[0229] Receive a task deletion instruction, wherein the task deletion instruction includes: a task flow name to be deleted and a task function to be deleted;

[0230] The task flow name to be deleted and the task function to be deleted are deleted from the registered task flow queue.

[0231] In one embodiment, the processor may be further configured to:

[0232] Receive a plug-in deletion instruction, wherein the plug-in deletion instruction includes: a name of the plug-in to be deleted;

[0233] Delete the plug-in corresponding to the plug-in name to be deleted from the plug-in array.

[0234] In one embodiment, the preset execution mode includes:

[0235] Parallel execution, serial execution, or waterfall execution.

[0236] In one embodiment, creating a new task flow queue includes:

[0237] Create at the head of an existing task flow queue;

[0238] or,

[0239] Create at the end of the existing task flow queue;

[0240] or,

[0241] Created before the preset task flow queue;

[0242] or,

[0243] Created after the task flow queue is preset.

[0244] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0245] Fig.11is a block diagram of a fusion 90 for multiple engineering tools according to an exemplary embodiment. For example, the device 90 can be provided as a server. The device 90 includes a processing component 902, which further includes one or more processors, and a memory resource represented by a memory 903 for storing instructions that can be executed by the processing component 902, such as an application. The application stored in the memory 903 can include one or more modules, each of which corresponds to a set of instructions. In addition, the processing component 902 is configured to execute instructions to perform the above method.

[0246] The device 90 may also include a power supply component 906 configured to perform power management of the device 90, a wired or wireless network interface 905 configured to connect the device 90 to a network, and an input / output (I / O) interface 908. The device 90 may operate based on an operating system stored in the memory 903, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™ or the like.

[0247] A non-transitory computer-readable storage medium, when the instructions in the storage medium are executed by the processor of the device 90, enables the device 90 to perform the method of integrating the above-mentioned multiple engineering tools, the method comprising:

[0248] Add the plug-in configured in the project; the plug-in is formed by encapsulating the engineering tool;

[0249] Initializing the plugin;

[0250] Obtaining a task flow name; the task flow includes a plurality of tasks, wherein each function implemented by the engineering tool is referred to as the task;

[0251] According to the task flow name, all task functions corresponding to the task flow are obtained from the task flow queue; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow;

[0252] Execute the task function according to the preset execution mode.

[0253] In one embodiment, the adding of the plug-in configured in the project includes:

[0254] Load the plug-in configuration file, which is used to configure the plug-in registered in the project and the corresponding configuration items of the plug-in;

[0255] Serialize the configuration file to obtain the registered plug-in and parameters corresponding to the plug-in;

[0256] According to the parameters corresponding to the plug-in and the preset adding method, the plug-in is inserted into the plug-in array.

[0257] In one embodiment, the method further comprises:

[0258] Receive a task registration instruction, wherein the task registration instruction includes: a task flow name to be registered and a task function to be registered;

[0259] Detect whether the task flow queue corresponding to the task flow name to be registered already exists;

[0260] If it does not exist, create a new task flow queue;

[0261] Establishing a mapping relationship between the task flow name to be registered and the new task flow queue;

[0262] Inserting the task function to be registered into the new task flow queue;

[0263] If it exists, insert the task function to be registered into the task flow queue corresponding to the task flow name to be registered.

[0264] In one embodiment, the method further comprises:

[0265] Receive a task deletion instruction, wherein the task deletion instruction includes: a task flow name to be deleted and a task function to be deleted;

[0266] The task flow name to be deleted and the task function to be deleted are deleted from the registered task flow queue.

[0267] In one embodiment, the method further comprises:

[0268] Receive a plug-in deletion instruction, wherein the plug-in deletion instruction includes: a name of the plug-in to be deleted;

[0269] Delete the plug-in corresponding to the plug-in name to be deleted from the plug-in array.

[0270] In one embodiment, the preset execution mode includes:

[0271] Parallel execution, serial execution, or waterfall execution.

[0272] In one embodiment, creating a new task flow queue includes:

[0273] Create at the head of an existing task flow queue;

[0274] or,

[0275] Create at the end of the existing task flow queue;

[0276] or,

[0277] Created before the preset task flow queue;

[0278] or,

[0279] Created after the task flow queue is preset.

[0280] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the present disclosure that follow the general principles of the present disclosure and include common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The description and examples are intended to be exemplary only, and the true scope and spirit of the present disclosure are indicated by the following claims.

[0281] It should be understood that the present disclosure is not limited to the exact structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims

1. A method for integrating multiple engineering tools, characterized in that: include: Add the plugin configured in the project; The plug-in is formed by encapsulating the engineering tool; Initializing the plugin; Get the task flow name; The task flow includes a plurality of tasks, wherein each function implemented by the engineering tool is referred to as the task; According to the task flow name, all task functions corresponding to the task flow are obtained from the task flow queue; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow; Execute the task function according to a preset execution mode; The method further comprises: Receive a task registration instruction, wherein the task registration instruction includes: a task flow name to be registered and a task function to be registered; Detect whether the task flow queue corresponding to the task flow name to be registered already exists; If it does not exist, create a new task flow queue; Establishing a mapping relationship between the task flow name to be registered and the new task flow queue; Inserting the task function to be registered into the new task flow queue; If it exists, insert the task function to be registered into the task flow queue corresponding to the task flow name to be registered.

2. The method according to claim 1, characterized in that The plugins configured in the added project include: Load the plug-in configuration file, which is used to configure the plug-in registered in the project and the corresponding configuration items of the plug-in; Serialize the configuration file to obtain the registered plug-in and parameters corresponding to the plug-in; According to the parameters corresponding to the plug-in and the preset adding method, the plug-in is inserted into the plug-in array.

3. The method according to claim 1, characterized in that The method further comprises: Receive a task deletion instruction, wherein the task deletion instruction includes: a task flow name to be deleted and a task function to be deleted; The task flow name to be deleted and the task function to be deleted are deleted from the registered task flow queue.

4. The method according to claim 2, characterized in that: The method further comprises: Receive a plug-in deletion instruction, wherein the plug-in deletion instruction includes: a name of the plug-in to be deleted; Delete the plug-in corresponding to the plug-in name to be deleted from the plug-in array.

5. The method according to claim 1, characterized in that The preset execution mode includes: Parallel execution, serial execution, or waterfall execution.

6. The method according to claim 1, characterized in that The creating of a new task flow queue comprises: Create at the head of an existing task flow queue; or, Create at the end of the existing task flow queue; or, Created before the preset task flow queue; or, Created after the task flow queue is preset.

7. A fusion device for multiple engineering tools, characterized in that: include: Add module to add plugins configured in the project; The plug-in is formed by encapsulating the engineering tool; An initialization module, used to initialize the plug-in; A name acquisition module, used to acquire a task flow name; the task flow includes a plurality of tasks, wherein each function implemented by the engineering tool is called the task; A function acquisition module, used to acquire all task functions corresponding to the task flow from a task flow queue according to the task flow name; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow; An execution module, used to execute the task function according to a preset execution mode; Also includes registration modules for: Receive a task registration instruction, wherein the task registration instruction includes: a task flow name to be registered and a task function to be registered; Detect whether the task flow queue corresponding to the task flow name to be registered already exists; If it does not exist, create a new task flow queue; Establishing a mapping relationship between the task flow name to be registered and the new task flow queue; Inserting the task function to be registered into the new task flow queue; If it exists, insert the task function to be registered into the task flow queue corresponding to the task flow name to be registered.

8. A fusion device for multiple engineering tools, characterized in that: include: processor; a memory for storing processor-executable instructions; Wherein, the processor is configured to: Add the plug-in configured in the project; the plug-in is formed by encapsulating the engineering tool; Initializing the plugin; Obtaining a task flow name; the task flow includes a plurality of tasks, wherein each function implemented by the engineering tool is referred to as the task; According to the task flow name, all task functions corresponding to the task flow are obtained from the task flow queue; the task function is used to implement the task; the task flow queue includes: a mapping relationship between the task flow name and all task functions corresponding to the task flow; Execute the task function according to a preset execution mode; Also includes: Receive a task registration instruction, wherein the task registration instruction includes: a task flow name to be registered and a task function to be registered; Detect whether the task flow queue corresponding to the task flow name to be registered already exists; If it does not exist, create a new task flow queue; Establishing a mapping relationship between the task flow name to be registered and the new task flow queue; Inserting the task function to be registered into the new task flow queue; If it exists, insert the task function to be registered into the task flow queue corresponding to the task flow name to be registered.

9. A computer-readable storage medium having computer instructions stored thereon, characterized in that: When the instruction is executed by a processor, the steps of the method described in any one of claims 1 to 6 are implemented.