|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.exolab.castor.mapping.loader.ClassDescriptorImpl
public class ClassDescriptorImpl
The standard ClassDescriptor implementation, holding general OO information
about the class described.
Natures to augment this class with engine-specific knowledge
and functionality, using addNature(String) to register these views
with this class.
Once a Nature has been registered with this ClassDescriptor, the nature
can be applied to the ClassDescriptor and nature-specific properties
can be accessed in a type-safe way.
Nature,
addNature(String),
hasNature(String)| Constructor Summary | |
|---|---|
ClassDescriptorImpl()
|
|
| Method Summary | |
|---|---|
void |
addNature(String nature)
|
ClassDescriptor |
getDepends()
Returns the ClassDescriptor of the class which this class
depends upon. |
ClassDescriptor |
getExtends()
Returns the class descriptor of the class extended by this class. |
FieldDescriptor[] |
getFields()
Returns a list of fields represented by this descriptor. |
FieldDescriptor[] |
getIdentities()
Returns the FieldDescriptors that describe the identities as defined for this class. |
FieldDescriptor |
getIdentity()
Returns the first FieldDescriptor instance. |
Class<?> |
getJavaClass()
Returns the Java class represented by this descriptor. |
ClassMapping |
getMapping()
Returns the ClassMapping instance used. |
Object |
getProperty(String name)
|
boolean |
hasNature(String nature)
|
void |
setDepends(ClassDescriptor depends)
Sets the ClassDescriptor of the class which this class
depends upon. |
void |
setExtends(ClassDescriptor extend)
Sets the descriptor of the class which this class extends. |
void |
setFields(FieldDescriptor[] fields)
Sets the FieldDescriptors that describe the fields defined for this class. |
void |
setIdentities(FieldDescriptor[] identities)
Sets the FieldDescriptors that describe the identities as defined for this class. |
void |
setJavaClass(Class<?> javaClass)
Sets the Java Class as described by this descriptor. |
void |
setMapping(ClassMapping mapping)
Sets the ClassMapping instance. |
void |
setProperty(String name,
Object value)
|
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public ClassDescriptorImpl()
| Method Detail |
|---|
public void setMapping(ClassMapping mapping)
ClassMapping instance.
mapping - The ClassMapping instance to be used.public ClassMapping getMapping()
ClassMapping instance used.
ClassMapping instance used.public void setJavaClass(Class<?> javaClass)
Class as described by this descriptor.
javaClass - The Java Class instance as described by this descriptor.public Class<?> getJavaClass()
getJavaClass in interface ClassDescriptorClassDescriptor.getJavaClass()public void setExtends(ClassDescriptor extend)
extend - the descriptor of the class which this class extends.public ClassDescriptor getExtends()
getExtends in interface ClassDescriptorClassDescriptor.getExtends()public void setDepends(ClassDescriptor depends)
ClassDescriptor of the class which this class
depends upon.
depends - the ClassDescriptor of the class which this class
depends uponpublic ClassDescriptor getDepends()
ClassDescriptor of the class which this class
depends upon.
ClassDescriptor of the class which this class
depends upon.public void setFields(FieldDescriptor[] fields)
FieldDescriptors that describe the fields defined for this class.
fields - the FieldDescriptors that describe the fields defined for this class.public FieldDescriptor[] getFields()
getFields in interface ClassDescriptorClassDescriptor.getFields()public String toString()
toString in class ObjectObject.toString()public Object getProperty(String name)
getProperty in interface PropertyHoldername - of the property
getProperty(java.lang.String)
public void setProperty(String name,
Object value)
setProperty in interface PropertyHoldername - of the propertyvalue - of the propertysetProperty(java.lang.String, java.lang.Object)public void addNature(String nature)
addNature in interface NatureExtendablenature - ID of the NatureaddNature(java.lang.String)public boolean hasNature(String nature)
hasNature in interface NatureExtendablenature - ID of the Nature
hasNature(java.lang.String)public void setIdentities(FieldDescriptor[] identities)
FieldDescriptors that describe the identities as defined for this class.
identities - the FieldDescriptors that describe the identities as defined
for this class.public FieldDescriptor[] getIdentities()
FieldDescriptors that describe the identities as defined for this class.
FieldDescriptors that describe the identities as defined for this class.public FieldDescriptor getIdentity()
FieldDescriptor instance.
getIdentity in interface ClassDescriptorFieldDescriptor instance
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||