Visual programming method and device, equipment and storage medium

Through Qt plug-in and meta-information technology, the problem of high coupling between visual programming platform and functional nodes in the existing technology is solved, and the ability to dynamically increase functional nodes without modifying the source code and deploying the development environment is realized, and the ability to dynamically increase functional nodes is improved. Programming efficiency and flexibility.

CN119225710APending Publication Date: 2024-12-31SHINING 3D TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310793011.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-06-29
Publication Date
2024-12-31

AI Technical Summary

Technical Problem

The existing visual programming platform needs to modify the source code and recompile when adding functional nodes. It has high coupling and affects efficiency. In addition, the development of functional nodes requires the deployment of development environments to limit flexibility.

Method used

Through Qt plug-in and meta-information technology, low-coupling development between the visual programming platform and functional nodes is realized, allowing functional nodes to be independently developed and loaded without modifying the platform source code and deploying the development environment, and new nodes are dynamically added.

Benefits of technology

It effectively reduces the coupling between the visual programming platform and functional nodes, improves the flexibility and programming efficiency of node development, and realizes the ability to call node function functions without including node function header files.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119225710A_ABST
    Figure CN119225710A_ABST
Patent Text Reader

Abstract

The invention relates to a visual programming method and device, equipment and a storage medium, and the visual programming method comprises the steps: reading a target plug-in, and loading the target plug-in, the target plug-in comprising meta information of at least one function node; generating a node list based on the meta-information of each function node, and displaying the node list, the node list comprising description information of each function node; in response to a trigger operation of description information of a target function node in the node list, displaying a graph of the target function node; and generating a connection graph comprising the graph of the target function node, and running the connection graph to generate a target program. According to the method provided by the invention, the coupling degree of the visual programming platform and the function nodes is effectively reduced, the node development flexibility is improved, and the visual programming efficiency is further improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of research and development management, and in particular to a visual programming method, device, equipment and storage medium. Background Art

[0002] At present, visual programming is widely used in R&D management. Visual programming is also called visual program design. It takes the principle of "what you see is what you get" programming and strives to realize the visualization of programming work, that is, the results can be seen at any time, and the adjustment of the program and the results is synchronized. Visual programming allows program developers to use the various nodes provided by the visual programming platform software itself to complete specific functional processes like building blocks. With the help of the visual programming platform, users do not need to write code or even have a lot of grammar knowledge and application programming interface (API) knowledge to realize some functions.

[0003] In existing visual programming platforms, function nodes are usually expanded through source code. However, each time a new function node is added, the source code needs to be modified and recompiled before the new function node can be used. The development of the visual programming platform itself and the development of the function node are highly coupled, and adding new nodes is more troublesome. At the same time, the developers of the function nodes also need to deploy the development environment of the visual programming platform before they can develop the function nodes. There are many restrictions on node development, which in turn affects the efficiency of visual programming. Summary of the invention

[0004] In order to solve the above technical problems, the embodiments of the present disclosure provide a visual programming method, apparatus, device and storage medium, which effectively reduce the coupling degree between the visual programming platform and the functional nodes, improve the flexibility of node development, and thus improve the efficiency of visual programming.

[0005] In a first aspect, an embodiment of the present disclosure provides a visual programming method, including:

[0006] Reading a target plug-in and loading the target plug-in, wherein the target plug-in includes meta information of at least one functional node;

[0007] Generate a node list based on the meta information of each functional node, and display the node list, wherein the node list includes description information of each functional node;

[0008] In response to a triggering operation of the description information of the target function node in the node list, displaying a graph of the target function node;

[0009] A connection graph including the graph of the target function node is generated, and the connection graph is run to generate a target program.

[0010] Optionally, before reading the target plug-in, the method further includes:

[0011] Obtaining basic functions that need to be inherited and functional functions that need to be implemented by the functional node to be developed, wherein the functional functions include an acquisition function, an input function, an output function, and an execution function;

[0012] Developing the function node according to the basic function and the function function;

[0013] An initial plug-in is created based on the basic function, and an instance of the function node is returned through a slot function to store meta information of the function node in the initial plug-in, thereby obtaining a target plug-in.

[0014] Optionally, the generating a node list based on the meta information of each functional node and displaying the node list, wherein the node list includes description information of each functional node, including:

