CN109783162B - Method function management method, device, computer equipment and storage medium - Google Patents

Method function management method, device, computer equipment and storage medium Download PDF

Info

Publication number
CN109783162B
CN109783162B CN201811527224.2A CN201811527224A CN109783162B CN 109783162 B CN109783162 B CN 109783162B CN 201811527224 A CN201811527224 A CN 201811527224A CN 109783162 B CN109783162 B CN 109783162B
Authority
CN
China
Prior art keywords
function
information
dead time
database
target
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.)
Active
Application number
CN201811527224.2A
Other languages
Chinese (zh)
Other versions
CN109783162A (en
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.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An 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 Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN201811527224.2A priority Critical patent/CN109783162B/en
Publication of CN109783162A publication Critical patent/CN109783162A/en
Application granted granted Critical
Publication of CN109783162B publication Critical patent/CN109783162B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Stored Programmes (AREA)

Abstract

The invention discloses a method function management method, a device, computer equipment and a storage medium. The method comprises the following steps: generating a function database and a basic information database according to preset parameter type information; if new function information input by a user is received, storing a method function in the new function information according to the new function information; if the function name and the parameter value input by the user are received, matching the parameter value according to the parameter type information to obtain a target parameter type matched with the parameter value; and matching the obtained target parameter type and the function name with basic information in a basic information database to obtain a target method function in a corresponding function database. The method and the device realize hierarchical storage of the method functions based on the hierarchical storage technology, can facilitate the user to store and call the method functions, and greatly improve the efficiency of maintaining and managing the stored method functions.

Description

Method function management method, device, computer equipment and storage medium
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a method function management method, a device, a computer device, and a storage medium.
Background
For convenience in managing the stored method functions, a Redis storage system can be adopted for storage. However, when there are many method functions to be stored in the enterprise, a large number of method functions need to be stored in the Redis storage system, so that a large amount of time is required to search for a large number of method functions in the process of using the method functions, and the management efficiency of the enterprise on the stored method functions is reduced due to the fact that a large amount of storage space is occupied by the stored method functions. Thus, the prior art method has a problem of low management efficiency of the method functions.
Disclosure of Invention
The embodiment of the invention provides a method function management method, a device, computer equipment and a storage medium, which aim to solve the problem of lower efficiency in managing a method function in the prior art.
In a first aspect, an embodiment of the present invention provides a method function management method, including:
generating a function database and a basic information database according to preset parameter type information;
if new function information input by a user is received, storing a method function in the new function information according to the new function information;
If the function name and the parameter value input by the user are received, matching the parameter value according to the parameter type information to obtain a target parameter type matched with the parameter value;
and matching the obtained target parameter type and the function name with basic information in a basic information database to obtain a target method function in a corresponding function database.
In a second aspect, an embodiment of the present invention provides a method function management apparatus, including:
the database generation unit is used for generating a function database and a basic information database according to preset parameter type information;
the method function storage unit is used for storing the method functions in the newly-added function information according to the newly-added function information if the newly-added function information input by a user is received;
the parameter type matching unit is used for matching the parameter value according to the parameter type information to obtain a target parameter type matched with the parameter value if the function name and the parameter value input by the user are received;
and the target method function unit is used for matching the obtained target parameter type and the function name with the basic information in the basic information database to obtain the target method function in the corresponding function database.
In a third aspect, an embodiment of the present invention further provides a computer apparatus, which includes a memory, a processor, and a computer program stored in the memory and capable of running on the processor, where the processor implements the method function management method described in the first aspect when executing the computer program.
In a fourth aspect, an embodiment of the present invention further provides a computer readable storage medium, where the computer readable storage medium stores a computer program, where the computer program when executed by a processor causes the processor to execute the method function management method according to the first aspect.
The embodiment of the invention provides a method function management method, a device, computer equipment and a storage medium. The method comprises the steps of generating a basic information database for storing basic information of the method functions, generating a plurality of function databases for storing the method functions, obtaining target parameter types through matching function names and parameter values input by users, further obtaining target method functions in the corresponding function databases, realizing hierarchical storage of the method functions, facilitating storage and calling of the method functions by users, and greatly improving maintenance and management efficiency of the stored method functions.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for the description of the embodiments will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a method function management method according to an embodiment of the present invention;
FIG. 2 is a schematic sub-flowchart of a method function management method according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of another sub-flowchart of a method function management method according to an embodiment of the present invention;
FIG. 4 is a schematic diagram of another sub-flowchart of a method function management method according to an embodiment of the present invention;
FIG. 5 is another flow chart of a method function management method according to an embodiment of the present invention;
FIG. 6 is a schematic block diagram of a method function management device according to an embodiment of the present invention;
FIG. 7 is a schematic block diagram of a subunit of a method function management device according to an embodiment of the present invention;
FIG. 8 is a schematic block diagram of another subunit of a method function management apparatus according to an embodiment of the present invention;
FIG. 9 is a schematic block diagram of another subunit of a method function management apparatus according to an embodiment of the present invention;
FIG. 10 is another schematic block diagram of a method function management apparatus according to an embodiment of the present invention;
fig. 11 is a schematic block diagram of a computer device according to an embodiment of the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are some, but not all embodiments of the invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
It should be understood that the terms "comprises" and "comprising," when used in this specification and the appended claims, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It is also to be understood that the terminology used in the description of the invention herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used in this specification and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.
It should be further understood that the term "and/or" as used in the present specification and the appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes such combinations.
Referring to fig. 1, fig. 1 is a flowchart illustrating a method function management method according to an embodiment of the invention. The method function management method is applied to a management server, the method is executed through application software installed in the management server, and the management server is an enterprise terminal for executing the method function management method to manage the method function.
As shown in fig. 1, the method includes steps S110 to S140.
S110, generating a function database and a basic information database according to preset parameter type information.
And generating a plurality of function databases according to the parameter types in the preset parameter type information, and generating a basic information database. The function databases are used for storing the method functions, the method functions with different parameter types are stored in the function databases, and the number of the function databases is more than one; the basic information database is used for storing basic information of the method functions and managing the method functions in the function database, and the number of the basic information database is only one. Because the number of the method functions to be stored is large, and the calculation logic contained in part of the method functions is very complex, in order to conveniently manage a large number of the method functions, the method functions and the basic information of the method functions need to be stored in different databases. The generated function databases are the function databases which are generated by corresponding quantity according to the quantity of the parameter types contained in the parameter type information, and only one basic information database is generated.
The method function is the function information for calculating the parameter value inputted by the user (user of the management server), and includes specific calculation logic for calculating the parameter value. The parameter type information is information for classifying specific types of parameter values, different types of parameter values have different parameter types, and the parameter type information contains all parameter types. The parameter values of different parameter types cannot be calculated, so that the parameter types of the parameter values used in the same method function are the same.
For example, when the Redis storage system is used to store data information, the parameter type information includes five parameter types, which are respectively: string, hash, list, set and ordered Set, and the corresponding data base is generated.
And S120, if newly added function information input by a user is received, storing the method functions in the newly added function information according to the newly added function information.
And if the newly added function information input by the user is received, storing the method functions in the newly added function information according to the newly added function information. The newly added function information is information of a method function which is input by a user and needs to be newly added to a function database, and the newly added function information comprises the method function, the parameter type and the function name. Specifically, the method function is the function information for calculating the specific parameter value, the method function includes specific calculation logic for calculating the parameter value input by the user, the parameter type is the type information of all the parameter values in the method function, and the function name is the name information of the method function.
For example, the information of a new function is shown in table 1.
Method function Parameter type Function name
X=a+b String add
TABLE 1
In one embodiment, as shown in FIG. 2, step S120 includes substeps S121, S122, and S123.
S121, storing the method functions in the newly-added function information into corresponding function databases according to the parameter types in the newly-added function information, and recording the function position information stored by the method functions.
And storing the method function in the newly-added function information into a corresponding function database according to the parameter type in the newly-added function information, and recording the function position information stored by the method function. Because the generated function databases respectively correspond to different parameter types, the method functions contained in the newly added function information can be stored into the corresponding function databases according to the parameter types in the newly added function information, and the function position information of the method functions can be recorded. The function position information is specific position information for recording the function storage of the method.
For example, as shown in table 1, if the parameter type in the function information corresponding to the new addition is String type, the method function is stored in the String function database corresponding to String type, and if the method function is 12 th method function added in the function database, the function position information of the method function is String function database-12.
S122, generating basic information of the method function according to the obtained function position information, the function name and the parameter type in the newly-added function information, and storing the basic information into a basic information database.
And generating basic information of the method function according to the obtained function position information, the function name and the parameter type in the newly added function information, and storing the basic information into a basic information database. The basic information only comprises function position information, function names and parameter types of the method functions, and does not comprise specific calculation logic information of the method functions. The basic information of the method functions is stored in the basic information database, so that the specific method functions in the function database can be managed conveniently, the retrieval speed of the specific method functions is improved, and the efficiency of acquiring the specific method functions is improved greatly.
S123, generating the dead time according to the default dead time information and the newly-added function information, and adding the dead time into the stored method function.
Generating the dead time according to the default dead time information and the newly added function information, and adding the generated dead time into the stored method function. The new function information further comprises dead time information, the dead time information is unnecessary information, and when a user inputs the dead time information in the new function information, corresponding dead time can still be generated through default dead time information. The failure time information is the time information for controlling the state of the method function input by the user in the newly added function information, the default failure time information is the default time information for controlling the state of the method function, which is preset, and the failure time is the time information for controlling the state of the method function added in the method function. If the stored time of the method function exceeds the failure time, deleting the method function from the function database and deleting the basic information of the method function from the basic information database, so as to ensure that the database occupies as little storage space as possible, and controlling the number of the stored method functions can also improve the retrieval speed of the specific method function and greatly improve the efficiency of acquiring the specific method function.
In one embodiment, as shown in FIG. 3, step S123 includes sub-steps S1231, S1232, and S1233.
S1231, judging whether the newly added function information contains the dead time information.
Judging whether the newly added function information contains failure time information. Specifically, the method for adding the dead time to the method function is that if the dead time information is input by a user in the newly added function information, the dead time information in the newly added function information is adopted as the dead time; if the user does not input the dead time information in the newly added function information, the preset default dead time information is adopted as the dead time.
S1232, if the newly added function information contains the dead time information, the dead time information is used as the dead time and is added into the method function corresponding to the newly added function information.
If the newly added function information contains the dead time information, the dead time information is used as the dead time and is added into the method function corresponding to the newly added function information. For example, if the time-to-failure information input by the user in the newly added function information is 5 days, 5 days are added as the time-to-failure to the stored function of the method.
S1233, if the newly added function information does not contain the dead time information, setting the default dead time information as the dead time and adding the dead time information into the method function corresponding to the newly added function information.
If the newly added function information does not contain the dead time information, setting default dead time information as dead time and adding the dead time information into a method function corresponding to the newly added function information. For example, if the default dead time information is 10 days and the user does not input dead time information in the newly added function information, 10 days are added as dead times to the stored method function.
And S130, if the function name and the parameter value input by the user are received, matching the parameter value according to the parameter type information to obtain a target parameter type matched with the parameter value.
And if the function name and the parameter value input by the user are received, matching the parameter value according to the parameter type information to obtain a target parameter type matched with the parameter value. The parameter values are divided into a plurality of different parameter types, so that the parameter values input by a user can be matched according to the parameter type information to obtain the target parameter type matched with the parameter values in the parameter type information. The target parameter type is obtained by matching parameter type information according to a parameter value input by a user, and the parameter types of the parameter values used in the same method function are the same, so that the obtained target parameter type is one and only one.
For example, the function name input by the user is add, the parameter value is "hello" or "world", and the parameter type information contains five parameter types, which are respectively: string, hash, list, set and ordered Set, and the parameter value is matched according to the parameter type information to obtain the target parameter type String.
And S140, matching the obtained target parameter type and the function name with basic information in a basic information database to obtain a target method function in a corresponding function database.
And matching the obtained target parameter type and the function name with basic information in a basic information database to obtain a target method function in a corresponding function database. In order to obtain the target method function and call the target method function, the obtained target parameter type and the function name input by the user are matched with the basic information in the basic information database to obtain the function position information of the corresponding function method, and further obtain the target method function in the corresponding function database. The target method functions are the method functions of which the target parameter types and function names are matched with those in the function database, and one target method function is obtained by matching and only one target method function is obtained.
In one embodiment, as shown in FIG. 4, step S140 includes sub-steps S141 and S142.
S141, matching the basic information in the basic information database according to the target parameter type and the function name to obtain the function position information matched with the target parameter type and the function name.
And matching the target parameter type and the function name with basic information in a basic information database to obtain function position information matched with the target parameter type and the function name. The basic information database contains basic information of all the method functions stored in the function databases, and the basic information contains function names, parameter types and function position information of the method functions, so that the function position information matched with the target function types and the function names can be obtained by matching the target parameter types and the function names with the basic information in the basic information database.
Specifically, the same function name can correspond to a plurality of method functions applied to different parameter types, so that the corresponding method functions need to be searched through the function names, and the plurality of method functions with the same function name and applied to specific parameter types through the parameter types are further searched to finally determine and obtain the function position information of the target method functions in the basic information database.
S142, obtaining a method function in a corresponding function database according to the function position information, and outputting the method function as a target method function.
And obtaining a method function in a corresponding function database according to the function position information, and outputting the method function as an objective method function. Because the function position information in the basic information database corresponds to the corresponding method functions in the function database one by one, the position stored by the target method function can be determined through the acquired function position information, and then the method function in the corresponding function database is acquired and output as the target method function.
In an embodiment, as shown in fig. 5, step S140 further includes step S150.
S150, inputting the parameter value input by the user into the obtained target method function to realize the calling of the target method function.
And inputting the parameter values input by the user into the obtained target method function to realize the calling of the target method function. After the target method function is obtained, in order to realize the call to the target method function, the parameter value input by the user can be input into the obtained target method function so as to realize the logic operation to the parameter value output by the user through the target method function, namely, the target method function is used.
The method comprises the steps of generating a basic information database for storing basic information of the method functions, generating a plurality of function databases for storing the method functions, obtaining target parameter types through matching function names and parameter values input by users, further obtaining target method functions in the corresponding function databases, realizing hierarchical storage of the method functions, facilitating storage and calling of the method functions by users, and greatly improving maintenance and management efficiency of the stored method functions.
The embodiment of the invention also provides a method function management device which is used for executing any embodiment of the method function management method. Specifically, referring to fig. 6, fig. 6 is a schematic block diagram of a method function management apparatus according to an embodiment of the present invention. The method function management apparatus 100 may be configured in a management server.
As shown in fig. 6, the method function management apparatus 100 includes a database generation unit 110, a method function storage unit 120, a parameter type matching unit 130, and an objective method function acquisition unit 140.
The database generating unit 110 is configured to generate a function database and a basic information database according to preset parameter type information.
And generating a plurality of function databases according to the parameter types in the preset parameter type information, and generating a basic information database. The function databases are used for storing the method functions, the method functions with different parameter types are stored in the function databases, and the number of the function databases is more than one; the basic information database is used for storing basic information of the method functions and managing the method functions in the function database, and the number of the basic information database is only one. Because the number of the method functions to be stored is large, and the calculation logic contained in part of the method functions is very complex, in order to conveniently manage a large number of the method functions, the method functions and the basic information of the method functions need to be stored in different databases. The generated function databases are the function databases which are generated by corresponding quantity according to the quantity of the parameter types contained in the parameter type information, and only one basic information database is generated.
The method function is the function information for calculating the parameter value inputted by the user (user of the management server), and includes specific calculation logic for calculating the parameter value. The parameter type information is information for classifying specific types of parameter values, different types of parameter values have different parameter types, and the parameter type information contains all parameter types. The parameter values of different parameter types cannot be calculated, so that the parameter types of the parameter values used in the same method function are the same.
And the method function storage unit 120 is configured to store the method function in the newly added function information according to the newly added function information if the newly added function information input by the user is received.
And if the newly added function information input by the user is received, storing the method functions in the newly added function information according to the newly added function information. The newly added function information is information of a method function which is input by a user and needs to be newly added to a function database, and the newly added function information comprises the method function, the parameter type and the function name. Specifically, the method function is the function information for calculating the specific parameter value, the method function includes specific calculation logic for calculating the parameter value input by the user, the parameter type is the type information of all the parameter values in the method function, and the function name is the name information of the method function.
In other embodiments of the invention, as shown in fig. 7, the method function storage unit 120 includes a subunit: a function storage unit 121, a basic information storage unit 122, and a dead time adding unit 123.
And a function storage unit 121, configured to store the method function in the newly added function information to a corresponding function database according to the parameter type in the newly added function information, and record the function location information stored by the method function.
And storing the method function in the newly-added function information into a corresponding function database according to the parameter type in the newly-added function information, and recording the function position information stored by the method function. Because the generated function databases respectively correspond to different parameter types, the method functions contained in the newly added function information can be stored into the corresponding function databases according to the parameter types in the newly added function information, and the function position information of the method functions can be recorded. The function position information is specific position information for recording the function storage of the method.
And the basic information storage unit 122 is used for generating basic information of the method function according to the obtained function position information, the function name and the parameter type in the newly added function information and storing the basic information into a basic information database.
And generating basic information of the method function according to the obtained function position information, the function name and the parameter type in the newly added function information, and storing the basic information into a basic information database. The basic information only comprises function position information, function names and parameter types of the method functions, and does not comprise specific calculation logic information of the method functions. The basic information of the method functions is stored in the basic information database, so that the specific method functions in the function database can be managed conveniently, the retrieval speed of the specific method functions is improved, and the efficiency of acquiring the specific method functions is improved greatly.
And a dead time adding unit 123, configured to generate a dead time according to the default dead time information and the new function information, and add the dead time to the stored method function.
Generating the dead time according to the default dead time information and the newly added function information, and adding the generated dead time into the stored method function. The new function information further comprises dead time information, the dead time information is unnecessary information, and when a user inputs the dead time information in the new function information, corresponding dead time can still be generated through default dead time information. The failure time information is the time information for controlling the state of the method function input by the user in the newly added function information, the default failure time information is the default time information for controlling the state of the method function, which is preset, and the failure time is the time information for controlling the state of the method function added in the method function. If the stored time of the method function exceeds the failure time, deleting the method function from the function database and deleting the basic information of the method function from the basic information database, so as to ensure that the database occupies as little storage space as possible, and controlling the number of the stored method functions can also improve the retrieval speed of the specific method function and greatly improve the efficiency of acquiring the specific method function.
In other embodiments of the invention, as shown in fig. 8, the dead time adding unit 123 includes a subunit: a dead time information judgment unit 1231, a first dead time addition unit 1232, and a second dead time addition unit 1233.
The dead time information judging unit 1231 is configured to judge whether the newly added function information includes dead time information.
Judging whether the newly added function information contains failure time information. Specifically, the method for adding the dead time to the method function is that if the dead time information is input by a user in the newly added function information, the dead time information in the newly added function information is adopted as the dead time; if the user does not input the dead time information in the newly added function information, the preset default dead time information is adopted as the dead time.
The first dead time adding unit 1232 is configured to, if the newly added function information includes dead time information, take the dead time information as dead time and add the dead time information to a method function corresponding to the newly added function information.
If the newly added function information contains the dead time information, the dead time information is used as the dead time and is added into the method function corresponding to the newly added function information.
The second dead time adding unit 1233 is configured to set the default dead time information as the dead time and add the dead time information to the method function corresponding to the newly added function information if the newly added function information does not include the dead time information.
If the newly added function information does not contain the dead time information, setting default dead time information as dead time and adding the dead time information into a method function corresponding to the newly added function information.
And the parameter type matching unit 130 is configured to, if the function name and the parameter value input by the user are received, match the parameter value according to the parameter type information to obtain a target parameter type matched with the parameter value.
And if the function name and the parameter value input by the user are received, matching the parameter value according to the parameter type information to obtain a target parameter type matched with the parameter value. The parameter values are divided into a plurality of different parameter types, so that the parameter values input by a user can be matched according to the parameter type information to obtain the target parameter type matched with the parameter values in the parameter type information. The target parameter type is obtained by matching parameter type information according to a parameter value input by a user, and the parameter types of the parameter values used in the same method function are the same, so that the obtained target parameter type is one and only one.
And the target method function obtaining unit 140 is configured to obtain a target method function in the corresponding function database by matching the obtained target parameter type and the function name with the basic information in the basic information database.
And matching the obtained target parameter type and the function name with basic information in a basic information database to obtain a target method function in a corresponding function database. In order to obtain the target method function and call the target method function, the obtained target parameter type and the function name input by the user are matched with the basic information in the basic information database to obtain the function position information of the corresponding function method, and further obtain the target method function in the corresponding function database. The target method functions are the method functions of which the target parameter types and function names are matched with those in the function database, and one target method function is obtained by matching and only one target method function is obtained.
In other embodiments of the present invention, as shown in fig. 9, the objective method function obtaining unit 140 includes a subunit: a function position information acquisition unit 141 and an objective method function output unit 142.
The function location information obtaining unit 141 is configured to match the basic information in the basic information database according to the target parameter type and the function name, so as to obtain function location information matched with the target parameter type and the function name.
And matching the target parameter type and the function name with basic information in a basic information database to obtain function position information matched with the target parameter type and the function name. The basic information database contains basic information of all the method functions stored in the function databases, and the basic information contains function names, parameter types and function position information of the method functions, so that the function position information matched with the target function types and the function names can be obtained by matching the target parameter types and the function names with the basic information in the basic information database.
Specifically, the same function name can correspond to a plurality of method functions applied to different parameter types, so that the corresponding method functions need to be searched through the function names, and the plurality of method functions with the same function name and applied to specific parameter types through the parameter types are further searched to finally determine and obtain the function position information of the target method functions in the basic information database.
And the target method function output unit 142 is configured to obtain, according to the function position information, a method function in the corresponding function database as a target method function for output.
And obtaining a method function in a corresponding function database according to the function position information, and outputting the method function as an objective method function. Because the function position information in the basic information database corresponds to the corresponding method functions in the function database one by one, the position stored by the target method function can be determined through the acquired function position information, and then the method function in the corresponding function database is acquired and output as the target method function.
In other embodiments of the invention, as shown in fig. 10, the method function management device 100 further includes a subunit: the method function call unit 150.
And a method function calling unit 150 for inputting the parameter value inputted by the user into the obtained target method function to realize the calling of the target method function.
And inputting the parameter values input by the user into the obtained target method function to realize the calling of the target method function. After the target method function is obtained, in order to realize the call to the target method function, the parameter value input by the user can be input into the obtained target method function so as to realize the logic operation to the parameter value output by the user through the target method function, namely, the target method function is used.
The method comprises the steps of generating a basic information database for storing basic information of the method functions, generating a plurality of function databases for storing the method functions, obtaining target parameter types through matching function names and parameter values input by users, further obtaining target method functions in the corresponding function databases, realizing hierarchical storage of the method functions, facilitating storage and calling of the method functions by users, and greatly improving maintenance and management efficiency of the stored method functions.
The above-described method function management means may be implemented in the form of a computer program which can be run on a computer device as shown in fig. 11.
Referring to fig. 11, fig. 11 is a schematic block diagram of a computer device according to an embodiment of the present invention.
With reference to FIG. 11, the computer device 500 includes a processor 502, memory, and a network interface 505 connected by a system bus 501, where the memory may include a non-volatile storage medium 503 and an internal memory 504.
The non-volatile storage medium 503 may store an operating system 5031 and a computer program 5032. The computer program 5032, when executed, causes the processor 502 to perform a method function management method.
The processor 502 is used to provide computing and control capabilities to support the operation of the overall computer device 500.
The internal memory 504 provides an environment for the execution of a computer program 5032 in the non-volatile storage medium 503, which computer program 5032, when executed by the processor 502, causes the processor 502 to perform a method function management method.
The network interface 505 is used for network communication, such as providing for transmission of data information, etc. It will be appreciated by those skilled in the art that the structure shown in FIG. 11 is merely a block diagram of some of the structures associated with the present inventive arrangements and does not constitute a limitation of the computer device 500 to which the present inventive arrangements may be applied, and that a particular computer device 500 may include more or fewer components than shown, or may combine some of the components, or have a different arrangement of components.
Wherein the processor 502 is configured to execute a computer program 5032 stored in a memory to perform the following functions: generating a function database and a basic information database according to preset parameter type information; if new function information input by a user is received, storing a method function in the new function information according to the new function information; if the function name and the parameter value input by the user are received, matching the parameter value according to the parameter type information to obtain a target parameter type matched with the parameter value; and matching the obtained target parameter type and the function name with basic information in a basic information database to obtain a target method function in a corresponding function database.
In one embodiment, the processor 502 performs the following operations when receiving the newly added function information input by the user and storing the method function in the newly added function information according to the newly added function information: storing the method functions in the newly-added function information into corresponding function databases according to the parameter types in the newly-added function information and recording the function position information stored by the method functions; generating basic information of the method function according to the obtained function position information, function names and parameter types in the newly-added function information, and storing the basic information into a basic information database; generating the dead time according to the default dead time information and the newly added function information and adding the dead time into the stored method function.
In one embodiment, the processor 502, when executing the step of generating the expiration time from the default expiration time information and the newly added function information and adding to the stored method function, performs the following operations: judging whether the newly added function information contains failure time information or not; if the newly added function information contains the dead time information, the dead time information is used as the dead time and is added into a method function corresponding to the newly added function information; if the newly added function information does not contain the dead time information, setting default dead time information as dead time and adding the dead time information into a method function corresponding to the newly added function information.
In one embodiment, the processor 502 performs the following operations when performing the step of matching the obtained target parameter type and the function name with the basic information in the basic information database to obtain the target method function in the corresponding function database: matching the target parameter type and the function name with basic information in a basic information database to obtain function position information matched with the target parameter type and the function name; and obtaining a method function in a corresponding function database according to the function position information, and outputting the method function as an objective method function.
In one embodiment, the processor 502 further performs the following operations after performing the step of matching the obtained target parameter type and the function name with the basic information in the basic information database to obtain the target method function in the corresponding function database: and inputting the parameter values input by the user into the obtained target method function to realize the calling of the target method function.
Those skilled in the art will appreciate that the embodiment of the computer device shown in fig. 11 is not limiting of the specific construction of the computer device, and in other embodiments, the computer device may include more or less components than those shown, or certain components may be combined, or a different arrangement of components. For example, in some embodiments, the computer device may include only a memory and a processor, and in such embodiments, the structure and function of the memory and the processor are consistent with the embodiment shown in fig. 11, and will not be described again.
It should be appreciated that in embodiments of the present invention, the processor 502 may be a central processing unit (Central Processing Unit, CPU), the processor 502 may also be other general purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), off-the-shelf Programmable gate arrays (FPGAs) or other Programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or the like. Wherein the general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
In another embodiment of the invention, a computer-readable storage medium is provided. The computer readable storage medium may be a non-volatile computer readable storage medium. The computer readable storage medium stores a computer program, wherein the computer program when executed by a processor performs the steps of: generating a function database and a basic information database according to preset parameter type information; if new function information input by a user is received, storing a method function in the new function information according to the new function information; if the function name and the parameter value input by the user are received, matching the parameter value according to the parameter type information to obtain a target parameter type matched with the parameter value; and matching the obtained target parameter type and the function name with basic information in a basic information database to obtain a target method function in a corresponding function database.
In an embodiment, the step of storing the method function in the newly added function information according to the newly added function information if the newly added function information input by the user is received includes: storing the method functions in the newly-added function information into corresponding function databases according to the parameter types in the newly-added function information and recording the function position information stored by the method functions; generating basic information of the method function according to the obtained function position information, function names and parameter types in the newly-added function information, and storing the basic information into a basic information database; generating the dead time according to the default dead time information and the newly added function information and adding the dead time into the stored method function.
In one embodiment, the step of generating the dead time according to the default dead time information and the new function information and adding the dead time to the stored method function includes: judging whether the newly added function information contains failure time information or not; if the newly added function information contains the dead time information, the dead time information is used as the dead time and is added into a method function corresponding to the newly added function information; if the newly added function information does not contain the dead time information, setting default dead time information as dead time and adding the dead time information into a method function corresponding to the newly added function information.
In an embodiment, the step of matching the obtained target parameter type and the function name with the basic information in the basic information database to obtain the target method function in the corresponding function database includes: matching the target parameter type and the function name with basic information in a basic information database to obtain function position information matched with the target parameter type and the function name; and obtaining a method function in a corresponding function database according to the function position information, and outputting the method function as an objective method function.
In an embodiment, after the step of matching the obtained target parameter type and the function name with the basic information in the basic information database to obtain the target method function in the corresponding function database, the method further includes: and inputting the parameter values input by the user into the obtained target method function to realize the calling of the target method function.
It will be clearly understood by those skilled in the art that, for convenience and brevity of description, specific working procedures of the apparatus, device and unit described above may refer to corresponding procedures in the foregoing method embodiments, which are not repeated herein. Those of ordinary skill in the art will appreciate that the elements and algorithm steps described in connection with the embodiments disclosed herein may be embodied in electronic hardware, in computer software, or in a combination of the two, and that the elements and steps of the examples have been generally described in terms of function in the foregoing description to clearly illustrate the interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
In the several embodiments provided by the present invention, it should be understood that the disclosed apparatus, device and method may be implemented in other manners. For example, the apparatus embodiments described above are merely illustrative, and for example, the division of the units is merely a logical function division, there may be another division manner in actual implementation, or units having the same function may be integrated into one unit, for example, multiple units or components may be combined or may be integrated into another system, or some features may be omitted, or not performed. In addition, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices, or elements, or may be an electrical, mechanical, or other form of connection.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the embodiment of the present invention.
In addition, each functional unit in the embodiments of the present invention may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in software functional units.
The integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention is essentially or part of what contributes to the prior art, or all or part of the technical solution may be embodied in the form of a software product stored in a computer-readable storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned computer-readable storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a magnetic disk, an optical disk, or other various media capable of storing program codes.
While the invention has been described with reference to certain preferred embodiments, it will be understood by those skilled in the art that various changes and substitutions of equivalents may be made and equivalents will be apparent to those skilled in the art without departing from the scope of the invention. Therefore, the protection scope of the invention is subject to the protection scope of the claims.

