private static class FastDateFormat.TimeZoneNumberRule extends java.lang.Object implements FastDateFormat.Rule
Inner class to output a time zone as a number +/-HHMM
or +/-HH:MM
.
Modifier and Type | Field and Description |
---|---|
(package private) static FastDateFormat.TimeZoneNumberRule |
INSTANCE_COLON |
(package private) static FastDateFormat.TimeZoneNumberRule |
INSTANCE_NO_COLON |
(package private) boolean |
mColon |
Constructor and Description |
---|
TimeZoneNumberRule(boolean colon)
Constructs an instance of
TimeZoneNumberRule with the specified properties. |
Modifier and Type | Method and Description |
---|---|
void |
appendTo(java.lang.StringBuffer buffer,
java.util.Calendar calendar)
Appends the value of the specified calendar to the output buffer based on the rule implementation.
|
int |
estimateLength()
Returns the estimated lentgh of the result.
|
static final FastDateFormat.TimeZoneNumberRule INSTANCE_COLON
static final FastDateFormat.TimeZoneNumberRule INSTANCE_NO_COLON
final boolean mColon
TimeZoneNumberRule(boolean colon)
TimeZoneNumberRule
with the specified properties.colon
- add colon between HH and MM in the output if true
public int estimateLength()
estimateLength
in interface FastDateFormat.Rule
public void appendTo(java.lang.StringBuffer buffer, java.util.Calendar calendar)
appendTo
in interface FastDateFormat.Rule
buffer
- the output buffercalendar
- calendar to be appended