CN115934069A - Visual program compiling method and device, electronic equipment and storage medium - Google Patents

Visual program compiling method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN115934069A
CN115934069A CN202211441795.0A CN202211441795A CN115934069A CN 115934069 A CN115934069 A CN 115934069A CN 202211441795 A CN202211441795 A CN 202211441795A CN 115934069 A CN115934069 A CN 115934069A
Authority
CN
China
Prior art keywords
functional component
program
functional
library
component
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202211441795.0A
Other languages
Chinese (zh)
Inventor
王郁
汤青松
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Xinglan Technology Co ltd
Original Assignee
Beijing Xinglan Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Xinglan Technology Co ltd filed Critical Beijing Xinglan Technology Co ltd
Priority to CN202211441795.0A priority Critical patent/CN115934069A/en
Publication of CN115934069A publication Critical patent/CN115934069A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Stored Programmes (AREA)

Abstract

The application relates to the technical field of program development, in particular to a visual program compiling method, a visual program compiling device, electronic equipment and a storage medium, which are applied to a visual program compiling platform comprising a functional component library and an editing interface, respond to the operation of a user on the functional component library, and drag functional components selected from the functional component library to the editing interface; performing parameter configuration on each functional component dragged to the editing interface, and connecting each functional component through lines representing logical relations to obtain a workflow of the program to be written; and generating a complete program code according to the obtained parameters configured by each functional component in the workflow of the program to be written and the logic relationship among the functional components.

Description

