CN114764325A - Service logic generation method, device and terminal - Google Patents

Service logic generation method, device and terminal Download PDF

Info

Publication number
CN114764325A
CN114764325A CN202110038659.6A CN202110038659A CN114764325A CN 114764325 A CN114764325 A CN 114764325A CN 202110038659 A CN202110038659 A CN 202110038659A CN 114764325 A CN114764325 A CN 114764325A
Authority
CN
China
Prior art keywords
node
service
logic
target
determining
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
CN202110038659.6A
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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN202110038659.6A priority Critical patent/CN114764325A/en
Publication of CN114764325A publication Critical patent/CN114764325A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/20Software design
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/60Generating or modifying game content before or while executing the game program, e.g. authoring tools specially adapted for game development or game-integrated level editor

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Telephonic Communication Services (AREA)

Abstract

The invention discloses a method, a device and a terminal for generating service logic, wherein the method comprises the following steps: responding to a first creation request on a service flow editing interface to create an event triggering logic node comprising a service event identifier; responding to a second creation request on the service flow editing interface to acquire a target basic node matched with the type of the target node from the basic node library; the target basic node comprises a node capability editing interface, and the node capability editing interface is configured with service capability information; responding to the selection instruction of the service capability information, determining the target service capability of the target basic node to obtain a service logic node; determining a logic node calling relationship in response to the associated instructions for the event-triggered logic node and the service logic node; and generating the target business logic according to the calling relation of the logic nodes. The invention enables a non-programmer to rapidly edit and generate the required business logic in a flow chart mode, and improves the generation efficiency of the business logic.

Description