[0015] Obtaining meta information of an available function node in the at least one function node, and storing function functions of the function node using a connection function through the meta information, wherein the available function node refers to a node that has been developed and can be used for visual programming;

[0016] Calling an acquisition function in the function function to acquire description information of the function node;

[0017] A node list of the target plug-in is generated according to the description information of the functional node, and the node list is displayed.

[0018] Optionally, generating a connection graph of a graph including the target function node comprises:

[0019] Determine that the graph and the graph of the target function node are in the previous function node of the same panel;

[0020] The graph of the target function node and the input and output of the graph of the previous function node are connected to generate a connection graph.

[0021] Optionally, the running of the connection diagram to generate a target program includes:

[0022] The function functions of each functional node in the connection diagram are called to make each functional node run in the connection sequence to generate a target program.

[0023] Optionally, after generating a connection graph of a graph including the target function node, the method further includes:

[0024] If the target function node is marked as a to-be-executed node, determining other function nodes connected to the to-be-executed node in the connection graph;

[0025] Calling the input function to obtain input information of the node to be executed based on output information of other function nodes;

[0026] Calling the execution function to generate the execution result of the node to be executed according to the input information of the node to be executed;

[0027] The output function is called to output the execution result to complete the functional test of the node to be executed.

[0028] In a second aspect, an embodiment of the present disclosure provides a visual programming device, including:

[0029] A reading unit, configured to read a target plug-in and load the target plug-in, wherein the target plug-in includes at least one function node;

[0030] An acquisition unit, configured to generate a node list based on the meta information of each functional node, and display the node list, wherein the node list includes description information of each functional node;

[0031] A display unit, configured to display a graph of a target function node in response to a triggering operation of the description information of the target function node in the node list;

[0032] A generating unit is used to generate a connection diagram of a graph including the target function node, and run the connection diagram to generate a target program.

[0033] Optionally, the device further includes a creating unit, wherein the creating unit is configured to:

[0034] Obtaining basic functions that need to be inherited and functional functions that need to be implemented by the functional node to be developed, wherein the functional functions include an acquisition function, an input function, an output function, and an execution function;

[0035] Developing the function node according to the basic function and the function function;

[0036] An initial plug-in is created based on the basic function, and an instance of the function node is returned through a slot function to store meta information of the function node in the initial plug-in, thereby obtaining a target plug-in.

[0037] In a third aspect, an embodiment of the present disclosure provides an electronic device, including:

[0038] Memory;

[0039] Processor; and

[0040] Computer programs;

[0041] The computer program is stored in the memory and is configured to be executed by the processor to implement the visual programming method as described above.

[0042] In a fourth aspect, an embodiment of the present disclosure provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program implements the steps of the above-mentioned visual programming method when executed by a processor.

[0043] The embodiment of the present disclosure provides a visual programming method, including: reading a target plug-in and loading the target plug-in, wherein the target plug-in includes meta information of at least one functional node; generating a node list based on the meta information of each functional node, and displaying the node list, wherein the node list includes description information of each functional node; displaying a graph of the target functional node in response to a trigger operation of the description information of the target functional node in the node list; generating a connection diagram including the graph of the target functional node, and running the connection diagram to generate a target program. The method provided by the present disclosure implements flexible addition of functional nodes on a visual programming platform through plug-in technology, and implements the visual programming platform through meta information technology to call node function functions to implement node functions without including node function function header files, thereby effectively reducing the coupling between the visual programming platform and the functional nodes, improving the flexibility of node development, and thus improving the efficiency of visual programming. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] 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.

[0045] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0046] Figure 1 A flowchart of a visual programming method provided by an embodiment of the present disclosure;

[0047] Figure 2 A schematic diagram of the relationship between a platform, a plug-in, and a node provided in an embodiment of the present disclosure;

[0048] Figure 3 A schematic diagram of a visual programming interface provided by an embodiment of the present disclosure;

[0049] Figure 4 A flowchart of another visual programming method provided by an embodiment of the present disclosure;

[0050] Figure 5 A schematic diagram of the structure of a visual programming device provided by an embodiment of the present disclosure;

[0051] Figure 6 A schematic diagram of the structure of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0052] In order to more clearly understand the above-mentioned objectives, features and advantages of the present disclosure, the scheme of the present disclosure will be further described below. It should be noted that the embodiments of the present disclosure and the features in the embodiments can be combined with each other without conflict.