Claims (7)

1. A method of managing a function, comprising:
generating a function database and a basic information database according to preset parameter type information;
if new function information input by a user is received, storing a method function in the new function information according to the new function information;
if the function name and the parameter value input by the user are received, matching the parameter value according to the parameter type information to obtain a target parameter type matched with the parameter value;
matching the obtained target parameter type and the function name with basic information in a basic information database to obtain a target method function in a corresponding function database;
the storing of the method function in the newly added function information according to the newly added function information comprises the following steps:
Storing the method functions in the newly-added function information into corresponding function databases according to the parameter types in the newly-added function information and recording the function position information stored by the method functions;
generating basic information of the method function according to the obtained function position information, function names and parameter types in the newly-added function information, and storing the basic information into a basic information database;
generating failure time according to default failure time information and the newly-added function information and adding the failure time into a stored method function;
the matching is carried out according to the obtained target parameter type and the function name and the basic information in the basic information database to obtain the target method function in the corresponding function database, comprising the following steps:
matching the target parameter type and the function name with basic information in a basic information database to obtain function position information matched with the target parameter type and the function name;
and acquiring a method function in a corresponding function database according to the function position information, and outputting the method function as an objective method function.
2. The method function management method according to claim 1, wherein the generating the dead time from the default dead time information and the newly added function information and adding the dead time to the stored method function includes:
Judging whether the newly added function information contains failure time information or not;
if the newly added function information contains the dead time information, the dead time information is used as the dead time and is added into a method function corresponding to the newly added function information;
if the newly added function information does not contain the dead time information, setting default dead time information as dead time and adding the dead time information into a method function corresponding to the newly added function information.
3. The method function management method according to claim 1, wherein after the matching between the obtained target parameter type and the function name and the basic information in the basic information database to obtain the target method function in the corresponding function database, further comprises:
and inputting the parameter values input by the user into the obtained target method function to realize the calling of the target method function.
4. A method function management apparatus, comprising:
the database generation unit is used for generating a function database and a basic information database according to preset parameter type information;
the method function storage unit is used for storing the method functions in the newly-added function information according to the newly-added function information if the newly-added function information input by a user is received;
The parameter type matching unit is used for matching the parameter value according to the parameter type information to obtain a target parameter type matched with the parameter value if the function name and the parameter value input by the user are received;
the target method function acquisition unit is used for matching the obtained target parameter type and the function name with the basic information in the basic information database to obtain a target method function in the corresponding function database;
the method function storage unit includes:
the function storage unit is used for storing the method functions in the newly-added function information to the corresponding function database according to the parameter types in the newly-added function information and recording the function position information stored by the method functions;
the basic information storage unit is used for generating basic information of the method function according to the obtained function position information, the function name and the parameter type in the newly added function information and storing the basic information into the basic information database;
the dead time adding unit is used for generating the dead time according to default dead time information and the newly-added function information and adding the dead time into the stored method function;
the target method function acquisition unit comprises a subunit: the function position information acquisition unit is used for matching the basic information in the basic information database according to the target parameter type and the function name so as to acquire function position information matched with the target parameter type and the function name; and the target method function output unit is used for acquiring the method functions in the corresponding function database according to the function position information and outputting the method functions as target method functions.
5. The method function management apparatus according to claim 4, wherein the dead time adding unit includes:
the failure time information judging unit is used for judging whether the newly added function information contains failure time information or not;
the first dead time adding unit is used for taking the dead time information as the dead time and adding the dead time information into a method function corresponding to the newly added function information if the newly added function information contains the dead time information;
and the second dead time adding unit is used for setting default dead time information as dead time and adding the dead time information into a method function corresponding to the newly added function information if the newly added function information does not contain the dead time information.
6. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the method function management method according to any of claims 1 to 3 when executing the computer program.
7. A computer readable storage medium, characterized in that the computer readable storage medium stores a computer program which, when executed by a processor, causes the processor to perform the method function management method according to any one of claims 1 to 3.
CN201811527224.2A 2018-12-13 2018-12-13 Method function management method, device, computer equipment and storage medium Active CN109783162B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811527224.2A CN109783162B (en) 2018-12-13 2018-12-13 Method function management method, device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811527224.2A CN109783162B (en) 2018-12-13 2018-12-13 Method function management method, device, computer equipment and storage medium

