Package org.nuiton.eugene.java
Enum BeanTransformerTagValues.Store
- java.lang.Object
-
- java.lang.Enum<BeanTransformerTagValues.Store>
-
- org.nuiton.eugene.java.BeanTransformerTagValues.Store
-
- All Implemented Interfaces:
Serializable
,Comparable<BeanTransformerTagValues.Store>
,org.nuiton.eugene.models.extension.tagvalue.TagValueMetadata
- Enclosing class:
- BeanTransformerTagValues
public static enum BeanTransformerTagValues.Store extends Enum<BeanTransformerTagValues.Store> implements org.nuiton.eugene.models.extension.tagvalue.TagValueMetadata
-
-
Enum Constant Summary
Enum Constants Enum Constant Description classNamePrefix
To add a prefix on the name of each generated bean class.classNameSuffix
To add a prefix on the name of each generated bean class.generateHelper
To generate a utility class around the bean. this classe offers functions, predicates, copy methods, ...generateHelperConstructors
To generate or not constructors methods on Default classes.generateHelperFunctions
To generate or not guava functions on each property of the bean.generateHelperPredicates
To generate or not guava predicates on each property of the bean.generateNotEmptyCollections
Tag value to generate lazy instantiation of any collection to avoid NPEs.generatePropertyChangeSupport
Tag value to generate property change support on generated beans.helperClassNamePrefix
To add a prefix on the name of each generated bean class.helperClassNameSuffix
To add a suffix on the name of each generated bean class.helperSuperClass
Tag value to use a super super-class for generated defaults class of a simple bean.superClass
Tag value to use a super class for generated bean.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getDefaultValue()
String
getDescription()
Class<org.nuiton.eugene.models.extension.tagvalue.matcher.EqualsTagValueNameMatcher>
getMatcherClass()
String
getName()
Set<Class<?>>
getTargets()
Class<?>
getType()
boolean
isDeprecated()
static BeanTransformerTagValues.Store
valueOf(String name)
Returns the enum constant of this type with the specified name.static BeanTransformerTagValues.Store[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
generateHelper
public static final BeanTransformerTagValues.Store generateHelper
To generate a utility class around the bean. this classe offers functions, predicates, copy methods, ... You must use it on the complete model.
-
generateHelperPredicates
public static final BeanTransformerTagValues.Store generateHelperPredicates
To generate or not guava predicates on each property of the bean. You can globally use it on the complete model or to a specific classifier.
-
generateHelperFunctions
public static final BeanTransformerTagValues.Store generateHelperFunctions
To generate or not guava functions on each property of the bean. You can globally use it on the complete model or to a specific classifier.
-
generateHelperConstructors
public static final BeanTransformerTagValues.Store generateHelperConstructors
To generate or not constructors methods on Default classes. You can globally use it on the complete model, package or on a specific classifier.- Since:
- 3.0
- See Also:
}
-
generatePropertyChangeSupport
public static final BeanTransformerTagValues.Store generatePropertyChangeSupport
Tag value to generate property change support on generated beans. You can globally use it on the complete model, on packages, or to a specific classifier.
-
generateNotEmptyCollections
public static final BeanTransformerTagValues.Store generateNotEmptyCollections
Tag value to generate lazy instantiation of any collection to avoid NPEs. You can globally use it on the complete model or a package, or to a specific classifier.
-
superClass
public static final BeanTransformerTagValues.Store superClass
Tag value to use a super class for generated bean. If the bean needs Property change support (says you use the tag-valuegeneratePropertyChangeSupport
, then your class must provide everything for it. More over, if you use some collections in your bean you must also define two method namedgetChild(Collection list, int index)
andgetChild(List list, int index)
See new code to know minimum stuff to add in your class for this purpose.public abstract class BeanSupport implements Serializable { private static final long serialVersionUID = 1L; protected final PropertyChangeSupport pcs = new PropertyChangeSupport(this); public void addPropertyChangeListener(PropertyChangeListener listener) { pcs.addPropertyChangeListener(listener); } public void addPropertyChangeListener(String propertyName, PropertyChangeListener listener) { pcs.addPropertyChangeListener(propertyName, listener); } public void removePropertyChangeListener(PropertyChangeListener listener) { pcs.removePropertyChangeListener(listener); } public void removePropertyChangeListener(String propertyName, PropertyChangeListener listener) { pcs.removePropertyChangeListener(propertyName, listener); } protected void firePropertyChange(String propertyName, Object oldValue, Object newValue) { pcs.firePropertyChange(propertyName, oldValue, newValue); } protected void firePropertyChange(String propertyName, Object newValue) { firePropertyChange(propertyName, null, newValue); } protected <T> T getChild(Collection<T> list, int index) { return CollectionUtil.getOrNull(list, index); } protected <T> T getChild(List<T> list, int index) { return CollectionUtil.getOrNull(list, index); } }
You can globally use it on the complete model or to a specific classifier.
-
helperSuperClass
public static final BeanTransformerTagValues.Store helperSuperClass
Tag value to use a super super-class for generated defaults class of a simple bean. You can globally use it on the complete model or to a specific classifier.
-
classNamePrefix
public static final BeanTransformerTagValues.Store classNamePrefix
To add a prefix on the name of each generated bean class. You can globally use it on the complete model or to a specific classifier.
-
classNameSuffix
public static final BeanTransformerTagValues.Store classNameSuffix
To add a prefix on the name of each generated bean class. You can globally use it on the complete model or to a specific classifier.
-
helperClassNamePrefix
public static final BeanTransformerTagValues.Store helperClassNamePrefix
To add a prefix on the name of each generated bean class. You can globally use it on the complete model or to a specific classifier.
-
helperClassNameSuffix
public static final BeanTransformerTagValues.Store helperClassNameSuffix
To add a suffix on the name of each generated bean class. You can globally use it on the complete model or to a specific classifier.
-
-
Method Detail
-
values
public static BeanTransformerTagValues.Store[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (BeanTransformerTagValues.Store c : BeanTransformerTagValues.Store.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static BeanTransformerTagValues.Store valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
getName
public String getName()
- Specified by:
getName
in interfaceorg.nuiton.eugene.models.extension.tagvalue.TagValueMetadata
-
getTargets
public Set<Class<?>> getTargets()
- Specified by:
getTargets
in interfaceorg.nuiton.eugene.models.extension.tagvalue.TagValueMetadata
-
getType
public Class<?> getType()
- Specified by:
getType
in interfaceorg.nuiton.eugene.models.extension.tagvalue.TagValueMetadata
-
getMatcherClass
public Class<org.nuiton.eugene.models.extension.tagvalue.matcher.EqualsTagValueNameMatcher> getMatcherClass()
- Specified by:
getMatcherClass
in interfaceorg.nuiton.eugene.models.extension.tagvalue.TagValueMetadata
-
getDescription
public String getDescription()
- Specified by:
getDescription
in interfaceorg.nuiton.eugene.models.extension.tagvalue.TagValueMetadata
-
getDefaultValue
public String getDefaultValue()
- Specified by:
getDefaultValue
in interfaceorg.nuiton.eugene.models.extension.tagvalue.TagValueMetadata
-
isDeprecated
public boolean isDeprecated()
- Specified by:
isDeprecated
in interfaceorg.nuiton.eugene.models.extension.tagvalue.TagValueMetadata
-
-