[0053] In the following description, many specific details are set forth to facilitate a full understanding of the present disclosure, but the present disclosure may also be implemented in other ways different from those described herein; it is obvious that the embodiments in the specification are only part of the embodiments of the present disclosure, rather than all of the embodiments.

[0054] In existing visual programming platforms, function nodes are usually expanded through source code. Each time a new function node is added, the source code needs to be modified and recompiled before the new function node can be used. The development of the visual programming platform itself and the development of the function node are highly coupled and highly dependent. Specifically, the code of the function node in the existing technology is integrated into the visual programming platform as a part of it. When a new function node is needed, it is necessary to obtain the source code of the visual programming platform, modify the source code to add a node, and recompile it for use. In addition, the function node developer needs to deploy the development environment of the visual programming platform before they can develop the function node.

[0055] In view of the above technical problems, the embodiments of the present disclosure provide a visual programming method, which realizes low coupling development between the visual programming platform and the functional nodes by combining the visual programming platform with the Qt plug-in and the meta-information method in the application development framework (Qt). The functional nodes are independently developed in the form of Qt plug-ins without the need to deploy the platform development environment, modify the platform source code, or recompile the platform. After the functional nodes are independently developed, they are added to the specified directory of the visual programming platform. When the platform is started, all plug-ins are read and all functional nodes are loaded, so that the purpose of dynamically adding new nodes in the visual programming platform can be achieved, which effectively reduces the coupling between the visual programming platform and the functional nodes and improves the flexibility of node development. This is described in detail by one or more of the following embodiments.

[0056] Figure 1A flowchart of a visual programming method provided in an embodiment of the present disclosure can be executed by a terminal or a server. The following embodiment is described in detail by taking the terminal execution as an example and applying it to the scenario of developing and using new function nodes in a visual programming platform. The visual programming platform can be deployed on the terminal, specifically including the following: Figure 1 Steps S110 to S140 shown:

[0057] S110: Read a target plug-in and load the target plug-in, wherein the target plug-in includes meta information of at least one functional node.

[0058] Optionally, before reading the target plug-in, the method further includes:

[0059] Obtain the basic functions that the function node to be developed needs to inherit and the functional functions that need to be implemented, wherein the functional functions include an acquisition function, an input function, an output function and an execution function; develop the function node according to the basic functions and the functional functions; create an initial plug-in based on the basic functions, and return an instance of the function node through a slot function to store the meta information of the function node in the initial plug-in to obtain a target plug-in.

[0060] It is understandable that before using the new nodes in the visual programming platform, plug-in design is required. Specifically, the plug-in can be a Qt plug-in. A plug-in includes multiple node classes. The node class refers to the functional node. The node class needs to inherit the base class (QObject class). Among them, the QObject class is the base class of all objects in Qt and the foundation of the QObject system. It provides important features such as the attribute system, signal and slot mechanism, and event processing mechanism. All objects inherited from this class can use these features. Therefore, when developing functional nodes, the basic functions that need to be inherited and the functional functions that need to be implemented by the functional nodes to be developed are obtained. The basic function refers to the base class. The functional functions of nodes with different functions are not exactly the same. For example, the addition node with the function of formula addition and the subtraction node with the function of formula subtraction can implement different functional functions. Among them, the function function at least includes the acquisition function, input function (write function), output function (read function) and execution function (apply()). The addition node in the above example may also include the addition function (add function). Both the basic function and the function function can be understood as slot functions. The signal slot refers to when an event occurs, for example, a button will send a signal (signal) when it detects a click operation, but the signal sent is purposeless, similar to broadcasting. If an object is interested in this signal, it will use the connection (connect) function to bind the signal to be processed with one of its own functions (called slot) to process the signal. That is to say, when the signal is sent, the connected slot function will be automatically called back. Then, the development of the function node is completed according to the basic function and the function function. For the specific node development process, please refer to the existing Qt node development method, which will not be repeated here. After completing the development of the function node, create an initial plug-in based on the basic function, that is, the plug-in also needs to inherit the QObject class. You can use Q_PLUGIN_METADATA (macro export plug-in) to create a Qt plug-in. The initial plug-in can be understood as an empty plug-in. Then, the QMetaObject instance of the function node is returned through the slot function in the initial plug-in to store the meta information of the function node in the initial plug-in to obtain the target plug-in. Based on the above example, the meta information of the addition node and the subtraction node is stored in the numerical operation plug-in. Then, the generated target plug-ins are placed in the specified plug-in directory to facilitate the visual programming platform to read the plug-in.

