public class PersistentObjectSet extends RelationshipFault implements Set, ValueHolder, PersistentObjectCollection
Modifier and Type | Field and Description |
---|---|
protected Set |
addedToUnresolved |
protected Set |
objectSet |
protected Set |
removedFromUnresolved |
relationshipName, relationshipOwner
Constructor and Description |
---|
PersistentObjectSet(Persistent relationshipOwner,
String relationshipName) |
Modifier and Type | Method and Description |
---|---|
boolean |
add(Object o) |
boolean |
addAll(Collection c) |
void |
addDirectly(Object target)
Adds an object without triggering an event
|
void |
clear() |
boolean |
contains(Object o) |
boolean |
containsAll(Collection c) |
boolean |
equals(Object o) |
Object |
getValue()
Returns an object stored by this ValueHolder.
|
Object |
getValueDirectly()
Retrieves ValueHolder value without triggering fault resolution.
|
int |
hashCode() |
void |
invalidate()
Turns itself into a fault, thus forcing a refresh on the next access.
|
boolean |
isEmpty() |
boolean |
isFault()
Returns whether this list is not yet resolved and requires a fetch.
|
Iterator |
iterator() |
protected void |
mergeLocalChanges(List resolved) |
boolean |
remove(Object o) |
boolean |
removeAll(Collection c) |
void |
removeDirectly(Object target)
Removes an object without triggering an event
|
protected Set |
resolvedObjectSet()
Returns internal objects list resolving it if needed.
|
boolean |
retainAll(Collection c) |
void |
setObjectSet(Set objectSet) |
Object |
setValue(Object value)
Sets an object stored by this ValueHolder.
|
Object |
setValueDirectly(Object value)
Sets ValueHolder vaue without triggering fault resolution.
|
int |
size() |
Object[] |
toArray() |
Object[] |
toArray(Object[] a) |
String |
toString() |
getRelationshipName, getRelationshipOwner, isTransientParent, isUncommittedParent, resolveFromDB, updateReverse
protected Set objectSet
protected Set addedToUnresolved
protected Set removedFromUnresolved
public PersistentObjectSet(Persistent relationshipOwner, String relationshipName)
public boolean isFault()
isFault
in interface ValueHolder
public void invalidate()
invalidate
in interface ValueHolder
public Object setValueDirectly(Object value) throws CayenneRuntimeException
ValueHolder
setValueDirectly
in interface ValueHolder
CayenneRuntimeException
public Object getValue() throws CayenneRuntimeException
ValueHolder
getValue
in interface ValueHolder
CayenneRuntimeException
public Object getValueDirectly() throws CayenneRuntimeException
ValueHolder
getValueDirectly
in interface ValueHolder
CayenneRuntimeException
public Object setValue(Object value) throws CayenneRuntimeException
ValueHolder
setValue
in interface ValueHolder
value
- a new value of the ValueHolder.CayenneRuntimeException
public void setObjectSet(Set objectSet)
public boolean add(Object o)
add
in interface Collection
add
in interface Set
public boolean addAll(Collection c)
addAll
in interface Collection
addAll
in interface Set
public void clear()
clear
in interface Collection
clear
in interface Set
public boolean contains(Object o)
contains
in interface Collection
contains
in interface Set
public boolean containsAll(Collection c)
containsAll
in interface Collection
containsAll
in interface Set
public boolean equals(Object o)
public int hashCode()
public boolean isEmpty()
isEmpty
in interface Collection
isEmpty
in interface Set
public Iterator iterator()
public boolean remove(Object o)
remove
in interface Collection
remove
in interface Set
public boolean removeAll(Collection c)
removeAll
in interface Collection
removeAll
in interface Set
public boolean retainAll(Collection c)
retainAll
in interface Collection
retainAll
in interface Set
public int size()
size
in interface Collection
size
in interface Set
public Object[] toArray()
toArray
in interface Collection
toArray
in interface Set
public Object[] toArray(Object[] a)
toArray
in interface Collection
toArray
in interface Set
protected Set resolvedObjectSet()
protected void mergeLocalChanges(List resolved)
mergeLocalChanges
in class RelationshipFault
public void addDirectly(Object target)
PersistentObjectCollection
addDirectly
in interface PersistentObjectCollection
public void removeDirectly(Object target)
PersistentObjectCollection
removeDirectly
in interface PersistentObjectCollection
Copyright © 2001–2014 Apache Cayenne. All rights reserved.