CN116225578A - Data serialization method, anti-serialization method and inter-process instruction parameter transmission method - Google Patents
Data serialization method, anti-serialization method and inter-process instruction parameter transmission method Download PDFInfo
- Publication number
- CN116225578A CN116225578A CN202310067733.6A CN202310067733A CN116225578A CN 116225578 A CN116225578 A CN 116225578A CN 202310067733 A CN202310067733 A CN 202310067733A CN 116225578 A CN116225578 A CN 116225578A
- Authority
- CN
- China
- Prior art keywords
- type
- field
- pointer
- instruction parameter
- instruction
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 110
- 230000005540 biological transmission Effects 0.000 title abstract description 9
- 238000013507 mapping Methods 0.000 claims abstract description 13
- 230000008569 process Effects 0.000 claims description 23
- 238000004590 computer program Methods 0.000 claims description 12
- 238000004891 communication Methods 0.000 claims description 7
- 230000007246 mechanism Effects 0.000 claims description 3
- 238000002716 delivery method Methods 0.000 claims 1
- 238000012545 processing Methods 0.000 abstract description 9
- 230000000694 effects Effects 0.000 abstract description 5
- 238000010586 diagram Methods 0.000 description 6
- 230000006870 function Effects 0.000 description 5
- 238000012986 modification Methods 0.000 description 4
- 230000004048 modification Effects 0.000 description 4
- 239000004744 fabric Substances 0.000 description 2
- 238000012423 maintenance Methods 0.000 description 2
- 238000012546 transfer Methods 0.000 description 2
- 238000003491 array Methods 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/448—Execution paradigms, e.g. implementations of programming paradigms
- G06F9/4488—Object-oriented
- G06F9/449—Object-oriented method invocation or resolution
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/445—Program loading or initiating
- G06F9/44505—Configuring for program initiating, e.g. using registry, configuration files
- G06F9/4451—User profiles; Roaming
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/54—Interprogram communication
- G06F9/546—Message passing systems or structures, e.g. queues
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Control Of Transmission Device (AREA)
Abstract
The invention discloses a data serialization method, an anti-serialization method and an inter-process instruction parameter transmission method, wherein for each instruction number and the corresponding instruction parameter type, a mapping relation is written in a configuration file, structural information of the instruction parameter type is written, the configuration file is compiled into a binary obj configuration file, in subsequent serialization and anti-serialization, the instruction parameter type corresponding to the instruction number is searched through the obj configuration file, and the instruction parameter is serialized and anti-serialized through the field composition of the instruction parameter according to the inherent preset serialization method and anti-serialization method of the field type. The method achieves automatic processing of instruction data of all instruction parameter types, converts the existing manual hard coding mode into a mode of processing data through configuration files, improves programming and executing efficiency, is convenient to understand and maintain, and is high in accuracy and good in effect.
Description
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a data serialization method, an inverse serialization method, and an inter-process instruction parameter transmission method.
Background
In the existing WOSA XFS framework, SP serves as a device service, and provides services for multiple applications at the same time, when each application needs to request a device to operate, an instruction is transmitted to the device service through wfsasystem execute (DWORD dwCommand, LPVOID lpmddata) form, the SP needs to queue and lock a call instruction, so that the SP and the application call need to be implemented in different processes, which involves inter-process parameter transmission, the instruction parameter is a pointer type when the application call is performed, and the pointer types cannot access each other in different processes, which requires that the structural parameter content of the pointer type at one end be resolved into a binary data stream which can be understood in a certain way, then data is restored to the pointer type through inter-process data exchange at the other end, and the content of the pointer and the content before-call remain unchanged even though the address of the pointer changes.
In the prior art, the data coding and the anti-coding of pointer type content are realized in a code mode, each instruction and the corresponding parameters thereof are realized in a hard coding mode, so that the code writing is boring, a large number of codes are repeated, the data processing is easy to make mistakes (the understanding and realization capabilities of each person are different), the code efficiency is low, the mapping relation between the instruction and the parameters thereof cannot be flexibly processed, the code is required to be dynamically adjusted due to the parameter structure change, the maintenance is inconvenient, the code is required to be modified due to the subsequent addition of an expansion instruction, and the parameter format of the log record is also not uniform (the realization of each person is different).
Disclosure of Invention
The invention provides a data serialization method, an anti-serialization method and an inter-process instruction parameter transmission method, which are used for solving the problems that the existing serialization and anti-serialization methods are low in development and maintenance efficiency and poor in effect.
In a first aspect, a method for serializing data is provided, comprising:
constructing a configuration file, writing a mapping relation between each instruction number and the corresponding instruction parameter type in the configuration file, and defining the structural information of each instruction parameter type;
compiling the constructed configuration file into a binary obj configuration file;
acquiring an instruction, and finding out a corresponding instruction parameter type from the obj configuration file according to the instruction number;
the method comprises the steps of firstly serializing instruction numbers, and then serializing instruction parameter values according to a preset serialization rule corresponding to the instruction parameter types to generate a binary data stream.
In one possible implementation manner, the serializing the instruction parameter value according to the preset serialization rule corresponding to the instruction parameter type includes:
a1: if the instruction parameter type is the basic data type of the non-structure pointer array type and the structure pointer type, directly serializing the instruction parameter value according to a preset serialization rule corresponding to each basic data type; if the instruction parameter type is the structure pointer array, the step A2 is entered; if the instruction parameter type is a structure pointer, the step A3 is entered;
A2: if the instruction parameter pointer is empty, serializing the element number N of the instruction parameter pointer to be 0, wherein the serialization number is 0, and completing serialization; if the number of the elements is not 0, serializing the number N of the elements, wherein each element is a structure pointer, and for the structure pointer element, entering a step A3 to serialize the content of the structure pointer element;
a3: starting serializing the single structure pointers, and entering a step A4;
a4: firstly serializing the length of the structure body, and then serializing each field contained in the structure body according to the data type of the field; if the field is the basic data type of the non-structure pointer array type and the structure pointer type, directly serializing the value corresponding to the field according to the corresponding preset serialization rule; if the field is the structure pointer array type, entering a step A2 recursion to serialize the value corresponding to the field; if the field is of the structure pointer type, entering a step A3 for recursion to serialize the value corresponding to the field;
a5: for the last field contained in the structure body as the field after the serialization is completed, if the last field is entered in the step A2, the next element of the pointer array of the structure body is taken, if the element is empty, the serialization is completed, and if the element is not empty, the step A3 is entered to serialize the element; if step A3 is entered, serialization is completed.
In one possible implementation, according to the first aspect, for the instruction parameter type LPSTR, the first byte at serialization represents the length of the entire string, followed by serialization of the string content.
In a second aspect, there is provided a data de-serialization method for de-serializing a binary data stream generated using the method as described above, comprising the steps of:
acquiring a binary data stream, and inversely serializing the first two bytes to obtain an instruction number;
finding out the corresponding instruction parameter type from the obj configuration file according to the instruction number;
and performing deserialization on the remaining bytes of the binary data stream according to a preset deserialization rule corresponding to the instruction parameter type to obtain the instruction parameter.
According to a second aspect, in one possible implementation manner, the de-serializing the remaining bytes of the binary data stream according to the preset de-serializing rule corresponding to the instruction parameter type includes:
b1: if the instruction parameter type is the basic data type of the unstructured pointer array type and the structured pointer type, directly deserializing the remaining bytes of the binary data stream according to a preset deserializing rule corresponding to each basic data type; if the instruction parameter type is the structure pointer array, entering a step B2; if the instruction parameter type is a structure pointer, entering a step B3;
B2: firstly, reversely listing the number N of elements in a binary data stream, and if N is 0, finishing the reverse serialization; if N is not 0, N structure pointers are firstly allocated, and for each structure pointer, step B3 is advanced to deserialize the content of the structure pointer; b3: starting to deserialize the single structure pointer, and entering a step B4;
b4: firstly, inversely serializing the length of the structure body, distributing a pointer with a corresponding length, and then, sequentially carrying out inverse serialization on each field contained in the structure body according to the data type of the field; if the field is the basic data type of the non-structure pointer array type and the structure pointer type, directly deserializing the value corresponding to the field according to the corresponding preset deserializing rule; if the field is the structure pointer array type, entering a step B2 recursion to deserialize a value corresponding to the field; if the field is of the structure pointer type, entering a step B3 for recursion to deserialize a value corresponding to the field;
b5: for the last field contained in the structure body as the field after the deserialization is completed, if the last field is entered in the step B2, the next element of the pointer array of the structure body is taken, if the element is empty, the deserialization is completed, and if the element is not empty, the step B3 is entered to deserialize the element; if step B3 is entered, the deserialization is completed.
According to a second aspect, in a possible implementation manner, when the instruction parameter type is LPSTR, the first byte is read first during deserialization, so as to obtain the length of the whole character string, a byte pointer with a corresponding length is allocated, and then the subsequent content with the corresponding length is copied into the allocated byte pointer.
In a third aspect, a method for transferring instruction parameters between processes is provided, including:
constructing a configuration file, writing a mapping relation between each instruction number and the corresponding instruction parameter type in the configuration file, and defining the structural information of each instruction parameter type;
compiling the constructed configuration file into a binary obj configuration file;
acquiring an instruction of a sender process, and finding out a corresponding instruction parameter type from an obj configuration file according to an instruction number; firstly serializing the instruction number, and then serializing the instruction parameter value according to a preset serialization rule corresponding to the instruction parameter type to generate a binary data stream;
transmitting the binary data stream to a receiver process through a network or an interprocess communication mechanism; and deserializing the first two bytes to obtain an instruction number; finding out the corresponding instruction parameter type from the obj configuration file according to the instruction number; and performing deserialization on the remaining bytes of the binary data stream according to a preset deserialization rule corresponding to the instruction parameter type to obtain the instruction parameter.
In one possible implementation manner, the serializing the instruction parameter value according to the preset serialization rule corresponding to the instruction parameter type includes:
a1: if the instruction parameter type is the basic data type of the non-structure pointer array type and the structure pointer type, directly serializing the instruction parameter value according to a preset serialization rule corresponding to each basic data type; if the instruction parameter type is the structure pointer array, the step A2 is entered; if the instruction parameter type is a structure pointer, the step A3 is entered;
a2: if the instruction parameter pointer is empty, serializing the element number N of the instruction parameter pointer to be 0, wherein the serialization number is 0, and completing serialization; if the number of the elements is not 0, serializing the number N of the elements, wherein each element is a structure pointer, and for the structure pointer element, entering a step A3 to serialize the content of the structure pointer element;
a3: starting serializing the single structure pointers, and entering a step A4;
a4: firstly serializing the length of the structure body, and then serializing each field contained in the structure body according to the data type of the field; if the field is the basic data type of the non-structure pointer array type and the structure pointer type, directly serializing the value corresponding to the field according to the corresponding preset serialization rule; if the field is the structure pointer array type, entering a step A2 recursion to serialize the value corresponding to the field; if the field is of the structure pointer type, entering a step A3 for recursion to serialize the value corresponding to the field;
A5: for the last field contained in the structure body as the field after the serialization is completed, if the last field is entered in the step A2, the next element of the pointer array of the structure body is taken, if the element is empty, the serialization is completed, and if the element is not empty, the step A3 is entered to serialize the element; if step A3 is entered, serialization is completed.
According to a first aspect, in one possible implementation manner, the deserializing the remaining bytes of the binary data stream according to a preset deserializing rule corresponding to the instruction parameter type includes:
b1: if the instruction parameter type is the basic data type of the unstructured pointer array type and the structured pointer type, directly deserializing the remaining bytes of the binary data stream according to a preset deserializing rule corresponding to each basic data type; if the instruction parameter type is the structure pointer array, entering a step B2; if the instruction parameter type is a structure pointer, entering a step B3;
b2: firstly, reversely listing the number N of elements in a binary data stream, and if N is 0, finishing the reverse serialization; if N is not 0, N structure pointers are firstly allocated, and for each structure pointer, step B3 is advanced to deserialize the content of the structure pointer; b3: starting to deserialize the single structure pointer, and entering a step B4;
B4: firstly, inversely serializing the length of the structure body, distributing a pointer with a corresponding length, and then, sequentially carrying out inverse serialization on each field contained in the structure body according to the data type of the field; if the field is the basic data type of the non-structure pointer array type and the structure pointer type, directly deserializing the value corresponding to the field according to the corresponding preset deserializing rule; if the field is the structure pointer array type, entering a step B2 recursion to deserialize a value corresponding to the field; if the field is of the structure pointer type, entering a step B3 for recursion to deserialize a value corresponding to the field;
b5: for the last field contained in the structure body as the field after the deserialization is completed, if the last field is entered in the step B2, the next element of the pointer array of the structure body is taken, if the element is empty, the deserialization is completed, and if the element is not empty, the step B3 is entered to deserialize the element; if step B3 is entered, the deserialization is completed.
In a fourth aspect, a computer readable storage medium is provided, storing a computer program which when executed by a processor also implements a data serialization method, or a reverse serialization method, or an inter-process instruction parameter transfer method as described above.
The invention provides a data serialization method, an inverse serialization method and an inter-process instruction parameter transmission method, which are based on a descriptive idea, wherein a mapping relation is written in a configuration file for each instruction number and the corresponding instruction parameter type, and the specific type of the corresponding instruction parameter is also written in the configuration file, and the configuration file capable of being adjusted at any time has the operations of mapping the instruction and the instruction parameter, forming specific fields of the instruction parameter, adding new expansion instructions or deleting the existing instructions, and the like, is very convenient to understand and maintain, and is critical to the modification, so long as the modification is written according to a specified format, and the actual code operation is not influenced. Whereas the prior art methods may even be slightly modified, require modification of the code to make the adjustment. After the descriptive rule configuration file is compiled, the descriptive rule configuration file is compiled into a binary obj configuration file, in the subsequent serialization and deserialization, the instruction parameter type corresponding to the instruction number can be searched through the obj configuration file at any time, each field of the instruction parameter is serialized and deserialized according to the inherent preset serialization method and deserialization method of the field type through the field composition of the instruction parameter, so that the instruction data of all the instruction parameter types are automatically processed, the existing manual hard coding mode is converted into the mode of processing the data through the configuration file, the programming and execution efficiency is improved, the accuracy is high, and the effect is good.
Drawings
In order to more clearly illustrate the embodiments of the invention or the technical solutions in the prior art, the drawings that are required in the embodiments or the description of the prior art will be briefly described, it being obvious that the drawings in the following description are only some embodiments of the invention, and that 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 data serialization method according to an embodiment of the present invention;
FIG. 2 is a flow chart of a method for deserializing data according to an embodiment of the present invention;
FIG. 3 is a flowchart of a method for communicating inter-process instruction parameters according to an embodiment of the present invention;
fig. 4 is a flow chart of an LPWORD type serialization anti-serialization method according to an embodiment of the present invention, where (a) is a flow chart of the serialization method, and (b) is a flow chart of the anti-serialization method.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the technical solutions of the present invention will be described in detail below. It will be apparent that the described embodiments are only some, but not all, embodiments of the invention. All other embodiments, based on the examples herein, which are within the scope of the invention as defined by the claims, will be within the scope of the invention as defined by the claims.
Based on the existing complex situations of serialization and deserialization, such as poor effect and stability, the invention provides a method for describing the mapping relation between an instruction number and a corresponding instruction parameter type through a configuration file, describing the field type, the field number and the structure size of a structure body, in particular to a related complex C language structure body, and compiling the content into an obj configuration file. In the serialization and deserialization processes, the mapping relation between the instruction number and the instruction parameter type is resolved through the obj configuration file, and for each defined structure body, the data type defined by each field of the structure body, the size of occupied bytes and the actual offset of each field in the structure body can be obtained from the obj configuration file, so that the data can be stripped from the instruction parameter types with various complexity, and the instruction parameter types with corresponding complexity can be restored conveniently.
The technical scheme of the invention is further described below with reference to specific embodiments.
The embodiment of the invention provides a data serialization method, which comprises the following steps:
step 1: constructing a configuration file, writing a mapping relation between each instruction number and the corresponding instruction parameter type in the configuration file, and defining the structural information of each instruction parameter type;
Step 2: compiling the constructed configuration file into a binary obj configuration file;
step 3: acquiring an instruction, and finding out a corresponding instruction parameter type from the obj configuration file according to the instruction number;
step 4: the method comprises the steps of firstly serializing instruction numbers, and then serializing instruction parameter values according to a preset serialization rule corresponding to the instruction parameter types to generate a binary data stream.
Specifically, as shown in fig. 1, the serializing the instruction parameter value according to the preset serialization rule corresponding to the instruction parameter type includes:
a1: if the instruction parameter type is the basic data type of the non-structure pointer array type and the structure pointer type, directly serializing the instruction parameter value according to a preset serialization rule corresponding to each basic data type; if the instruction parameter type is the structure pointer array, the step A2 is entered; if the instruction parameter type is a structure pointer, the step A3 is entered;
a2: if the instruction parameter pointer is empty, serializing the element number N of the instruction parameter pointer to be 0, wherein the serialization number is 0, and completing serialization; if the number of the elements is not 0, serializing the number N of the elements, wherein each element is a structure pointer, and for the structure pointer element, entering a step A3 to serialize the content of the structure pointer element;
A3: starting serializing the single structure pointers, and entering a step A4;
a4: firstly serializing the length of the structure body, and then serializing each field contained in the structure body according to the data type of the field; if the field is the basic data type of the non-structure pointer array type and the structure pointer type, directly serializing the value corresponding to the field according to the corresponding preset serialization rule; if the field is the structure pointer array type, entering a step A2 recursion to serialize the value corresponding to the field; if the field is of the structure pointer type, entering a step A3 for recursion to serialize the value corresponding to the field;
a5: for the last field contained in the structure body as the field after the serialization is completed, if the last field is entered in the step A2, the next element of the pointer array of the structure body is taken, if the element is empty, the serialization is completed, and if the element is not empty, the step A3 is entered to serialize the element; if step A3 is entered, serialization is completed.
Based on the data serialization method provided by the above embodiment, the embodiment of the present invention further provides a method for deserializing a binary data stream generated by using the method provided by the above embodiment, including the following steps:
Acquiring a binary data stream, and inversely serializing the first two bytes to obtain an instruction number;
finding out the corresponding instruction parameter type from the obj configuration file according to the instruction number;
and performing deserialization on the remaining bytes of the binary data stream according to a preset deserialization rule corresponding to the instruction parameter type to obtain the instruction parameter.
Specifically, as shown in fig. 2, the deserializing the remaining bytes of the binary data stream according to the preset deserializing rule corresponding to the instruction parameter type includes:
b1: if the instruction parameter type is the basic data type of the unstructured pointer array type and the structured pointer type, directly deserializing the remaining bytes of the binary data stream according to a preset deserializing rule corresponding to each basic data type; if the instruction parameter type is the structure pointer array, entering a step B2; if the instruction parameter type is a structure pointer, entering a step B3;
b2: firstly, reversely listing the number N of elements in a binary data stream, and if N is 0, finishing the reverse serialization; if N is not 0, N structure pointers are firstly allocated, and for each structure pointer, step B3 is advanced to deserialize the content of the structure pointer; b3: starting to deserialize the single structure pointer, and entering a step B4;
B4: firstly, inversely serializing the length of the structure body, distributing a pointer with a corresponding length, and then, sequentially carrying out inverse serialization on each field contained in the structure body according to the data type of the field; if the field is the basic data type of the non-structure pointer array type and the structure pointer type, directly deserializing the value corresponding to the field according to the corresponding preset deserializing rule; if the field is the structure pointer array type, entering a step B2 recursion to deserialize a value corresponding to the field; if the field is of the structure pointer type, entering a step B3 for recursion to deserialize a value corresponding to the field;
b5: for the last field contained in the structure body as the field after the deserialization is completed, if the last field is entered in the step B2, the next element of the pointer array of the structure body is taken, if the element is empty, the deserialization is completed, and if the element is not empty, the step B3 is entered to deserialize the element; if step B3 is entered, the deserialization is completed.
The embodiment of the invention also provides a method for transmitting the inter-process instruction parameters by using the data serialization method and the anti-serialization method provided by the embodiment, as shown in fig. 3, comprising the following steps:
S1: constructing a configuration file, writing a mapping relation between each instruction number and the corresponding instruction parameter type in the configuration file, and defining the structural information of each instruction parameter type;
s2: compiling the constructed configuration file into a binary obj configuration file;
s3: acquiring an instruction of a sender process, and finding out a corresponding instruction parameter type from an obj configuration file according to an instruction number; firstly serializing the instruction number, and then serializing the instruction parameter value according to a preset serialization rule corresponding to the instruction parameter type to generate a binary data stream;
s4: transmitting the binary data stream to a receiver process through a network or an interprocess communication mechanism; and deserializing the first two bytes to obtain an instruction number; finding out the corresponding instruction parameter type from the obj configuration file according to the instruction number; and performing deserialization on the remaining bytes of the binary data stream according to a preset deserialization rule corresponding to the instruction parameter type to obtain the instruction parameter.
The specific process of the serialization method and the deserialization method are referred to the foregoing embodiments, and are not described herein.
For a further understanding of the present invention, the following describes the technical solution of the present invention in more detail in connection with the application under the WOSA XFS framework.
The function prototype of the WOSA API call is a reduced form as follows:
HRESULT extern WINAPI WFSAsyncExecute(DWORD dwCommand,LPVOID lpCmdData);
where dwCommand is the instruction number, lpmdData is the instruction parameter, which may be in the form of a specific LPWROD, LPSHORT, or custom structure pointer, the invention sequences and deserializes the additional lpmdData instruction parameter for a specific dwCommand. For the type of the instruction parameter data which is known to be common at present, the following definition corresponding to the table 1 is made:
TABLE 1
Description: LPSTRUCT is a pseudo definition common to pointers to constructs, where a particular construct may be in the form of a c-language definition as follows:
we define this type of custom type as constant 9, whether LPSTRUCT actually corresponds to LPPerson or LPUpdateInfo.
For the case where the lpmddata actual content is a pointer to a specific structure, the following table 2 is defined correspondingly for the part of the structure content composition, i.e., the data type of the structure field:
TABLE 2
Description: LPSTRUCT is a pseudo definition common to pointers to constructs, where a particular construct may be in the form of a c-language definition as follows:
wherein the corresponding custom type constant is 14.LPPSTRUCT is a pointer to a structure pointer, i.e., a pointer array. In the above definition of ComputeTwo, (2) corresponds to the pointer array type, and its custom type constant is 15.
The process of serialization and deserialization is described in detail below from the API call WFSASyncExecute (DWORD dwCommand, LPVOID lpCMdData):
case 1: if dwCommand instruction is constant 1, in obj configuration file, the parameter lpmdData transferred by the instruction corresponds to lpWORD, then the serialization process is to serialize the command dwCommand into 2 bytes first, and in the serialization order of the higher order and the lower order (the subsequent byte serialization is described as the higher order and the lower order), then the command dwCommand is then serialized into the parameter lpWORD, because the contents transferred between processes are not original pointers, we only need to transfer the data contained in the pointers, if the content corresponding to the lpWORD is 3, the serialized byte is 00, the data after the whole serialization of the command is 00 01 00 03, after the inter-process communication, the receiver also deserializes the 2 bytes dwORD dwCommand by using the same obj configuration file, and also in the principle of the higher order and the lower order, then the command dwCommand is known from 01 to be 1, then the corresponding to the LPWORD is known from the index 1, then the type of the LPWORD is assigned to be 2 bytes, then the type of the reverse-ordered is known from the index is 3, then the type of the work is assigned, and the type of the reverse-ordered is assigned to be 2 bytes. The entire serialization anti-serialization flow is shown in fig. 4 (a) and (b).
Case 2: if the dwCommand instruction is constant 2, in the OBJ configuration file, the parameter lpmdData transmitted by the instruction corresponds to LPUSHORT, the serialization process is to serialize the instruction dwCommand into 2 bytes first, and the serialization sequence is to sequence the instruction dwCommand into 00 in the last order (the subsequent byte serialization is described as the last order), then the parameter LPHORT is serialized, because the USHORT is 2 bytes, if the corresponding content is 3, the serialized byte is 0003, the data after the whole serialization of the instruction is 00 02 0003, the receiver also deserializes the 2 bytes DWORD dwCommand by using the same OBJ configuration file after the inter-process communication, and also knows that the instruction corresponding to dwCommand is 2 from 02 in the last order according to the principle of the last order, then the parameter type corresponding to the instruction 2 is LPHORT is known from the OBJ configuration file, then the reverse sequence of 2 bytes is allocated to the index 3, and the reverse sequence of the index is set to be 3, and the reverse sequence of the USHORT is completed.
Case 3: the two serialization anti-serialization methods are equally applicable to the case where the instruction parameter is LPSHORT, LPDWORD, LPULONG, LPLONG, LPBOOL.
Case 4: for the case where the serialized anti-serialized instruction parameter is LPSTR, three cases are divided:
1) Ending with NULL;
2) Ending with a 0x00, for example, the string is "WFP\0", and the actual content is 0x57 0x46 0x50 0x00;
3) Ending with two 0x 00's, such as a string of "WFP\0WFP\0\0", the actual content is 0x57 0x46 0x50 0x000x57 0x46 0x50 0x00 0x00.
The first byte represents the length of the whole character string during serialization, and the lengths are 0, 4 and 9 in the above three cases respectively, the first byte after serialization is 0x00,0x04 and 0x09 respectively, then the content of the following character string is serialized, and the final serialized bytes in the last three cases are as follows respectively:
1)0x00
2)0x04 0x57 0x46 0x50 0x00
3)0x09 0x57 0x46 0x50 0x00 0x57 0x46 0x50 0x00 0x00
the process of deserialization: the first byte is read first, and for case 1), when the read value is 0x00, it is known that the string length is 0, and the value is NULL after the reverse serialization. 2) and 3) knowing that byte pointers of 4 and 9 byte lengths should be allocated first, and then copying the contents of the subsequent pointers of 4 and 9 lengths into the byte pointer just allocated, the deserialization operation is completed.
Case 5: for the case that the instruction parameter is LPSTRUCT, it is necessary to perform serialization and deserialization one by one for each content item contained in its structure field, where the type of each field of the structure is within the above-defined range, and any structure is a combination of the above-mentioned fields, taking the following structure as an example:
The structure field consists of 6 different data types, BOOL, ULONG, LPSTR, LPWORD, LPPersion and lppprersion, respectively, and in the serialization process, the corresponding serialization is performed one by one in the order from field 1 to field 6. The serialization steps are as follows:
step11: knowing from the instruction number that the corresponding structure type is ComputeTwo, the length of the entire structure is first written to be BOOL (2-byte length) +ulong (4-byte length) +lpstr (8-byte length) +lpword (8-byte length) +lpprecision (8-byte length) =38, that is, the first byte is 0×26.
Step12: the BOOL bFale is then serialized in 2 bytes, with 0x00 x01 if the value is TRUE and 0x00 if the value is FALSE.
Step13: next, ULONG ulAge,4 bytes, if this value is 1, the serialized bytes are 0x000x00 0x00 0x01.
Step14: strExtra is then serialized as in the case of the aforementioned serialized LPSTR, and if its value is "WFP\0WFP\0\0", then the serialized byte is 0x09 0x57 0x46 0x50 0x00 0x57 0x46 0x50 0x00 0x00.
Step15: next, LPWORD lpTime is serialized, and if the pointer corresponds to a value of 3, the serialized byte is 0x00 x03.
Step16: next, the field is a structure pointer, and each element within the structure element is recursively serialized with reference to serialization case 5, LPPerson lpPersion:
step161: the length of the whole structure is (2+4+8=14) bytes, and the serialized bytes are 0x0E. Step162: the BOOL bFalse is then serialized, with the serialized byte being 0x00 if the value is FALSE and 0x00 x01 if the value is TRUE.
Step163: next, ULONG ulAge is serialized, if this value is 9, then 0x00 0x00 0x00 0x09.Step164: next, LPSTR strExtra is serialized, and if its value is "WFP\0WFP\0\0", then the serialized byte is 0x09 0x57 0x46 0x50 0x00 0x57 0x46 0x50 0x00 0x00.
Step17: lpversion lpppman is then serialized, which field is an array of pointers, typically specifying that the last pointer element in the array is NULL. Assuming that the pointer array is two lpprecision pointers, the serialization process is as follows:
step171: the number of the array of the serialization pointers is 0x02 (one byte).
Step172: for each lpprecision pointer within the pointer array, serialization is completed following the process of Step 16.
For case 5, the byte data after the entire serialization process is completed is as follows: 0x26 0x00 0x01 0x000x00 0x00 0x010x09 0x57 0x46 0x50 0x00 0x57 0x46 0x50 0x000x00 0x00 0x03 0x0E 0x00 0x01 0x000x00 0x00 0x09 0x09 0x57 0x46 0x50 0x00 0x57 0x46 0x50 0x000x00 0x02 0x0E 0x00 0x01 0x000x00 0x00 0x09 0x09 0x57 0x46 0x50 0x00 0x57 0x46 0x50 0x000x00 0x0E 0x00 0x01 0x000x00 0x00 0x09 0x09 0x57 0x46 0x50 0x00 0x57 0x46 0x50 0x00 0x00.
The de-serialization steps are as follows:
step21: knowing from the instruction number and the corresponding obj configuration file that the type of structure to be deserialized is ComputeTwo, it is first known from the byte stream that the entire structure to be allocated is 0x26 in length, and then a byte pointer of 0x26 bytes in length is allocated.
Step22: the first reverse-sequenced field is known from the struct ComputeTwo as BOOL bfole, 2 bytes, and the value of this field is known as TRUE when the contents of the two bytes are read to be 0x00 x 01.
Step23: the second deserialized field is known from the struct ComputeTwo as ULONG ulAge,4 bytes, and reading the content of four bytes as 0x000x00 0x00 0x01, the value of this field can be known as 1.
Step24: knowing that the third deserialized field is LPSTR strExtra from the struct ComputeTwo, first reading the length of the string to 0x09, then allocating a string pointer of 9 bytes in length, knowing that the content of the string is 0x57 0x46 0x50 0x00 0x57 0x46 0x50 0x00 0x00 (9 bytes) from the byte stream, copying the 9 bytes of byte stream data to the string pointer completes the deserialization of the field.
Step25: the fourth deserialized field is known from the struct ComputeTwo as LPWORD lpTime, which occupies two bytes, and its content is known from byte stream as 0x00 x03, because its field is a pointer to WORD, the deserialization is completed by first allocating a pointer occupying two bytes, and setting the content of the pointer (a WORD value) to 3.
Step26: from the struct ComputeTwo is known that the fifth deserialized field is LPPerson lpPersion, which is a struct pointer, and the deserialization step of reference case 5 recursively deserializes each of the inside of the struct element:
step261: first, a Person structure pointer with the length of 0x0E is allocated, and the ComputeTwo structure field is used for the
The pointer of lpprecision points to the Person structure pointer just allocated.
Step262: the first field to be deserialized is known from the fabric Person as BOOL bFalse, and the value is known from the byte stream as 0x00 0x01, so this value is TRUE.
Step263: the second field that needs to be deserialized is known from the fabric Person as ULONG ulAge, which takes 4 bytes, and from the byte stream it is known that its value is if this value is 0x00 0x00 0x00 0x09, so the value of ulAge is 9.
Step264: the third field requiring deserialization is known from the structure Person as LPSTR extra, which is a string pointer, so a string pointer with a length of 0x09 is allocated first, and byte stream data 0x57 x46 x50
0x00 0x57 0x46 0x50 0x00 0x00 is copied into the string pointer.
Step27: from the struct ComputeTwo is known that the fifth deserialized field is lpprecision lppMan, which is an array of pointers, the deserialization process is as follows:
step271: knowing that the number of pointer arrays is 0x02 from the byte stream, 2 pointers (16 bytes total) are allocated first, pointing the ComputeTwo field lppMan to the head address of the pointer array.
Step272: for each lpprecision pointer within the pointer array, deserialization is completed following the process of Step 26.
The solution provided by the above embodiment has the following advantages:
high expansibility and security: according to the serialization and deserialization method provided by the embodiment, for the interprocess communication data structure which accords with WOSA XFS specification definition, the field types of each instruction and communication structure body are defined through a header file with predefined configuration, after the processing of a compiling tool, the defined structure bodies and instructions are mapped into obj files, the effect of automatically analyzing data is achieved when the binary data stream is truly serialized and restored from the binary data stream is carried out later, and for the message composition of the binary data stream, the security of data transmission can be further achieved through encryption.
Wide application field: the above embodiment provides a method for automatically parsing and restoring data by analyzing the data type, the data length and the field name to be recorded of each field of the general C-language-based structure pointer data, and the method achieves the purposes of automatically parsing and restoring data by means of configuration file mapping, and can be further expanded to other application scenes except for WOSA XFS specifications.
The embodiment of the invention also provides a computer readable storage medium, which stores a computer program, and the computer program realizes the data serialization method, the inverse serialization method or the inter-process instruction parameter transmission method provided by the embodiment when being executed by a processor.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
It is to be understood that the same or similar parts in the above embodiments may be referred to each other, and that in some embodiments, the same or similar parts in other embodiments may be referred to.
While embodiments of the present invention have been shown and described above, it will be understood that the above embodiments are illustrative and not to be construed as limiting the invention, and that variations, modifications, alternatives and variations may be made to the above embodiments by one of ordinary skill in the art within the scope of the invention.
Claims (10)
1. A method of serializing data, comprising:
constructing a configuration file, writing a mapping relation between each instruction number and the corresponding instruction parameter type in the configuration file, and defining the structural information of each instruction parameter type;
compiling the constructed configuration file into a binary obj configuration file;
acquiring an instruction, and finding out a corresponding instruction parameter type from the obj configuration file according to the instruction number;
the method comprises the steps of firstly serializing instruction numbers, and then serializing instruction parameter values according to a preset serialization rule corresponding to the instruction parameter types to generate a binary data stream.
2. The method for serializing data according to claim 1, wherein the serializing the instruction parameter value according to the preset serializing rule corresponding to the instruction parameter type includes:
a1: if the instruction parameter type is the basic data type of the non-structure pointer array type and the structure pointer type, directly serializing the instruction parameter value according to a preset serialization rule corresponding to each basic data type; if the instruction parameter type is the structure pointer array, the step A2 is entered; if the instruction parameter type is a structure pointer, the step A3 is entered;
A2: if the instruction parameter pointer is empty, serializing the element number N of the instruction parameter pointer to be 0, wherein the serialization number is 0, and completing serialization; if the number of the elements is not 0, serializing the number N of the elements, wherein each element is a structure pointer, and for the structure pointer element, entering a step A3 to serialize the content of the structure pointer element;
a3: starting serializing the single structure pointers, and entering a step A4;
a4: firstly serializing the length of the structure body, and then serializing each field contained in the structure body according to the data type of the field; if the field is the basic data type of the non-structure pointer array type and the structure pointer type, directly serializing the value corresponding to the field according to the corresponding preset serialization rule; if the field is the structure pointer array type, entering a step A2 recursion to serialize the value corresponding to the field; if the field is of the structure pointer type, entering a step A3 for recursion to serialize the value corresponding to the field;
a5: for the last field contained in the structure body as the field after the serialization is completed, if the last field is entered in the step A2, the next element of the pointer array of the structure body is taken, if the element is empty, the serialization is completed, and if the element is not empty, the step A3 is entered to serialize the element; if step A3 is entered, serialization is completed.
3. A method of serializing data according to claim 1 or 2, wherein for an instruction parameter type of LPSTR, the first byte in the serialization represents the length of the entire string, followed by serialization of the string content.
4. A method of data de-serializing, for de-serializing a binary data stream generated using the method of any of claims 1 to 3, comprising the steps of:
acquiring a binary data stream, and inversely serializing the first two bytes to obtain an instruction number;
finding out the corresponding instruction parameter type from the obj configuration file according to the instruction number;
and performing deserialization on the remaining bytes of the binary data stream according to a preset deserialization rule corresponding to the instruction parameter type to obtain the instruction parameter.
5. The method for deserializing data as recited in claim 4, wherein deserializing the remaining bytes of the binary data stream according to a predetermined deserializing rule corresponding to the instruction parameter type, comprises:
b1: if the instruction parameter type is the basic data type of the unstructured pointer array type and the structured pointer type, directly deserializing the remaining bytes of the binary data stream according to a preset deserializing rule corresponding to each basic data type; if the instruction parameter type is the structure pointer array, entering a step B2; if the instruction parameter type is a structure pointer, entering a step B3;
B2: firstly, reversely listing the number N of elements in a binary data stream, and if N is 0, finishing the reverse serialization; if N is not 0, N structure pointers are firstly allocated, and for each structure pointer, step B3 is advanced to deserialize the content of the structure pointer;
b3: starting to deserialize the single structure pointer, and entering a step B4;
b4: firstly, inversely serializing the length of the structure body, distributing a pointer with a corresponding length, and then, sequentially carrying out inverse serialization on each field contained in the structure body according to the data type of the field; if the field is the basic data type of the non-structure pointer array type and the structure pointer type, directly deserializing the value corresponding to the field according to the corresponding preset deserializing rule; if the field is the structure pointer array type, entering a step B2 recursion to deserialize a value corresponding to the field; if the field is of the structure pointer type, entering a step B3 for recursion to deserialize a value corresponding to the field;
b5: for the last field contained in the structure body as the field after the deserialization is completed, if the last field is entered in the step B2, the next element of the pointer array of the structure body is taken, if the element is empty, the deserialization is completed, and if the element is not empty, the step B3 is entered to deserialize the element; if step B3 is entered, the deserialization is completed.
6. The method according to claim 4 or 5, wherein for the instruction parameter type LPSTR, the first byte is read during the deserialization to obtain the length of the entire string, a byte pointer with a corresponding length is allocated, and then the subsequent content with a corresponding length is copied into the allocated byte pointer.
7. An inter-process instruction parameter delivery method, comprising:
constructing a configuration file, writing a mapping relation between each instruction number and the corresponding instruction parameter type in the configuration file, and defining the structural information of each instruction parameter type;
compiling the constructed configuration file into a binary obj configuration file;
acquiring an instruction of a sender process, and finding out a corresponding instruction parameter type from an obj configuration file according to an instruction number; firstly serializing the instruction number, and then serializing the instruction parameter value according to a preset serialization rule corresponding to the instruction parameter type to generate a binary data stream;
transmitting the binary data stream to a receiver process through a network or an interprocess communication mechanism; and deserializing the first two bytes to obtain an instruction number; finding out the corresponding instruction parameter type from the obj configuration file according to the instruction number; and performing deserialization on the remaining bytes of the binary data stream according to a preset deserialization rule corresponding to the instruction parameter type to obtain the instruction parameter.
8. The method for transmitting inter-process instruction parameters according to claim 7, wherein the serializing the instruction parameter values according to the preset serializing rule corresponding to the instruction parameter type comprises:
a1: if the instruction parameter type is the basic data type of the non-structure pointer array type and the structure pointer type, directly serializing the instruction parameter value according to a preset serialization rule corresponding to each basic data type; if the instruction parameter type is the structure pointer array, the step A2 is entered; if the instruction parameter type is a structure pointer, the step A3 is entered;
a2: if the instruction parameter pointer is empty, serializing the element number N of the instruction parameter pointer to be 0, wherein the serialization number is 0, and completing serialization; if the number of the elements is not 0, serializing the number N of the elements, wherein each element is a structure pointer, and for the structure pointer element, entering a step A3 to serialize the content of the structure pointer element;
a3: starting serializing the single structure pointers, and entering a step A4;
a4: firstly serializing the length of the structure body, and then serializing each field contained in the structure body according to the data type of the field; if the field is the basic data type of the non-structure pointer array type and the structure pointer type, directly serializing the value corresponding to the field according to the corresponding preset serialization rule; if the field is the structure pointer array type, entering a step A2 recursion to serialize the value corresponding to the field; if the field is of the structure pointer type, entering a step A3 for recursion to serialize the value corresponding to the field;
A5: for the last field contained in the structure body as the field after the serialization is completed, if the last field is entered in the step A2, the next element of the pointer array of the structure body is taken, if the element is empty, the serialization is completed, and if the element is not empty, the step A3 is entered to serialize the element; if step A3 is entered, serialization is completed.
9. The method for transmitting inter-process instruction parameters according to claim 7 or 8, wherein the de-serializing the remaining bytes of the binary data stream according to a preset de-serializing rule corresponding to the instruction parameter type comprises:
b1: if the instruction parameter type is the basic data type of the unstructured pointer array type and the structured pointer type, directly deserializing the remaining bytes of the binary data stream according to a preset deserializing rule corresponding to each basic data type; if the instruction parameter type is the structure pointer array, entering a step B2; if the instruction parameter type is a structure pointer, entering a step B3;
b2: firstly, reversely listing the number N of elements in a binary data stream, and if N is 0, finishing the reverse serialization; if N is not 0, N structure pointers are firstly allocated, and for each structure pointer, step B3 is advanced to deserialize the content of the structure pointer;
B3: starting to deserialize the single structure pointer, and entering a step B4;
b4: firstly, inversely serializing the length of the structure body, distributing a pointer with a corresponding length, and then, sequentially carrying out inverse serialization on each field contained in the structure body according to the data type of the field; if the field is the basic data type of the non-structure pointer array type and the structure pointer type, directly deserializing the value corresponding to the field according to the corresponding preset deserializing rule; if the field is the structure pointer array type, entering a step B2 recursion to deserialize a value corresponding to the field; if the field is of the structure pointer type, entering a step B3 for recursion to deserialize a value corresponding to the field;
b5: for the last field contained in the structure body as the field after the deserialization is completed, if the last field is entered in the step B2, the next element of the pointer array of the structure body is taken, if the element is empty, the deserialization is completed, and if the element is not empty, the step B3 is entered to deserialize the element; if step B3 is entered, the deserialization is completed.
10. A computer-readable storage medium, in which a computer program is stored, which computer program, when being executed by a processor, implements the method according to any one of claims 1 to 9.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202310067733.6A CN116225578A (en) | 2023-01-16 | 2023-01-16 | Data serialization method, anti-serialization method and inter-process instruction parameter transmission method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202310067733.6A CN116225578A (en) | 2023-01-16 | 2023-01-16 | Data serialization method, anti-serialization method and inter-process instruction parameter transmission method |
Publications (1)
Publication Number | Publication Date |
---|---|
CN116225578A true CN116225578A (en) | 2023-06-06 |
Family
ID=86570786
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202310067733.6A Pending CN116225578A (en) | 2023-01-16 | 2023-01-16 | Data serialization method, anti-serialization method and inter-process instruction parameter transmission method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN116225578A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116737135A (en) * | 2023-06-25 | 2023-09-12 | 上海同星智能科技有限公司 | Parameter configuration method and system for graphic program |
CN117171042A (en) * | 2023-08-16 | 2023-12-05 | 上海同星智能科技有限公司 | Development and debugging system and method based on parameter configuration method for graphic program |
-
2023
- 2023-01-16 CN CN202310067733.6A patent/CN116225578A/en active Pending
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116737135A (en) * | 2023-06-25 | 2023-09-12 | 上海同星智能科技有限公司 | Parameter configuration method and system for graphic program |
CN116737135B (en) * | 2023-06-25 | 2024-01-30 | 上海同星智能科技有限公司 | Parameter configuration method and system for graphic program |
CN117171042A (en) * | 2023-08-16 | 2023-12-05 | 上海同星智能科技有限公司 | Development and debugging system and method based on parameter configuration method for graphic program |
CN117171042B (en) * | 2023-08-16 | 2024-03-12 | 上海同星智能科技有限公司 | Development and debugging system and method based on parameter configuration method for graphic program |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11010681B2 (en) | Distributed computing system, and data transmission method and apparatus in distributed computing system | |
CN116225578A (en) | Data serialization method, anti-serialization method and inter-process instruction parameter transmission method | |
CN109308224B (en) | Cross-platform data communication and cross-platform data processing method, device and system | |
EP0737916B1 (en) | Methods, apparatus and data structures for managing objects | |
EP2260377B1 (en) | Accessing different type structures via a common data structure | |
US5680616A (en) | Method and system for generating and maintaining property sets with unique format identifiers | |
US6898604B1 (en) | XML serialization and deserialization | |
CN111124551B (en) | Data serialization and data deserialization methods, devices and computer equipment | |
US6931642B1 (en) | Data type mapping for external callouts | |
US20100115126A1 (en) | Automated conversion of versioned data collections | |
JP5011311B2 (en) | Method and mechanism for loading an XML document into memory | |
CN113391791A (en) | Data processing method, device and storage medium | |
US6182202B1 (en) | Generating computer instructions having operand offset length fields for defining the length of variable length operand offsets | |
US7003773B2 (en) | Dynamic interface aggregation on demand | |
EP1231547A2 (en) | System and method for mapping structured documents to structured data of program language and program for executing its method | |
CN113296979A (en) | Data communication method for unreal engine and external program | |
CN116775392A (en) | Chip communication testing method and device, electronic equipment and storage medium | |
CN114048352B (en) | Method for converting XML file into structure with indefinite length | |
US6708310B1 (en) | Method and system for implementing user-defined codeset conversions in a computer system | |
CN116414689A (en) | Interface parameter verification method and system based on reflection mechanism | |
CN114697402B (en) | Internet of things protocol serialization method and device and electronic equipment | |
CN116506523B (en) | Unified communication method suitable for multiple protocols | |
CN118364033B (en) | Data processing method and device among database clusters and related equipment | |
CN117519691B (en) | Application processing method, device, computer equipment and storage medium | |
US7941452B2 (en) | Apparatus and method for efficient encoding of application definition using contiguous arrays |
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 |