public class SimpleDateFormatParser extends DateFormatParser
SimpleDateFormat
,
Serialized FormConstructor and Description |
---|
SimpleDateFormatParser()
DefaultConstructor.
|
Modifier and Type | Method and Description |
---|---|
String |
getFormatString()
Returns the formatString for this SimpleDateFormat.
|
String |
getLocalizedFormatString()
Returns a localized formatString for this SimpleDateFormat.
|
SimpleDateFormat |
getSimpleDateFormat()
Returns the SimpleDateFormat object used in this parser.
|
Object |
getValue(ExpressionRuntime runtime,
ReportElement element)
Returns the formatted string.
|
boolean |
isKeepState()
Defines, whether the filter should keep its state, if a locale change is detected.
|
void |
setFormatString(String format)
defines the formatString for this SimpleDateFormat.
|
void |
setFormatter(Format format)
Sets the date format for the filter.
|
void |
setKeepState(boolean keepState)
Defines, whether the filter should keep its state, if a locale change is detected.
|
void |
setLocalizedFormatString(String format)
defines the localized formatString for this SimpleDateFormat.
|
void |
setSimpleDateFormat(SimpleDateFormat format)
Sets the date format for the parser.
|
getDateFormat, setDateFormat, setNullValue
clone, getDataSource, getFormatter, getNullValue, setDataSource
public SimpleDateFormat getSimpleDateFormat()
public void setSimpleDateFormat(SimpleDateFormat format)
format
- The format.NullPointerException
- if the format given is nullpublic void setFormatter(Format format)
setFormatter
in class DateFormatParser
format
- The format.NullPointerException
- if the format given is nullClassCastException
- if the format given is no DateFormatpublic String getFormatString()
SimpleDateFormat
public void setFormatString(String format)
format
- the formatStringIllegalArgumentException
- if the string is invalidpublic String getLocalizedFormatString()
SimpleDateFormat
public void setLocalizedFormatString(String format)
format
- the formatStringIllegalArgumentException
- if the string is invalidpublic boolean isKeepState()
public void setKeepState(boolean keepState)
keepState
- set to true, if the locale should not update the DateSymbols, false otherwise.public Object getValue(ExpressionRuntime runtime, ReportElement element)
getValue
in interface DataSource
getValue
in class DateFormatParser
runtime
- the expression runtime that is used to evaluate formulas and expressions when computing the value of this
filter.element
-