|
<< Click to Display Table of Contents >> Navigation: PAS - Softwareentwicklung > API Encoding - DataTypes |
The encoding is done under RFC3339. The fractional part of the seconds should be limited to 3 digits (milliseconds) and after all the transfer of data should always be done to UTC timezone (Z). The UI has then to present the information according to the needs of the user.
There is no binary transfer of this information - simply following the hint from RFC3339: "Human readability has proved to be a valuable feature of Internet protocols."
Date
According to RFC3339, a date information is defined by:
date-fullyear = 4DIGIT
date-month = 2DIGIT ; 01-12
date-mday = 2DIGIT ; 01-28, 01-29, 01-30, 01-31 based on month/year
full-date = date-fullyear "-" date-month "-" date-mday
According to RFC3339, a time information is defined by.
time-hour = 2DIGIT ; 00-23
time-minute = 2DIGIT ; 00-59
time-second = 2DIGIT ; 00-58, 00-59, 00-60 based on leap second rules
time-secfrac = "." 1*DIGIT
time-numoffset = ("+" / "-") time-hour ":" time-minute
time-offset = "Z" / time-numoffset
partial-time = time-hour ":" time-minute ":" time-second [time-secfrac]
full-time = partial-time time-offset
According to RFC3339, a full time and date is defined by:
date-time = full-date "T" full-time