org.apache.tools.ant.types.resources.selectors
public class Date extends Object implements ResourceSelector
Since: Ant 1.7
Method Summary | |
---|---|
String | getDatetime()
Get the date & time in String format. |
long | getGranularity()
Get the timestamp granularity used by this ResourceSelector. |
long | getMillis()
Get the date/time in ms. |
String | getPattern()
Get the pattern for use with the datetime attribute. |
TimeComparison | getWhen()
Get the comparison mode. |
boolean | isSelected(Resource r)
Return true if this Resource is selected. |
void | setDateTime(String s)
Set the date and time as a String. |
void | setGranularity(long g)
Set the granularity to use for this ResourceSelector. |
void | setMillis(long m)
Set the date/time in milliseconds since 1970. |
void | setPattern(String p)
Set the optional pattern to use with the datetime attribute. |
void | setWhen(TimeComparison c)
Set the comparison mode. |
Returns: a String representing a date & time.
Returns: the long granularity.
Returns: long number of millis since 1970.
Returns: a SimpleDateFormat-compatible pattern string.
Returns: a TimeComparison object.
Parameters: r the Resource to check.
Returns: whether the Resource was selected.
Parameters: s the date & time to use.
Parameters: g the timestamp granularity.
Parameters: m the number of millis.
Parameters: p the SimpleDateFormat-compatible pattern string.
Parameters: c a TimeComparison object.