Service logic generation method, device and terminal
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a method, an apparatus, and a terminal for generating business logic.
Background
In the related art, when implementing service logic such as logic of a certain game stage or logic of an entire game, a visual logic editor such as PlayMaker based on a finite-state machine and Blueprint based on function call is generally provided.
The basic principle of PlayMaker is a finite state machine, in which a developer defines several operations and the state that each operation is likely to produce, and the user connects the state of the operation with other operations to form a logical chain, as shown in fig. 1 a. The basic principle of Blueprint is to visualize function-level calls, in PlayMaker, as shown in fig. 1b, a developer implements several functions, defines parameters and return values required by the functions, and a user connects the functions in series, connects corresponding variables to the parameters of each function, can perform mathematical or logical operations on the variables, and needs to use various branch controllers if a logical branch is encountered.
However, the above editing method of the service logic is not friendly to the service planning staff, and the planning staff needs to care about the operation or the logic granularity is too fine, so that the service logic can be edited only with a certain programming basis; and the operations or logics executed at the same time are inconvenient to gather together, so that the connection in the logic flow becomes redundant and complicated, and the later maintenance and processing are inconvenient.
Disclosure of Invention
In order to solve the problems in the prior art, embodiments of the present invention provide a method, an apparatus, and a terminal for generating service logic. The technical scheme is as follows:
in one aspect, a method for generating business logic is provided, where the method includes:
responding to a first creation request on a service flow editing interface, and creating an event triggering logic node; the event triggering logic node comprises a service event identifier;
responding to a second creation request on the service flow editing interface, and acquiring a target basic node matched with the type of the target node from the basic node library; the target basic node comprises a node capability editing interface, and the node capability editing interface is configured with service capability information;
responding to the selection instruction of the service capability information, determining the target service capability of the target basic node, and obtaining a service logic node;
responding to the associated instructions of the event trigger logic node and the service logic node, and determining a logic node calling relationship;
and generating the target business logic according to the calling relation of the logic node.
In another aspect, an apparatus for generating business logic is provided, the apparatus comprising:
The first creating module is used for responding to a first creating request on the service flow editing interface and creating an event triggering logic node; the event triggering logic node comprises a service event identifier;
the second establishing module is used for responding to a second establishing request on the service flow editing interface and acquiring a target base node matched with the type of the target node from the base node library; the target basic node comprises a node capability editing interface, and the node capability editing interface is configured with service capability information;
a node service capability determining module, configured to determine, in response to the selection instruction of the service capability information, a target service capability of the target base node, to obtain a service logic node;
a calling relation determining module, configured to determine a logic node calling relation in response to an instruction associated with the event-triggered logic node and the service logic node;
and the service logic generation module is used for generating target service logic according to the logic node calling relationship.
As an optional implementation manner, if the target node type is a first node type, the target base node is a first base node, and the service capability information of the first base node includes a plurality of service scripts;
Correspondingly, the node service capability determining module comprises:
the first determining module is used for responding to the selection instruction of the plurality of service scripts and determining at least one target service script;
a second determining module, configured to determine an execution order of the at least one target service script in response to a position adjustment instruction for the at least one target service script;
and a third determining module, configured to determine, according to an execution sequence of the at least one target service script, a target service capability of the target base node.
As an optional implementation manner, if the target node type is the second node type, the target base node includes an instant condition sub-node and the first base node; the service capability information of the instant condition sub-node comprises an instant judgment condition;
correspondingly, the node service capability determining module comprises:
the instant condition determining module is used for responding to a selection instruction of the instant judgment condition of the instant condition sub-node and determining a target instant judgment condition;
the first establishing module is used for establishing calling of the first basic node when the judgment result of the target instant judgment condition is true;
A fourth determining module, configured to determine at least one target service script in response to a selection instruction for the plurality of service scripts of the first base node;
a fifth determining module, configured to determine an execution order of the at least one target service script in response to a position adjustment instruction for the at least one target service script;
a sixth determining module, configured to determine, according to the target determining condition and the execution sequence of the at least one target service script, a target service capability of the target base node.
As an optional implementation manner, if the target node type is a third node type, the target base node includes a monitoring sub-node and the first base node; the service capability information of the monitoring sub-node comprises a monitoring triggering condition;
correspondingly, the node service capability determining module comprises:
the monitoring condition module is used for responding to a selection instruction of the monitoring triggering condition of the monitoring sub-node and determining a target monitoring triggering condition;
the first calling module is used for calling the first basic node when the target monitoring triggering condition is met;
a seventh determining module, configured to determine at least one target service script in response to a selection instruction for the plurality of service scripts of the first base node;
An eighth determining module, configured to determine an execution order of the at least one target service script in response to a position adjustment instruction for the at least one target service script;
a ninth determining module, configured to determine a target service capability of the target base node according to the target monitoring trigger condition and the execution sequence of the at least one target service script.
As an optional embodiment, the at least one target service script comprises a jump branch script; the calling relation determining module comprises:
a first call relation determining module, configured to determine, in response to an instruction associated with an output port of the event-triggered logic node and an input port of a first service logic node, a first call relation of the event-triggered logic node to the first service logic node;
a second call relation determining module, configured to determine, in response to an associated instruction for an output port of the jump branch script and an input port of a second service logic node, a second call relation of the jump branch script to the second service logic node;
wherein the service logic nodes comprise the first service logic node and a second service logic node; the calling relation of the logic node comprises the first calling relation and the second calling relation.
As an optional embodiment, the at least one target service script comprises a wait for execution script; the node service capability determining module further comprises:
the waiting duration determining module is used for responding to a setting instruction of the time parameter of the script to be executed and determining the waiting execution duration;
correspondingly, when determining the target service capability of the target base node, the node service capability determining module further determines the target service capability of the target base node according to the waiting execution duration.
As an optional embodiment, the apparatus further comprises:
the packaging module is used for responding to a packaging instruction of the target business logic and packaging the target business logic to obtain a sub-process logic node;
an input/output node creation module for creating an input node and an output node, respectively, in response to an input/output creation request for the sub-flow logic node;
a tenth determining module for determining input ports and output ports of the sub-flow logic nodes in response to the associated instructions associating the input nodes and output nodes with the sub-flow logic nodes, respectively;
And the storage module is used for responding to the storage instruction and storing the sub-flow logic node.
As an optional implementation, the apparatus further comprises:
the sub-process logic node calling module is used for responding to a sub-process logic node calling request on the service process editing interface and calling a target sub-process logic node;
correspondingly, the calling relation determining module is configured to determine a calling relation of a logic node in response to an associated instruction for the event-triggered logic node, the service logic node, and the target sub-process logic node.
In another aspect, a terminal is provided, which includes a processor and a memory, where at least one instruction or at least one program is stored in the memory, and the at least one instruction or the at least one program is loaded and executed by the processor to implement the service logic generation method.
In another aspect, a computer-readable storage medium is provided, in which at least one instruction or at least one program is stored, and the at least one instruction or the at least one program is loaded and executed by a processor to implement the business logic generation method as described above.
In another aspect, a computer program product or computer program is provided, the computer program product or computer program comprising computer instructions stored in a computer readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the business logic generation method provided in the above-mentioned various alternative implementations.
The embodiment of the invention creates an event trigger logic node containing a service event identifier by responding to a first creation request on a service flow editing interface, acquires a target base node matched with the type of the target node from a base node library by responding to a second creation request on the service flow editing interface, the target base node includes a node capability editing interface configured with service capability information, and further determines a target service capability of the target base node to obtain a service logic node in response to a selection instruction of the service capability information of the node capability editing interface, and determining a logic node calling relationship in response to the associated instructions of the event trigger logic node and the service logic node, so as to generate the target service logic according to the logic node calling relationship. In the technical scheme, a non-programmer can quickly edit and generate the required business logic in a flow chart mode, fine-grained attention of a planning worker to operation or logic is not needed, the association relation in the logic flow is simple and clear, post-maintenance and processing are facilitated, and the generation efficiency of the business logic is improved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to these drawings without creative efforts.
FIG. 1a is a schematic representation of the prior art PlayMaker rationale;
FIG. 1b is a schematic representation of the basic principles of Blueprint in the prior art;
fig. 2 is a schematic flowchart of a business logic generation method according to an embodiment of the present invention;
FIG. 3a is a conceptual diagram, a structural block diagram, and an interface diagram of an event-triggered logical node according to an embodiment of the present invention;
FIG. 3b is an exemplary parameter editing of a service script provided by an embodiment of the present invention;
FIG. 3c is a conceptual diagram, a structural block diagram, and an interface schematic diagram of a generic service logic node according to an embodiment of the present invention;
FIG. 3d is a conceptual diagram, a structural block diagram, and an interface schematic diagram of an instant condition logical node according to an embodiment of the present invention;
FIG. 3e is a conceptual diagram, a structural block diagram, and an interface diagram of a trigger condition logical node according to an embodiment of the present invention;
FIG. 4a is a conceptual diagram, a structural block diagram and an interface diagram of the execution wait among the internal logics of a common logic node according to the embodiment of the present invention;
FIG. 4b is a conceptual diagram, a block diagram, and an interface diagram illustrating the execution of internal logic branches between internal logics of a generic logic node according to an embodiment of the present invention;
FIG. 4c is a block diagram and an interface diagram of a custom flow script executed between internal logics of a generic logic node according to an embodiment of the present invention;
FIG. 5 is a conceptual diagram, a structural block diagram, and an interface schematic of the loop logic provided by embodiments of the present invention;
FIG. 6a is a schematic diagram of an interface defining input nodes and output nodes for sub-process logic nodes according to an embodiment of the present invention;
FIG. 6b is an exemplary diagram of a call sub-flow logical node provided by an embodiment of the present invention;
FIG. 7 is a schematic diagram of a basic underlying framework involved in providing an embodiment of the present invention;
FIG. 8 is a diagram of a data structure involved in providing an embodiment of the present invention;
fig. 9 is a block diagram of a service logic generation apparatus according to an embodiment of the present invention;
fig. 10 is a block diagram of a hardware structure of a terminal according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be described clearly and completely with reference to the accompanying drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be obtained by a person skilled in the art without any inventive step based on the embodiments of the present invention, are within the scope of the present invention.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are capable of operation in sequences other than those illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or server that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
The embodiment of the invention provides a business logic generation method, which can be applied to a business logic generation device, and the business logic generation device can be configured in electronic equipment such as a terminal and the like. The terminal may include, but is not limited to, a smart phone, a desktop computer, a tablet computer, a notebook computer, a digital assistant, and the like.
Please refer to fig. 2, which is a flowchart illustrating a business logic generating method according to an embodiment of the present invention. It is noted that the present specification provides the method steps as described in the examples or flowcharts, but may include more or less steps based on routine or non-inventive labor. The order of steps recited in the embodiments is merely one manner of performing the steps in a multitude of sequences, and does not represent the only order of performance. In actual system or product execution, sequential execution or parallel execution (e.g., parallel processor or multi-threaded environment) may be possible according to the embodiments or methods shown in the figures. Specifically, as shown in fig. 2, the method may include:
s201, responding to a first creation request on a service flow editing interface, and creating an event triggering logic node.
Wherein the event triggering logic node comprises a service event identifier, and the service event identifier is used for identifying an event triggering the service logic, such as a starting event triggering the execution of the service logic. As shown in fig. 3a, the concept diagram, the structural diagram and the interface diagram of the event triggered logic node are shown, and the event triggered logic node further includes an output port through which a call relationship can be established between the event triggered logic node and other logic nodes.
S203, responding to the second establishing request on the service flow editing interface, and obtaining the target basic node matched with the type of the target node from the basic node library.
The second creation request may carry a target node type, the target base node includes a node capability editing interface, and the node capability editing interface is configured with service capability information. In a specific implementation, a user may click a right button on a business process editing interface to call out a node type list, may select a target node type to be created in the node type list, and after the target node type is selected, the terminal may generate a second creation request based on the target node type, and obtain a target base node matched with the target node type from a base node library in response to the second creation request.
The node capability of the basic node in the basic node library in the embodiment of the invention allows a user to set according to actual needs, wherein the node capability is a logic function which can be realized by the node, and the node capability can be determined according to the selection of the user on the service capability information. The node types of the base nodes contained in the base node library may include a common node type, an instant condition node type, a trigger condition node type and an event node type, the service capability information corresponding to each base node may correspond to the node type thereof, and the service capability information under different node types may be the same or different.
It should be noted that the base node further includes an input port and an output port, and the base node can be associated through the input port and the output port, so as to establish a call to the base node.
S205, responding to the selection instruction of the service capability information, determining the target service capability of the target basic node, and obtaining a service logic node.
Specifically, a user can call out the service capability information corresponding to the node capability editing interface through the node capability editing interface of the target base node, and select the target service capability information from the service capability information, so that the target base node can have the target node capability required by the user based on the selected target service capability information, that is, the corresponding service logic node can be obtained.
As a possible implementation manner, if the destination node type is the first node type, that is, the aforementioned common node type, the destination base node matched with the destination node type is the first base node, and the service capability information of the first base node may include a plurality of service scripts. Correspondingly, in step S205, in response to the instruction for selecting the service capability information, determining the target service capability of the target base node may include the following steps:
(1) And responding to the selection instructions of the plurality of service scripts, and determining at least one target service script.
Specifically, the user may call the plurality of service scripts through the node capability editing interface of the first base node, and may select one or more required service scripts from the plurality of service scripts, where the selected one or more required service scripts are the determined at least one target service script.
In practical applications, the service parameters in the selected service script may also be set, for example, as shown in fig. 3b, a parameter editing example of a service script is provided, the service script provides a pull-down list for each service parameter, and a user may select a parameter value of the service parameter according to needs.
(2) And determining the execution sequence of the at least one target service script in response to the position adjustment instruction of the at least one target service script.
Specifically, the user may adjust the position relationship of the selected at least one target service script according to the actual need for the node service capability, so as to determine the execution sequence of the at least one target service script.
(3) And determining the target service capability of the target base node according to the execution sequence of the at least one target service script.
As shown in fig. 3c, a conceptual diagram, a structural diagram and an interface schematic diagram of a general service logic node are shown, where the general service logic node is a first basic node with a target service capability, where the target service capability is determined by a plurality of selected scripts, such as script 1 and script 2, in the structural diagram and a location relationship of each selected script.
As a possible implementation manner, if the target node type is the second node type, that is, the instant condition node type, the target base node matched with the target node type includes an instant condition subnode and the first base node, the service capability information of the instant condition subnode includes an instant determination condition, and when the determination result of the determination condition is true, the first base node is executed. Correspondingly, in step S205, in response to the selection instruction of the service capability information, determining the target service capability of the target base node may include the following steps:
(1) and responding to the selection instruction of the instant judgment condition of the instant condition sub-node to determine a target instant judgment condition.
Specifically, the immediate condition sub-node is pre-configured with a plurality of immediate judgment conditions, which are immediate judgment conditions, so that a user can select a target immediate judgment condition from the plurality of immediate judgment conditions as required. It is understood that the parameter value of the immediate condition parameter can be set for the selected target immediate judgment condition.
(2) And when the judgment result of the target instant judgment condition is true, establishing the call of the first basic node.
In the embodiment of the invention, the base node of the instant condition node type combines the instant condition sub-node and the first base node in the same process node, and the first base node in the process node is used as an execution object when the instant condition sub-node instant judgment condition is true, so that a user only needs to select the instant judgment condition in the instant condition sub-node and select the business capability information of the first base node in the process node when editing the base node of the instant condition node type.
(3) And responding to a selection instruction of the plurality of service scripts of the first base node, and determining at least one target service script.
(4) And determining the execution sequence of the at least one target service script in response to the position adjustment instruction of the at least one target service script.
(5) And determining the target service capability of the target base node according to the target instant judgment condition and the execution sequence of the at least one target service script.
Fig. 3d shows a conceptual diagram, a structural diagram and an interface schematic diagram of an instant condition logic node, where the instant condition logic node is a basic node of an instant condition node type with a target service capability, where the target service capability is determined by an instant condition in the structural diagram, a plurality of selected scripts such as script 1 and script 2, and a position relationship of each selected script.
As a possible implementation manner, if the target node type is the third node type, that is, the aforementioned trigger condition node type, the target base node matched with the target node type includes a snooping sub-node and the aforementioned first base node, the service capability information of the snooping sub-node includes a snooping trigger condition, and when the snooping trigger condition is satisfied, the first base node is executed. The monitoring trigger condition is not determined immediately, but is determined by delaying the triggering, for example, an event is monitored, and when the event actually occurs, the monitoring trigger condition is satisfied, and the first base node is executed. Correspondingly, in step S205, in response to the selection instruction of the service capability information, determining the target service capability of the target base node may include the following steps:
(1) and responding to a selection instruction of the monitoring triggering condition of the monitoring sub-node, and determining a target monitoring triggering condition.
Specifically, a plurality of monitoring triggering conditions are pre-configured in the monitoring sub-node, the monitoring triggering conditions are delayed to trigger and judge, and a user can select a target monitoring triggering condition from the plurality of monitoring triggering conditions according to needs. It is understood that the setting of the parameter value of the interception trigger parameter may be performed for the selected target interception trigger.
(2) And when the target monitoring triggering condition is met, calling the first basic node.
In the embodiment of the invention, the monitoring sub-node and the first basic node are combined in the same process node by the basic node of the trigger condition node type, the first basic node in the process node is taken as an execution object only when the monitoring sub-node is met, and a user only needs to select the monitoring trigger condition in the monitoring sub-node and select the service capability information of the first basic node in the process node when editing the basic node of the trigger condition type.
(3) And responding to a selection instruction of the plurality of service scripts of the first base node, and determining at least one target service script.
(4) And determining the execution sequence of the at least one target service script in response to the position adjustment instruction of the at least one target service script.
(5) And determining the target service capability of the target base node according to the target monitoring trigger condition and the execution sequence of the at least one target service script.
As shown in fig. 3e, the concept diagram, the structural diagram and the interface diagram of the trigger condition logic node are shown, and the trigger condition logic node is a basic node of a trigger condition node type with a target service capability, where the target service capability is determined by monitoring the trigger condition in the structural diagram, a plurality of selected scripts 1, 2 and the like, and the position relationship of each selected script.
The embodiment of the invention configures the node type of the basic node into the common node type, the instant condition node type and the trigger condition node type based on the function of the flow node in the flow chart, so that a user does not need to pay attention to specific function information in the actual service logic editing process, thereby not only being beneficial to simplifying the subsequent association between the nodes, but also greatly reducing the requirements on the user and improving the editing efficiency and maintainability of the service logic.
In practical applications, it is sometimes necessary to wait for a certain time or number of frames to execute subsequent logic between internal logics of a common service logic node, and based on this, as a possible implementation manner, the service capability information of the first base node may further include a wait-to-execute script, so that when the internal logics of the common service logic node need to wait for a certain time or number of frames to execute again, the wait-to-execute script may be selected, that is, the at least one target service script may further include a wait-to-execute script. Correspondingly, after at least one target service script is determined in response to the selection instruction of the plurality of service scripts, the method may further include: and determining the waiting execution time length in response to a setting instruction of the time parameter of the waiting execution script. As shown in fig. 4a, the conceptual diagram, the structural block diagram and the interface diagram of executing wait among internal logics of a common logic node can implement a wait instruction of internal logic of a service logic node by setting a time parameter, such as a frame number, of a wait execution script. In the conceptual diagram of fig. 4a, "logic 1" represents a logic formed by a part of the target service script, and "logic 2" represents a logic formed by another part of the target service script. Then, in step S205, when determining the target service capability of the target base node, the target service capability of the target base node may also be determined according to the wait execution duration.
And S207, responding to the associated instructions of the event trigger logic node and the service logic node, and determining a logic node calling relationship.
In the embodiment of the present invention, as shown in fig. 3a to 3e, each basic node is configured with an input port and an output port, and after the service logic nodes with various target service capabilities are obtained in step S205, the input ports and the output ports of each service logic node may be connected to establish the calling relationship between the service logic nodes and the calling relationship between the event triggered logic node and the service logic node.
As a possible implementation manner, in order to implement execution of internal logic branches between internal logics of the common logic node, the service capability information of the first base node may further include a jump branch script, so that when an internal logic branch needs to be performed, the jump branch script may be selected, that is, the aforementioned at least one target service script may further include a jump branch script. Correspondingly, the determining a logic node calling relationship in response to the instruction associated with the event trigger logic node and the service logic node may include the following steps:
(1) And determining a first calling relation of the event trigger logic node to the first service logic node in response to the associated instructions to the output port of the event trigger logic node and the input port of the first service logic node.
In a specific implementation, a user may draw a connection line between an output port of the event-triggered logic node and an input port of the first service logic node, and establish a first call relationship of the event-triggered logic node to the first service logic node through the connection line. The first service logic node is a service logic node which needs to be executed after the event triggering logic node is triggered.
(2) And responding to the associated instructions of the output port of the jump branch script and the input port of the second service logic node, and determining a second calling relationship of the jump branch script to the second service logic node.
In the embodiment of the invention, each service script in the service capability information of the basic node can also be provided with a corresponding output port, and the call relation of the service script to other service logic nodes can be established through the output port of the service script. As shown in fig. 4b, the concept diagram, the structure diagram and the interface diagram of executing internal logic branches between internal logics of a common logic node can establish a second call relationship of the jump branch script to a second service logic node by connecting an output port of the jump branch script with an input port of the second service logic node, so that the target node capability of the target base node also includes the node capability of the second service logic node. Wherein, the "logic 1" in the conceptual diagram of fig. 4b represents the logic formed by a part of the target service script, and the "logic 2" represents the logic formed by another part of the target service script. It is understood that the second service logic node may be any service logic node, and the logic node calling relationship in step S207 may include the first calling relationship and the second calling relationship.
It can be understood that the wait-to-execute script and the skip branch script shown in fig. 4a and 4b are both used to implement flow control on the internal logic flow of the common service logic node, and in order to further improve flexibility of service logic editing, in the embodiment of the present invention, the service capability information of the first base node may further include a custom flow script, and when a user needs to customize a flow control instruction according to an actual requirement, the custom flow script may be selected, so that any custom flow control script may be extended. As shown in fig. 4c, the user can expand multiple flow branches according to actual needs by executing the structure diagram and the interface diagram of the custom flow script between the internal logics of the common logic nodes.
As a possible implementation, when the cyclic logic needs to be executed, it is only necessary to connect several service logic nodes in series by using the connection lines, and connect the output port of the last service logic node with the input port of the first service logic node. However, in order to avoid dead loops, all of the service logic nodes used for forming the loop logic cannot be ordinary service logic nodes, and at least one immediate condition logic node and/or trigger condition logic node is required in the middle. Taking the trigger condition logic node as an example, as shown in a conceptual diagram, a structural block diagram, and an interface schematic diagram of the cyclic logic shown in fig. 5, by connecting an output port of the trigger condition logic node with an input port thereof, a call relationship of the output port to the input port can be established, so as to form a call relationship of the cyclic logic.
In practical applications, communication between different service logics is often involved, and as a possible implementation manner, the communication between different service logics is implemented in an event manner in the embodiment of the present invention. Specifically, when editing different service logics, event trigger logic nodes including a target communication event can be created for two service logic flows that need to communicate, and an output port of the event trigger logic node of the information sender is connected with an input port of the event trigger logic node of the information receiver, so that communication between the two corresponding service logic flows is established. When the service logic of the information sender triggers the target communication event, the event trigger logic node of the information sender sends the target communication event to the event trigger logic node of the information receiver, thereby realizing the communication between the two.
S209, generating the target business logic according to the logic node calling relationship.
In the embodiment of the invention, in order to improve the generation efficiency of the business logic, a completed business logic is allowed to be packaged into a sub business logic, so that the sub business logic can be integrally called in the editing process of other business logics (which can be called as parent business logics). Based on this, in step S209, after generating the target service logic according to the logic node calling relationship, the method may further include the following steps:
(1) And responding to the packaging instruction of the target business logic, and packaging the target business logic to obtain a sub-process logic node.
(2) And responding to the input and output establishment request of the sub-process logic nodes, and respectively establishing input nodes and output nodes.
In order to improve the flexibility of the sub-flow logic node calling, the number of the input nodes and the number of the output nodes can be multiple, and the specific number can be determined according to actual needs.
(3) Responsive to an associated instruction associating the input node and the output node with the sub-flow logic node, respectively, an input port and an output port of the sub-flow logic node are determined.
As shown in fig. 6a, the interface schematic diagram defining the input node and the output node of the sub-process logic node may define the input node and the output node of the sub-process logic node by creating the input node and the output node and connecting the input node and the output node to the input port and the output port of the sub-process logic node, respectively.
It will be appreciated that, as shown in the exemplary diagram of FIG. 6b for invoking sub-process logic nodes, a sub-process logic node may have multiple input nodes and output nodes, and that when the sub-process logic node is invoked by a parent business logic, the parent business logic may select which input node and which output nodes of the sub-process logic node to connect.
(4) And responding to a storage instruction, and storing the sub-flow logic nodes.
Based on this, the method for generating service logic according to the embodiment of the present invention may further include the steps of: and responding to the sub-process logic node calling request on the service process editing interface, and calling the target sub-process logic node. However, when determining the logic node calling relationship in response to the association instruction for the event-triggered logic node and the service logic node in step S207, the logic node calling relationship may be determined in response to the association instruction for the event-triggered logic node, the service logic node, and the target sub-process logic node, so as to simplify the connection relationship between the service logic and the service logic, thereby not only improving the editing efficiency of the service logic, but also improving the maintainability of the service logic in the later period.
The embodiment of the invention creates the basic nodes of each node type by thinking of a flow chart, and the basic underlying framework related to the embodiment of the invention is shown as figure 7.
The KFGraph corresponds to a flowchart, and in a narrow sense, a flowchart is a logical flow initiated from a start event. However, in consideration of the management cost of the flowcharts, the somewhat narrow-sense flowcharts are very simple and do not need to be made into a single KFGraph, and therefore, the flowcharts corresponding to the kfgraphs are generalized flowcharts, which may have a plurality of start events corresponding to a plurality of flow logics. The method can provide easy-to-use editor operation for the generalized flow chart in a business flow editor, can select a starting event in the editor, and only displays nodes which are directly or indirectly connected with the nodes and also supports grouping of a plurality of nodes selected in the flow chart. These ease of use solutions are also part of the overall solution. The main functional logic of the KFgraph is to analyze the configuration of the flow chart and construct a graph-like topological structure of various nodes according to the configuration.
KFGraphBlockBase is the base class of various nodes in the flow chart; KFGraphBlockEventPoint is used for realizing event nodes of communication between the flow charts; KFGraphBlockExportPoint is used for realizing input and output nodes in the flow chart nesting function; KFGraphBlockNormal is used for realizing common logic nodes of the flow chart; the KFGraphDecocorator is used for realizing condition-based logic nodes, such as instant conditions and trigger conditions; KFGraphFrame is used for realizing specific logic in the common logic node; KFGraphScript is used to implement scripts of specific logic in common logical nodes.
Fig. 8 shows a data structure according to an embodiment of the present invention, and based on the data structure, a main logic flow according to an embodiment of the present invention includes the following steps:
(1) start event node: firstly, the event triggering logic node monitors the event corresponding to the node name, finds the target node through the Outputs information of the node, and then executes the logic of the target node.
(2) Common service logical node: firstly, the Input port of the service logic node of the common node type is called, and then the target scripts in the Frame script list are sequentially executed.
(3) Instant conditional logical node: firstly, the Input port of the instant condition sub-node is called, then the condition logic in the Decorator is executed, if the condition logic is judged to be true, the target script in the Frame script list is executed according to the sequence execution in the (2) common service logic node.
(4) Triggering condition logical nodes: firstly, an Input port of a monitoring sub-node is called, then condition monitoring in a Decorator is activated, if the monitoring is triggered, whether condition logic is true is judged, and if the condition logic is true, execution is carried out according to a target script in a Frame script list sequentially executed in (2) common service logic nodes.
(5) And (3) circulation: firstly, an Input port of a service logic node of a common node type is called, then the steps are executed according to the actual situation in the steps of (2), (3) or (4), and a target node is found through the information of a certain output port of the node, if the target node is the node, the step of calling the Input port is executed, and the process is circulated.
(6) Nesting of the flow chart: firstly, an Input port of a service logic node of a common node type is called, then if Target designates a module function and the module is a flow chart module, an example of the flow chart module is found, if the example is not found, an example is created according to the type information of the flow chart module, and finally the designated node in the flow chart corresponding to the example is executed.
(7) Communication between flowcharts: first, in example 1 of the flowchart, an event of the node name is issued by a node of the event type, and then, in example 2 of the flowchart, the event of the node name is monitored by the node of the event type.
In the embodiment of the invention, a non-programmer can quickly edit and generate the required business logic in a flow chart mode without planning fine-grained attention of personnel to operation or logic, and the association relation in the logic flow is simple and clear, so that the method is convenient for later maintenance and processing, is favorable for improving the generation efficiency of the business logic, and can be applied to the generation of the flow logic of the game level and the flow logic of the whole game.
Corresponding to the service logic generation methods provided in the foregoing embodiments, embodiments of the present invention further provide a service logic generation apparatus, and since the service logic generation apparatus provided in the embodiments of the present invention corresponds to the service logic generation methods provided in the foregoing embodiments, the implementation of the foregoing service logic generation method is also applicable to the service logic generation apparatus provided in this embodiment, and is not described in detail in this embodiment.
Referring to fig. 9, it shows a schematic structural diagram of a service logic generation apparatus according to an embodiment of the present invention, where the apparatus has a function of implementing the service logic generation method in the foregoing method embodiment, and the function may be implemented by hardware or by hardware executing corresponding software. As shown in fig. 9, the apparatus may include:
A first creating module 910, configured to create an event-triggered logical node in response to a first creation request on a business process editing interface; the event triggering logic node comprises a service event identifier;
a second creating module 920, configured to, in response to a second creating request on the service flow editing interface, obtain a target base node matching the target node type from the base node library; the target base node comprises a node capability editing interface, and the node capability editing interface is configured with service capability information;
a node service capability determining module 930, configured to determine, in response to the selection instruction of the service capability information, a target service capability of the target base node, so as to obtain a service logic node;
a calling relation determining module 940, configured to determine a calling relation of a logic node in response to an instruction associated with the event-triggered logic node and the service logic node;
and a service logic generation module 950, configured to generate a target service logic according to the logic node calling relationship.
As an optional implementation manner, if the target node type is a first node type, the target base node is a first base node, and the service capability information of the first base node includes a plurality of service scripts;
Accordingly, the node service capability determining module 930 includes:
the first determining module is used for responding to the selection instruction of the plurality of service scripts and determining at least one target service script;
a second determining module, configured to determine an execution order of the at least one target service script in response to a position adjustment instruction for the at least one target service script;
and a third determining module, configured to determine, according to an execution sequence of the at least one target service script, a target service capability of the target base node.
As an optional implementation manner, if the target node type is the second node type, the target base node includes an instant condition sub-node and the first base node; the service capability information of the instant condition sub-node comprises an instant judgment condition;
accordingly, the node service capability determining module 930 includes:
the instant condition determining module is used for responding to a selection instruction of the instant judgment condition of the instant condition sub-node and determining a target instant judgment condition;
the first establishing module is used for establishing calling of the first basic node when the judgment result of the target instant judgment condition is true;
A fourth determining module, configured to determine at least one target service script in response to a selection instruction for multiple service scripts of the first base node;
a fifth determining module, configured to determine an execution order of the at least one target service script in response to a position adjustment instruction for the at least one target service script;
a sixth determining module, configured to determine, according to the target determining condition and the execution sequence of the at least one target service script, a target service capability of the target base node.
As an optional implementation manner, if the target node type is a third node type, the target base node includes a monitoring sub-node and the first base node; the service capability information of the monitoring sub-node comprises a monitoring triggering condition;
accordingly, the node service capability determining module 930 includes:
the monitoring condition module is used for responding to a selection instruction of the monitoring triggering condition of the monitoring sub-node and determining a target monitoring triggering condition;
the first calling module is used for calling the first basic node when the target monitoring triggering condition is met;
a seventh determining module, configured to determine at least one target service script in response to a selection instruction for the plurality of service scripts of the first base node;
An eighth determining module, configured to determine an execution order of the at least one target service script in response to a position adjustment instruction for the at least one target service script;
a ninth determining module, configured to determine a target service capability of the target base node according to the target monitoring trigger condition and the execution sequence of the at least one target service script.
As an optional embodiment, the at least one target service script comprises a jump branch script; the call relation determining module 940 includes:
a first call relation determining module, configured to determine, in response to an instruction associated with an output port of the event-triggered logic node and an input port of a first service logic node, a first call relation of the event-triggered logic node to the first service logic node;
a second call relation determining module, configured to determine, in response to an associated instruction for an output port of the jump branch script and an input port of a second service logic node, a second call relation of the jump branch script to the second service logic node;
wherein the service logic nodes comprise the first service logic node and a second service logic node; the logic node calling relationship comprises the first calling relationship and the second calling relationship.
As an optional embodiment, the at least one target service script comprises a wait-to-execute script; the node service capability determining module 930 further includes:
the waiting duration determining module is used for responding to a setting instruction of the time parameter of the script to be executed and determining the waiting execution duration;
correspondingly, when determining the target service capability of the target base node, the node service capability determining module further determines the target service capability of the target base node according to the waiting execution duration.
As an optional embodiment, the apparatus further comprises:
the packaging module is used for responding to a packaging instruction of the target business logic and packaging the target business logic to obtain a sub-process logic node;
an input/output node creation module for creating an input node and an output node, respectively, in response to an input/output creation request for the sub-flow logic node;
a tenth determining module for determining input ports and output ports of the sub-flow logic nodes in response to the associated instructions associating the input nodes and output nodes with the sub-flow logic nodes, respectively;
And the storage module is used for responding to the storage instruction and storing the sub-process logic node.
As an optional embodiment, the apparatus further comprises:
the sub-process logic node calling module is used for responding to a sub-process logic node calling request on the service process editing interface and calling a target sub-process logic node;
correspondingly, the call relationship determining module 940 is specifically configured to determine a call relationship of a logic node in response to an associated instruction for the event triggered logic node, the service logic node, and the target sub-process logic node.
It should be noted that, when the apparatus provided in the foregoing embodiment implements the functions thereof, the division of each functional module is merely used as an example, and in practical applications, the above function distribution may be completed by different functional modules according to needs, that is, the internal structure of the device is divided into different functional modules, so as to complete all or part of the functions described above. In addition, the apparatus and method embodiments provided in the above embodiments belong to the same concept, and specific implementation processes thereof are described in detail in the method embodiments, which are not described herein again.
An embodiment of the present invention provides a terminal, where the terminal includes a processor and a memory, where the memory stores at least one instruction, at least one program, a code set, or an instruction set, and the at least one instruction, the at least one program, the code set, or the instruction set is loaded and executed by the processor to implement the service logic generation method provided in the foregoing method embodiment.
The memory may be used to store software programs and modules, and the processor may execute various functional applications and business logic generation by executing the software programs and modules stored in the memory. The memory may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, application programs required for functions, and the like; the storage data area may store data created according to use of the apparatus, and the like. Further, the memory may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, the memory may also include a memory controller to provide the processor access to the memory.
The method provided by the embodiment of the invention can be executed in a computer terminal, a server or a similar operation device. Taking the example of running on a terminal, fig. 10 is a hardware structure block diagram of the terminal running a service logic generation method provided in the embodiment of the present invention, specifically:
the terminal may include RF (Radio Frequency) circuitry 1010, memory 1020 including one or more computer-readable storage media, input unit 1030, display unit 1040, sensor 1050, audio circuitry 1060, WiFi (wireless fidelity) module 1070, processor 1080 including one or more processing cores, and power source 1090. Those skilled in the art will appreciate that the terminal structure shown in fig. 10 is not intended to be limiting and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components. Wherein:
RF circuit 1010 may be used for receiving and transmitting signals during a message transmission or communication process, and in particular, for receiving downlink information from a base station and then processing the received downlink information by one or more processors 1080; in addition, data relating to uplink is transmitted to the base station. In general, RF circuitry 1010 includes, but is not limited to, an antenna, at least one amplifier, a tuner, one or more oscillators, a Subscriber Identity Module (SIM) card, a transceiver, a coupler, an LNA (low noise amplifier), a duplexer, and the like. Further, the RF circuit 1010 can communicate with a network and other terminals through wireless communication. The wireless communication may use any communication standard or protocol, including but not limited to GSM (Global System for mobile communication), GPRS (General Packet Radio Service), CDMA (Code Division Multiple Access), WCDMA (Wideband Code Division Multiple Access), LTE (Long Term Evolution), e-mail, SMS (short messaging Service), etc.
The memory 1020 may be used to store software programs and modules, and the processor 1080 executes various functional applications and data processing by operating the software programs and modules stored in the memory 1020. The memory 1020 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, application programs required for functions, and the like; the storage data area may store data created according to the use of the terminal, and the like. Further, the memory 1020 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state memory device. Accordingly, memory 1020 may also include a memory controller to provide access to memory 1020 by processor 1080 and input unit 1030.
The input unit 1030 may be used to receive input numeric or character information and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function control. In particular, input unit 1030 may include touch-sensitive surface 1031, as well as other input devices 1032. The touch-sensitive surface 1031, also referred to as a touch display screen or a touch pad, may collect touch operations by a user (e.g., operations by a user on or near the touch-sensitive surface 1031 using a finger, a stylus, or any other suitable object or attachment) thereon or nearby, and drive the corresponding connection device according to a preset program. Optionally, the touch sensitive surface 1031 may comprise two parts, a touch detection means and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts the touch information into touch point coordinates, and sends the touch point coordinates to the processor 1080, and can receive and execute commands sent by the processor 1080. Further, the touch-sensitive surface 1031 may be implemented in various types, such as resistive, capacitive, infrared, and surface acoustic wave. The input unit 1030 may also include other input devices 1032 in addition to the touch-sensitive surface 1031. In particular, other input devices 1032 may include, but are not limited to, one or more of a physical keyboard, function keys (e.g., volume control keys, switch keys, etc.), a track ball, a mouse, a joystick, and the like.
The display unit 1040 may be used to display information input by or provided to a user and various graphical user interfaces of the terminal, which may be made up of graphics, text, icons, video, and any combination thereof. The Display unit 1040 may include a Display panel 1041, and optionally, the Display panel 1041 may be configured in the form of an LCD (Liquid Crystal Display), an OLED (Organic Light-Emitting Diode), or the like. Further, the touch-sensitive surface 1031 may cover the display panel 1041, and when a touch operation is detected on or near the touch-sensitive surface 1031, the touch operation is transmitted to the processor 1080 for determining the type of the touch event, and then the processor 1080 provides a corresponding visual output on the display panel 1041 according to the type of the touch event. Touch-sensitive surface 1031 and display panel 1041 may be implemented as two separate components for input and output functions, although in some embodiments touch-sensitive surface 1031 may be integrated with display panel 1041 for input and output functions.
The terminal may also include at least one sensor 1050, such as a light sensor, motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor that adjusts brightness of the display panel 1041 according to brightness of ambient light, and a proximity sensor that turns off the display panel 1041 and/or a backlight when the terminal moves to the ear. As one of the motion sensors, the gravity acceleration sensor can detect the magnitude of acceleration in each direction (generally three axes), detect the magnitude and direction of gravity when the mobile terminal is stationary, and can be used for applications of recognizing terminal gestures (such as horizontal and vertical screen switching, related games, magnetometer gesture calibration), vibration recognition related functions (such as pedometer and tapping), and the like; other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer, and an infrared sensor may also be configured on the terminal, which are not further described herein.
Audio circuitry 1060, speaker 1061, microphone 1062 may provide an audio interface between a user and the terminal. The audio circuit 1060 can transmit the electrical signal converted from the received audio data to the speaker 1061, and the electrical signal is converted into a sound signal by the speaker 1061 and output; on the other hand, the microphone 1062 converts the collected sound signal into an electrical signal, which is received by the audio circuit 1060 and converted into audio data, which is then processed by the audio data output processor 1080 and then transmitted to, for example, another terminal via the RF circuit 1010, or output to the memory 1020 for further processing. The audio circuit 1060 may also include an earbud jack to provide communication of peripheral headphones with the terminal.
WiFi belongs to short-range wireless transmission technology, and the terminal can help users send and receive e-mails, browse web pages, access streaming media and the like through the WiFi module 1070, and provides wireless broadband internet access for users. Although fig. 10 shows the WiFi module 1070, it is understood that it does not belong to the essential constitution of the terminal, and can be omitted entirely as needed within the scope not changing the essence of the invention.
The processor 1080, which is a control center of the terminal, connects various parts of the entire terminal using various interfaces and lines, performs various functions of the terminal and processes data by operating or executing software programs and/or modules stored in the memory 1020 and calling data stored in the memory 1020, thereby integrally monitoring the terminal. Optionally, processor 1080 may include one or more processing cores; preferably, the processor 1080 may integrate an application processor, which primarily handles operating systems, user interfaces, application programs, etc., and a modem processor, which primarily handles wireless communications. It is to be appreciated that the modem processor described above may not be integrated into processor 1080.
The terminal also includes a power supply 1090 (e.g., a battery) for powering the various components, which may be logically coupled to processor 1080 via a power management system that may be configured to manage charging, discharging, and power consumption. Power supply 1090 may also include any component including one or more DC or AC power sources, recharging systems, power failure detection circuitry, power converters or inverters, power status indicators, and the like.
Although not shown, the terminal may further include a camera, a bluetooth module, and the like, which are not described in detail herein. In this embodiment, the terminal further includes a memory and one or more programs, where the one or more programs are stored in the memory and configured to be executed by the one or more processors. The one or more programs include instructions for performing the business logic generation provided by the above-described method embodiments.
An embodiment of the present invention further provides a computer-readable storage medium, where the storage medium may be configured in a terminal to store at least one instruction, at least one program, a code set, or a set of instructions related to implementing a service logic generation method, where the at least one instruction, the at least one program, the code set, or the set of instructions is loaded by and executed by the processor to implement the service logic generation method provided by the foregoing method embodiment.
Optionally, in this embodiment, the storage medium may include but is not limited to: a U-disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic disk, or an optical disk, and various media capable of storing program codes.
It should be noted that: the precedence order of the above embodiments of the present invention is only for description, and does not represent the merits of the embodiments. And specific embodiments thereof have been described above. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.
The embodiments in the present specification are described in a progressive manner, and portions that are similar to each other in the embodiments are referred to each other, and each embodiment focuses on differences from other embodiments. In particular, as for the apparatus embodiment, since it is substantially similar to the method embodiment, the description is relatively simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
It will be understood by those skilled in the art that all or part of the steps for implementing the above embodiments may be implemented by hardware, or may be implemented by a program instructing relevant hardware, and the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a magnetic disk, an optical disk, or the like.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and should not be taken as limiting the scope of the present invention, which is intended to cover any modifications, equivalents, improvements, etc. within the spirit and scope of the present invention.

