Comparison of data serialization formats
Encyclopedia
This is a comparison of data serialization format
File format
A file format is a particular way that information is encoded for storage in a computer file.Since a disk drive, or indeed any computer storage, can store only bits, the computer must have some way of converting information to 0s and 1s and vice-versa. There are different kinds of formats for...

s
, different ways to convert complex object
Object (computer science)
In computer science, an object is any entity that can be manipulated by the commands of a programming language, such as a value, variable, function, or data structure...

s to sequences of bit
Bit
A bit is the basic unit of information in computing and telecommunications; it is the amount of information stored by a digital device or other physical system that exists in one of two possible distinct states...

s. It does not include markup language
Markup language
A markup language is a modern system for annotating a text in a way that is syntactically distinguishable from that text. The idea and terminology evolved from the "marking up" of manuscripts, i.e. the revision instructions by editors, traditionally written with a blue pencil on authors' manuscripts...

s used exclusively as document file format
Document file format
A document file format is a text or binary file format for storing documents on a storage media, especially for use by computers.There currently exist a multitude of incompatible document file formats....

s.

Overview

Name Creator/Maintainer Based on Standardized? Specification Binary? Human-readable
Human-readable
A human-readable medium or human-readable format is a representation of data or information that can be naturally read by humans.In computing, human-readable data is often encoded as ASCII or Unicode text, rather than presented in a binary representation...

?
reference
Reference (computer science)
In computer science, a reference is a value that enables a program to indirectly access a particular data item, such as a variable or a record, in the computer's memory or in some other storage device. The reference is said to refer to the data item, and accessing those data is called...

 support?
Schema/IDL
Interface description language
An interface description language , or IDL for short, is a specification language used to describe a software component's interface...

?
Standard APIs
ASN.1 ISO, IEC
International Electrotechnical Commission
The International Electrotechnical Commission is a non-profit, non-governmental international standards organization that prepares and publishes International Standards for all electrical, electronic and related technologies – collectively known as "electrotechnology"...

, ITU-T
ITU-T
The ITU Telecommunication Standardization Sector is one of the three sectors of the International Telecommunication Union ; it coordinates standards for telecommunications....

ISO/IEC 8824; X.680 series of ITU-T Recommendations
(BER
Basic Encoding Rules
The Basic Encoding Rules is one of the encoding formats defined as part of the ASN.1 standard specified by the ITU in X.690.-Description:...

, DER
Distinguished Encoding Rules
Distinguished Encoding Rules , is a message transfer syntax specified by the ITU in X.690. The Distinguished Encoding Rules of ASN.1 is an International Standard drawn from the constraints placed on basic encoding rules encodings by X.509. DER encodings are valid BER encodings...

, PER
Packed Encoding Rules
Packed encoding rules are ASN.1 encoding rules for producing a compact transfer syntax for data structures described in ASN.1, defined in 1994....

, or custom via ECN
Encoding Control Notation
The Encoding Control Notation is a standardized formal language that is part of the Abstract Syntax Notation One family of international standards...

)

(XER
XML Encoding Rules
XML Encoding Rules , defined in ITU-T standard X.693, are a set of ASN.1 encoding rules for producing an XML-based verbose textual transfer syntax for data structures described in ASN.1....

, GSER
Generic String Encoding Rules
Generic String Encoding Rules are a set of ASN.1 encoding rules for producing a verbose, human-readable textual transfer syntax for data structures described in ASN.1....

, or custom via ECN
Encoding Control Notation
The Encoding Control Notation is a standardized formal language that is part of the Abstract Syntax Notation One family of international standards...

)
(built-in)
Bencode
Bencode
Bencode is the encoding used by the peer-to-peer file sharing system BitTorrent for storing and transmitting loosely structured data.It supports four different types of values:* byte strings,* integers,* lists, and* dictionaries ....

BitTorrent, Inc. Part of BitTorrent protocol specification
(numbers are ASCII-based)
BSON
BSON
BSON is a computer data interchange format used mainly as a data storage and network transfer format in the MongoDB database. It is a binary form for representing simple data structures and associative arrays...