[0061] It is understandable that when the main visual programming software is started, it reads all the plug-ins in the specified directory and loads the target plug-in through QPluginLoader (class dynamic loading plug-in), wherein the target plug-in includes the meta information of at least one function node.

[0062] For example, see Figure 2 , Figure 2A schematic diagram of the relationship between a platform, plug-ins, and nodes provided in an embodiment of the present disclosure, wherein the visual programming platform can load n node plug-ins under a specified directory, and each node plug-in developed by means of a Qt plug-in contains n functional nodes, which are newly added nodes for the visual programming platform.

[0063] S120: Generate a node list based on the meta information of each functional node, and display the node list, where the node list includes description information of each functional node.

[0064] It is understandable that, based on the above S110, the nodes() function is called to obtain the QMetaObject instance of each functional node, obtain the meta information of all node classes, and generate a node list based on the meta information of all node classes. Each plug-in has a displayable node list, and each node list includes the description information of at least one functional node. Subsequently, the node list is displayed on the operation interface of the visual programming platform, wherein the node list includes the description information of each functional node, and the description information includes the node name, label value operation information, function description, input and output information, etc.

[0065] Optionally, generating a node list based on the meta information of each functional node in S120 may be implemented by the following steps:

[0066] Obtain meta information of an available function node in the at least one function node, and store function functions of the available function node using a connection function through the meta information, wherein the available function node refers to a node that has been developed and can be used for visual programming; call an acquisition function in the function function to obtain description information of the available function node; and generate a node list according to the description information of the available function node.

[0067] Understandably, available function nodes are determined in at least one function node contained in the target plug-in, and available function nodes refer to nodes that have been developed and can be used for visual programming. Then, the meta information of the available function nodes is obtained, and the function functions of the function nodes such as input and output are stored in the visual programming platform using QMetaMethod (connection slot) through the meta information. Then, QMetaMethod::invoke() is used to call the acquisition function in the stored function function to obtain the description information of the function node and display it in the node list.

[0068] S130 . In response to a triggering operation of the description information of the target function node in the node list, display a graph of the target function node.

[0069] It is understandable that, based on the above S120, after the node list is displayed on the panel of the visual programming platform, the user triggers the target function node on the panel, such as clicking the target function node, and other triggering methods are not described here. Subsequently, the visual programming platform responds to the triggering operation of the description information of the target function node in the node list, and adds and displays the graphics of the target function node on the panel. It is understandable that the description information of the function node is displayed in the node list, indicating that the function node has been developed and can be added to the panel for visual programming.

[0070] S140, generating a connection diagram including a graph of the target function node, and running the connection diagram to generate a target program.

[0071] It is understandable that, based on the above S130, the graphics of the function nodes on the panel are connected into a graph to generate a connection graph including the target function node graph. The connection graph is then run, and after the run is successful, a target program is generated to complete the visual programming.

[0072] Optionally, generating a connection graph including the target function node in S140 may be implemented by the following steps:

[0073] Determine a previous function node associated with the target function node in a panel displaying the graph of the target function node; connect the input and output of the graph of the target function node and the graph of the previous function node to generate a connection graph.

[0074] It is understandable that in the graphs of all function nodes displayed on the panel, the previous function node associated with the target function node is determined, and the previous function node refers to the node that implements the same programming as the target function node, and the number of previous function nodes is not limited. After determining the previous function node, the graph of the previous function node and the graph of the target function node are connected according to the input-output connection relationship between the nodes to generate a connection diagram for implementing the same programming, for example, the output of the previous function node 1 is the input of the target function node, and the output of the target function node is the input of the previous function node 2. Based on the input-output connection relationship, a connection diagram including the previous function node 1, the target function node and the previous function node 2 is generated.