Claims (10)

1. A method for generating business logic, the method comprising:
responding to a first establishing request on a service flow editing interface, and establishing an event triggering logic node; the event triggering logic node comprises a service event identifier;
responding to a second creation request on the service flow editing interface, and acquiring a target basic node matched with the type of the target node from the basic node library; the target basic node comprises a node capability editing interface, and the node capability editing interface is configured with service capability information;
responding to the selection instruction of the service capability information, determining the target service capability of the target basic node, and obtaining a service logic node;
responding to the associated instructions of the event trigger logic node and the service logic node, and determining a logic node calling relationship;
and generating the target business logic according to the logic node calling relation.
2. The method according to claim 1, wherein if said destination node type is a first node type, said destination base node is a first base node, and said service capability information of said first base node includes a plurality of service scripts;
correspondingly, the determining the target service capability of the target base node in response to the selection instruction of the service capability information includes:
responding to the selection instructions of the plurality of service scripts, and determining at least one target service script;
determining an execution sequence of the at least one target service script in response to a position adjustment instruction for the at least one target service script;
and determining the target service capability of the target base node according to the execution sequence of the at least one target service script.
3. The business logic generation method of claim 2, wherein if said target node type is a second node type, said target base node comprises an immediate conditional sub-node and said first base node; the service capability information of the instant condition sub-node comprises an instant judgment condition;
correspondingly, the determining the target service capability of the target base node in response to the selection instruction of the service capability information includes:
Responding to a selection instruction of the instant judgment condition of the instant condition sub-node, and determining a target instant judgment condition;
when the judgment result of the target instant judgment condition is true, establishing calling of the first basic node;
responding to a selection instruction of a plurality of service scripts of the first base node, and determining at least one target service script;
determining an execution sequence of the at least one target service script in response to a position adjustment instruction for the at least one target service script;
and determining the target service capability of the target base node according to the target instant judgment condition and the execution sequence of the at least one target service script.
4. The business logic generating method according to claim 2, wherein if said destination node type is a third node type, said destination base node comprises a snooping sub-node and said first base node; the service capability information of the monitoring sub-node comprises a monitoring triggering condition;
correspondingly, the determining the target service capability of the target base node in response to the selection instruction of the service capability information includes:
responding to a selection instruction of the monitoring triggering condition of the monitoring sub-node, and determining a target monitoring triggering condition;
When the target monitoring triggering condition is met, calling the first basic node;
responding to a selection instruction of a plurality of service scripts of the first basic node, and determining at least one target service script;
determining an execution sequence of the at least one target service script in response to a position adjustment instruction for the at least one target service script;
and determining the target service capability of the target base node according to the target monitoring trigger condition and the execution sequence of the at least one target service script.
5. The business logic generation method according to any one of claims 2 to 4, wherein the at least one target business script comprises a jump branch script; said determining a logical node invocation relationship in response to said event-triggered logical node and said service logical node's associated instruction comprises:
responding to the correlation instruction of the output port of the event trigger logic node and the input port of the first service logic node, and determining a first calling relation of the event trigger logic node to the first service logic node;
responding to the associated instructions of the output port of the jump branch script and the input port of a second service logic node, and determining a second calling relation of the jump branch script to the second service logic node;
Wherein the service logic nodes comprise the first service logic node and a second service logic node; the calling relation of the logic node comprises the first calling relation and the second calling relation.
6. The business logic generation method according to any one of claims 2 to 4, wherein the at least one target business script comprises a wait-to-execute script; after determining at least one target service script in response to the selection instruction of the plurality of service scripts, the method further comprises:
responding to a setting instruction of the time parameter of the script waiting for execution, and determining the waiting execution duration;
correspondingly, when determining the target service capability of the target base node, the method further includes:
and determining the target service capability of the target base node according to the waiting execution time length.
7. The method of generating business logic according to claim 1, wherein after generating target business logic according to said logical node call relationship, said method further comprises:
in response to the packaging instruction of the target business logic, packaging the target business logic to obtain a sub-process logic node;
Responding to an input and output establishing request for the sub-process logic nodes, and respectively establishing input nodes and output nodes;
determining input ports and output ports of said sub-flow logic nodes in response to associated instructions associating said input nodes and output nodes with said sub-flow logic nodes, respectively;
and responding to a storage instruction, and storing the sub-flow logic nodes.
8. The business logic generation method of claim 7, further comprising:
responding to a sub-process logic node calling request on a service process editing interface, and calling a target sub-process logic node;
correspondingly, the determining a logic node calling relationship in response to the instruction associated with the event-triggered logic node and the service logic node includes:
and determining a logic node calling relationship in response to the associated instructions for the event trigger logic node, the service logic node and the target sub-flow logic node.
9. An apparatus for generating business logic, the apparatus comprising:
the first creating module is used for responding to a first creating request on the service flow editing interface and creating an event triggering logic node; the event triggering logic node comprises a service event identifier;
A second establishing module, which is used for responding to a second establishing request on the service flow editing interface and acquiring a target base node matched with the type of the target node from the base node library; the target base node comprises a node capability editing interface, and the node capability editing interface is configured with service capability information;
a node service capability determining module, configured to determine, in response to a selection instruction for the service capability information, a target service capability of the target base node, to obtain a service logic node;
a calling relation determining module for determining a calling relation of the logic node in response to the association instruction of the event trigger logic node and the service logic node;
and the service logic generation module is used for generating the target service logic according to the calling relation of the logic node.
10. A terminal comprising a processor and a memory, wherein the memory stores at least one instruction or at least one program, and the at least one instruction or the at least one program is loaded by the processor and executed to implement the business logic generation method of any one of claims 1 to 8.
CN202110038659.6A 2021-01-12 2021-01-12 Service logic generation method, device and terminal Pending CN114764325A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110038659.6A CN114764325A (en) 2021-01-12 2021-01-12 Service logic generation method, device and terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110038659.6A CN114764325A (en) 2021-01-12 2021-01-12 Service logic generation method, device and terminal