Visual program compiling method and device, electronic equipment and storage medium
Technical Field
The present application relates to the field of program development technologies, and in particular, to a method and an apparatus for compiling a visual program, an electronic device, and a storage medium.
Background
In the network security industry, a security engineer needs to repeatedly use a part of tools (such as nmap, sqlmap and the like) and APIs (such as gitlab, fofa and the like), and when one job needs to be done, a plurality of tools and APIs are combined, and the engineer needs to master a programming language and a calling mode and a return result of each tool or API. For example, when code auditing work is performed, a code warehouse list needs to be obtained first, codes of the warehouse need to be downloaded, a code auditing tool needs to be called, and an auditing result sends a notice; many tools or APIs are used in these several steps, and engineers need to master the calling mode and the result output format of each tool, which consumes a lot of time in debugging programs.
In the prior art, when the application program is written, an engineer must master the capability of writing the code, and needs to learn the calling mode of each tool, which has high technical requirements and a large amount of written code.
Disclosure of Invention
In order to overcome the defects in the prior art, the application provides a visual program compiling method, a visual program compiling device, an electronic device and a storage medium, and the program can be compiled in a short time and the error rate is reduced by presetting functional components.
In a first aspect, the present application provides a visual program compiling method applied to a visual program compiling platform, where the visual program compiling platform includes a functional component library and an editing interface, and the method includes the following steps:
responding to the operation of a user on the functional component library, and dragging the functional component selected from the functional component library to an editing interface; the functional components selected from the functional component library are determined according to the workflow of the program to be written, and the functional component library comprises functional components which are suitable for the workflow creation of different types of programs to be written;
configuring parameters of each functional component dragged to the editing interface, and connecting each functional component through lines representing logical relations to obtain a workflow of the program to be compiled;
and generating a complete program code according to the obtained parameters configured by each functional component in the workflow of the program to be written and the logic relationship among the functional components.
In one possible implementation, the function component library includes a text import function component, a file import function component, an HTTP package sending function component, a database reading function component, a script execution function component, a filter function component, and a container function component.
In a possible implementation manner, the editing interface includes a parameter configuration window and a global variable setting unit, and the parameter configuration for each functional component dragged into the editing interface includes the following steps:
responding to the operation of the user on the parameter configuration window, and respectively configuring the parameters of each functional component dragged to the editing interface;
responding to the operation of a user on the global variable setting unit, and uniformly configuring the common parameters of each functional component dragged to the editing interface.
In a possible implementation manner, the generating a complete program code according to the obtained parameters of the configuration of each functional component in the workflow of the program to be written and the logical relationship between the functional components includes the following steps:
detecting each functional component and an execution state corresponding to the logic relation between the functional components in the program code generation process; wherein the execution state comprises a first execution state in which the corresponding program code is successfully generated according to the functional component and a second execution state in which the corresponding program code is not successfully generated according to the functional component;
different executing states in the code generating process are correspondingly displayed in an editing interface by adopting different graphs;
and reconfiguring parameters of the functional components displaying the second execution state in the editing interface, and detecting again until the execution states of all the functional components are the first execution state to obtain a complete program code.
In one possible implementation, the execution states further include a third execution state in accordance with the functional component generating the corresponding program code.
In one possible embodiment, the function component library further comprises a function component private library and a function component shared library; after the parameter configuration is carried out on each functional component dragged to the editing interface, the method further comprises the following steps:
renaming the function component after parameter configuration and storing the function component into a function component private library;
or renaming the functional components after the parameter configuration and storing the functional components into the functional component shared library.
In a possible implementation manner, the dragging, in response to the operation of the user on the function component library, a function component selected from the function component library into the editing interface includes the following steps:
judging whether the workflow of the current program to be written has a workflow of a historical writing program similar to the workflow of the current program to be written, wherein in the process of generating codes by the historical writing program, functional components with well-configured parameters are stored in a functional component private library or a functional component shared library;
and if the functional component library exists, responding to the operation of the user on the functional component library, calling the functional component saved in the process of generating the code by the history compiling program from the functional component private library or the functional component shared library, and dragging the functional component to an editing interface.
In a second aspect, the present application provides a visual program compiling apparatus applied to a visual program compiling platform, where the visual program compiling platform includes a functional component library and an editing interface, the apparatus includes:
the response module is used for responding to the operation of a user on the functional component library and dragging the functional components selected from the functional component library to the editing interface; the functional components selected from the functional component library are determined according to the workflow of the program to be written, and the functional component library comprises functional components which are suitable for the workflow creation of different types of programs to be written;
the editing module is used for carrying out parameter configuration on each functional component dragged to the editing interface and connecting each functional component through a line representing a logical relation to obtain a workflow of the program to be compiled;
and the generating module is used for generating a complete program code according to the obtained parameters configured by each functional component in the workflow of the program to be written and the logic relationship among the functional components.
In a third aspect, the present application provides an electronic device, comprising: a processor, a memory and a bus, the memory storing machine-readable instructions executable by the processor, the processor and the memory communicating via the bus when the electronic device is running, the machine-readable instructions when executed by the processor performing the steps of the visualization program writing method according to any one of the first aspect.
In a fourth aspect, the present application provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the visualization program writing method according to any of the first aspects.
The method, the device, the electronic equipment and the storage medium for compiling the visual program provided by the embodiment are applied to a visual program compiling platform comprising a function component library and an editing interface, respond to the operation of a user on the function component library, and drag the function component selected from the function component library to the editing interface; performing parameter configuration on each functional component dragged to the editing interface, and connecting each functional component through lines representing logical relations to obtain a workflow of the program to be written; and generating a complete program code according to the obtained parameters configured by each functional component in the workflow of the program to be written and the logic relationship among the functional components.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are required to be used in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present invention and therefore should not be considered as limiting the scope, and for those skilled in the art, other related drawings can be obtained according to the drawings without inventive efforts.
Fig. 1 is a flowchart illustrating a visualization program writing method according to an embodiment of the present application;
FIG. 2 is a schematic interface diagram of a visualization program writing platform according to an embodiment of the present application;
FIG. 3 is a flow diagram illustrating parameter configuration of a functional component according to an embodiment of the present application;
FIG. 4 is a diagram illustrating a parameter configuration window according to an embodiment of the present application;
FIG. 5 is a diagram illustrating a private library of functional components according to an embodiment of the present application;
FIG. 6 is a diagram illustrating a shared library of functional components according to one embodiment of the present application;
FIG. 7 is a flow chart illustrating the generation of complete program code according to an embodiment of the present application;
fig. 8 shows a block diagram of a visualization program writing device according to an embodiment of the present application;
fig. 9 shows a block diagram illustrating a structure of an electronic device according to an embodiment of the present application.
Detailed Description
In order to make the purpose, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it should be understood that the drawings in the present application are only for illustration and description purposes and are not used to limit the protection scope of the present application. Additionally, it should be understood that the schematic drawings are not necessarily drawn to scale. The flowcharts used in this application illustrate operations implemented according to some embodiments of the present application. It should be understood that the operations of the flow diagrams may be performed out of order, and that steps without logical context may be reversed in order or performed concurrently. One skilled in the art, under the guidance of this application, may add one or more other operations to, or remove one or more operations from, the flowchart.
In addition, the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. The components of the embodiments of the present application, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present application, presented in the accompanying drawings, is not intended to limit the scope of the claimed application, but is merely representative of selected embodiments of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the present application without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that in the embodiments of the present application, the term "comprising" is used to indicate the presence of the features stated hereinafter, but does not exclude the addition of further features.
With the application program updating speed in the market becoming faster and faster, application program developers often need to spend a large amount of time to write repeated and simple codes, resulting in high error rate and low working efficiency. In the process of application program development, developers usually perform code layout and writing according to personal abilities and habits, and non-developers are difficult to quickly locate problems in the later maintenance process. Based on the method and the device, the electronic equipment and the storage medium, the program can be written in a short time by presetting the functional components, and the error rate is reduced.
Referring to the accompanying drawing 1 of the specification, in an embodiment, the present application provides a visualization program writing method applied to a visualization program writing platform, where the visualization program writing platform includes a function component library and an editing interface, and the method includes the following steps:
s1, responding to the operation of a user on a function component library, and dragging a function component selected from the function component library to an editing interface; the functional components selected from the functional component library are determined according to the workflow of the program to be written, and the functional component library comprises functional components which are suitable for the workflow creation of different types of programs to be written;
in order to clearly understand the technical solution of the embodiment of the present invention, an application scenario may be first exemplarily described, and in the present application, the visualization program writing platform is mainly used for responding to an operation instruction of a user and finally automatically generating a code of a program to be written. In an embodiment, the interface of the visualization program writing platform may be referred to in fig. 2 of the specification, and mainly consists of a function component library on the left side and an editing interface on the right side, where the editing interface includes a canvas for creating a workflow of a program to be written and a parameter configuration window, where the canvas is disposed between the function component library and the parameter configuration window.
In other embodiments, the interface of the visualization program writing platform may adopt different modes according to actual needs, and the application does not limit and fix the interfaces.
In step S1, the visualization program writing platform can respond to a drag operation instruction of a user in the functional component library, and further move the functional component dragged by the user into a canvas of an editing interface to create a workflow of a program to be written. The functional component library comprises seven types of components including a text import functional component, a file import functional component, an HTTP packet sending functional component, a database reading functional component, a script running functional component, a filter functional component and a container functional component, and accordingly the establishment of workflows for constructing different types of programs to be written is met.
In an embodiment, a user firstly determines a workflow of a program to be written according to the program to be written, then selects a plurality of required functional components according to the determined workflow, for example, the workflow to be created requires a text import functional component, a filter functional component and a script execution functional component, and drags the three functional components from a functional component library to a canvas of an editing interface in sequence to prepare for creating the workflow of the program to be written.
S2, parameter configuration is carried out on each functional component dragged to the editing interface, and each functional component is connected through lines representing logical relations, so that the workflow of the program to be written is obtained;
specifically, after all the functional components creating the workflow of the program to be written are dragged to the canvas of the editing interface, the parameters of each functional component need to be configured, wherein a global variable setting unit is further provided in the editing interface besides a processing setting parameter configuration window, referring to fig. 3 in the specification, to configure the parameters of each functional component dragged to the editing interface, and the method includes the following steps:
s201, responding to the operation of a user on the parameter configuration window, and respectively configuring the parameters of each functional component dragged to the editing interface;
s202, responding to the operation of the user on the global variable setting unit, and uniformly configuring the common parameters of each functional component dragged to the editing interface.
That is, the parameter configuration window is used for filling the necessary parameters corresponding to each functional component, for example, referring to fig. 4 in the specification, the necessary parameters such as field name, matching adjustment, value and the like of the filter functional component are configured; for the common configuration of all the functional components in the canvas, the common configuration may be set in the global variable setting unit, and the content set in the global variable may be stored in the environment variable of each functional component, for example, the common parameters such as name, key, value, etc. are configured in the global variable setting unit;
after the parameter configuration of the functional components in the canvas is completed, each functional component needs to be further connected through lines to represent the logical relationship between the functional components, namely the upstream and downstream relationship of data, and finally the workflow of the program to be written is obtained.
In other embodiments, each functional component may be connected through a line representing a logical relationship, and then parameter configuration may be performed on each functional component dragged to the editing interface; or, firstly dragging a functional component from the functional component library to the editing interface, configuring the parameter of the functional component, then dragging a second functional component from the functional component library to the editing interface, configuring the parameter of the functional component until each required functional component is dragged to the editing interface and the parameter is configured, and finally connecting each functional component through a line representing a logical relationship; that is, there are various ways to create a workflow of a program to be written, which are not limited or fixed by this application.
Further, the function component library further comprises a function component private library and a function component shared library, and the function component private library and the function component shared library are used for renaming and storing the function components with the configured parameters, wherein the function components stored in the function component private library can be called only by an individual user, and the function components stored in the function component shared library can be called by all users of the visual program writing platform through a certain rule, such as payment. In an embodiment, referring to fig. 5 of the specification, the "my component" is a private library of functional components, and is stored with nikto scanner functional components configured with parameters, eye functional components in Zhongkui, POC script functional components, and the like; referring to fig. 6 of the specification, the "component market" is a shared library of functional components, and stores a staple notification functional component and a flybook notification functional component with configured parameters.
The reason why some function components with configured parameters are stored is that when some function component is reused in the later period, the function component can be directly called from the function component private library or the function component shared library without reconfiguring the parameters of the function component or only modifying a few parameters, so that the efficiency of creating the workflow of the program to be written is improved.
In an embodiment, a user can judge whether a workflow of a historical writing program similar to the workflow of the current program to be written exists or not according to the workflow of the current program to be written, and when the code of the historical writing program is generated at first, a functional component with well-configured parameters is stored in a functional component private library or a functional component shared library, if so, the functional component stored in the code generating process of the historical writing program is called from the functional component private library or the functional component shared library and dragged to an editing interface, and then the parameters of the functional component are slightly modified or not modified; and if not, selecting the required function component from the seven types of components in the function component library, dragging the function component to an editing interface, and then configuring parameters, thereby quickly creating the workflow of the current program to be written.
S3, generating a complete program code according to the obtained parameters configured by each functional component in the workflow of the program to be written and the logic relationship among the functional components;
in step S3, referring to fig. 7 in the specification, according to the obtained parameters configured by each functional component in the workflow of the program to be written and the logical relationship between the functional components, generating a complete program code, including the following steps:
s301, detecting each functional component and an execution state corresponding to the logic relationship between the functional components in the program code generation process; wherein the execution state comprises a first execution state in which the corresponding program code is successfully generated according to the functional component and a second execution state in which the corresponding program code is not successfully generated according to the functional component;
s302, correspondingly displaying different execution states in the code generation process in an editing interface by adopting different graphs;
and S303, reconfiguring parameters of the functional components displaying the second execution state in the editing interface, and detecting again until the execution states of all the functional components are the first execution state to obtain a complete program code.
In one embodiment, a code generation button is arranged in the editing interface, the visual program writing platform responds to an operation instruction of a user on the button, and the workflow of the program to be written generates complete program codes according to the configuration parameters of each functional component and the logical relationship among the functional components. And in the process of generating the program code, detecting each link and generating a corresponding execution state. For example, if the program code corresponding to a certain functional component is successfully generated, a first execution state is displayed for the functional component, and if the program code corresponding to a certain functional component is not successfully generated, a second execution state is displayed for the functional component, in this embodiment, the first execution state is represented by displaying a green √ beside the functional component; representing a second execution state by displaying x in red alongside the functional component; in addition, when the program code corresponding to a certain functional component is being generated, a third execution state is displayed on the line upstream of the functional component.
For the detected functional components with the display red x, the parameters are reconfigured, and then the operation instruction generated by the code is executed again until all the functional components display green √, which indicates that the complete program code is obtained.
The method for compiling the visual program is applied to a visual program compiling platform comprising a function component library and an editing interface, and the function components selected from the function component library are dragged to the editing interface; performing parameter configuration on each functional component dragged to the editing interface, and connecting each functional component through lines representing logical relations to obtain a workflow of the program to be written; and generating a complete program code according to the obtained parameters configured by each functional component in the workflow of the program to be written and the logic relationship among the functional components.
Based on the same inventive concept, the embodiment of the present application further provides a device for compiling a visualization program, and since the principle of solving the problem of the device in the embodiment of the present application is similar to that of the method for compiling the visualization program in the embodiment of the present application, the implementation of the device can refer to the implementation of the method, and repeated details are not repeated.
As shown in fig. 8 in the specification, the present application further provides a visualization program writing device, which is applied to a visualization program writing platform, where the visualization program writing platform includes a function component library and an editing interface, and the device includes:
a response module 801, configured to respond to an operation of a user on a function component library, and drag a function component selected from the function component library to an editing interface; the functional components selected from the functional component library are determined according to the workflow of the program to be written, and the functional component library comprises functional components which are suitable for the workflow creation of different types of programs to be written;
the editing module 802 is configured to perform parameter configuration on each functional component dragged into the editing interface, and connect each functional component together through a line representing a logical relationship, so as to obtain a workflow of the program to be written;
the generating module 803 is configured to generate a complete program code according to the obtained parameter configured by each functional component in the workflow of the program to be written and the logical relationship between the functional components.
In some embodiments, the library of functional components includes a text import functional component, a file import functional component, an HTTP bundle sending functional component, a database reading functional component, a script execution functional component, a filter functional component, and a container functional component.
In some embodiments, the editing interface includes a parameter configuration window and a global variable setting unit, and the editing module 802 performs parameter configuration on each functional component dragged into the editing interface, including:
responding to the operation of a user on the parameter configuration window, and respectively configuring the parameters of each functional component dragged to the editing interface;
responding to the operation of the user on the global variable setting unit, and uniformly configuring the common parameters of each functional component dragged to the editing interface.
In some embodiments, the generating module 803 generates a complete program code according to the obtained parameters of each functional component configuration in the workflow of the program to be written and the logical relationship between the functional components, including:
detecting each functional component and an execution state corresponding to the logic relation between the functional components in the program code generation process; wherein the execution state comprises a first execution state in which the corresponding program code is successfully generated according to the functional component and a second execution state in which the corresponding program code is not successfully generated according to the functional component;
different executing states in the code generating process are correspondingly displayed in an editing interface by adopting different graphs;
and reconfiguring parameters of the functional components displaying the second execution state in the editing interface, and detecting again until the execution states of all the functional components are the first execution state to obtain a complete program code.
In some embodiments, the execution states further include a third execution state in accordance with the functional component generating the corresponding program code.
In some embodiments, the functional component library further comprises a functional component private library and a functional component shared library; the device further comprises:
the storage module is used for renaming each function component after parameter configuration and storing the function component after parameter configuration to the function component private library after parameter configuration is carried out on each function component dragged to the editing interface; or renaming the functional components after the parameter configuration and storing the functional components into the functional component shared library.
In some embodiments, the editing module 802, in response to an operation of the functional component library by a user, drags a functional component selected from the functional component library into the editing interface, further includes:
judging whether the workflow of the current program to be written has a similar workflow of a historical writing program, wherein in the process of generating codes by the historical writing program, functional components with well-configured parameters are stored in a functional component private library or a functional component shared library;
and if the functional component exists, responding to the operation of the user on the functional component library, calling the functional component saved in the process of generating the code by the history compiling program from the functional component private library or the functional component shared library, and dragging the functional component to an editing interface.
The visual program compiling device is applied to a visual program compiling platform comprising a function component library and an editing interface, and a response module drags a function component selected from the function component library to the editing interface; parameter configuration is carried out on each functional component dragged to the editing interface through an editing module, and each functional component is connected through a line representing a logical relation, so that the workflow of the program to be compiled is obtained; and generating a complete program code by the generation module according to the obtained parameters configured by each functional component in the workflow of the program to be written and the logic relationship among the functional components.
Based on the same concept of the present invention, as shown in fig. 9 in the specification, an embodiment of the present application provides a structure of an electronic device 900, where the electronic device 900 includes: at least one processor 901, at least one network interface 904 or other user interface 903, memory 905, at least one communication bus 902. A communication bus 902 is used to enable connective communication between these components. The electronic device 900 optionally contains a user interface 903 including a display (e.g., touchscreen, LCD, CRT, holographic (Holographic) or projection (Projector), etc.), a keyboard or a pointing device (e.g., mouse, trackball (trackball), touch pad or touch screen, etc.).
The memory 905 may include a read-only memory and a random access memory, and provides instructions and data to the processor 901. A portion of the memory 905 may also include non-volatile random access memory (NVRAM).
In some embodiments, the memory 905 stores the following elements, executable modules or data structures, or a subset thereof, or an expanded set thereof:
an operating system 9051, which includes various system programs for implementing various basic services and for processing hardware-based tasks;
the application module 9052 contains various applications, such as a desktop (launcher), a Media Player (Media Player), a Browser (Browser), and the like, for implementing various application services.
In the embodiment of the present application, the processor 901 is configured to execute the steps in a visual program writing method by calling the program or the instructions stored in the memory 905, and by presetting functional components, the writing of the program can be realized in a short time, and the error rate is reduced.
The present application also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the method as in a visualization program.
In particular, the storage medium can be a general-purpose storage medium, such as a removable disk, a hard disk, or the like, and when the computer program on the storage medium is executed, the visualization program writing method can be executed.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. The above-described embodiments of the apparatus are merely illustrative, and for example, a division of a unit is merely a division of one logic function, and there may be other divisions when actually implemented, and for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection of devices or units through some communication interfaces, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one position, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments provided in the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application or portions thereof that substantially contribute to the prior art may be embodied in the form of a software product stored in a storage medium and including instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk, and various media capable of storing program codes.
Finally, it should be noted that: the above examples are only specific embodiments of the present application, and are not intended to limit the technical solutions of the present application, and the scope of the present application is not limited thereto.

