Binary serialization method
The invention provides a binary serialization method. The binary serialization method comprises the following steps: S1, defining an XML format interface based on a field type; s2, constructing a binary serialization algorithm and a deserialization algorithm according to the XML format interface; an...
Gespeichert in:
Hauptverfasser: | , , |
---|---|
Format: | Patent |
Sprache: | chi ; eng |
Schlagworte: | |
Online-Zugang: | Volltext bestellen |
Tags: |
Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
|
Zusammenfassung: | The invention provides a binary serialization method. The binary serialization method comprises the following steps: S1, defining an XML format interface based on a field type; s2, constructing a binary serialization algorithm and a deserialization algorithm according to the XML format interface; and S3, acquiring a data field from the cache, reading the data field, and based on an XML format interface, realizing data transmission according to the constructed binary serialization algorithm and deserialization algorithm. According to the serialization method, judgment of the field type and calculation of the field position are all carried out in the compiling period, the computing power overhead during program running is saved, meanwhile, based on the XML format structure, modularization of large and small end serialization and deserialization logic is achieved at the same time, the technical requirement for personnel is lowered, and the coding efficiency is improved.
本发明提供了一种二进制序列化方法,包括S1:基于字段类型定义XML格式接口;S2:根 |
---|