org.objectweb.speedo.runtime.genclass.collection
Class CollectionImpl
org.objectweb.speedo.runtime.genclass.GenClass
|
+--org.objectweb.speedo.runtime.genclass.collection.CollectionImpl
- All Implemented Interfaces:
- java.util.Collection, SpeedoAccessor, SpeedoGenClassProxy, SpeedoProxy
- Direct Known Subclasses:
- SetImpl
- public class CollectionImpl
- extends GenClass
- implements java.util.Collection
This class is an implementation of the java.util.Collection interface.
- Author:
- Eric.Bruneton, S.Chassande-Barrioz
Field Summary |
protected java.util.Collection |
collection
is the internal collection used when the generic class is not persistent |
Fields inherited from class org.objectweb.speedo.runtime.genclass.GenClass |
accessor, accessors, age, fixCount, inner, jdoIsActive, jdoStatus, linkedField, logger, mapperName, pbinding, pmf, pms, pnameHints, projectName, ptype, tpm, tx |
Constructor Summary |
CollectionImpl()
Instantiates a new collection. |
CollectionImpl(java.util.Collection collection,
org.objectweb.jorm.type.api.PType ptype,
java.lang.String linkedField,
org.objectweb.jorm.naming.api.PName linkedPName,
java.lang.String mapperName)
|
CollectionImpl(int size)
Instanciates and initializes a new collection with an initial size. |
CollectionImpl(org.objectweb.jorm.type.api.PType ptype,
java.lang.String linkedField,
org.objectweb.jorm.naming.api.PName linkedPName,
java.lang.String mapperName)
|
Methods inherited from class org.objectweb.speedo.runtime.genclass.GenClass |
bind, elementIsReference, exist, export, export, fixCe, getCeAge, getCeFixCount, getCeIdentifier, getCeObject, getJormConfig, getLogger, getLoggerFactory, getMemoryInstance, getPClassMapping, getPName, getSpeedoAccessor, getSpeedoAccessors, getStatus, init, jdoChangeStatus, jdoCopyFields, jdoCopyKeyFieldsFromObjectId, jdoCopyKeyFieldsToObjectId, jdoCopyKeyFieldsToObjectId, jdoDeletePersistent, jdoGePNameHints, jdoGetGenClassId, jdoGetJdoFileName, jdoGetMapperName, jdoGetObjectId, jdoGetPersistenceManager, jdoGetPersistenceManagerFactory, jdoGetPersistenceManagerSwitch, jdoGetProjectName, jdoGetPType, jdoGetSpeedoProxy, jdoGetStatus, jdoGetTransaction, jdoGetTransactionalObjectId, jdoGetTransactionalPersistenceManager, jdoIsActive, jdoIsActive, jdoIsContainerId, jdoIsDeleted, jdoIsDirty, jdoIsNew, jdoIsPersistent, jdoIsTransactional, jdoMakeDirty, jdoNewInstance, jdoNewInstance, jdoNewObjectIdInstance, jdoNewObjectIdInstance, jdoProvideField, jdoProvideFields, jdoReadIntention, jdoReplaceField, jdoReplaceFields, jdoReplaceFlags, jdoReplaceStateManager, jdoSetLinkedField, jdoSetMapperName, jdoSetPBinding, jdoSetPBinding, jdoSetPersistenceManagerFactory, jdoSetPersistenceManagerSwitch, jdoSetPNameHints, jdoSetPType, jdoSetSpeedoProxy, jdoSetStatus, jdoSetTransaction, jdoSetTransactionalPersistenceManager, jdoWriteIntention, read, read, removeSpeedoAccessor, setCeAge, setInner, setLogger, setLoggerFactory, setPName, setStatus, unbind, unexport, unfixCe, write |
Methods inherited from interface java.util.Collection |
hashCode |
collection
protected java.util.Collection collection
- is the internal collection used when the generic class is not persistent
CollectionImpl
public CollectionImpl()
- Instantiates a new collection.
CollectionImpl
public CollectionImpl(int size)
- Instanciates and initializes a new collection with an initial size.
CollectionImpl
public CollectionImpl(java.util.Collection collection,
org.objectweb.jorm.type.api.PType ptype,
java.lang.String linkedField,
org.objectweb.jorm.naming.api.PName linkedPName,
java.lang.String mapperName)
CollectionImpl
public CollectionImpl(org.objectweb.jorm.type.api.PType ptype,
java.lang.String linkedField,
org.objectweb.jorm.naming.api.PName linkedPName,
java.lang.String mapperName)
toString
public java.lang.String toString()
add
public boolean add(java.lang.Object o)
- Specified by:
add
in interface java.util.Collection
addAll
public boolean addAll(java.util.Collection c)
- Specified by:
addAll
in interface java.util.Collection
clear
public void clear()
- Specified by:
clear
in interface java.util.Collection
contains
public boolean contains(java.lang.Object o)
- Specified by:
contains
in interface java.util.Collection
containsAll
public boolean containsAll(java.util.Collection c)
- Specified by:
containsAll
in interface java.util.Collection
equals
public boolean equals(java.lang.Object o)
- Specified by:
equals
in interface java.util.Collection
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty
in interface java.util.Collection
iterator
public java.util.Iterator iterator()
- Specified by:
iterator
in interface java.util.Collection
remove
public boolean remove(java.lang.Object o)
- Specified by:
remove
in interface java.util.Collection
removeAll
public boolean removeAll(java.util.Collection c)
- Specified by:
removeAll
in interface java.util.Collection
retainAll
public boolean retainAll(java.util.Collection c)
- Specified by:
retainAll
in interface java.util.Collection
size
public int size()
- Specified by:
size
in interface java.util.Collection
toArray
public java.lang.Object[] toArray()
- Specified by:
toArray
in interface java.util.Collection
toArray
public java.lang.Object[] toArray(java.lang.Object[] a)
- Specified by:
toArray
in interface java.util.Collection
jdoLoadFieldsInAccessor
public void jdoLoadFieldsInAccessor(SpeedoAccessor sa)
- Description copied from interface:
SpeedoProxy
- Stores fields owned by this object into an accessor
- Overrides:
jdoLoadFieldsInAccessor
in class GenClass
- Following copied from interface:
org.objectweb.speedo.api.SpeedoProxy
- Parameters:
sa
- the accessor requiring persistent fields
jdoLoadFieldsFromAccessor
public void jdoLoadFieldsFromAccessor(SpeedoAccessor sa)
- Description copied from interface:
SpeedoProxy
- Stores fields owned by the accessor into the proxy
- Overrides:
jdoLoadFieldsFromAccessor
in class GenClass
- Following copied from interface:
org.objectweb.speedo.api.SpeedoProxy
- Parameters:
sa
- the accessor containing persistent fields
jdoMakePersistent
public void jdoMakePersistent(ProxyManager pm)
jdoMakePersistent
public void jdoMakePersistent(ProxyManager pm,
SpeedoProxy sp)
- Overrides:
jdoMakePersistent
in class GenClass
createAccessor
protected SpeedoAccessor createAccessor()
- Overrides:
createAccessor
in class GenClass
createCollection
protected java.util.Collection createCollection(int size)
createInstance
protected CollectionImpl createInstance(int size)
getGenClassElements
public java.util.Collection getGenClassElements(SpeedoAccessor sa)
- Overrides:
getGenClassElements
in class GenClass
setGCValue
public void setGCValue(java.lang.Object o)
- Overrides:
setGCValue
in class GenClass