MongoDB
MongoDB
MongoDB is an open source, high-performance, schema-free, document-oriented database written in the C++ programming language...

JSON
JSON
JSON , or JavaScript Object Notation, is a lightweight text-based open standard designed for human-readable data interchange. It is derived from the JavaScript scripting language for representing simple data structures and associative arrays, called objects...

BSON Specification
Candle
Candle (programming language)
Candle is a high-level general-purpose scripting language for both desktop and Internet applications. It unifies the core features of many XML related technologies like XQuery, XSLT, RELAX NG. Its first public beta release was on 12 Oct 2005...

 Markup
Henry Luo XML
XML
Extensible Markup Language is a set of rules for encoding documents in machine-readable form. It is defined in the XML 1.0 Specification produced by the W3C, and several other related specifications, all gratis open standards....

, JSON
JSON
JSON , or JavaScript Object Notation, is a lightweight text-based open standard designed for human-readable data interchange. It is derived from the JavaScript scripting language for representing simple data structures and associative arrays, called objects...

, JavaFX
JavaFX
JavaFX is a software platform for creating and delivering rich Internet applications that can run across a wide variety of connected devices....

Candle Markup Reference (XPointer
XPointer
XPointer is a system for addressing components of XML based internet media.XPointer is divided among four specifications: a "framework" which forms the basis for identifying XML fragments, a positional element addressing scheme, a scheme for namespaces, and a scheme for XPath-based addressing...

, XPath
XPath
XPath is a language for selecting nodes from an XML document. In addition, XPath may be used to compute values from the content of an XML document...

)

(Candle Pattern Reference)
XQuery
XQuery
- Features :XQuery provides the means to extract and manipulate data from XML documents or any data source that can be viewed as XML, such as relational databases or office documents....

, XPath
XPath
XPath is a language for selecting nodes from an XML document. In addition, XPath may be used to compute values from the content of an XML document...

Comma-separated values
Comma-separated values
A comma-separated values file stores tabular data in plain-text form. As a result, such a file is easily human-readable ....

 (CSV)
RFC author:
Yakov Shafranovich

(myriad informal variants used)
RFC 4180
(among others)
D-Bus
D-Bus
In computing, D-Bus is a simple inter-process communication open-source system for software applications to communicate with one another. Heavily influenced by KDE2–3's DCOP system, D-Bus has replaced DCOP in the KDE 4 release. An implementation of D-Bus supports most POSIX operating...

 Message Protocol
freedesktop.org
Freedesktop.org
freedesktop.org is a project to work on interoperability and shared base technology for free software desktop environments for the X Window System on Linux and other Unix-like operating systems. It was founded by Havoc Pennington from Red Hat in March 2000.The organisation focuses on the user....

D-Bus Specification
(Type Signatures)

(see D-Bus
D-Bus
In computing, D-Bus is a simple inter-process communication open-source system for software applications to communicate with one another. Heavily influenced by KDE2–3's DCOP system, D-Bus has replaced DCOP in the KDE 4 release. An implementation of D-Bus supports most POSIX operating...

)
JSON
JSON
JSON , or JavaScript Object Notation, is a lightweight text-based open standard designed for human-readable data interchange. It is derived from the JavaScript scripting language for representing simple data structures and associative arrays, called objects...

Douglas Crockford
Douglas Crockford
Douglas Crockford is an American computer programmer and entrepreneur, best known for his ongoing involvement in the development of the JavaScript language, and for having popularized the data format JSON , and for developing JSLint...

JavaScript syntax
JavaScript syntax
The syntax of JavaScript is the set of rules that define a correctly structured JavaScript program.The examples below make use of the alert function for standard text output. The JavaScript standard library lacks an official standard text output function...

RFC 4627 , but see BSON
BSON
BSON is a computer data interchange format used mainly as a data storage and network transfer format in the MongoDB database. It is a binary form for representing simple data structures and associative arrays...