[0075] For example, see Figure 3 , Figure 3 A schematic diagram of a visual programming interface provided by an embodiment of the present disclosure. The operation interface of the visual programming platform includes a node list and a panel. The node list includes description information of at least one functional node, such as Figure 3The node list shown includes sub-node lists of the target plug-in and the newly added plug-in, wherein the sub-node list 1 of the target plug-in includes description information of the target function node, the newly added function node 1 and the newly added function node 2. The user clicks the target function node in the sub-node list 1 to add the graph of the target function node to the panel. After the addition of the newly added node (target function node) is completed, the panel now includes the graphs of the previous function node 1, the previous function node 2 and the target function node. The input and output of the graphs of the previous function node 1, the previous function node 2 and the target function node are connected into a graph to obtain a connection graph including three function nodes, as shown in FIG. Figure 3 Connection diagram shown in the middle panel.

[0076] Optionally, after generating a connection graph of a graph including the target function node in S140, the method further includes:

[0077] If the target function node is marked as a node to be executed, then other function nodes connected to the node to be executed are determined in the connection diagram; the input function is called to obtain the input information of the node to be executed based on the output information of the other function nodes; the execution function is called to generate the execution result of the node to be executed according to the input information; and the output function is called to output the execution result to complete the functional test of the node to be executed.

[0078] Understandably, after adding the graph of the target function node to the panel, the target function node can be marked as a node to be executed, and the node to be executed refers to a node that has not been run and tested. Then determine other function nodes connected to the node to be executed in the connection diagram, that is, nodes connected to the input or output of the target function node, such as the previous function node 1 and the previous function node 2 in the above example. The function of the target function node is tested by calling the input function, the output function and the execution function through the meta information of the target function node. Specifically, the input information of the node to be executed is obtained through the input function, and the input information is the output information of other function nodes. The execution function of the node to be executed is operated based on the input information according to the set logic inside the node, and the execution result of the node to be executed is obtained. For example, if the node to be executed is an addition node, all input information is added to obtain the execution result. Subsequently, the execution result is output through the output function of the node to be executed to complete the functional test of the node to be executed.

[0079] It is understandable that there is no limit to the number of nodes marked as to-be-executed. For example, a preset number of nodes to be executed can be uniformly subjected to functional testing, or a functional test of the function node can be performed each time a function node is added to the panel, so as to improve the efficiency of visual programming and further improve the accuracy of programming.

[0080] Optionally, running the connection diagram to generate a target program in S140 may be implemented by the following steps:

[0081] The function functions of each functional node in the connection diagram are called to make each functional node run in the connection sequence to generate a target program.

[0082] It can be understood that when running the connection graph, an instance of each function node in the connection graph is created through QMetaObjec::newInstance(). Each function node on the panel has a specific instance. Then, the function function of each function node is called through the meta information to complete the input and output reading and writing of the node and execute the node function until the entire connection graph is completed according to the node connection order and the target program is generated.

[0083] A visual programming method provided by the disclosed embodiment combines visual programming with Qt plug-in and Qt meta information technology, realizes flexible addition of function nodes in the visual programming platform through Qt plug-in technology, and realizes that the platform can call node function functions to realize node functions without including node function function header files through Qt meta information technology. The coupling degree between the visual programming platform and the newly added function nodes is effectively reduced, and the development of function nodes can be carried out without deploying the development environment of the visual programming platform. In addition, there is no need to associate the visual programming platform with the function nodes through header files. The function nodes only need to implement the specified input, output, execution and other function functions. The visual programming platform can directly call the function nodes in the plug-in through Qt meta information, and add the function nodes to the panel for visual programming, which improves the flexibility of node development and thus improves the efficiency of visual programming.

[0084] Based on the above embodiments, Figure 4 A flowchart of another visual programming method provided by the embodiment of the present disclosure specifically includes the following steps: Figure 4 Steps S410 to S460 shown:

[0085] S410, start the visual programming platform and read all plug-ins in the specified directory.

[0086] S420: Determine whether all function nodes have been traversed.

[0087] It is understandable that if yes, execute S450, if no, execute S430.

[0088] S430. Load all function nodes developed by means of Qt plug-ins.

[0089] S440 , reading description information of the function node through Qt meta information.

[0090] S450 , displaying the node list, and displaying the graphics of the triggered target function nodes in the node list on the panel.

[0091] S460 , calling the function function of the target function node by means of Qt meta information to execute the target function node.

[0092] It is understandable that the specific implementation steps of the above S410 to S460 refer to the above embodiments and are not described in detail here.

