public enum TimeSpanType extends Enum<TimeSpanType> implements com.alibaba.fastjson.serializer.JSONSerializable
| Enum Constant and Description |
|---|
CUSTOM |
FIXED |
LASTWEEK |
RELATIVE
Relative time span, e,g -1m-now.
|
THEDAYBEFOREYESTERDAY |
THISMONTH |
THISQUARTER |
THISWEEK |
TODAY |
TRUNCATED
Truncated time span.
|
YESTERDAY |
| Modifier and Type | Method and Description |
|---|---|
static TimeSpanType |
fromString(String value) |
String |
toString() |
static TimeSpanType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static TimeSpanType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
void |
write(com.alibaba.fastjson.serializer.JSONSerializer serializer,
Object fieldName,
Type fieldType,
int features) |
public static final TimeSpanType RELATIVE
public static final TimeSpanType TRUNCATED
public static final TimeSpanType TODAY
public static final TimeSpanType YESTERDAY
public static final TimeSpanType CUSTOM
public static final TimeSpanType FIXED
public static final TimeSpanType THEDAYBEFOREYESTERDAY
public static final TimeSpanType THISWEEK
public static final TimeSpanType LASTWEEK
public static final TimeSpanType THISMONTH
public static final TimeSpanType THISQUARTER
public static TimeSpanType[] values()
for (TimeSpanType c : TimeSpanType.values()) System.out.println(c);
public static TimeSpanType valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic String toString()
toString in class Enum<TimeSpanType>public static TimeSpanType fromString(String value)
Copyright © 2025. All Rights Reserved.