01: package org.conform;
02:
03: /**
04: * Other standard formatters are appliead based on the property type.
05: */
06: public enum FormatType {
07: NONE(null),
08: /**
09: * String template with variable expansion.
10: */
11: TEMPLATE("template"),
12: /**
13: * Simply prints the size of a collection valued property.
14: */
15: COLLECTION_SIZE("collection-size"),
16: /**
17: * Formats the numerical value as a currency.
18: */
19: CURRENCY("currency"),
20:
21: /**
22: * Formats the numerical value as a percentage.
23: */
24: PERCENTAGE("percentage"),
25:
26: CUSTOM("custom");
27:
28: private final String value;
29:
30: FormatType(String value) {
31: this .value = value;
32: }
33:
34: public String getValue() {
35: return value;
36: }
37: }
|