Claims (10)

1. A visual program writing method is applied to a visual program writing platform, the visual program writing platform comprises a functional component library and an editing interface, and the method comprises the following steps:
responding to the operation of a user on the functional component library, and dragging the functional component selected from the functional component library to an editing interface; the functional components selected from the functional component library are determined according to the workflow of the program to be written, and the functional component library comprises functional components which are suitable for the workflow creation of different types of programs to be written;
performing parameter configuration on each functional component dragged to the editing interface, and connecting each functional component through lines representing logical relations to obtain a workflow of the program to be written;
and generating a complete program code according to the obtained parameters configured by each functional component in the workflow of the program to be written and the logic relationship among the functional components.
2. A visualization program writing method according to claim 1, wherein the function component library includes a text import function component, a file import function component, an HTTP package sending function component, a database reading function component, a script running function component, a filter function component, and a container function component.
3. A visualization program writing method according to claim 2, wherein the editing interface includes a parameter configuration window and a global variable setting unit, and the parameter configuration of each functional component dragged into the editing interface includes the following steps:
responding to the operation of the user on the parameter configuration window, and respectively configuring the parameters of each functional component dragged to the editing interface;
responding to the operation of the user on the global variable setting unit, and uniformly configuring the common parameters of each functional component dragged to the editing interface.
4. A visualization program writing method according to claim 3, wherein the generating of the complete program code according to the obtained parameters of each functional component configuration in the workflow of the program to be written and the logical relationship between the functional components comprises the following steps:
detecting each functional component and an execution state corresponding to the logic relation between the functional components in the program code generation process; wherein the execution state comprises a first execution state in which the corresponding program code is successfully generated according to the functional component and a second execution state in which the corresponding program code is not successfully generated according to the functional component;
different executing states in the code generating process are correspondingly displayed in an editing interface by adopting different graphs;
and reconfiguring parameters of the functional components displaying the second execution state in the editing interface, and re-detecting until the execution states of all the functional components are the first execution state to obtain a complete program code.
5. A visualization program writing method according to claim 4, wherein the execution state further comprises a third execution state in accordance with the functional component generating the corresponding program code.
6. A visualization program writing method according to claim 5, wherein the function component library further comprises a function component private library and a function component shared library; after the parameter configuration is carried out on each functional component dragged to the editing interface, the method further comprises the following steps:
renaming the function component after parameter configuration and storing the function component into a function component private library;
or renaming the functional components after the parameter configuration and storing the functional components into the functional component shared library.
7. A visualization program writing method according to claim 6, wherein the dragging the selected functional component from the functional component library to the editing interface in response to the user operating the functional component library comprises the following steps:
judging whether the workflow of the current program to be written has a workflow of a historical writing program similar to the workflow of the current program to be written, wherein in the process of generating codes by the historical writing program, functional components with well-configured parameters are stored in a functional component private library or a functional component shared library;
and if the functional component library exists, responding to the operation of the user on the functional component library, calling the functional component saved in the process of generating the code by the history compiling program from the functional component private library or the functional component shared library, and dragging the functional component to an editing interface.
8. A visual program writing device is applied to a visual program writing platform, the visual program writing platform comprises a functional component library and an editing interface, and the device comprises:
the response module is used for responding to the operation of a user on the functional component library and dragging the functional components selected from the functional component library to the editing interface; the functional components selected from the functional component library are determined according to the workflow of the program to be written, and the functional component library comprises functional components which are suitable for the workflow creation of different types of programs to be written;
the editing module is used for carrying out parameter configuration on each functional component dragged to the editing interface and connecting each functional component through a line representing a logical relation to obtain a workflow of the program to be compiled;
and the generating module is used for generating a complete program code according to the obtained parameters configured by each functional component in the workflow of the program to be written and the logic relationship among the functional components.
9. An electronic device, comprising: a processor, a memory and a bus, the memory storing machine-readable instructions executable by the processor, the processor and the memory communicating via the bus when the electronic device is operating, the machine-readable instructions when executed by the processor performing the steps of the visualization programming method according to any of claims 1 to 7.
10. A computer-readable storage medium, characterized in that a computer program is stored on the computer-readable storage medium, which computer program, when being executed by a processor, performs the steps of the visualization program writing method according to any one of claims 1 to 7.
CN202211441795.0A 2022-11-17 2022-11-17 Visual program compiling method and device, electronic equipment and storage medium Pending CN115934069A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211441795.0A CN115934069A (en) 2022-11-17 2022-11-17 Visual program compiling method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211441795.0A CN115934069A (en) 2022-11-17 2022-11-17 Visual program compiling method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN115934069A true CN115934069A (en) 2023-04-07

