public interface TemplateDateModel extends TemplateModel
Date
; a time-zone-independent date-only, time-only
or date-time value. Contrary to Java, FreeMarker distinguishes values that represent only a time, only a date, or a
combined date and time.Modifier and Type | Field and Description |
---|---|
static int |
DATE
The date model represents a date-only value.
|
static int |
DATETIME
The date model represents a date-time value.
|
static int |
TIME
The date model represents a time-only value.
|
static java.util.List |
TYPE_NAMES |
static int |
UNKNOWN
It is not known whether the date represents a time-only, a date-only, or a date-time value.
|
NOTHING
Modifier and Type | Method and Description |
---|---|
java.util.Date |
getAsDate()
Returns the date value.
|
int |
getDateType()
Returns the type of the date.
|
static final int UNKNOWN
static final int TIME
static final int DATE
static final int DATETIME
static final java.util.List TYPE_NAMES
java.util.Date getAsDate() throws TemplateModelException
null
.TemplateModelException
int getDateType()