public static class JsonFormat.Value extends java.lang.Object implements JacksonAnnotationValue<JsonFormat>, java.io.Serializable
JsonFormat
annotation.Modifier and Type | Field and Description |
---|---|
private JsonFormat.Features |
_features |
private java.util.Locale |
_locale |
private java.lang.String |
_pattern |
private JsonFormat.Shape |
_shape |
private java.util.TimeZone |
_timezone |
private java.lang.String |
_timezoneStr |
private static JsonFormat.Value |
EMPTY |
private static long |
serialVersionUID |
Constructor and Description |
---|
Value() |
Value(JsonFormat ann) |
Value(java.lang.String p,
JsonFormat.Shape sh,
java.util.Locale l,
java.lang.String tzStr,
java.util.TimeZone tz)
Deprecated.
since 2.6
|
Value(java.lang.String p,
JsonFormat.Shape sh,
java.util.Locale l,
java.lang.String tzStr,
java.util.TimeZone tz,
JsonFormat.Features f) |
Value(java.lang.String p,
JsonFormat.Shape sh,
java.util.Locale l,
java.util.TimeZone tz)
Deprecated.
since 2.6
|
Value(java.lang.String p,
JsonFormat.Shape sh,
java.util.Locale l,
java.util.TimeZone tz,
JsonFormat.Features f) |
Value(java.lang.String p,
JsonFormat.Shape sh,
java.lang.String localeStr,
java.lang.String tzStr)
Deprecated.
since 2.6
|
Value(java.lang.String p,
JsonFormat.Shape sh,
java.lang.String localeStr,
java.lang.String tzStr,
JsonFormat.Features f) |
Modifier and Type | Method and Description |
---|---|
private static <T> boolean |
_equal(T value1,
T value2) |
static JsonFormat.Value |
empty() |
boolean |
equals(java.lang.Object o) |
static JsonFormat.Value |
forPattern(java.lang.String p) |
static JsonFormat.Value |
forShape(JsonFormat.Shape sh) |
static JsonFormat.Value |
from(JsonFormat ann) |
java.lang.Boolean |
getFeature(JsonFormat.Feature f)
Accessor for checking whether this format value has specific setting for
given feature.
|
java.util.Locale |
getLocale() |
java.lang.String |
getPattern() |
JsonFormat.Shape |
getShape() |
java.util.TimeZone |
getTimeZone() |
int |
hashCode() |
boolean |
hasLocale() |
boolean |
hasPattern() |
boolean |
hasShape() |
boolean |
hasTimeZone() |
java.lang.String |
timeZoneAsString()
Alternate access (compared to
getTimeZone() ) which is useful
when caller just wants time zone id to convert, but not as JDK
provided TimeZone |
java.lang.String |
toString() |
java.lang.Class<JsonFormat> |
valueFor()
Introspection method that may be used to find actual annotation that may be used
as the source for value instance.
|
JsonFormat.Value |
withFeature(JsonFormat.Feature f) |
JsonFormat.Value |
withLocale(java.util.Locale l) |
JsonFormat.Value |
withoutFeature(JsonFormat.Feature f) |
JsonFormat.Value |
withOverrides(JsonFormat.Value overrides) |
JsonFormat.Value |
withPattern(java.lang.String p) |
JsonFormat.Value |
withShape(JsonFormat.Shape s) |
JsonFormat.Value |
withTimeZone(java.util.TimeZone tz) |
private static final long serialVersionUID
private static final JsonFormat.Value EMPTY
private final java.lang.String _pattern
private final JsonFormat.Shape _shape
private final java.util.Locale _locale
private final java.lang.String _timezoneStr
private final JsonFormat.Features _features
private transient java.util.TimeZone _timezone
public Value()
public Value(JsonFormat ann)
public Value(java.lang.String p, JsonFormat.Shape sh, java.lang.String localeStr, java.lang.String tzStr, JsonFormat.Features f)
public Value(java.lang.String p, JsonFormat.Shape sh, java.util.Locale l, java.util.TimeZone tz, JsonFormat.Features f)
public Value(java.lang.String p, JsonFormat.Shape sh, java.util.Locale l, java.lang.String tzStr, java.util.TimeZone tz, JsonFormat.Features f)
@Deprecated public Value(java.lang.String p, JsonFormat.Shape sh, java.util.Locale l, java.util.TimeZone tz)
@Deprecated public Value(java.lang.String p, JsonFormat.Shape sh, java.lang.String localeStr, java.lang.String tzStr)
@Deprecated public Value(java.lang.String p, JsonFormat.Shape sh, java.util.Locale l, java.lang.String tzStr, java.util.TimeZone tz)
public static final JsonFormat.Value empty()
public static final JsonFormat.Value from(JsonFormat ann)
public final JsonFormat.Value withOverrides(JsonFormat.Value overrides)
public static JsonFormat.Value forPattern(java.lang.String p)
public static JsonFormat.Value forShape(JsonFormat.Shape sh)
public JsonFormat.Value withPattern(java.lang.String p)
public JsonFormat.Value withShape(JsonFormat.Shape s)
public JsonFormat.Value withLocale(java.util.Locale l)
public JsonFormat.Value withTimeZone(java.util.TimeZone tz)
public JsonFormat.Value withFeature(JsonFormat.Feature f)
public JsonFormat.Value withoutFeature(JsonFormat.Feature f)
public java.lang.Class<JsonFormat> valueFor()
JacksonAnnotationValue
valueFor
in interface JacksonAnnotationValue<JsonFormat>
public java.lang.String getPattern()
public JsonFormat.Shape getShape()
public java.util.Locale getLocale()
public java.lang.String timeZoneAsString()
getTimeZone()
) which is useful
when caller just wants time zone id to convert, but not as JDK
provided TimeZone
public java.util.TimeZone getTimeZone()
public boolean hasShape()
public boolean hasPattern()
public boolean hasLocale()
public boolean hasTimeZone()
public java.lang.Boolean getFeature(JsonFormat.Feature f)
Boolean.TRUE
or
Boolean.FALSE
, indicating 'yes/no/dunno' choices, where `null` ("dunno")
indicates that the default handling should be used based on global defaults,
and there is no format override.public java.lang.String toString()
toString
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
private static <T> boolean _equal(T value1, T value2)