Class FieldGroupElementImpl
- java.lang.Object
-
- com.sun.jdo.api.persistence.model.jdo.impl.PersistenceElementImpl
-
- com.sun.jdo.api.persistence.model.jdo.impl.PersistenceMemberElementImpl
-
- com.sun.jdo.api.persistence.model.jdo.impl.FieldGroupElementImpl
-
- All Implemented Interfaces:
FieldGroupElement.Impl,PersistenceElement.Impl,PersistenceElementProperties,PersistenceMemberElement.Impl
- Direct Known Subclasses:
ConcurrencyGroupElementImpl
public class FieldGroupElementImpl extends PersistenceMemberElementImpl implements FieldGroupElement.Impl
- Version:
- %I%
- Author:
- raccah
-
-
Field Summary
-
Fields inherited from interface com.sun.jdo.api.persistence.model.jdo.PersistenceElement.Impl
ADD, REMOVE, SET
-
Fields inherited from interface com.sun.jdo.api.persistence.model.jdo.PersistenceElementProperties
PROP_CARDINALITY, PROP_COLLECTION_CLASS, PROP_DELETE_ACTION, PROP_ELEMENT_CLASS, PROP_FIELDS, PROP_GROUPS, PROP_IDENTITY, PROP_INVERSE_FIELD, PROP_KEY_CLASS, PROP_KEY_FIELD, PROP_MODIFIED, PROP_NAME, PROP_PERSISTENCE, PROP_PREFETCH, PROP_SENSITIVITY, PROP_UPDATE_ACTION
-
-
Constructor Summary
Constructors Constructor Description FieldGroupElementImpl()Create new FieldGroupElementImpl with no corresponding name.FieldGroupElementImpl(String name)Creates new FieldGroupElementImpl with the corresponding name
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidchangeFields(PersistenceFieldElement[] fields, int action)Change the set of fields.PersistenceElementCollectiongetCollection()Returns the field collection of this field group element.PersistenceFieldElementgetField(String name)Find a field by name.PersistenceFieldElement[]getFields()Get all fields.voidsetCollection(PersistenceElementCollection collection)Set the field collection of this field group element to the supplied collection.-
Methods inherited from class com.sun.jdo.api.persistence.model.jdo.impl.PersistenceMemberElementImpl
firePropertyChange, fireVetoableChange
-
Methods inherited from class com.sun.jdo.api.persistence.model.jdo.impl.PersistenceElementImpl
addPropertyChangeListener, addVetoableChangeListener, attachToElement, getName, removePropertyChangeListener, removeVetoableChangeListener, setName
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.sun.jdo.api.persistence.model.jdo.PersistenceElement.Impl
addPropertyChangeListener, addVetoableChangeListener, attachToElement, getName, removePropertyChangeListener, removeVetoableChangeListener, setName
-
-
-
-
Constructor Detail
-
FieldGroupElementImpl
public FieldGroupElementImpl()
Create new FieldGroupElementImpl with no corresponding name. This constructor should only be used for cloning and archiving.
-
FieldGroupElementImpl
public FieldGroupElementImpl(String name)
Creates new FieldGroupElementImpl with the corresponding name- Parameters:
name- the name of the element
-
-
Method Detail
-
getField
public PersistenceFieldElement getField(String name)
Find a field by name.- Specified by:
getFieldin interfaceFieldGroupElement.Impl- Parameters:
name- the name to match- Returns:
- the field, or
nullif it does not exist
-
getFields
public PersistenceFieldElement[] getFields()
Get all fields.- Specified by:
getFieldsin interfaceFieldGroupElement.Impl- Returns:
- the fields
-
changeFields
public void changeFields(PersistenceFieldElement[] fields, int action) throws ModelException
Change the set of fields.- Specified by:
changeFieldsin interfaceFieldGroupElement.Impl- Parameters:
fields- the new fieldsaction-PersistenceElement.Impl.ADD,PersistenceElement.Impl.REMOVE, orPersistenceElement.Impl.SET- Throws:
ModelException- if impossible
-
getCollection
public PersistenceElementCollection getCollection()
Returns the field collection of this field group element. This method should only be used internally and for cloning and archiving.- Returns:
- the field collection of this field group element
-
setCollection
public void setCollection(PersistenceElementCollection collection)
Set the field collection of this field group element to the supplied collection. This method should only be used internally and for cloning and archiving.- Parameters:
collection- the field collection of this field group element
-
-