(Kwalify, Rx, JSON Schema Proposal)
MessagePack
MessagePack
MessagePack is a computer data interchange format. It is a binary form for representing simple data structure like arrays and associative arrays. MessagePack aims to be as compact and simple as possible...

Sadayuki Furuhashi JSON
JSON
JSON , or JavaScript Object Notation, is a lightweight text-based open standard designed for human-readable data interchange. It is derived from the JavaScript scripting language for representing simple data structures and associative arrays, called objects...

 (loosely)
MessagePack format specification
Netstrings Dan Bernstein netstrings.txt
OGDL
OGDL
OGDL , is a "structured textual format that represents information in the form of graphs, where the nodes are strings and the arcs or edges are spaces or indentation."...

Rolf Veen 1.0 Working draft
(Binary 1.0 Working draft)

(Path 1.0 Working draft)

(Schema WD)
Property list
Property list
In the Mac OS X, iOS, NeXTSTEP, and GNUstep programming frameworks, property list files are files that store serialized objects. Property list files use the filename extension .plist, and thus are often referred to as p-list files....

NeXT
NeXT
Next, Inc. was an American computer company headquartered in Redwood City, California, that developed and manufactured a series of computer workstations intended for the higher education and business markets...

 (creator)
Apple (maintainer)
Public DTD for XML format Cocoa, CoreFoundation, OpenStep, GnuStep
Protocol Buffers
Protocol Buffers
Protocol Buffers are a serialization format with an interface description language developed by Google. The original Google implementation for C++, Java and Python is available under a free software, open source license....

Google
Google
Google Inc. is an American multinational public corporation invested in Internet search, cloud computing, and advertising technologies. Google hosts and develops a number of Internet-based services and products, and generates profit primarily from advertising through its AdWords program...

Developer Guide: Encoding (built-in)
Internet Draft author:
Ron Rivest
Ron Rivest
Ronald Linn Rivest is a cryptographer. He is the Andrew and Erna Viterbi Professor of Computer Science at MIT's Department of Electrical Engineering and Computer Science and a member of MIT's Computer Science and Artificial Intelligence Laboratory...

Lisp, Netstrings
(largely de facto)
"S-Expressions" Internet Draft
Internet Draft
Internet Drafts is a series of working documents published by the IETF. Typically, they are drafts for RFCs, but may be other works in progress not intended for publication as RFCs. It is considered inappropriate to rely on Internet Drafts for reference purposes...


("Canonical representation")

("Advanced transport representation")
IETF RFC 3072
Thrift
Thrift (protocol)
Thrift is an interface definition language that is used to define and create services for numerous languages. It is used as a remote procedure call framework and was developed at Facebook for "scalable cross-language services development"...

Facebook
Facebook
Facebook is a social networking service and website launched in February 2004, operated and privately owned by Facebook, Inc. , Facebook has more than 800 million active users. Users must register before using the site, after which they may create a personal profile, add other users as...

 (creator)
Apache
Apache Software Foundation
The Apache Software Foundation is a non-profit corporation to support Apache software projects, including the Apache HTTP Server. The ASF was formed from the Apache Group and incorporated in Delaware, U.S., in June 1999.The Apache Software Foundation is a decentralized community of developers...

 (maintainer)
Original whitepaper (built-in)
eXternal Data Representation
External Data Representation
External Data Representation is a standard data serialization format, for uses such as computer network protocols. It allows data to be transferred between different kinds of computer systems. Converting from the local representation to XDR is called encoding. Converting from XDR to the local...

IETF RFC 4506
XML
XML
Extensible Markup Language is a set of rules for encoding documents in machine-readable form. It is defined in the XML 1.0 Specification produced by the W3C, and several other related specifications, all gratis open standards....

W3C SGML
1.0 (Fifth Edition)
1.1 (Second Edition)

