Type IDateTimeFormat
Interface
--+
|
IFormat
--+
|
IDateTimeFormat
DateTime formatting and parsing interface. Here is a list of
possible characters and their meaning:
Symbol Meaning Presentation Example
G era designator (Text) AD
y year (Number) 1996
M month in year (Text and Number) July and 07
d day in month (Number) 10
h hour in am/pm (1-12) (Number) 12
H hour in day (0-23) (Number) 0
m minute in hour (Number) 30
s second in minute (Number) 55
S millisecond (Number) 978
E day in week (Text and Number) Tuesday
D day in year (Number) 189
F day of week in month (Number) 2 (2nd Wed in July)
w week in year (Number) 27
W week in month (Number) 2
a am/pm marker (Text) pm
k hour in day (1-24) (Number) 24
K hour in am/pm (0-11) (Number) 0
z time zone (Text) Pacific Standard Time
' escape for text
'' single quote '
Meaning of the amount of characters:
Text
Four or more, use full form, <4, use short or abbreviated form if it
exists. (for example, "EEEE" produces "Monday", "EEE" produces "Mon")
Number
The minimum number of digits. Shorter numbers are zero-padded to this
amount (for example, if "m" produces "6", "mm" produces "06"). Year is
handled specially; that is, if the count of 'y' is 2, the Year will be
truncated to 2 digits. (for example, if "yyyy" produces "1997", "yy"
produces "97".)
Text and Number
Three or over, use text, otherwise use number. (for example, "M"
produces "1", "MM" produces "01", "MMM" produces "Jan", and "MMMM"
produces "January".)
Class Variable Summary |
str |
calendar = "This object must implement ILocaleCalendar. ...
|
str |
format = 'Format an object to a string using the pattern...
|
str |
getPattern = 'Get the currently used pattern.'
|
str |
parse = 'Parse the text and convert it to an object, whi...
|
str |
setPattern = 'Overwrite the old formatting pattern with ...
|
calendar
-
- Type:
-
str
- Value:
"""This object must implement ILocaleCalendar. See
this interface's documentation for details\
."""
|
|
format
-
- Type:
-
str
- Value:
'Format an object to a string using the pattern as a rule.'
|
|
getPattern
-
- Type:
-
str
- Value:
'Get the currently used pattern.'
|
|
parse
-
- Type:
-
str
- Value:
'Parse the text and convert it to an object, which is returned.'
|
|
setPattern
-
- Type:
-
str
- Value:
'Overwrite the old formatting pattern with the new one.'
|
|