org.objectweb.jorm.metainfo.api
Interface Reference

All Superinterfaces:
MetaObject, java.io.Serializable, TypedElement
All Known Subinterfaces:
ClassRef, GenClassRef

public interface Reference
extends TypedElement

Reference interface is the top level of the Reference objects. The sub-classes are ClassRef and GenClassRef.

Author:
X. Spengler

Method Summary
 NameDef createNameDef()
          Creates a new NameDef object for the current reference class object.
 NameDef getNameDef(java.lang.String mappingName)
          Returns a NameDef object from a given mappingName.
 java.util.Iterator iterateNameDef()
          Returns an iterator on existing NameDef for the current object.
 
Methods inherited from interface org.objectweb.jorm.metainfo.api.TypedElement
getName, getType
 
Methods inherited from interface org.objectweb.jorm.metainfo.api.MetaObject
getParent, setParent
 

Method Detail

createNameDef

public NameDef createNameDef()
Creates a new NameDef object for the current reference class object. If this NameDef already exists for the current object, it is returned, in other case, a new NameDef object is created and returned.
Parameters:
nameDefName - the name of the nameDef read in the persistence description file
isSystem - true, the namedef is defined outside jorm, and false, the namedef is define inside jorm
Returns:
a new object used to describe the name projection for the current reference class, or an existing one if it already exists

iterateNameDef

public java.util.Iterator iterateNameDef()
Returns an iterator on existing NameDef for the current object. If no NameDef object is defined, an empty iterator is returned.
Returns:
an iterator on NameDef object

getNameDef

public NameDef getNameDef(java.lang.String mappingName)
Returns a NameDef object from a given mappingName. If the corresponding NameDef exists, it is returned, in other case, null is returned.
Parameters:
mappingName - the name of the mapping
Returns:
an existing namedef object if exists, either null