public enum NamingConvention extends Enum<NamingConvention>
| Enum Constant and Description |
|---|
DEFAULT_NAME
This means the item should use its default name e.g.
|
LOWER_UNDERSCORE
This means the item should use always lowercase with underscores separating words, for example firstName would become first_name, it will use this even
if there is a naming annotation or javadoc tag for it
|
LOWER_UNDERSCORE_UNLESS_OVERRIDDEN
This means the item should use lowercase with underscores separating words, for example firstName would become first_name unless there is a naming
annotation or javadoc tag for it
|
LOWERCASE
This means the item should always use lowercase even if there is a naming annotation or javadoc tag for it
|
LOWERCASE_UNLESS_OVERRIDDEN
This means the item should use lowercase unless there is a naming annotation or javadoc tag for it
|
UPPERCASE
This means the item should always use uppercase even if there is a naming annotation or javadoc tag for it
|
UPPERCASE_UNLESS_OVERRIDDEN
This means the item should use uppercase unless there is a naming annotation or javadoc tag for it
|
| Modifier and Type | Method and Description |
|---|---|
static NamingConvention |
forValue(String value,
NamingConvention defaultValue)
This gets a naming convention whose name matches the given string, if none matches it will return the given default value.
|
static String |
toLowerUnderscore(String value)
This converts a camel case type value into lower underscore form
|
static NamingConvention |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static NamingConvention[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final NamingConvention DEFAULT_NAME
public static final NamingConvention LOWERCASE_UNLESS_OVERRIDDEN
public static final NamingConvention UPPERCASE_UNLESS_OVERRIDDEN
public static final NamingConvention LOWER_UNDERSCORE_UNLESS_OVERRIDDEN
public static final NamingConvention LOWERCASE
public static final NamingConvention UPPERCASE
public static final NamingConvention LOWER_UNDERSCORE
public static NamingConvention[] values()
for (NamingConvention c : NamingConvention.values()) System.out.println(c);
public static NamingConvention valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant
with the specified nameNullPointerException - if the argument is nullpublic static final NamingConvention forValue(String value, NamingConvention defaultValue)
value - The value to matchdefaultValue - The default value if none matchesCopyright © 2015. All rights reserved.