Data processing method, electronic equipment and storage medium
By generating a unified interface and using reflection mechanism to split the properties of the business entity class into the most basic data types, the difficulties of industrial equipment host computer software in parameter modification and compatibility are solved, and adaptability and efficient compatibility are achieved without modifying the interface code.
Patent Information
- Application Number
- CN202411982663.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-27
- Publication Date
- 2025-04-25
AI Technical Summary
Existing industrial equipment hosting software has difficulties in parameter modification and compatibility, especially when the data structure of business entity class changes, the interface code needs to be manually modified to match the new data structure, resulting in reduced compatibility.
By generating a unified interface, a data interface is generated based on the business entity class, and the reflection mechanism is used to split the properties of the business entity class into the most basic data types to realize the display, modification and storage of data.
It can adapt to changes in business entities without modifying the interface code, improving the compatibility and development efficiency of industrial equipment computer software.
Smart Images

Figure CN119883441A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of computer technology, and more specifically, to a data processing method, an electronic device and a storage medium. Background Art
[0002] The host computer software of industrial equipment is a software application installed on a computer or server. It exchanges data with the lower computer (such as PLC, single-chip microcomputer, sensor, etc.) through a specific communication protocol to realize the monitoring and management of industrial equipment. During the use of the host computer software of industrial equipment, it is often necessary to modify the parameters of the host computer software of industrial equipment. How to improve the compatibility of the host computer software is an issue that needs to be considered during the design and use of the host computer software of industrial equipment. Summary of the invention
[0003] The purpose of the embodiments of the present application is to provide a data processing method, an electronic device and a storage medium, which can facilitate the modification of data.
[0004] In the first aspect, an embodiment of the present application provides a data processing method, including: displaying a data interface of a host computer software of an industrial device; the data interface is provided by a unified interface; the data interface includes a data modification control; the unified interface is generated based on a business entity class corresponding to a product business requirement; receiving modification operation information of the data modification control; calling the unified interface according to the modification operation information to obtain target data corresponding to the modification operation information in the host computer software of the industrial device; the target data includes information of the business entity class; the information of the business entity class is a basic data type of the target data; changing the target data according to the modification operation information to obtain the changed target data; calling the unified interface to store the changed target data.
[0005] In a second aspect, an embodiment of the present application provides a data processing device, comprising: a display module, used to display the data interface of the host computer software of the industrial equipment; the data interface is provided by a unified interface; the data interface includes a data modification control; the unified interface is generated based on the business entity class corresponding to the product business requirements; a receiving module, used to receive modification operation information of the data modification control; a calling module, used to call the unified interface according to the modification operation information, and obtain the target data corresponding to the modification operation information in the host computer software of the industrial equipment; the target data includes information of the business entity class; the information of the business entity class is the basic data type of the target data; a changing module, used to change the target data according to the modification operation information to obtain the changed target data; a storage module, used to call the unified interface and store the changed target data.
[0006] In a third aspect, an embodiment of the present application provides an electronic device, including a processor, which is coupled to a memory, and the processor is used to execute a computer program or instruction stored in the memory so that the electronic device implements a data processing method provided in any embodiment of the present application.
[0007] In a fourth aspect, an embodiment of the present application further provides a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to enable a computer to execute a method provided by any embodiment of the present application.
[0008] In the embodiment of the present application, the information of the business entity class is the basic data type in the industrial equipment host computer software, and is also the basic data type of the target data stored and modified in the industrial equipment host computer software. Through the method provided in the embodiment of the present application, the information of the business entity class is split into the most basic data types in the industrial equipment host computer software, and a data interface is generated according to the business entity class through a unified interface. Therefore, when the business entity class changes, there is no need to modify the interface code to match the new data structure, thereby improving the compatibility of the industrial equipment host computer software. BRIEF DESCRIPTION OF THE DRAWINGS
[0009] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0010] Figure 1 A schematic diagram of a data processing method flow chart provided in an embodiment of the present application;
[0011] Figure 2 A schematic diagram of a data processing method provided by another embodiment of the present application;
[0012] Figure 3 A schematic diagram of a data processing method provided in yet another embodiment of the present application. DETAILED DESCRIPTION
[0013] In order to make the technical problems, technical solutions and beneficial effects to be solved by the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0014] The present application provides a data processing method, such as Figure 1 As shown, the process includes the following steps S11 to S15.
[0015] Step S11: Display the data interface of the upper computer software of the industrial equipment; the data interface is provided by a unified interface; the data interface includes a data modification control; the unified interface is generated based on the business entity class corresponding to the product business requirements.
[0016] In an embodiment of the present application, the data interface may include a data display area and a data modification area. The data display area may be used to display information of a business entity class. For example, the data display area may display attributes or other parameters of a business entity class. In a possible implementation.
[0017] In a possible implementation, the business entity class is the parameters of the host software of the industrial equipment. The product business requirements refer to the parameters that need to be set for motion, process, algorithm, etc. in the host software of the industrial equipment, and these parameters need to be modified through the operation interface and stored in the computer.
[0018] A business entity class refers to the code or core data object written for specific product business needs, which is a class or struct that usually needs to be defined in a programming language.
[0019] For example, in the capacitor appearance detection software, some algorithm parameters need to be adjusted to adapt to different products. These parameters need to be able to be modified on the operation interface, and the data after the operation needs to be stored in the product solution. Correspondingly, product business requirements may include: model directory, model mode, capacitor positioning method, white spot detection switch, etc. The C++ pseudo code of the business entity class corresponding to the product business requirements is expressed as follows.
[0020] Class DetectCapBottom
[0021] {
[0022] private:
[0023] / / parameter
[0024] String_modelDir; / / Model directory
[0025] String_modelMode; / / Model mode
[0026] Int_capLocationMode; / / capacitance positioning method
[0027] Bool_capWhiteDetectSwitch; / / capWhite detection switch
[0028] Public:
[0029] / / Algorithm execution
[0030] Int invoke()
[0031] {
[0032] / / The above parameters need to be used here
[0033] }
[0034] }.
[0035] The data modification controls of the data interface can correspond to each business entity class.
[0036] Step S12: receiving modification operation information of the data modification control.
[0037] The modification operation information of the data modification control may include information of the input operation of the data modification control.
[0038] Step S13: According to the modification operation information, the unified interface is called to obtain the corresponding target data in the upper computer software of the industrial equipment of the modification operation information; the target data includes the information of the business entity class; the information of the business entity class is the basic data type of the target data.
[0039] The target data may include information such as attributes of business entity classes. Business entity classes may be stored in the business layer of the industrial equipment host software, while the data interface exists in the interface layer of the industrial equipment host software. The unified interface is the connection channel from the interface layer to the business layer.
[0040] Step S14: modifying the target data according to the modification operation information to obtain modified target data.
[0041] In a possible implementation, the unified interface can be used to: obtain the attribute data type of the business entity class, obtain the attribute name of the business entity class, obtain the interface explanation of the attribute name, obtain the attribute value of the business entity class, obtain the sub-attributes of the business entity class, set the attribute value of the business entity class, set the dynamic attributes of the business entity class, obtain the dynamic attributes of the business entity class, uniformly store the target data, and statistically load the target data.
[0042] The target data may include information of the business entity class, and the information of the business entity class may include information of attributes of the business entity class. The information of the attributes of the business entity class may include at least one of the following: attribute data type of the business entity class, attribute name of the business entity class, interface explanation of the attribute name, attribute value of the business entity class, sub-attribute of the business entity class, and dynamic attribute of the business entity class.
[0043] Step S15: calling the unified interface to store the modified target data.
[0044] In the embodiment of the present application, a unified interface is called to transfer the modified target data from the data interface of the interface layer to the business layer storage.
[0045] Before industrial equipment can start working, it is usually necessary to set many software parameters, including system parameters, parameters of various motion modules, and process parameters. These software parameters are the above-mentioned business entity classes. The process parameters are for products. Different products have different process parameters. After these process parameters are set, they usually need to be stored for subsequent use. One of the characteristics of the upper computer software development of industrial equipment is its non-fixedness. The number of parameters may change frequently during the development process. It is very normal to delete a parameter or add a parameter.
[0046] In one possible implementation, the storage method of parameters in the upper computer software of industrial equipment can be: (1) Storing parameters in a database, manually writing code to create a table according to the entity class, and then writing the parameters into the corresponding fields, or reading the corresponding field information into the entity class. (2) Storing parameters in configuration files such as ini (Initialization File), yaml (Yet Another Markup Language), xml (Extensible Markup Language), and json (JavaScript Object Notation). It is necessary to convert the conversion code into the corresponding format according to the manually written information of the entity class and then write it into the file. (3) Serializing the parameters into a file through a binary sequence.
[0047] If the parameters in the host computer software are stored through any of the above (1) to (3), when the data structure in the business entity class changes (which may refer to the modification of the business entity class code, such as adding or deleting parameters), it may be necessary to manually write the corresponding conversion code, and the interface code also needs to be modified to adapt to the new data structure. If the storage method is binary serialization, the version compatibility of the host computer software also needs to be considered. Therefore, how to quickly add or delete parameters without modifying the interface code, minimize code modifications, and be compatible with loading the old process plans that have been stored is a common problem that needs to be solved in the development of industrial equipment host computer software.
[0048] In the embodiment of the present application, the information of the business entity class is the basic data type in the industrial equipment host computer software, and is also the basic data type of the target data stored and modified in the industrial equipment host computer software. Through the method provided in the embodiment of the present application, the information of the business entity class is split into the most basic data types in the industrial equipment host computer software, and a data interface is generated according to the business entity class through a unified interface. The code of the business entity class is abstractly encapsulated through the unified interface. Therefore, when the business entity class changes, there is no need to modify the interface code to match the new data structure, thereby improving the compatibility of the industrial equipment host computer software.
[0049] In one embodiment, the data processing method also includes: obtaining product business requirement information; the product business requirement information includes functional requirement information of the host computer software of the industrial equipment; generating the corresponding business entity class based on the product business requirement information, and the business entity class is used to implement the product business requirement information; using the business entity class to generate the unified interface.
[0050] In one embodiment, generating the corresponding business entity according to the product business requirement information includes: generating instruction code for executing the requirement information according to the product requirement information; and combining the instruction code with variables of the product requirement information to generate the business entity.
[0051] In one embodiment, the modification operation information includes at least one of the following: adding information of a business entity class, deleting information of a business entity class, and modifying information of an attribute of a business entity class; and changing the target data according to the modification operation information includes:
[0052] Passing the modification operation information to the business layer; the business layer includes the business entity class;
[0053] The target data is modified according to the modification information of the business entity class; the data interface does not change when the business entity class is modified.
[0054] In one implementation, the attributes of the business entity class conform to a reflective declaration method; the reflective declaration method is determined according to preset information.
[0055] In the embodiments of the present application, reflection declaration may refer to the process of declaring or accessing program elements such as classes, methods, and properties using the reflection mechanism. Reflection is a capability in many programming languages that allows a program to inspect, modify, and manipulate the internal structure of a program, including classes, interfaces, fields (properties), methods, etc., at runtime (rather than at compile time). In simple terms, the reflection mechanism enables a program to "see" its own structure and to dynamically create objects, call methods, and access properties.
[0056] In the embodiment of the present application, through the reflection mechanism, the program can be provided with the ability of self-reflection when the program is running, which is a capability already provided by most languages; take the following code as an example:
[0057] Struct A
[0058] {
[0059] Int a;
[0060] Int b;
[0061] Void doSomeWork();
[0062] };
[0063] A objA;
[0064] If there is no reflection mechanism, when the program is running, it is impossible to know that the object objA has attributes a, attribute b, and an executable method doSomeWork(); with a reflection mechanism, the situation is the opposite.
[0065] Of course, you can write objA.a; objA.b; and objA.doSomeWork() in the code, but this is not when the program is running, this is hard-coded; the internal structure of the object can be known when the program is running through the reflection mechanism.
[0066] In one embodiment, the use of the business entity class to generate the unified interface includes: obtaining the attributes of the business entity class through the application programming interface (API) of the reflection class library; the reflection class library is used to provide information of the reflection declaration, and the information of the reflection declaration includes the method of the reflection declaration; and packaging the attributes of the business entity class into the unified interface through the application programming interface of the reflection class library.
[0067] The method provided in the embodiment of the present application obtains all the attributes of a class through the reflection class library API, splits the attributes into indivisible minimum types, such as double (double-precision floating point data), int, bool (Boolean) and other basic types, and then uses the serialization library to uniformly serialize the basic type data after the segmentation into corresponding files, and finally compresses it into one file to complete the storage process. During deserialization, the file is first decompressed, and then the corresponding files decompressed are read in sequence according to the minimum attribute type obtained by the reflection class library API to complete the reading process. All the attributes in the class are extracted through the reflection class library API to package a unified interface, and the interface can automatically complete the interface adaptation according to the unified interface. When packaging the unified interface, a class library can be encapsulated and the class library can be used as a unified interface. When the interface is automatically adapted, it can be hard-coded according to the basic data type. For example, for int type, the editing and modification interface of int type is used, for Boolean type, the editing and modification interface of Boolean type is used, and for string type, the editing and modification interface of string type is used. Thus, through the method provided in the embodiment of the present application, for class structures that need to be frequently modified, attributes can be quickly added or subtracted without modifying interface codes, serialization, deserialization and other codes, and compatibility with old solution files can be achieved without manually writing conversion codes.
[0068] In one implementation, the reflection class library includes the unified interface.
[0069] In one embodiment, the data processing method also includes: obtaining selection condition information of the reflection class library; the selection condition information includes: being able to obtain all properties and methods in the business entity class; being able to decompose the structure of the business entity class into basic type data; being able to serialize the type of the basic type data into a single file and then compress and store / decompress the file, and deserialize it back to the entity class; and determining the reflection class library based on the selection condition information.
[0070] In the embodiment of the present application, a suitable reflection class library can be selected according to the specific language used by the host computer software. In the case of using the C++ language, a reflection class library can be generated according to the writing information that meets the requirements. When using the reflection class library generated by the writing information, the reflection class library can include the above-mentioned unified interface, which can obtain all the properties and methods of the class, split all the properties into basic type data (double / int / bool / string, etc.) and store them in a single file and then compress them into one file, decompress the file and read the file content into the entity class, and modify any attribute content.
[0071] In one example of the present application, a method for implementing general data storage and upgrading of industrial equipment is provided, such as Figure 2 The process shown includes the following steps.
[0072] Step S21: When the data interface receives operation information for modifying data through the interface, the data interface modifies and stores the data through the unified interface.
[0073] Step S21 is equivalent to steps S13 to S15 in the aforementioned embodiment.
[0074] Step S22: When the business layer receives the compilation information, the business layer adds or deletes data according to the compilation information.
[0075] The data in step S21 and step S22 may be the target data in the aforementioned embodiment.
[0076] Exemplarily, the target data is the attribute of the business entity class. Before step S22, the business entity class is constructed according to the specific business needs, and all business entity classes are declared according to the requirements of the selected reflection class library, and a unified interface is provided for obtaining, modifying, and storing data. Then, before step S22, a data display and modification interface adapted to it is quickly built according to the unified access interface to form a data interface. In step 22, when the business entity class of the business layer needs to add attributes or delete attributes, because all operations involving data display, modification, storage, loading, etc. have been completed in advance, it is only necessary to recompile the code of the business entity class, and the front-end interface and data modification, storage, reading and other related codes do not need to be changed.
[0077] When all business entity classes are declared according to the requirements of the selected reflection class library, you can choose the appropriate reflection class library according to the specific language used. The reflection class library contains the unified interface required by the above method. The interface can obtain all properties and methods of the class, split all properties into basic types of data (double / int / bool / string, etc.) and store them in a single file and then compress them into a file, decompress the file and read the file content into the entity class, and modify any property content.
[0078] Exemplarily, when selecting a reflection class library that meets the requirements, if the reflection class library of C++ language is used, a reflection class library that meets the following conditions can be generated: 1. All attributes in the class can be obtained; 2. The attributes can be split into basic data types (double, int, bool, string and other basic data), for example, for the structure Struct Data{M My;}, if its structure M is Struct M{int A; bool B;}, for the entity class Data a; its attributes should be split into My.A, My.B; 3. The basic data types can be serialized into a single file and then compressed and stored / decompressed and deserialized back to the entity class. For C++, general open source class libraries such as boost cannot meet requirements 2 and 3. For other languages such as C#, Java can basically only meet requirement 1, but not requirements 2 and 3. Therefore, in order to generate a reflection class library, the function code of the reflection class library can be received, the function code of the reflection class library can be written into a class, compiled into a lib (library) file, and the reflection class library can be obtained for calling.
[0079] When quickly building a data display and modification interface that is compatible with the unified access interface, the data interface can complete the interface creation work in advance according to the interface of the reflection class library. Because after splitting the attributes through the reflection class library interface, it only involves language-related basic data types (double, bool, int, etc.), so no matter how the attributes of the business entity class change, they can eventually be split into basic data types.
[0080] The advantage of the method provided by the embodiment of the present application is that: since the method uses reflection to automatically generate the attribute display and modification interface of the entity class, when the business entity class deletes attributes or adds new attributes, the interface code will automatically adapt to the supporting interface of the entity class without modifying any interface code. At the same time, since the method uses reflection to split the entity class attributes into the most basic data types to complete the display, modification, storage, and loading of data, it is not necessary to bind specific business logic and data structures, and can be reused in other systems, reducing the amount of code, thereby improving the efficiency of software development. In addition, since the method uses reflection to split the entity class attributes into the most basic data types for storage, there is no version compatibility issue.
[0081] In one example of the present application, the data processing method includes: Figure 3 Steps shown.
[0082] Step S31: Declare the business entity class according to the declaration method provided by the reflection class library.
[0083] Step S32: the data interface obtains the attributes in the business entity class according to the unified interface, splits the business entity class into basic data types, and displays the business entity class.
[0084] Step S33: When modifying the basic data type, call the unified interface to perform the modification.
[0085] Step S34: When a business entity class is added or deleted, return to step S31.
[0086] The embodiment of the present application also provides a data processing device, including: a display module, used to display the data interface of the upper computer software of the industrial equipment; the data interface is provided by a unified interface; the data interface includes a data modification control; the unified interface is generated based on the business entity class corresponding to the product business requirements; a receiving module, used to receive modification operation information of the data modification control; a calling module, used to call the unified interface according to the modification operation information, and obtain the target data corresponding to the modification operation information in the upper computer software of the industrial equipment; the target data includes information of the business entity class; the information of the business entity class is the basic data type of the target data; a changing module, used to change the target data according to the modification operation information to obtain the changed target data; a storage module, used to call the unified interface and store the changed target data.
[0087] The data processing device provided in the embodiments of the present application can implement any data processing method provided in the embodiments of the present application.
[0088] The implementation of the above-mentioned embodiment of the present application is a combination of elements and features of the embodiment of the present application. Unless otherwise mentioned, elements or features may be considered as optional. Each element or feature may be put into practice without being combined with other elements or features. In addition, the implementation of the present application may be constructed by combining some elements and / or features. The order of operations described in the implementation of the present application may be rearranged. Some constructions of any one embodiment may be included in another embodiment, and may be replaced by the corresponding construction of another embodiment. It is obvious to those skilled in the art that claims that do not have a clear reference relationship to each other in the attached claims may be combined with the implementation of this application, or may be included as new claims in the amendment after submitting this application.
[0089] In a firmware or software configuration, the embodiments of the present application may be implemented in the form of modules, processes, functions, etc. The software code may be stored in a memory unit and executed by a processor. The memory unit is located inside or outside the processor and may send data to and receive data from the processor via various known means.
[0090] Various aspects of the systems and methods described herein may be implemented as functions programmed into any of a variety of circuits, including programmable logic devices (PLDs), such as field programmable gate arrays (FPGAs), programmable array logic (PAL) devices, electronic programmable logic and storage devices, standard cell-based devices, and application-specific integrated circuits (ASICs). Some other possibilities for implementing these aspects of the system include: microcontrollers with memory, such as electronically erasable programmable read-only memory (EEPROM), embedded microprocessors, firmware, software, etc. In addition, these aspects of the system may be embodied in microprocessors with software-based circuit simulation, discrete logic (sequential and combinational), custom devices, fuzzy (neural) logic, quantum devices, and combinations of any of the above various device types. Of course, the underlying device technology may be provided in a variety of component types, such as metal oxide semiconductor field effect transistor (MOSFET) technology such as complementary metal oxide semiconductor (CMOS), bipolar technology such as emitter coupled logic (ECL), polymer technology (e.g., silicon conjugated polymer and metal conjugated polymer metal structure), hybrid analog and digital, etc.
[0091] The various functions or processes disclosed herein may be described as data and / or instructions embodied in various computer-readable media in terms of their behavior, register transfers, logic components, transistors, geometric layouts, and / or other characteristics. Computer-readable media that may contain such formatted data and / or instructions include, but are not limited to, various forms of non-volatile storage media (e.g., optical, magnetic, or semiconductor storage media) and carrier waves, which may be used to transmit such formatted data and / or instructions via wireless, optical, or wired signal media, or any combination thereof. When received in any of a variety of circuits (e.g., computers), such data and / or instructions may be processed by a processing entity (e.g., one or more processors).
[0092] The above description of the illustrated embodiments of the systems and methods is not intended to be exhaustive or to limit the systems and methods to the precise forms disclosed. Although specific embodiments and examples of the system components and methods are described herein for illustrative purposes, it will be appreciated by those skilled in the art that various equivalent modifications may be made within the scope of the systems, components, and methods. The teachings of the systems and methods provided herein may be applied to other processing systems and methods, not just to the above-described systems and methods.
[0093] Those skilled in the art will appreciate that, without departing from the spirit or scope of the broad description of the present application, various changes and / or modifications may be made to the present application shown in the specific embodiments. Therefore, the present embodiment will be considered in all respects to be illustrative and not restrictive. In addition, the present application includes any combination of features described for different embodiments (including features in the abstract section), even if the feature or combination of features is not clearly defined in the claims or the detailed description of the present embodiment.
[0094] Generally, in the following claims, the terms used should not be construed to limit the systems and methods to the specific embodiments disclosed in the specification and the claims, but should be construed to include all processing systems that operate under the claims. Therefore, the systems and methods are not limited by the present disclosure, but rather the scope of the systems and methods is determined entirely by the claims.
[0095] Unless the context clearly requires otherwise, throughout the specification and claims, the words "include", "including", "comprising", etc. should be interpreted in an inclusive sense and not in an exclusive or exhaustive sense; that is, in the sense of "including but not limited to". Words using the singular or plural number also include the singular or plural number, respectively. In addition, "herein", "herein below", "above", "hereafter" and words of similar meaning refer to this application as a whole and not to any particular part of this application. When the word "or" is used in a list involving two or more items, the word "or" includes all of the following interpretations of the word: any item in the list, all items in the list, and any combination of items in the list.
[0096] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of this application, the meaning of "plurality" is more than two, unless otherwise clearly and specifically defined.
[0097] The above are only preferred embodiments of the present application and are not intended to limit the present application. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present application should be included in the protection scope of the present application.
Claims
1. A data processing method, characterized in that: include: Display the data interface of the upper computer software of the industrial equipment; the data interface is provided by a unified interface; the data interface includes a data modification control; the unified interface is generated based on the business entity class corresponding to the product business requirements; Receiving modification operation information of the data modification control; According to the modification operation information, the unified interface is called to obtain the target data corresponding to the modification operation information in the upper computer software of the industrial equipment; the target data includes the information of the business entity class; the information of the business entity class is the basic data type of the target data; According to the modification operation information, the target data is modified to obtain the modified target data; The unified interface is called to store the changed target data.
2. The method according to claim 1, characterized in that: The method further comprises: Acquire product business requirement information; the product business requirement information includes functional requirement information of the upper computer software of the industrial equipment; Generate the corresponding business entity class according to the product business requirement information, and the business entity class is used to implement the product business requirement information; The unified interface is generated using the business entity class.
3. The method according to claim 1 or 2, characterized in that: Generating the corresponding business entity according to the product business requirement information includes: Generate instruction code for executing the demand information according to the product business demand information; The instruction code is combined with the variables of the product demand information to generate the business entity.
4. The method according to claim 1, characterized in that: The modification operation information includes at least one of the following: information about adding a business entity class, information about deleting a business entity class, and information about modifying attributes of a business entity class; The step of changing the target data according to the modification operation information includes: Passing the modification operation information to the business layer; the business layer includes the business entity class; The target data is modified according to the modification information of the business entity class; the data interface does not change when the business entity class is modified.
5. The method according to claim 2, characterized in that: The attributes of the business entity class conform to the reflection declaration method; the reflection declaration method is determined according to preset information.
6. The method according to claim 5, characterized in that The using the business entity class to generate the unified interface includes: Obtaining the attributes of the business entity class through an application programming interface of a reflection class library; the reflection class library is used to provide information of the reflection declaration, and the information of the reflection declaration includes the mode of the reflection declaration; The attributes of the business entity class are packaged into the unified interface through the application programming interface of the reflection class library.
7. The method according to claim 6, characterized in that The reflection class library includes the unified interface; the unified interface is used to execute at least one of the following: obtaining the attribute data type of the business entity class, obtaining the attribute name of the business entity class, obtaining the interface interpretation of the attribute name, obtaining the attribute value of the business entity class, obtaining the sub-attributes of the business entity class, setting the attribute value of the business entity class, setting the dynamic attributes of the business entity class, obtaining the dynamic attributes of the business entity class, uniformly storing target data, and statistically loading target data.
8. The method according to claim 6 or 7, characterized in that: The method further comprises: Obtaining selection condition information of the reflection class library; the selection condition information includes: being able to obtain all attributes and methods in the business entity class; being able to disassemble the structure of the business entity class into basic type data; being able to serialize the type of the basic type data into a single file and then compress and store / decompress the file, and deserialize it back to the entity class; The reflection class library is determined according to the selection condition information.
9. An electronic device, characterized in that: The electronic device comprises a processor coupled to a memory, wherein the processor is configured to execute a computer program or instruction stored in the memory, so that the electronic device implements the method according to any one of claims 1 to 8.
10. A non-transitory computer-readable storage medium storing computer instructions, wherein: The computer instructions are used to cause the computer to execute the method according to any one of claims 1-8.