(XPointer
XPointer
XPointer is a system for addressing components of XML based internet media.XPointer is divided among four specifications: a "framework" which forms the basis for identifying XML fragments, a positional element addressing scheme, a scheme for namespaces, and a scheme for XPath-based addressing...

, XPath
XPath
XPath is a language for selecting nodes from an XML document. In addition, XPath may be used to compute values from the content of an XML document...

)
(XML schema
XML schema
An XML schema is a description of a type of XML document, typically expressed in terms of constraints on the structure and content of documents of that type, above and beyond the basic syntactical constraints imposed by XML itself...

)
DOM
Document Object Model
The Document Object Model is a cross-platform and language-independent convention for representing and interacting with objects in HTML, XHTML and XML documents. Aspects of the DOM may be addressed and manipulated within the syntax of the programming language in use...

, SAX
Simple API for XML
SAX is an event-based sequential access parser API developed by the XML-DEV mailing list for XML documents. SAX provides a mechanism for reading data from an XML document that is an alternative to that provided by the Document Object Model...

, XQuery
XQuery
- Features :XQuery provides the means to extract and manipulate data from XML documents or any data source that can be viewed as XML, such as relational databases or office documents....

, XPath
XPath
XPath is a language for selecting nodes from an XML document. In addition, XPath may be used to compute values from the content of an XML document...

YAML
YAML
YAML is a human-readable data serialization format that takes concepts from programming languages such as C, Perl, and Python, and ideas from XML and the data format of electronic mail . YAML was first proposed by Clark Evans in 2001, who designed it together with Ingy döt Net and Oren Ben-Kiki...

Clark Evans, Ingy döt Net, and Oren Ben-Kiki XML
XML
Extensible Markup Language is a set of rules for encoding documents in machine-readable form. It is defined in the XML 1.0 Specification produced by the W3C, and several other related specifications, all gratis open standards....

, C
C (programming language)
C is a general-purpose computer programming language developed between 1969 and 1973 by Dennis Ritchie at the Bell Telephone Laboratories for use with the Unix operating system....

, Python
Python (programming language)
Python is a general-purpose, high-level programming language whose design philosophy emphasizes code readability. Python claims to "[combine] remarkable power with very clear syntax", and its standard library is large and comprehensive...

, Perl
Perl
Perl is a high-level, general-purpose, interpreted, dynamic programming language. Perl was originally developed by Larry Wall in 1987 as a general-purpose Unix scripting language to make report processing easier. Since then, it has undergone many changes and revisions and become widely popular...

, Email
Email
Electronic mail, commonly known as email or e-mail, is a method of exchanging digital messages from an author to one or more recipients. Modern email operates across the Internet or other computer networks. Some early email systems required that the author and the recipient both be online at the...

Version 1.2 (Kwalify, Rx, built-in language type-defs)
  • a. The current default format is binary.
  • b. The "classic" format is plain text, and an XML format is also supported.
  • c. Theoretically possible due to abstraction, but no implementation is included.
  • d. The primary format is binary but a text format is available.
  • e. Means that generic tools/libraries know how to encode, decode, and dereference a reference to another piece of data in the same document. A tool may require the IDL
    Interface description language
    An interface description language , or IDL for short, is a specification language used to describe a software component's interface...

     file, but no more. Excludes custom, non-standardized referencing techniques.
  • f. ASN.1 does offer OIDs
    Object identifier
    In computing, an object identifier or OID is an identifier used to name an object . Structurally, an OID consists of a node in a hierarchically-assigned namespace, formally defined using the ITU-T's ASN.1 standard. Successive numbers of the nodes, starting at the root of the tree, identify each...

    , a standard format for globally unique identifiers. However, there is no standard for "marking"/"tagging" an arbitrary piece of data in a document with an OID. There is also no standard format for locally unique identifiers within a document. Therefore, a generic ASN.1 tool/library can not automatically encode/decode/resolve references within a document without help from custom-written program code.

Syntax comparison of human-readable formats

Format Null Boolean true Boolean false Integer
Integer (computer science)
In computer science, an integer is a datum of integral data type, a data type which represents some finite subset of the mathematical integers. Integral data types may be of different sizes and may or may not be allowed to contain negative values....