[0093] Figure 5 The structure diagram of the visual programming device provided by the embodiment of the present disclosure is as follows. The visual programming device provided by the embodiment of the present disclosure can execute the processing flow provided by the embodiment of the visual programming method, such as Figure 5 As shown, the visual programming device 500 includes a reading unit 510, an acquisition unit 520, a display unit 530 and a generation unit 540, wherein:

[0094] A reading unit 510 is configured to read a target plug-in and load the target plug-in, wherein the target plug-in includes at least one function node;

[0095] An acquisition unit 520, configured to generate a node list based on the meta information of each functional node, and display the node list, wherein the node list includes description information of each functional node;

[0096] A display unit 530, configured to display a graph of a target function node in response to a triggering operation of the description information of the target function node in the node list;

[0097] The generating unit 540 is used to generate a connection diagram including the graph of the target function node, and run the connection diagram to generate a target program.

[0098] Optionally, the apparatus 500 further includes a creating unit, wherein the creating unit is configured to:

[0099] Obtaining basic functions that need to be inherited and functional functions that need to be implemented by the functional node to be developed, wherein the functional functions include an acquisition function, an input function, an output function, and an execution function;

[0100] Developing the function node according to the basic function and the function function;

[0101] An initial plug-in is created based on the basic function, and an instance of the function node is returned through a slot function to store meta information of the function node in the initial plug-in, thereby obtaining a target plug-in.

[0102] Optionally, the acquiring unit 520 is used to:

[0103] Obtaining meta information of an available function node in the at least one function node, and storing function functions of the function node using a connection function through the meta information, wherein the available function node refers to a node that has been developed and can be used for visual programming;

[0104] Calling an acquisition function in the function function to acquire description information of the function node;

[0105] A node list of the target plug-in is generated according to the description information of the functional node, and the node list is displayed.

[0106] Optionally, the generating unit 540 is used for:

[0107] Determine that the graph and the graph of the target function node are in the previous function node of the same panel;

[0108] The graph of the target function node and the input and output of the graph of the previous function node are connected to generate a connection graph.

[0109] Optionally, the generating unit 540 is used for:

[0110] The function functions of each functional node in the connection diagram are called to make each functional node run in the connection sequence to generate a target program.

[0111] Optionally, the device 500 is further used for:

[0112] If the target function node is marked as a to-be-executed node, determining other function nodes connected to the to-be-executed node in the connection graph;

[0113] Calling the input function to obtain input information of the node to be executed based on output information of other function nodes;

[0114] Calling the execution function to generate the execution result of the node to be executed according to the input information of the node to be executed;

[0115] The output function is called to output the execution result to complete the functional test of the node to be executed.

[0116] Figure 5 The visual programming device of the illustrated embodiment can be used to execute the technical solution of the above-mentioned method embodiment. Its implementation principle and technical effect are similar and will not be described in detail here.

[0117] Figure 6 This is a schematic diagram of the structure of an electronic device provided by an embodiment of the present disclosure. Figure 6, which shows a schematic diagram of the structure of an electronic device 600 suitable for implementing the embodiment of the present disclosure. The electronic device 600 in the embodiment of the present disclosure may include, but is not limited to, mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), vehicle terminals (such as vehicle navigation terminals), wearable electronic devices, etc., and fixed terminals such as digital TVs, desktop computers, smart home devices, etc. Figure 6 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.

[0118] like Figure 6 As shown, the electronic device 600 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 601, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 602 or a program loaded from a storage device 608 to a random access memory (RAM) 603 to implement the visual programming method of the embodiment described in the present disclosure. In the RAM 603, various programs and data required for the operation of the electronic device 600 are also stored. The processing device 601, the ROM 602, and the RAM 603 are connected to each other via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.

[0119] Typically, the following devices may be connected to the I / O interface 605: an input device 606 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 607 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 608 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 609. The communication device 609 may allow the electronic device 600 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 6 The electronic device 600 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead.

[0120] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart, thereby implementing the visual programming method as described above. In such an embodiment, the computer program can be downloaded and installed from the network through the communication device 609, or installed from the storage device 608, or installed from the ROM 602. When the computer program is executed by the processing device 601, the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.

