libmongo-client  0.1.8
 All Data Structures Functions Variables Enumerations Enumerator Groups Pages
Enumerations | Functions
Types
Collaboration diagram for Types:

Enumerations

enum  bson_type {
  BSON_TYPE_NONE = 0, BSON_TYPE_DOUBLE = 0x01, BSON_TYPE_STRING, BSON_TYPE_DOCUMENT,
  BSON_TYPE_ARRAY, BSON_TYPE_BINARY, BSON_TYPE_UNDEFINED, BSON_TYPE_OID,
  BSON_TYPE_BOOLEAN, BSON_TYPE_UTC_DATETIME, BSON_TYPE_NULL, BSON_TYPE_REGEXP,
  BSON_TYPE_DBPOINTER, BSON_TYPE_JS_CODE, BSON_TYPE_SYMBOL, BSON_TYPE_JS_CODE_W_SCOPE,
  BSON_TYPE_INT32, BSON_TYPE_TIMESTAMP, BSON_TYPE_INT64, BSON_TYPE_MIN = 0xff,
  BSON_TYPE_MAX = 0x7f
}
 Supported BSON object types. More...
 
enum  bson_binary_subtype {
  BSON_BINARY_SUBTYPE_GENERIC = 0x00, BSON_BINARY_SUBTYPE_FUNCTION = 0x01, BSON_BINARY_SUBTYPE_BINARY = 0x02, BSON_BINARY_SUBTYPE_UUID = 0x03,
  BSON_BINARY_SUBTYPE_MD5 = 0x05, BSON_BINARY_SUBTYPE_USER_DEFINED = 0x80
}
 Supported BSON binary subtypes. More...
 

Functions

const gchar * bson_type_as_string (bson_type type)
 Return a type's stringified name. More...
 

Detailed Description

Enumeration Type Documentation

Supported BSON binary subtypes.

Enumerator
BSON_BINARY_SUBTYPE_GENERIC 

The Generic subtype, the default.

BSON_BINARY_SUBTYPE_FUNCTION 

Binary representation of a function.

BSON_BINARY_SUBTYPE_BINARY 

Obsolete, do not use.

BSON_BINARY_SUBTYPE_UUID 

Binary representation of an UUID.

BSON_BINARY_SUBTYPE_MD5 

Binary representation of an MD5 sum.

BSON_BINARY_SUBTYPE_USER_DEFINED 

User defined data, nothing's known about the structure.

enum bson_type

Supported BSON object types.

Enumerator
BSON_TYPE_NONE 

Only used for errors.

BSON_TYPE_DOUBLE 

8byte double

BSON_TYPE_STRING 

4byte length + NULL terminated string

BSON_TYPE_DOCUMENT 

4byte length + NULL terminated document

BSON_TYPE_ARRAY 

4byte length + NULL terminated document

BSON_TYPE_BINARY 

4byte length + 1byte subtype + data

BSON_TYPE_OID 

12byte ObjectID

BSON_TYPE_BOOLEAN 

1byte boolean value

BSON_TYPE_UTC_DATETIME 

8byte timestamp; milliseconds since Unix epoch

BSON_TYPE_NULL 

NULL value, No following data.

BSON_TYPE_REGEXP 

Two NULL terminated C strings, the regex itself, and the options.

BSON_TYPE_JS_CODE 

4byte length + NULL terminated string

BSON_TYPE_SYMBOL 

4byte length + NULL terminated string

BSON_TYPE_JS_CODE_W_SCOPE 

4byte length, followed by a string and a document

BSON_TYPE_INT32 

4byte integer

BSON_TYPE_TIMESTAMP 

4bytes increment + 4bytes timestamp

BSON_TYPE_INT64 

8byte integer

Function Documentation

const gchar* bson_type_as_string ( bson_type  type)

Return a type's stringified name.

Parameters
typeis the type to stringify.
Returns
The stringified type, or NULL on error.