|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectnet.sf.hibernate.collection.PersistentCollection
net.sf.hibernate.collection.ODMGCollection
net.sf.hibernate.collection.Set
A persistent wrapper for a java.util.Set. The underlying collection is a HashSet.
HashSet,
Serialized Form| Constructor Summary | |
Set()
|
|
Set(SessionImplementor session)
|
|
Set(SessionImplementor session,
Set set)
|
|
| Method Summary | |
boolean |
add(Object value)
|
boolean |
addAll(Collection coll)
|
void |
beforeInitialize(CollectionPersister persister)
Called before any elements are read into the collection, allowing appropriate initializations to occur. |
void |
beginRead()
Called just before reading any rows from the JDBC result set |
void |
clear()
|
boolean |
contains(Object o)
|
boolean |
containsAll(Collection coll)
|
org.odmg.DSet |
difference(org.odmg.DSet otherSet)
|
Serializable |
disassemble(CollectionPersister persister)
Disassemble the collection, ready for the cache |
boolean |
empty()
Is the initialized collection empty? |
boolean |
endRead()
Called after reading all rows from the JDBC result set |
Iterator |
entries()
Iterate all collection entries, during update of the database |
boolean |
entryExists(Object key,
int i)
Does an element exist at this entry in the collection? |
boolean |
equals(Object other)
|
boolean |
equalsSnapshot(Type elementType)
Does the current state exactly match the snapshot? |
Iterator |
getDeletes(Type elemType)
Get all the elements that need deleting |
Object |
getIndex(Object entry,
int i)
Get the index of the given collection entry |
Collection |
getOrphans(Serializable snapshot)
get all "orphaned" elements |
int |
hashCode()
|
void |
initializeFromCache(CollectionPersister persister,
Serializable disassembled,
Object owner)
Read the state of the collection from a disassembled cached value |
org.odmg.DSet |
intersection(org.odmg.DSet otherSet)
|
boolean |
isEmpty()
|
boolean |
isWrapper(Object collection)
Is this the wrapper for the given underlying collection instance? |
Iterator |
iterator()
|
boolean |
needsInserting(Object entry,
int i,
Type elemType)
Do we need to insert this element? |
boolean |
needsUpdating(Object entry,
int i,
Type elemType)
Do we need to update this element? |
boolean |
properSubsetOf(org.odmg.DSet otherSet)
|
boolean |
properSupersetOf(org.odmg.DSet otherSet)
|
Object |
readFrom(ResultSet rs,
CollectionPersister persister,
Object owner)
Read a row from the JDBC result set |
boolean |
remove(Object value)
|
boolean |
removeAll(Collection coll)
|
boolean |
retainAll(Collection coll)
|
int |
size()
|
protected Serializable |
snapshot(CollectionPersister persister)
Return a new snapshot of the current state |
boolean |
subsetOf(org.odmg.DSet otherSet)
|
boolean |
supersetOf(org.odmg.DSet otherSet)
|
Object[] |
toArray()
|
Object[] |
toArray(Object[] array)
|
String |
toString()
|
org.odmg.DSet |
union(org.odmg.DSet otherSet)
|
void |
writeTo(PreparedStatement st,
CollectionPersister persister,
Object entry,
int i,
boolean writeOrder)
Write a row to the JDBC prepared statement |
| Methods inherited from class net.sf.hibernate.collection.ODMGCollection |
existsElement, query, select, selectElement |
| Methods inherited from class net.sf.hibernate.collection.PersistentCollection |
afterRowInsert, delayedAddAll, forceInitialization, getCollectionSnapshot, getOrphans, getSession, getSnapshot, getSnapshot, getValue, hasQueuedAdditions, initialize, isDirectlyAccessible, needsRecreate, postFlush, preInsert, queueAdd, queueAddAll, queuedAdditionIterator, read, setCollectionSnapshot, setCurrentSession, setDirectlyAccessible, setInitialized, unsetSession, wasInitialized, write |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.odmg.DCollection |
existsElement, query, select, selectElement |
| Constructor Detail |
public Set(SessionImplementor session)
public Set()
public Set(SessionImplementor session,
Set set)
| Method Detail |
protected Serializable snapshot(CollectionPersister persister)
throws HibernateException
PersistentCollection
snapshot in class PersistentCollectionHibernateException
public Collection getOrphans(Serializable snapshot)
throws HibernateException
PersistentCollection
getOrphans in class PersistentCollectionHibernateException
public boolean equalsSnapshot(Type elementType)
throws HibernateException
PersistentCollection
equalsSnapshot in class PersistentCollectionHibernateExceptionpublic void beforeInitialize(CollectionPersister persister)
PersistentCollection
beforeInitialize in class PersistentCollection
public void initializeFromCache(CollectionPersister persister,
Serializable disassembled,
Object owner)
throws HibernateException
PersistentCollection
initializeFromCache in class PersistentCollectionHibernateExceptionpublic boolean empty()
PersistentCollection
empty in class PersistentCollectionpublic int size()
size in interface SetSet.size()public boolean isEmpty()
isEmpty in interface SetSet.isEmpty()public boolean contains(Object o)
contains in interface SetSet.contains(Object)public Iterator iterator()
iterator in interface SetSet.iterator()public Object[] toArray()
toArray in interface SetSet.toArray()public Object[] toArray(Object[] array)
toArray in interface SetSet.toArray(Object[])public boolean add(Object value)
add in interface SetSet.add(Object)public boolean remove(Object value)
remove in interface SetSet.remove(Object)public boolean containsAll(Collection coll)
containsAll in interface SetSet.containsAll(Collection)public boolean addAll(Collection coll)
addAll in interface SetSet.addAll(Collection)public boolean retainAll(Collection coll)
retainAll in interface SetSet.retainAll(Collection)public boolean removeAll(Collection coll)
removeAll in interface SetSet.removeAll(Collection)public void clear()
clear in interface SetSet.clear()public String toString()
public void writeTo(PreparedStatement st,
CollectionPersister persister,
Object entry,
int i,
boolean writeOrder)
throws HibernateException,
SQLException
PersistentCollection
writeTo in class PersistentCollectionHibernateException
SQLExceptionPersistentCollection.writeTo(PreparedStatement, CollectionPersister, Object, int, boolean)
public Object readFrom(ResultSet rs,
CollectionPersister persister,
Object owner)
throws HibernateException,
SQLException
PersistentCollection
readFrom in class PersistentCollectionHibernateException
SQLExceptionPersistentCollection.readFrom(ResultSet, CollectionPersister, Object)public void beginRead()
PersistentCollection
beginRead in class PersistentCollectionpublic boolean endRead()
PersistentCollection
endRead in class PersistentCollectionpublic Iterator entries()
PersistentCollection
entries in class PersistentCollectionPersistentCollection.entries()
public Serializable disassemble(CollectionPersister persister)
throws HibernateException
PersistentCollection
disassemble in class PersistentCollectionHibernateException
public Iterator getDeletes(Type elemType)
throws HibernateException
PersistentCollection
getDeletes in class PersistentCollectionHibernateException
public boolean needsInserting(Object entry,
int i,
Type elemType)
throws HibernateException
PersistentCollection
needsInserting in class PersistentCollectionHibernateException
public boolean needsUpdating(Object entry,
int i,
Type elemType)
PersistentCollection
needsUpdating in class PersistentCollection
public Object getIndex(Object entry,
int i)
PersistentCollection
getIndex in class PersistentCollectionpublic org.odmg.DSet union(org.odmg.DSet otherSet)
union in interface org.odmg.DSetDSet.union(DSet)public org.odmg.DSet difference(org.odmg.DSet otherSet)
difference in interface org.odmg.DSetDSet.difference(DSet)public org.odmg.DSet intersection(org.odmg.DSet otherSet)
intersection in interface org.odmg.DSetDSet.intersection(DSet)public boolean properSubsetOf(org.odmg.DSet otherSet)
properSubsetOf in interface org.odmg.DSetDSet.properSubsetOf(DSet)public boolean properSupersetOf(org.odmg.DSet otherSet)
properSupersetOf in interface org.odmg.DSetDSet.properSupersetOf(DSet)public boolean subsetOf(org.odmg.DSet otherSet)
subsetOf in interface org.odmg.DSetDSet.subsetOf(DSet)public boolean supersetOf(org.odmg.DSet otherSet)
supersetOf in interface org.odmg.DSetDSet.supersetOf(DSet)public boolean equals(Object other)
equals in interface Setpublic int hashCode()
hashCode in interface Set
public boolean entryExists(Object key,
int i)
PersistentCollection
entryExists in class PersistentCollectionPersistentCollection.entryExists(java.lang.Object, int)public boolean isWrapper(Object collection)
PersistentCollection
isWrapper in class PersistentCollection
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||