quinta-feira, 29 de agosto de 2013

Format of dates ISO 8601 translated to C#

Formatos ISO 8601 (inclui Atom)

    yyyy-MM-ddTHH:mm:ss.SSSZ
    yyyy-MM-ddTHH:mm:ss.SSS
    yyyy-MM-ddTHH:mm:ssZ
    yyyy-MM-ddTHH:mm:ss
    yyyy-MM-ddTHH:mmZ
    yyyy-MM-ddTHH:mm
    yyyy-MM-dd
    yyyy-MM
    yyyy

Translate to C#

    yyyy-MM-ddTHH:mm:ss.fffz
    yyyy-MM-ddTHH:mm:ss.fff
    yyyy-MM-ddTHH:mm:ssz
    yyyy-MM-ddTHH:mm:ss
    yyyy-MM-ddTHH:mmz
    yyyy-MM-ddTHH:mm
    yyyy-MM-dd
    yyyy-MM
    yyyy


yyyy
     The year shown in 4 digits. For example: 2008.
MM
     The month shown in 2 digits. For example, appear as of April 04. If the month is not given, the default is the first month of the year (01).
dd
     The day, shown in 2 digits. For example, appear as new day 09. If the day is not given, the default is the first day of the month (01).
T
     Designates the beginning of the time component of the representation date / time. If the time is not given, it defaults to 00:00:00.000.
HH
     The time shown in 2 digits. For example, 1 pm appear to 13. If the time is not provided, the default is 00.
mm
     The minutes, shown in 2 digits. For example, 15. If the minute is not provided, the default is 00.
ss
     The second, shown in 2 digits. For example, 49. If seconds are not provided, the default is 00.
SSS (for C# fff)
     Milliseconds, shown in 3 digits. For example, 555. If milliseconds are not provided, the default is 000.
Z (for C# z)
     The assignment for the time zone Zulu, which is the allocation and military aviation for GMT (Greenwich Mean Time).

     With ISO 8601, the time zone can also be expressed as moving to plus (+) or minus (-) from time Coordinated Universal Time (UTC) or GMT. For example: 2008-04-13T17 :25:55.123-08: 00. If the time zone is not provided, the default is the time zone in which the JVM is running MashupHub.

Nenhum comentário:

Postar um comentário