Floating-point String
String (computer science)
In formal languages, which are used in mathematical logic and theoretical computer science, a string is a finite sequence of symbols that are chosen from a set or alphabet....

Array
Array data type
In computer science, an array type is a data type that is meant to describe a collection of elements , each selected by one or more indices that can be computed at run time by the program. Such a collection is usually called an array variable, array value, or simply array...

Associative array
Associative array
In computer science, an associative array is an abstract data type composed of a collection of pairs, such that each possible key appears at most once in the collection....

/Object
Object (computer science)
In computer science, an object is any entity that can be manipulated by the commands of a programming language, such as a value, variable, function, or data structure...

ASN.1
XML Encoding Rules
XML Encoding Rules , defined in ITU-T standard X.693, are a set of ASN.1 encoding rules for producing an XML-based verbose textual transfer syntax for data structures described in ASN.1....


(XML Encoding Rules)
true false 685230 6.8523015e+5

true

-42.1e7
A to Z
We said, "no".
An object (the key is a field name):

true

1.85
Bob Peterson


A data mapping (the key is a data value):



John
3.14


Jane
2.718


Candle
Candle (programming language)
Candle is a high-level general-purpose scripting language for both desktop and Internet applications. It unifies the core features of many XML related technologies like XQuery, XSLT, RELAX NG. Its first public beta release was on 12 Oct 2005...

 Markup
, "" true false 685230
-685230
6.8523015e+5 "A to Z"
"""
A
to
Z
"""
(true, , -42.1e7, "A to Z")
_{%342=true A%20to%20Z=(1, 2, 3)}
or
_{
_{key=42 value=true}
_{key="A to Z" value=(1, 2, 3)}
}
CSV
Comma-separated values
A comma-separated values file stores tabular data in plain-text form. As a result, such a file is easily human-readable ....

null
(or an empty element in the row)
1
true
0
false
685230
-685230
6.8523015e+5
true,,-42.1e7,"A to Z"
42,1
A to Z,1,2,3
Netstrings 0:,
4:null,
1:1,
4:true,
1:0,
5:false,
6:685230, 9:6.8523e+5, 29:4:true,0:,7:-42.1e7,6:A to Z,,
JSON
JSON
JSON , or JavaScript Object Notation, is a lightweight text-based open standard designed for human-readable data interchange. It is derived from the JavaScript scripting language for representing simple data structures and associative arrays, called objects...

null true false 685230
-685230
6.8523015e+5 [true, null, -42.1e7, "A to Z"] {"42": true, "A to Z": [1, 2, 3]}
OGDL
OGDL
OGDL , is a "structured textual format that represents information in the form of graphs, where the nodes are strings and the arcs or edges are spaces or indentation."...

null true false 685230 6.8523015e+5 "A to Z"
'A to Z'
NoSpaces
true
null
-42.1e7
"A to Z"

(true, null, -42.1e7, "A to Z")
42
true
"A to Z"
1
2
3

42
true
"A to Z", (1, 2, 3)
Property list
Property list
In the Mac OS X, iOS, NeXTSTEP, and GNUstep programming frameworks, property list files are files that store serialized objects. Property list files use the filename extension .plist, and thus are often referred to as p-list files....


(plain text format)
<*BY> <*BN> <*I685230> <*R6.8523015e+5> "A to Z" ( <*BY>, <*R-42.1e7>, "A to Z" )
{
"42" = <*BY>;
"A to Z" = ( <*I1>, <*I2>, <*I3> );
}
Property list
Property list
In the Mac OS X, iOS, NeXTSTEP, and GNUstep programming frameworks, property list files are files that store serialized objects. Property list files use the filename extension .plist, and thus are often referred to as p-list files....


(XML format)
685230 6.8523015e+5


-42.1e7
A to Z

42

A to Z

1
2
3

S-expression
S-expression
S-expressions or sexps are list-based data structures that represent semi-structured data. An S-expression may be a nested list of smaller S-expressions. S-expressions are probably best known for their use in the Lisp family of programming languages...