Family

ID=86699984

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211441795.0A Pending CN115934069A (en) 2022-11-17 2022-11-17 Visual program compiling method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115934069A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117032536A (en) * 2023-09-04 2023-11-10 镁佳(北京)科技有限公司 Method and device for quickly constructing OTX diagnostic sequence

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117032536A (en) * 2023-09-04 2023-11-10 镁佳(北京)科技有限公司 Method and device for quickly constructing OTX diagnostic sequence

Similar Documents

Publication Publication Date Title
US11733669B2 (en) Task based configuration presentation context
EP1849064A1 (en) Applying coding standards in graphical programming environments
CN107015791B (en) Processing method, device and system for generating chart component system
US10942715B2 (en) Composable context menus
CN112506500B (en) Visual control creating method and device
CN108038241A (en) Integrated WEB visual workflows method, apparatus, readable storage medium storing program for executing and system
CN115934069A (en) Visual program compiling method and device, electronic equipment and storage medium
US11366567B2 (en) Preferential automation view curation
US20090031226A1 (en) Method and System for Extending Task Models for Use In User-Interface Design
CN113741881A (en) RPA visual process design method
CN101710275B (en) Gui tool is utilized to carry out the method and system of editing stream logic and screens
CN110764864A (en) Terraform-based visual resource arrangement method
CN115061746A (en) Jenkins-based vehicle-mounted network controller product development method and system
EP3629149A1 (en) Project autonomy in industrial automation design environments
CN114518875A (en) Graphical programming system and programming method thereof
KR20210070896A (en) Cloud system realization apparatus and method, recording medium storing program for executing the same
CN111679832A (en) Tool assembly integration method and device based on DevOps platform
JP5540856B2 (en) Apparatus and method for setting a workflow
KR20200022254A (en) Apparatus and method for configuration of os based on self-defined definition
CN116431142B (en) High-efficiency programming method capable of being quickly constructed and not prone to error
CN112000366B (en) System parameter configuration method and device based on code generator
JP7391269B1 (en) FA control program generation support program, FA control program generation support device, FA control program generation support method
US8516307B2 (en) Execution layer debugger
CN115016781A (en) Embedded software development method and device, electronic equipment and readable storage medium
JP4439947B2 (en) Development process support apparatus, development process support method, and development process support program

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination