Sun StorageTek 5800 System Client API Reference Manual

Canonical String Format

Each type in a 5800 system has a canonical representation as a string value. The canonical string representation of each type is shown in Table 4–1.

Table 4–1 Canonical String Representation of Data Types

Data Type  

Canonical String Representation  


The string itself. 


The string itself. 


Hexadecimal dump of the value with two hex digits per byte. 


Result of Long.toString. For example, 88991 or -7975432785.


Result of Double.toString. For example, 1.45 or NaN or -Infinity or -1.56E200.


YYYY-mm-dd. For example, 2001-01-01.


HH:mm:sss. For example, 12:02:01.


YYYY-mm-ddThh:mm:ss.fffZ (time relative to UTC). For example, 1969-12-31T23:59:59.999Z.


60-digit hexadecimal dump of the objectid.

This canonical string encoding is used in the following places:

The Canonical String Decode Operation

The inverse of the canonical string encoding is used in the following places:

Example 4–1 Virtual View Lookup Operation

If you take a value V and encode it into a string S, and then perform the canonical decode operation on S to get a new value V’. Does V always equal V’? The answer is yes in most cases, but not always.

What is actually guaranteed is the weaker statement that if encode(V) = S and if decode(S)=V’, then encode(V’) is also equal to S.