s
NIL
nil
T
#t
true
NIL
#f
false
685230 6.8523015e+5 abc
"abc"
#616263#
3:abc
{MzphYmM=}
>YWJj|
(T NIL -42.1e7 "A to Z") ((42 T) ("A to Z" (1 2 3)))
YAML
YAML
YAML is a human-readable data serialization format that takes concepts from programming languages such as C, Perl, and Python, and ideas from XML and the data format of electronic mail . YAML was first proposed by Clark Evans in 2001, who designed it together with Ingy döt Net and Oren Ben-Kiki...

~
null
Null
NULL
y
Y
yes
Yes
YES
on
On
ON
true
True
TRUE
n
N
no
No
NO
off
Off
OFF
false
False
FALSE
685230
+685_230
-685230
02472256
0x_0A_74_AE
0b1010_0111_0100_1010_1110
190:20:30
6.8523015e+5
685.230_15e+03
685_230.15
190:20:30.15
.inf
-.inf
.Inf
.INF
.NaN
.nan
.NAN
A to Z
"A to Z"
'A to Z'
[y, ~, -42.1e7, "A to Z"]
- y
-
- -42.1e7
- A to Z
{"John":3.14, "Jane":2.718}
42: y
A to Z: [1, 2, 3]
XML
XML
Extensible Markup Language is a set of rules for encoding documents in machine-readable form. It is defined in the XML 1.0 Specification produced by the W3C, and several other related specifications, all gratis open standards....



685230 6.8523015e+5

true

-42.1e7
A to Z


42
true


A to Z









  • a. One possible encoding; the specification document does not specifically give an encoding for this datatype.
  • b. The RFC CSV specification only deals with delimiters, newlines, and quote characters; it does not directly deal with serializing programming data structure
    Data structure
    In computer science, a data structure is a particular way of storing and organizing data in a computer so that it can be used efficiently.Different kinds of data structures are suited to different kinds of applications, and some are highly specialized to specific tasks...

    s.
  • c. The netstrings specification only deals with nested byte strings; anything else is outside the scope of the specification.
  • d. XML
    XML
    Extensible Markup Language is a set of rules for encoding documents in machine-readable form. It is defined in the XML 1.0 Specification produced by the W3C, and several other related specifications, all gratis open standards....

     in and of itself is not a data serialization language, but many data serialization formats have been derived from it; as such, there are many different ways, in addition to those shown, to serialize programming data structure
    Data structure
    In computer science, a data structure is a particular way of storing and organizing data in a computer so that it can be used efficiently.Different kinds of data structures are suited to different kinds of applications, and some are highly specialized to specific tasks...

    s into XML.
  • e. This syntax is not compatible with the Internet-Draft, but is used by some dialects of Lisp.

Comparison of binary formats

Format Null Booleans Integer
Integer (computer science)
In computer science, an integer is a datum of integral data type, a data type which represents some finite subset of the mathematical integers. Integral data types may be of different sizes and may or may not be allowed to contain negative values....

Floating-point String
String (computer science)
In formal languages, which are used in mathematical logic and theoretical computer science, a string is a finite sequence of symbols that are chosen from a set or alphabet....

Array
Array data type
In computer science, an array type is a data type that is meant to describe a collection of elements , each selected by one or more indices that can be computed at run time by the program. Such a collection is usually called an array variable, array value, or simply array...

Associative array
Associative array
In computer science, an associative array is an abstract data type composed of a collection of pairs, such that each possible key appears at most once in the collection....

/Object
Object (computer science)
In computer science, an object is any entity that can be manipulated by the commands of a programming language, such as a value, variable, function, or data structure...

ASN.1
(BER
Basic Encoding Rules
The Basic Encoding Rules is one of the encoding formats defined as part of the ASN.1 standard specified by the ITU in X.690.-Description:...

 or PER
Packed Encoding Rules
Packed encoding rules are ASN.1 encoding rules for producing a compact transfer syntax for data structures described in ASN.1, defined in 1994....

 encoding)