Publications (2)

Publication Number Publication Date
CN109783162A CN109783162A (en) 2019-05-21
CN109783162B true CN109783162B (en) 2024-04-16

Family

ID=66496184

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811527224.2A Active CN109783162B (en) 2018-12-13 2018-12-13 Method function management method, device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN109783162B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101299862A (en) * 2008-06-11 2008-11-05 中国电信股份有限公司 Telecommunication service generation environmental system
CN102023861A (en) * 2010-12-08 2011-04-20 中兴通讯股份有限公司 Method and system for generating test script and test suite
ES2554278A1 (en) * 2014-12-10 2015-12-17 Universidad De Málaga Methods of obtaining and selecting adsorbent materials for water purification (Machine-translation by Google Translate, not legally binding)
CN105653720A (en) * 2016-01-07 2016-06-08 北京人大金仓信息技术股份有限公司 Database hierarchical storage optimization method capable of achieving flexible configuration
CN106502745A (en) * 2016-10-26 2017-03-15 腾讯科技(深圳)有限公司 A kind of function calling method and device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101299862A (en) * 2008-06-11 2008-11-05 中国电信股份有限公司 Telecommunication service generation environmental system
CN102023861A (en) * 2010-12-08 2011-04-20 中兴通讯股份有限公司 Method and system for generating test script and test suite
ES2554278A1 (en) * 2014-12-10 2015-12-17 Universidad De Málaga Methods of obtaining and selecting adsorbent materials for water purification (Machine-translation by Google Translate, not legally binding)
CN105653720A (en) * 2016-01-07 2016-06-08 北京人大金仓信息技术股份有限公司 Database hierarchical storage optimization method capable of achieving flexible configuration
CN106502745A (en) * 2016-10-26 2017-03-15 腾讯科技(深圳)有限公司 A kind of function calling method and device

