public class JDOMetaDataPropertyImpl extends Support implements ExtendedJDOMetaData
CHECK_READ, CHECK_WRITE, MEDIATE_READ, MEDIATE_WRITE, SERIALIZABLEjavaLangCloneablePath, JDOExternalPath, JDOFlagsFieldName, JDOFlagsFieldSig, JDOFlagsFieldType, JDOInstanceCallbacksName, JDOInstanceCallbacksPath, JDOInstanceCallbacksSig, JDOInstanceCallbacksType, JDOPath, JDOPersistenceCapableName, JDOPersistenceCapablePath, JDOPersistenceCapableSig, JDOPersistenceCapableType, JDOPersistenceManagerName, JDOPersistenceManagerPath, JDOPersistenceManagerSig, JDOPersistenceManagerType, JDOSecondClassObjectBaseName, JDOSecondClassObjectBasePath, JDOSecondClassObjectBaseSig, JDOSecondClassObjectBaseType, JDOStateManagerFieldName, JDOStateManagerFieldSig, JDOStateManagerFieldType, JDOStateManagerName, JDOStateManagerPath, JDOStateManagerSig, JDOStateManagerType| Constructor and Description |
|---|
JDOMetaDataPropertyImpl(Properties properties)
Creates an instance.
|
JDOMetaDataPropertyImpl(Properties properties,
PrintWriter out)
Creates an instance.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getClassModifiers(String classname)
Gets the access modifier of a class.
|
int |
getFieldFlags(String classPath,
String fieldName)
Returns the field flags for a declared field of a class.
|
int[] |
getFieldFlags(String classPath,
String[] fieldNames)
Returns the field flags for some declared, managed fields of a class.
|
int |
getFieldModifiers(String classname,
String fieldname)
Gets the access modifier of a field.
|
int |
getFieldNo(String classPath,
String fieldName)
Returns the unique field index of a declared, persistent field of a
class.
|
int[] |
getFieldNo(String classPath,
String[] fieldNames)
Returns the unique field index of some declared, managed fields of a
class.
|
String |
getFieldType(String classname,
String fieldname)
Gets the type of a field.
|
String[] |
getFieldType(String classname,
String[] fieldnames)
Gets the type of some fields.
|
String |
getKeyClass(String classPath)
Returns the name of the key class of a class.
|
String[] |
getKeyFields(String classPath)
Returns an array of field names of all key fields of a class.
|
String[] |
getKnownClasses()
No interface method.
|
String[] |
getKnownFields(String classname)
Gets all known fields of a class.
|
String[] |
getManagedFields(String classname)
Returns an array of field names of all declared, persistent fields
of a class.
|
String |
getPersistenceCapableRootClass(String classPath)
Returns the name of the persistence-capable root class of a class.
|
String |
getPersistenceCapableSuperClass(String classPath)
Returns the name of the persistence-capable superclass of a class.
|
String |
getSuperClass(String classname)
Returns the superclass of a class.
|
String |
getSuperKeyClass(String classPath)
Returns the name of the key class of the next persistence-capable
superclass that defines one.
|
boolean |
isDefaultFetchGroupField(String classPath,
String fieldName)
Tests whether a field of a class is known to be part of the
Default Fetch Group.
|
boolean |
isKeyField(String classPath,
String fieldName)
Returns whether a field of a class is key.
|
boolean |
isKnownNonManagedField(String classPath,
String fieldName,
String fieldSig)
Returns whether a field of a class is known to be non-managed.
|
boolean |
isManagedField(String classPath,
String fieldName)
Returns whether a field of a class is transient transactional
or persistent.
|
boolean |
isMutableSecondClassObjectType(String classPath)
Tests whether a type is known for Mutable Second Class Objects.
|
boolean |
isPersistenceCapableClass(String classPath)
Tests whether a class is known to be persistence-capable.
|
boolean |
isPersistenceCapableRootClass(String classPath)
Tests whether a class is known as a persistence-capable root class.
|
boolean |
isPersistentField(String classPath,
String fieldName)
Tests whether a field of a class is known to be persistent.
|
boolean |
isPrimaryKeyField(String classPath,
String fieldName)
Tests whether a field of a class is known to be Primary Key.
|
boolean |
isSecondClassObjectType(String classPath)
Tests whether a type is known for Second Class Objects.
|
boolean |
isTransactionalField(String classPath,
String fieldName)
Tests whether a field of a class is known to be transactional.
|
boolean |
isTransientClass(String classPath)
Tests whether a class is known to be transient.
|
getI18N, getI18N, getI18N, getI18N, getI18N, getI18Npublic JDOMetaDataPropertyImpl(Properties properties, PrintWriter out) throws JDOMetaDataUserException, JDOMetaDataFatalError
public JDOMetaDataPropertyImpl(Properties properties) throws JDOMetaDataUserException, JDOMetaDataFatalError
public boolean isPersistenceCapableClass(String classPath) throws JDOMetaDataUserException, JDOMetaDataFatalError
isPersistenceCapableClass in interface JDOMetaDataclassPath - the JVM-qualified name of the classJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic boolean isTransientClass(String classPath) throws JDOMetaDataUserException, JDOMetaDataFatalError
JDOMetaDataThe following invariant holds: isTransientClass(classPath) => !isPersistenceCapableClass(classPath)
isTransientClass in interface JDOMetaDataclassPath - the JVM-qualified name of the classJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic boolean isPersistenceCapableRootClass(String classPath) throws JDOMetaDataUserException, JDOMetaDataFatalError
isPersistenceCapableRootClass in interface JDOMetaDataclassPath - the JVM-qualified name of the classJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic String getPersistenceCapableRootClass(String classPath) throws JDOMetaDataUserException, JDOMetaDataFatalError
getPersistenceCapableRootClass in interface JDOMetaDataclassPath - the JVM-qualified name of the classJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic final String getSuperClass(String classname)
getSuperClass in interface JDOMetaDataclassname - the JVM-qualified name of the classpublic boolean isSecondClassObjectType(String classPath) throws JDOMetaDataUserException, JDOMetaDataFatalError
isSecondClassObjectType in interface JDOMetaDataclassPath - the JVM-qualified name of the typeJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic boolean isMutableSecondClassObjectType(String classPath) throws JDOMetaDataUserException, JDOMetaDataFatalError
isMutableSecondClassObjectType in interface JDOMetaDataclassPath - the JVM-qualified name of the typeJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic boolean isPersistentField(String classPath, String fieldName) throws JDOMetaDataUserException, JDOMetaDataFatalError
isPersistentField in interface JDOMetaDataclassPath - the JVM-qualified name of the classfieldName - the name of the fieldJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic boolean isTransactionalField(String classPath, String fieldName) throws JDOMetaDataUserException, JDOMetaDataFatalError
isTransactionalField in interface JDOMetaDataclassPath - the JVM-qualified name of the classfieldName - the name of the fieldJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic boolean isPrimaryKeyField(String classPath, String fieldName) throws JDOMetaDataUserException, JDOMetaDataFatalError
isPrimaryKeyField in interface JDOMetaDataclassPath - the JVM-qualified name of the classfieldName - the name of the fieldJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic boolean isDefaultFetchGroupField(String classPath, String fieldName) throws JDOMetaDataUserException, JDOMetaDataFatalError
isDefaultFetchGroupField in interface JDOMetaDataclassPath - the JVM-qualified name of the classfieldName - the name of the fieldJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic int getFieldNo(String classPath, String fieldName) throws JDOMetaDataUserException, JDOMetaDataFatalError
getFieldNo in interface JDOMetaDataclassPath - the JVM-qualified name of the classfieldName - the name of the fieldJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic String[] getManagedFields(String classname)
getManagedFields in interface JDOMetaDataclassname - the JVM-qualified name of the classpublic final String[] getKnownClasses()
getKnownClasses in interface ExtendedJDOMetaDatapublic final String[] getKnownFields(String classname)
getKnownFields in interface ExtendedJDOMetaDataclassname - The classname.public final int getClassModifiers(String classname)
getClassModifiers in interface ExtendedJDOMetaDataclassname - The classname.Modifierpublic final int getFieldModifiers(String classname, String fieldname)
getFieldModifiers in interface ExtendedJDOMetaDataclassname - The classname.fieldname - The fieldname.Modifierpublic final String getFieldType(String classname, String fieldname)
ExtendedJDOMetaDatagetFieldType in interface ExtendedJDOMetaDataclassname - The classname.fieldname - The fieldname.public String getKeyClass(String classPath) throws JDOMetaDataUserException, JDOMetaDataFatalError
ExtendedJDOMetaDataThe following holds: (String s = getKeyClass(classPath)) != null ==> !isPersistenceCapableClass(s) && isPersistenceCapableClass(classPath)
getKeyClass in interface ExtendedJDOMetaDataclassPath - the non-null JVM-qualified name of the classJDOMetaDataUserExceptionJDOMetaDataFatalErrorJDOMetaData.isPersistenceCapableClass(String)public boolean isKeyField(String classPath, String fieldName) throws JDOMetaDataUserException, JDOMetaDataFatalError
ExtendedJDOMetaDataA key field must be persistent. The following holds: isKeyField(classPath, fieldName) ==> isPersistentField(classPath, fieldName) && !isDefaultFetchGroupField(classPath, fieldName)
This method requires the field having been declared by declareField().
isKeyField in interface ExtendedJDOMetaDataclassPath - the non-null JVM-qualified name of the classfieldName - the non-null name of the fieldJDOMetaDataUserExceptionJDOMetaDataFatalErrorJDOMetaData.isPersistentField(String, String)public boolean isKnownNonManagedField(String classPath, String fieldName, String fieldSig)
ExtendedJDOMetaDataThis method differs from isManagedField() in that a field may or may not be managed if its not known as non-managed. The following holds (not vice versa!): isKnownNonManagedField(classPath, fieldName) ==> !isManagedField(classPath, fieldName)
This method doesn't require the field having been declared by declareField().
isKnownNonManagedField in interface ExtendedJDOMetaDataclassPath - the non-null JVM-qualified name of the classfieldName - the non-null name of the fieldfieldSig - the non-null type signature of the fieldExtendedJDOMetaData.isManagedField(String, String)public boolean isManagedField(String classPath, String fieldName) throws JDOMetaDataUserException, JDOMetaDataFatalError
ExtendedJDOMetaDataA managed field must not be known as non-managed and must be either transient transactional or persistent. The following holds: isManagedField(classPath, fieldName) ==> !isKnownNonManagedField(classPath, fieldName) && (isPersistentField(classPath, fieldName) ^ isTransactionalField(classPath, fieldName))
This method requires the field having been declared by declareField().
isManagedField in interface ExtendedJDOMetaDataclassPath - the non-null JVM-qualified name of the classfieldName - the non-null name of the fieldJDOMetaDataUserExceptionJDOMetaDataFatalErrorExtendedJDOMetaData.isKnownNonManagedField(String, String, String),
JDOMetaData.isPersistentField(String, String),
JDOMetaData.isPersistenceCapableClass(String)public int getFieldFlags(String classPath, String fieldName) throws JDOMetaDataUserException, JDOMetaDataFatalError
ExtendedJDOMetaDataThe following holds for the field flags: int f = getFieldFlags(classPath, fieldName); !isManagedField(classPath, fieldName) ==> (f & CHECK_READ == 0) && (f & MEDIATE_READ == 0) && (f & CHECK_WRITE == 0) && (f & MEDIATE_WRITE == 0) isTransientField(classPath, fieldName) ==> (f & CHECK_READ == 0) && (f & MEDIATE_READ == 0) && (f & CHECK_WRITE != 0) && (f & MEDIATE_WRITE == 0) isKeyField(classPath, fieldName) ==> (f & CHECK_READ == 0) && (f & MEDIATE_READ == 0) && (f & CHECK_WRITE == 0) && (f & MEDIATE_WRITE != 0) isDefaultFetchGroupField(classPath, fieldName) ==> (f & CHECK_READ != 0) && (f & MEDIATE_READ != 0) && (f & CHECK_WRITE == 0) && (f & MEDIATE_WRITE == 0) isPersistentField(classPath, fieldName) && isKeyField(classPath, fieldName) && isDefaultFetchGroupField(classPath, fieldName) ==> (f & CHECK_READ == 0) && (f & MEDIATE_READ == 0) && (f & CHECK_WRITE != 0) && (f & MEDIATE_WRITE != 0)
This method requires the field having been declared by declareField().
getFieldFlags in interface ExtendedJDOMetaDataclassPath - the non-null JVM-qualified name of the classfieldName - the non-null name of the fieldJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic int[] getFieldFlags(String classPath, String[] fieldNames) throws JDOMetaDataUserException, JDOMetaDataFatalError
ExtendedJDOMetaDataThis method requires all fields having been declared by declareField().
getFieldFlags in interface ExtendedJDOMetaDataclassPath - the non-null JVM-qualified name of the classfieldNames - the non-null array of names of the declared fieldsJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic final String[] getFieldType(String classname, String[] fieldnames)
ExtendedJDOMetaDatagetFieldType in interface ExtendedJDOMetaDataclassname - The classname.fieldnames - The fieldnames.public int[] getFieldNo(String classPath, String[] fieldNames) throws JDOMetaDataUserException, JDOMetaDataFatalError
ExtendedJDOMetaDataThis method requires all fields having been declared by declareField().
getFieldNo in interface ExtendedJDOMetaDataclassPath - the non-null JVM-qualified name of the classfieldNames - the non-null array of names of the declared fieldsJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic String[] getKeyFields(String classPath) throws JDOMetaDataUserException, JDOMetaDataFatalError
ExtendedJDOMetaDataThis method requires all fields having been declared by declareField().
getKeyFields in interface ExtendedJDOMetaDataclassPath - the non-null JVM-qualified name of the classJDOMetaDataUserExceptionJDOMetaDataFatalErrorpublic String getPersistenceCapableSuperClass(String classPath) throws JDOMetaDataUserException, JDOMetaDataFatalError
ExtendedJDOMetaDataThe following holds: (String s = getPersistenceCapableSuperClass(classPath)) != null ==> isPersistenceCapableClass(classPath) && !isPersistenceCapableRootClass(classPath)
getPersistenceCapableSuperClass in interface ExtendedJDOMetaDataclassPath - the non-null JVM-qualified name of the classJDOMetaDataUserExceptionJDOMetaDataFatalErrorJDOMetaData.isPersistenceCapableClass(String),
JDOMetaData.getPersistenceCapableRootClass(String)public String getSuperKeyClass(String classPath) throws JDOMetaDataUserException, JDOMetaDataFatalError
ExtendedJDOMetaDataThe following holds: (String s = getSuperKeyClass(classPath)) != null ==> !isPersistenceCapableClass(s) && isPersistenceCapableClass(classPath) && !isPersistenceCapableRootClass(classPath)
getSuperKeyClass in interface ExtendedJDOMetaDataclassPath - the non-null JVM-qualified name of the classJDOMetaDataUserExceptionJDOMetaDataFatalErrorExtendedJDOMetaData.getKeyClass(String),
ExtendedJDOMetaData.getPersistenceCapableSuperClass(String)Copyright © 2013. All Rights Reserved.