|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD | |||||||||
java.lang.Objectjava.lang.Enum<DateUtil.DatePartType>
net.sourceforge.annovalidator.util.DateUtil.DatePartType
public static enum DateUtil.DatePartType
Identifies part of a date, and identifies the format pattern required to parse that portion of the date.
| Nested Class Summary | |
|---|---|
static class |
DateUtil.DatePartType.UnrecognisedDatePartException
Exception indicating that a given value does not match any known date formatting pattern. |
| Enum Constant Summary | |
|---|---|
DAY
Date part is a day. |
|
HOUR
Date part is an hour. |
|
MINUTE
Date part is a minute. |
|
MONTH
Date part is a month. |
|
SECOND
Date part is a second. |
|
YEAR
Date part is a year. |
|
| Method Summary | |
|---|---|
java.lang.String |
determineFormatPatternForDatePart(java.lang.String value)
Returns the date formatting pattern that matches value
for the current DatePartType. |
java.lang.String[][] |
getValidSeperators()
|
static DateUtil.DatePartType |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. |
static DateUtil.DatePartType[] |
values()
Returns an array containing the constants of this enum type, in the order they're declared. |
| Methods inherited from class java.lang.Enum |
|---|
clone, compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Enum Constant Detail |
|---|
public static final DateUtil.DatePartType DAY
Supports the following formats:
public static final DateUtil.DatePartType MONTH
Supports the following formats:
public static final DateUtil.DatePartType YEAR
Supports the following formats:
public static final DateUtil.DatePartType HOUR
Supports the following formats:
public static final DateUtil.DatePartType MINUTE
Supports the following formats:
public static final DateUtil.DatePartType SECOND
Supports the following formats:
| Method Detail |
|---|
public static final DateUtil.DatePartType[] values()
for(DateUtil.DatePartType c : DateUtil.DatePartType.values())
System.out.println(c);
public static DateUtil.DatePartType valueOf(java.lang.String name)
name - the name of the enum constant to be returned.
java.lang.IllegalArgumentException - if this enum type has no constant
with the specified namepublic java.lang.String[][] getValidSeperators()
public java.lang.String determineFormatPatternForDatePart(java.lang.String value)
throws DateUtil.DatePartType.UnrecognisedDatePartException
value
for the current DatePartType.
value - The value to try and match.
DateUtil.DatePartType.UnrecognisedDatePartException - If no matching pattern can be found.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD | |||||||||