[0121] It should be noted that the computer-readable medium disclosed above may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that may be used by or in combination with an instruction execution system, device or device. In the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.

[0122] In some embodiments, the client and the server may communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and may be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or future developed network.

[0123] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.

[0124] Optionally, when the above one or more programs are executed by the electronic device, the electronic device may also execute other steps described in the above embodiments.

[0125] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages ​​or a combination thereof, including, but not limited to, object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., through the Internet using an Internet service provider).

[0126] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0127] The units involved in the embodiments described in the present disclosure may be implemented by software or hardware, wherein the name of a unit does not, in some cases, limit the unit itself.

[0128] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.

[0129] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0130] It should be noted that, in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or gateway that includes a series of elements includes not only those elements, but also other elements that are not explicitly listed, or also includes elements inherent to such process, method, article or gateway. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or gateway that includes the elements.

[0131] The above description is only a specific embodiment of the present disclosure, so that those skilled in the art can understand or implement the present disclosure. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present disclosure. Therefore, the present disclosure will not be limited to the embodiments described herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A visual programming method, characterized in that: include: Reading a target plug-in and loading the target plug-in, wherein the target plug-in includes meta information of at least one functional node; Generate a node list based on the meta information of each functional node, and display the node list, wherein the node list includes description information of each functional node; In response to a triggering operation of the description information of the target function node in the node list, displaying a graph of the target function node; A connection graph including the graph of the target function node is generated, and the connection graph is run to generate a target program.

2. The method according to claim 1, characterized in that Before reading the target plug-in, the method further includes: Obtaining basic functions that need to be inherited and functional functions that need to be implemented by the functional node to be developed, wherein the functional functions include an acquisition function, an input function, an output function, and an execution function; Developing the function node according to the basic function and the function function; An initial plug-in is created based on the basic function, and an instance of the function node is returned through a slot function to store meta information of the function node in the initial plug-in, thereby obtaining a target plug-in.

3. The method according to claim 1, characterized in that The generating of the node list based on the meta information of each functional node includes: Obtaining meta information of an available function node in the at least one function node, and storing function functions of the available function node using a connection function through the meta information, wherein the available function node refers to a node that has been developed and can be used for visual programming; Calling an acquisition function in the function function to acquire description information of the available function node; A node list is generated according to the description information of the available function nodes.

4. The method according to claim 1, characterized in that: The generating of a connection graph including a graph of the target function node comprises: Determining a previous function node associated with the target function node in a panel displaying a graphic of the target function node; The graph of the target function node and the input and output of the graph of the previous function node are connected to generate a connection graph.

5. The method according to claim 1, characterized in that The step of running the connection diagram to generate a target program includes: The function functions of each functional node in the connection diagram are called to make each functional node run in the connection sequence to generate a target program.

6. The method according to claim 2, characterized in that After generating a connection graph including the target function node, the method further comprises: If the target function node is marked as a to-be-executed node, determining other function nodes connected to the to-be-executed node in the connection graph; Calling the input function to obtain input information of the node to be executed based on output information of other function nodes; Calling the execution function to generate the execution result of the node to be executed according to the input information; The output function is called to output the execution result to complete the functional test of the node to be executed.

7. A visual programming device, characterized in that: include: A reading unit, configured to read a target plug-in and load the target plug-in, wherein the target plug-in includes at least one function node; An acquisition unit, configured to generate a node list based on the meta information of each functional node, and display the node list, wherein the node list includes description information of each functional node; A display unit, configured to display a graph of a target function node in response to a triggering operation of the description information of the target function node in the node list; A generating unit is used to generate a connection diagram of a graph including the target function node, and run the connection diagram to generate a target program.

8. The device according to claim 7, characterized in that The device also includes a creation unit, which is used to: Obtaining basic functions that need to be inherited and functional functions that need to be implemented by the functional node to be developed, wherein the functional functions include an acquisition function, an input function, an output function, and an execution function; Developing the function node according to the basic function and the function function; An initial plug-in is created based on the basic function, and meta information of the functional node is stored in the initial plug-in to obtain a target plug-in.

9. An electronic device, characterized in that: include: Memory; processor; as well as Computer programs; The computer program is stored in the memory and is configured to be executed by the processor to implement the visual programming method as claimed in any one of claims 1 to 6.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the visual programming method according to any one of claims 1 to 6 are implemented.