NULL type BOOLEAN; BER as 1 byte in binary form INTEGER; variable length big-endian binary representation up to 2^2^1024 bits REAL; representation as IEEE double or as three integer (mantissa + base + exponent) Multiple valid types (VisibleString, PrintableString, GeneralString, UniversalString) data specifications SET OF (unordered) and SEQUENCE OF (guaranteed order) user definable type
BSON
BSON
BSON is a computer data interchange format used mainly as a data storage and network transfer format in the MongoDB database. It is a binary form for representing simple data structures and associative arrays...

Null type - 0 bytes for value True: one byte \x01
False: \x00
int32: 32-bit little-endian 2's complement or int64: 64-bit little-endian 2's complement double: little-endian binary64 UTF-8
UTF-8
UTF-8 is a multibyte character encoding for Unicode. Like UTF-16 and UTF-32, UTF-8 can represent every character in the Unicode character set. Unlike them, it is backward-compatible with ASCII and avoids the complications of endianness and byte order marks...

 encoded, preceded by int32 encoded string length in bytes
BSON
BSON
BSON is a computer data interchange format used mainly as a data storage and network transfer format in the MongoDB database. It is a binary form for representing simple data structures and associative arrays...

 embedded document with numeric keys
BSON
BSON
BSON is a computer data interchange format used mainly as a data storage and network transfer format in the MongoDB database. It is a binary form for representing simple data structures and associative arrays...

 embedded document
MessagePack
MessagePack
MessagePack is a computer data interchange format. It is a binary form for representing simple data structure like arrays and associative arrays. MessagePack aims to be as compact and simple as possible...

\xc0 True: \xc3 False: \xc2 Single byte "fixnum" (values -32..127)
or
typecode (one byte) + big-endian (u)int8/16/32/64
Typecode (one byte) + IEEE single/double As "fixraw" (single-byte prefix + up to 31 raw bytes)
or
typecode (one byte) + 2-4 bytes length + raw bytes
As "fixarray" (single-byte prefix + up to 15 array items)
or
typecode (one byte) + 2-4 bytes length + array items
As "fixmap" (single-byte prefix + up to 15 key-value pairs)
or
typecode (one byte) + 2-4 bytes length + key-value pairs
Netstrings 0:, True: 1:1,
OGDL
OGDL
OGDL , is a "structured textual format that represents information in the form of graphs, where the nodes are strings and the arcs or edges are spaces or indentation."...

 Binary
Property list
Property list
In the Mac OS X, iOS, NeXTSTEP, and GNUstep programming frameworks, property list files are files that store serialized objects. Property list files use the filename extension .plist, and thus are often referred to as p-list files....


(binary format)
Protocol Buffers
Protocol Buffers
Protocol Buffers are a serialization format with an interface description language developed by Google. The original Google implementation for C++, Java and Python is available under a free software, open source license....

Variable encoding length signed 32-bit: varint encoding of "ZigZag"-encoded value (n << 1) XOR (n >> 31)
Variable encoding length signed 64-bit: varint encoding of "ZigZag"-encoded (n << 1) XOR (n >> 63)

Constant encoding length 32-bit: 32 bits in little-endian 2's complement

Constant encoding length 64-bit: 54 bits in little-endian 2's complement
floats
Single precision floating-point format
Single-precision floating-point format is a computer number format that occupies 4 bytes in computer memory and represents a wide dynamic range of values by using a floating point....

: little-endian binary32
doubles: little-endian binary64
UTF-8
UTF-8
UTF-8 is a multibyte character encoding for Unicode. Like UTF-16 and UTF-32, UTF-8 can represent every character in the Unicode character set. Unlike them, it is backward-compatible with ASCII and avoids the complications of endianness and byte order marks...

 encoded, preceded by varint-encoded integer length of string in bytes
Thrift
Thrift (protocol)
Thrift is an interface definition language that is used to define and create services for numerous languages. It is used as a remote procedure call framework and was developed at Facebook for "scalable cross-language services development"...


External links

The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK