org.openide.util.lookup
Class ArrayStorage.Transaction

java.lang.Object
  extended by java.util.AbstractCollection<E>
      extended by java.util.AbstractSet<E>
          extended by java.util.HashSet<AbstractLookup.Pair<?>>
              extended by org.openide.util.lookup.ArrayStorage.Transaction
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.lang.Iterable<AbstractLookup.Pair<?>>, java.util.Collection<AbstractLookup.Pair<?>>, java.util.Set<AbstractLookup.Pair<?>>
Enclosing class:
ArrayStorage

static final class ArrayStorage.Transaction
extends java.util.HashSet<AbstractLookup.Pair<?>>

HashSet with additional field for new array which is callocated in case we are doing replace to hold all new items.


Field Summary
 java.lang.Object[] arr
          array with new objects
 java.lang.Object[] current
          array with current objects
 
Constructor Summary
ArrayStorage.Transaction(int ensure, java.lang.Object currentContent)
           
 
Method Summary
 int addPair(AbstractLookup.Pair<?> p)
           
 java.lang.Object newContent(java.lang.Object prev)
           
 
Methods inherited from class java.util.HashSet
add, clear, clone, contains, isEmpty, iterator, remove, size
 
Methods inherited from class java.util.AbstractSet
equals, hashCode, removeAll
 
Methods inherited from class java.util.AbstractCollection
addAll, containsAll, retainAll, toArray, toArray, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.Set
addAll, containsAll, equals, hashCode, removeAll, retainAll, toArray, toArray
 

Field Detail

current

public final java.lang.Object[] current
array with current objects


arr

public final java.lang.Object[] arr
array with new objects

Constructor Detail

ArrayStorage.Transaction

public ArrayStorage.Transaction(int ensure,
                                java.lang.Object currentContent)
Method Detail

addPair

public int addPair(AbstractLookup.Pair<?> p)

newContent

public java.lang.Object newContent(java.lang.Object prev)