Publications (1)

Publication Number Publication Date
CN114764325A true CN114764325A (en) 2022-07-19

Family

ID=82362900

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110038659.6A Pending CN114764325A (en) 2021-01-12 2021-01-12 Service logic generation method, device and terminal

Country Status (1)

Country Link
CN (1) CN114764325A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115766278A (en) * 2022-12-06 2023-03-07 深圳市天源景云科技有限公司 Firewall strategy generation method, device, equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115766278A (en) * 2022-12-06 2023-03-07 深圳市天源景云科技有限公司 Firewall strategy generation method, device, equipment and storage medium
CN115766278B (en) * 2022-12-06 2023-08-15 深圳市宜嘉科技有限公司 Firewall policy generation method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
CN111176961B (en) Application program testing method and device and storage medium
CN104142868B (en) Establish the method and device of connection
CN108039963B (en) Container configuration method and device and storage medium
WO2015078293A1 (en) Sound effect processing method and device, plug-in unit manager and sound effect plug-in unit
CN107666406B (en) Intelligent card display method and device
CN106502906A (en) A kind of method and apparatus of test application program
CN109067981A (en) Split screen application switching method, device, storage medium and electronic equipment
CN113377469A (en) Business interface display method and device for mobile application, terminal and storage medium
CN106201547A (en) Method, device and the mobile terminal that a kind of message based on mobile terminal shows
CN108932094A (en) Split screen application switching method, device, storage medium and electronic equipment
CN111273955B (en) Thermal restoration plug-in optimization method and device, storage medium and electronic equipment
CN108984142A (en) Multi-screen display method, device, storage medium and electronic equipment
CN112003978A (en) Conference management interface display method and device, storage medium and terminal equipment
CN106919458B (en) Method and device for Hook target kernel function
CN112749074A (en) Test case recommendation method and device
CN112308947A (en) Animation generation method and device and storage medium
CN111359210B (en) Data processing method and device, electronic equipment and storage medium
WO2018219118A1 (en) Interface displaying method and related product
CN107193551B (en) Method and device for generating image frame
CN109218313A (en) A kind of method, equipment and the storage medium of supervision application
CN114764325A (en) Service logic generation method, device and terminal
CN108845755A (en) split screen processing method, device, storage medium and electronic equipment
CN115589432A (en) Message push management method, device, medium and equipment
CN114518718A (en) Device control method, device, storage medium and electronic device
CN114490134A (en) Event processing method, system, device, computer equipment and storage medium

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