|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectdsto.dfc.swing.text.selection.DateSelector
public class DateSelector
A basic selector for java.util.Date objects. Currently allows "*" or an ISO date (yyyy-mm-dd hh:mm:ss timezone or shortened versions of the same) as a selector. Multiple dates can OR'd with ",". Ranges (inclusive) can be specified using syntax like "date1 > date2".
Examples:
"*" "2001" "2001-01-02" "2001-01-02 10:14:01" (uses local timezone) "2001-01-02 10:14:01 UTC+9:30" "2001>2002,2004>2005"
IsoDateFormat,
Serialized Form| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface dsto.dfc.swing.text.selection.PatternSelector |
|---|
PatternSelector.SelectAllSelector |
| Field Summary | |
|---|---|
static ValueConverter |
CONVERTER
ValueConverter for this class: converts to/from String. |
protected long[] |
dateRanges
A set of time (Date.getTime ()) [lower, upper] pairs. |
protected String |
expression
|
| Fields inherited from interface dsto.dfc.swing.text.selection.PatternSelector |
|---|
SELECT_ALL |
| Constructor Summary | |
|---|---|
DateSelector()
Create a default "select all" selector. |
|
DateSelector(String expression)
Create an instance using an expression. |
|
| Method Summary | |
|---|---|
ValueConverter |
getConverter()
Return a converter that at least supports conversion to and from String. |
String |
getExpression()
|
boolean |
matches(Object value)
True if this pattern selector matches the given value. |
void |
setExpression(String expression)
Set the value of the pattern used to match against. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final ValueConverter CONVERTER
protected String expression
protected transient long[] dateRanges
| Constructor Detail |
|---|
public DateSelector()
public DateSelector(String expression)
throws IllegalArgumentException
IllegalArgumentException| Method Detail |
|---|
public boolean matches(Object value)
PatternSelector
matches in interface PatternSelectormatches in interface Selector
public void setExpression(String expression)
throws IllegalArgumentException
PatternSelector
setExpression in interface PatternSelectorexpression - String value
IllegalArgumentExceptionpublic String getExpression()
getExpression in interface PatternSelectorpublic ValueConverter getConverter()
PatternSelector
getConverter in interface ConvertablegetConverter in interface PatternSelectorpublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||