org.apache.openjpa.kernel
Class BrokerImpl.TransactionalCache

java.lang.Object
  extended by org.apache.openjpa.kernel.BrokerImpl.TransactionalCache
All Implemented Interfaces:
Serializable, Iterable, Collection, Set
Enclosing class:
BrokerImpl

static class BrokerImpl.TransactionalCache
extends Object
implements Set, Serializable

Transactional cache that holds soft refs to clean instances.


Constructor Summary
BrokerImpl.TransactionalCache(boolean orderDirty)
           
 
Method Summary
 boolean add(Object obj)
           
 boolean addAll(Collection coll)
           
 void addClean(StateManagerImpl sm)
          Add the given instance to the clean cache.
 void addDirty(StateManagerImpl sm)
          Add the given instance to the dirty cache.
 void clear()
           
 boolean contains(Object obj)
           
 boolean containsAll(Collection coll)
           
 Collection copy()
          Return a copy of all transactional state managers.
 Collection copyDirty()
          Return a copy of all dirty state managers.
 void flushed(StateManagerImpl sm)
          Transfer the given instance from the dirty cache to the clean cache.
 boolean isEmpty()
           
 Iterator iterator()
           
 boolean remove(Object obj)
           
 boolean remove(StateManagerImpl sm)
          Remove the given instance from the cache.
 boolean removeAll(Collection coll)
           
 boolean retainAll(Collection c)
           
 int size()
           
 Object[] toArray()
           
 Object[] toArray(Object[] arr)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Set
equals, hashCode
 

Constructor Detail

BrokerImpl.TransactionalCache

public BrokerImpl.TransactionalCache(boolean orderDirty)
Method Detail

copy

public Collection copy()
Return a copy of all transactional state managers.


copyDirty

public Collection copyDirty()
Return a copy of all dirty state managers.


flushed

public void flushed(StateManagerImpl sm)
Transfer the given instance from the dirty cache to the clean cache.


addClean

public void addClean(StateManagerImpl sm)
Add the given instance to the clean cache.


addDirty

public void addDirty(StateManagerImpl sm)
Add the given instance to the dirty cache.


remove

public boolean remove(StateManagerImpl sm)
Remove the given instance from the cache.


iterator

public Iterator iterator()
Specified by:
iterator in interface Iterable
Specified by:
iterator in interface Collection
Specified by:
iterator in interface Set

contains

public boolean contains(Object obj)
Specified by:
contains in interface Collection
Specified by:
contains in interface Set

containsAll

public boolean containsAll(Collection coll)
Specified by:
containsAll in interface Collection
Specified by:
containsAll in interface Set

clear

public void clear()
Specified by:
clear in interface Collection
Specified by:
clear in interface Set

isEmpty

public boolean isEmpty()
Specified by:
isEmpty in interface Collection
Specified by:
isEmpty in interface Set

size

public int size()
Specified by:
size in interface Collection
Specified by:
size in interface Set

add

public boolean add(Object obj)
Specified by:
add in interface Collection
Specified by:
add in interface Set

addAll

public boolean addAll(Collection coll)
Specified by:
addAll in interface Collection
Specified by:
addAll in interface Set

remove

public boolean remove(Object obj)
Specified by:
remove in interface Collection
Specified by:
remove in interface Set

removeAll

public boolean removeAll(Collection coll)
Specified by:
removeAll in interface Collection
Specified by:
removeAll in interface Set

retainAll

public boolean retainAll(Collection c)
Specified by:
retainAll in interface Collection
Specified by:
retainAll in interface Set

toArray

public Object[] toArray()
Specified by:
toArray in interface Collection
Specified by:
toArray in interface Set

toArray

public Object[] toArray(Object[] arr)
Specified by:
toArray in interface Collection
Specified by:
toArray in interface Set


Copyright © 2006-2012 Apache Software Foundation. All Rights Reserved.