public interface TopiaEntityEnum extends Serializable
TestDOAHelper.TestEntityEnum
enumeration generated.
The contract gives some informations about the classes for any entity dealed
by the dao helper. More precisely :
- contract class of the entity (this must be an interface class)
- the implementation fqn class of an entity (at generation time, we might
not have the implementation class)
- the implementation class (will be looked up at runtime execution, in that
way we make possible to used a different implementation at runtime.
- a method to accept any TopiaEntity class for this entity descriptionModifier and Type | Method and Description |
---|---|
boolean |
accept(Class<? extends TopiaEntity> klass)
Test if a given type of entity is matching the contract of this entity.
|
String |
dbSchemaName() |
String |
dbTableName() |
Class<? extends TopiaEntity> |
getContract() |
Class<? extends TopiaEntity> |
getImplementation()
Note : this is a lazy accessor.
|
String |
getImplementationFQN() |
String[] |
getNaturalIds() |
String[] |
getNotNulls() |
boolean |
isUseNaturalIds() |
boolean |
isUseNotNulls() |
String |
name()
This is a convinient method, as entity enum offers this
method from
Enum.name() . |
void |
setImplementationFQN(String implementationFQN)
Change the implementation class of the entity.
|
String name()
Enum.name()
.String dbSchemaName()
String dbTableName()
Class<? extends TopiaEntity> getContract()
Class<? extends TopiaEntity> getImplementation()
String getImplementationFQN()
String[] getNaturalIds()
String[] getNotNulls()
boolean isUseNaturalIds()
true
if entity use natural ids, false
otherwise.boolean isUseNotNulls()
true
if entity use some not-null properties,
false
otherwise.void setImplementationFQN(String implementationFQN)
implementationFQN
- the new fully qualifed name of the new
implementation class of the entity.boolean accept(Class<? extends TopiaEntity> klass)
EntityEnum.A.accept(Class<A>) -> true EntityEnum.A.accept(Class<B>) -> false EntityEnum.B.accept(Class<B>) -> true EntityEnum.B.accept(Class<A>) -> false
klass
- the type of an entity to test.true
if given type is dealed directly by this entity,
false
otherwise.Copyright © 2004–2022 Code Lutin. All rights reserved.