Also Published As

Publication number Publication date
CN109783162A (en) 2019-05-21

Similar Documents

Publication Publication Date Title
US8572108B2 (en) Method and system for specifying, preparing and using parameterized database queries
CN111247518B (en) Method and system for database sharding
US8782635B2 (en) Reconfiguration of computer system to allow application installation
US20140164391A1 (en) Data block saving system and method
TWI670623B (en) Method and device for acquiring device fingerprint
WO2017090475A1 (en) Information processing system, function creation method, and function creation program
US11715030B2 (en) Automatic object optimization to accelerate machine learning training
CN111104540B (en) Image searching method, device, equipment and computer readable storage medium
JP2019504390A (en) Data inquiry method and apparatus, and database system
CN106156070A (en) A kind of querying method, Piece file mergence method and relevant apparatus
CN109446225B (en) Data caching method and device, computer equipment and storage medium
CN108140022B (en) Data query method and database system
WO2019136797A1 (en) Hive table scanning method and device, computer apparatus, and storage medium
CN110275889B (en) Feature processing method and device suitable for machine learning
CN117033424A (en) Query optimization method and device for slow SQL (structured query language) statement and computer equipment
CN109815227B (en) Data lock management method, device, computer equipment and storage medium
CN109783162B (en) Method function management method, device, computer equipment and storage medium
CN117421771A (en) Structured data-oriented searchable encryption method and device and electronic equipment
CN109213972B (en) Method, device, equipment and computer storage medium for determining document similarity
CN104809146B (en) System and method for determining index of the object in object sequence
CN107248929B (en) Strong correlation data generation method of multi-dimensional correlation data
CN112148551A (en) Method, apparatus and computer program product for determining a rate of change of use of a storage system
KR101638048B1 (en) Sql query processing method using mapreduce
CN111831874B (en) Webpage data information acquisition method and device, computer equipment and storage medium
CN117332543B (en) Distribution processing method for heterogeneous data sources of power grid

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
GR01 Patent grant
GR01 Patent grant