|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.objectweb.speedo.metadata.SpeedoElement
org.objectweb.speedo.metadata.SpeedoClass
public class SpeedoClass
Describes a persistence capable class.
Field Summary | |
---|---|
static byte |
ALREADY_ENHANCED
The class has been previously enhanced and no additional operation is required. |
java.util.HashMap |
callBacks
Register some callback methods and their associated application method to which the callback is mapped. |
static byte |
ENHANCEMENT_FAILED
The enhancement of the class has failed. |
static byte |
ENHANCEMENT_REQUIRED
The enhancement is required. |
byte |
enhancementStatus
Specify the status of the persistent class with regards to the enhancement process. |
java.util.Map |
fetchGroups
Description of fetchgroups defined for this class. |
java.util.Map |
fields
Description of persistent capable fields of this class. |
SpeedoIdentity |
identity
Defines the identifier of the persistent class. |
SpeedoInheritance |
inheritance
Defines the inheritance strategy if this class inherits from a persistent class. |
boolean |
isAbstract
Indicates if the class is abstract. |
boolean |
isDetachable
Attribute detachable. |
boolean |
isInstanceCallbacks
Indicates if the class implements InstanceCallbacks |
boolean |
isSerializable
Indicates if the class implements Serailizable |
SpeedoJoin[] |
joinToExtTables
Is the join to reach external tables. |
org.objectweb.jorm.metainfo.api.Class |
jormclass
JORM meta object corresponding to this Speedo meta object. |
SpeedoTable |
mainTable
The main table of the persistent class. |
SpeedoPackage |
moPackage
Description of the package which contains this class. |
java.lang.String |
name
Class name. |
java.util.Map |
name2query
Contains the predefined query key = a query name value = the SpeedoPredefinedQuery instance |
java.lang.String |
nameForQuery
Class name for queries. |
static byte |
NO_NO_ARG_CONSTRUCTOR
The persistent class has no no-arg constructor. |
byte |
noArgConstructorStatus
Qualifies the status of the no-arg constructor of the persistent class. |
static byte |
NON_PUBLIC_NO_ARG_CONSTRUCTOR
The persistent class has no-arg constructor but it is not public |
static byte |
PUBLIC_NO_ARG_CONSTRUCTOR
The persistent class has a public no-arg constructor. |
SpeedoVersion |
version
Description of the version. |
SpeedoField |
versionField
Defines the field used for database optimitic locking policy. |
Fields inherited from class org.objectweb.speedo.metadata.SpeedoElement |
---|
jdoExtension, personality |
Constructor Summary | |
---|---|
SpeedoClass()
|
Method Summary | |
---|---|
void |
add(java.lang.Object field)
Adds a SpeedoField to the class. |
void |
add(java.lang.Object field,
boolean failsOnError,
org.objectweb.util.monolog.api.Logger logger)
Adds a SpeedoField to the class. |
void |
addFetchGroup(java.lang.Object fetchGroup)
Adds a SpeedoFetchGroup to the class. |
void |
addFetchGroup(java.lang.Object fetchGroup,
boolean failsOnError,
org.objectweb.util.monolog.api.Logger logger)
Adds a SpeedoFetchgroup to the class. |
void |
addJoin(SpeedoJoin j)
|
int |
computeFieldNumbers()
Computes the field numbers for the fields of this class. |
boolean |
containsJoin(SpeedoJoin join)
|
boolean |
enhancementFailed()
|
boolean |
generateObjectId()
|
SpeedoClass |
getAncestor()
|
SpeedoColumn |
getColumn(java.lang.String colname,
boolean mainonly)
Look for a column with a given name defined into the given SpeedoClass. |
SpeedoTable |
getExtTable(java.lang.String tableName,
boolean createifnone)
|
SpeedoField |
getField(java.lang.String fieldName)
Finds a field from its name. |
SpeedoField |
getFieldFromColumn(java.lang.String colname)
|
java.lang.String |
getFQName()
|
byte |
getIdentityType()
|
SpeedoField |
getInheritedField(java.lang.String name)
|
SpeedoJoin |
getJoin(java.lang.String tableName)
|
SpeedoJoin |
getJoin(java.lang.String tableName,
boolean createifnone)
|
int |
getJoinIndex(SpeedoJoin join)
|
java.lang.String |
getJormFileName()
|
java.lang.String |
getObjectidClass()
|
java.util.List |
getParents()
|
int |
getPkFieldCount()
|
java.util.List |
getPKFields()
|
java.lang.String |
getSourceDesc()
|
java.lang.String |
getSourceDescShort()
|
SpeedoClass |
getSpeedoClassFromContext(java.lang.String className)
|
SpeedoClass |
getSuper()
|
java.lang.String |
getSuperClassName()
|
java.util.List |
getTableIndexes()
|
SpeedoField |
getUniquePKField()
Find in the class or in its parent, the unique persistent field marked as primary key. |
java.lang.String |
getXMLFileName()
|
boolean |
isAlreadyEnhanced()
|
void |
removeJoin(SpeedoJoin j)
|
boolean |
requireEnhancement()
|
void |
setAlreadyEnhanced(boolean v)
|
void |
setDatastoreIdSequenceName(java.lang.String sequenceName)
|
void |
setIdentityType(byte identityType)
|
void |
setRequireEnhancement(boolean v)
|
void |
setSuperClassName(java.lang.String superClassName)
|
java.lang.String |
toString()
Transforms a SpeedoClass into a String. |
Methods inherited from class org.objectweb.speedo.metadata.SpeedoElement |
---|
addExtension, addInArray, getExtension, getExtensionByKey, getExtensionValueByKey, indexOfInArray, removeInArray, setValueInArray |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final byte ALREADY_ENHANCED
public static final byte ENHANCEMENT_REQUIRED
public static final byte ENHANCEMENT_FAILED
public static final byte NO_NO_ARG_CONSTRUCTOR
public static final byte NON_PUBLIC_NO_ARG_CONSTRUCTOR
public static final byte PUBLIC_NO_ARG_CONSTRUCTOR
public java.lang.String name
public java.lang.String nameForQuery
public SpeedoPackage moPackage
public SpeedoIdentity identity
public SpeedoField versionField
public SpeedoInheritance inheritance
public SpeedoVersion version
public boolean isDetachable
public java.util.Map fields
public java.util.Map fetchGroups
public boolean isAbstract
public boolean isInstanceCallbacks
public boolean isSerializable
public org.objectweb.jorm.metainfo.api.Class jormclass
public java.util.HashMap callBacks
SpeedoCallback
,
HomeItf.PRE_NEW
public byte enhancementStatus
ALREADY_ENHANCED
,
ENHANCEMENT_REQUIRED
,
ENHANCEMENT_FAILED
public java.util.Map name2query
SpeedoPredefinedQuery
public byte noArgConstructorStatus
NO_NO_ARG_CONSTRUCTOR
,
NON_PUBLIC_NO_ARG_CONSTRUCTOR
,
PUBLIC_NO_ARG_CONSTRUCTOR
public SpeedoTable mainTable
joinToExtTables
public SpeedoJoin[] joinToExtTables
Constructor Detail |
---|
public SpeedoClass()
Method Detail |
---|
public java.lang.String getObjectidClass()
public java.lang.String getFQName()
public java.lang.String toString()
toString
in class java.lang.Object
public boolean enhancementFailed()
public boolean isAlreadyEnhanced()
public void setAlreadyEnhanced(boolean v)
public boolean requireEnhancement()
public void setRequireEnhancement(boolean v)
public void add(java.lang.Object field)
field
- field to add.public void add(java.lang.Object field, boolean failsOnError, org.objectweb.util.monolog.api.Logger logger) throws SpeedoException
field
- field to add.failsOnError
- if an error must be thrown or creates a warning.logger
- logger for writting warn message if necessary.
SpeedoException
- if the field was already defined into the class.public void setDatastoreIdSequenceName(java.lang.String sequenceName)
public void addFetchGroup(java.lang.Object fetchGroup)
fetchGroup
- the fetchgroup to add.public void addFetchGroup(java.lang.Object fetchGroup, boolean failsOnError, org.objectweb.util.monolog.api.Logger logger) throws SpeedoException
fetchGroup
- the fetchgroup to add.failsOnError
- if an error must be thrown or creates a warning.logger
- logger for writting warn message if necessary.
SpeedoException
- if the field was already defined into the class.public int computeFieldNumbers()
public java.lang.String getJormFileName()
public boolean generateObjectId()
public int getPkFieldCount()
public java.util.List getPKFields()
public SpeedoField getUniquePKField() throws SpeedoException
SpeedoException
- if there are several persistent fields marked as primary key.public SpeedoClass getSpeedoClassFromContext(java.lang.String className)
public java.lang.String getXMLFileName()
public SpeedoClass getSuper()
public SpeedoField getInheritedField(java.lang.String name)
public SpeedoClass getAncestor()
public SpeedoField getField(java.lang.String fieldName)
fieldName
- is the name of a persistent field. the name can be fully
qualified (ie the field name is prefixed by the class name,
the separator is a dot or #)
public SpeedoField getFieldFromColumn(java.lang.String colname)
public void setIdentityType(byte identityType)
public byte getIdentityType()
public void setSuperClassName(java.lang.String superClassName) throws SpeedoException
SpeedoException
public java.lang.String getSuperClassName()
public void addJoin(SpeedoJoin j)
public void removeJoin(SpeedoJoin j)
public java.lang.String getSourceDesc()
public java.lang.String getSourceDescShort()
public SpeedoJoin getJoin(java.lang.String tableName)
public SpeedoJoin getJoin(java.lang.String tableName, boolean createifnone)
public int getJoinIndex(SpeedoJoin join)
public boolean containsJoin(SpeedoJoin join)
public SpeedoTable getExtTable(java.lang.String tableName, boolean createifnone)
public SpeedoColumn getColumn(java.lang.String colname, boolean mainonly)
colname
- The name of the column.mainonly
- Speficy if we must look only for main table columns.
public java.util.List getTableIndexes()
public java.util.List getParents()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |