public class EnvironmentPropertyType extends EnumPropertyType<Environment>
dk.heick.properties.types.custom.enums.Environment. | Constructor Example | Comments | ||
|---|---|---|---|
Property<Environment> A_PROPERTY = |
No default value. | ||
Property<Environment> A_PROPERTY = |
Default value is "Environment.DEVELOPMENT". | ||
| Type of value(s) | Examples | Result | Comments |
| Valid | DEVELOPMENT | Environment.DEVELOPMENT | Validate successfully. |
| Valid | uat_2 | Environment.UAT_2 | Validate successfully. |
| Invalid | cow | null |
Validate will throw an exception. The resulting value is null. |
| Invalid | horse | null |
|
| Invalid | «empty string» | null |
|
| Invalid | «empty string after trim» | null |
|
| Invalid | null |
defaultValue OR null |
Validate will throw an exception. Return default value if set, otherwise null. |
Environment,
Serialized FormTYPE| Constructor and Description |
|---|
EnvironmentPropertyType()
Default constructor, with
null as default value. |
EnvironmentPropertyType(Environment defaultValue)
Constructor with default value.
|
getEnumClazz, getEnumConstants, getRestrictions, isAllLowercased, isAllUppercased, setEnumClazz, validateConstraints, validateValueequals, getDefaultValue, getDefaultValueAsString, getDefaultValueDescription, getDescription, getDescription, getInitializationPriority, getIo, getLogger, getTypeName, hasDefaultValue, isDefaultValueValid, postGetValueProcessing, setDefaultValue, setInitializationPriority, setIo, setTypedValue, setTypeName, toString, toType, validate, validateNullTypepublic EnvironmentPropertyType()
null as default value.public EnvironmentPropertyType(Environment defaultValue)
defaultValue - default value returned if property value is undefined.