6.1 Mapping of basic data types
oneM2M has defined the data types that describe the format of the value stored at the attribute. Those oneM2M data types are listed in the below table, and mapped to the data types specified by OMA Lightweight M2M 1.0 [5] (shortened in OMA LwM2M).
Table 6.1-1 Basic data types
oneM2M Data Types | Mapping to data types in OMA LwM2M | description |
---|---|---|
xs:string | String | UTF-8 string. |
xs:integer | Integer | ASCII signed integer 1, 2,4 or 8 bytes. |
xs:boolean | Boolean | Data type for BooleanASCII value 0 or 1. |
xs:float | Float | A 32 or 64-bit floating point value. The valid range of the value for a Resource SHOULD be defined. |
xs:base64Binary | Opaque | A sequence of binary octets, the minimum and/or maximum length of the octets MAY be defined. |
xs:dateTime | Time | Unix Time. A signed integer representing the number of seconds since Jan 1st, 1970 in the UTC time zone. |
The mgmtLink attribute in the <mgmtObj> Resource | Objlink | The OMA LwM2M Objlink data type describes the format of a reference to an Object Instance. The mgmtLink attribute in the <mgmtObj> Resource supports the hierarchy of <mgmtObj> Resource. |