org.multiverse.transactional.collections
Interface TransactionalCollection<E>
- Type Parameters:
E -
- All Superinterfaces:
- Collection<E>, Iterable<E>
- All Known Subinterfaces:
- TransactionalDeque<E>, TransactionalList<E>, TransactionalQueue<E>, TransactionalSet<E>
- All Known Implementing Classes:
- AbstractTransactionalDeque, TransactionalArrayList, TransactionalLinkedList
public interface TransactionalCollection<E>
- extends Collection<E>
A Transactional version of the Collection interface.
- Author:
- Peter Veentjer.
- See Also:
Collection
size
int size()
- Specified by:
size in interface Collection<E>
atomicSize
int atomicSize()
- Returns the current size of the TransactionalCollection. The big difference between
the normal
size() method is that this one returns the actual size of
this map and doesn't look at the current transaction. So you could see changes
made by other threads.
- Returns:
- the current size of the TransactionalMap.
isEmpty
boolean isEmpty()
- Specified by:
isEmpty in interface Collection<E>
contains
boolean contains(Object o)
- Specified by:
contains in interface Collection<E>
iterator
Iterator<E> iterator()
- Specified by:
iterator in interface Collection<E>- Specified by:
iterator in interface Iterable<E>
toArray
Object[] toArray()
- Specified by:
toArray in interface Collection<E>
toArray
<T> T[] toArray(T[] a)
- Specified by:
toArray in interface Collection<E>
containsAll
boolean containsAll(Collection<?> c)
- Specified by:
containsAll in interface Collection<E>
toString
String toString()
- Overrides:
toString in class Object
equals
boolean equals(Object o)
- Specified by:
equals in interface Collection<E>- Overrides:
equals in class Object
hashCode
int hashCode()
- Specified by:
hashCode in interface Collection<E>- Overrides:
hashCode in class Object
add
boolean add(E e)
- Specified by:
add in interface Collection<E>
remove
boolean remove(Object o)
- Specified by:
remove in interface Collection<E>
addAll
boolean addAll(Collection<? extends E> c)
- Specified by:
addAll in interface Collection<E>
removeAll
boolean removeAll(Collection<?> c)
- Specified by:
removeAll in interface Collection<E>
retainAll
boolean retainAll(Collection<?> c)
- Specified by:
retainAll in interface Collection<E>
clear
void clear()
- Specified by:
clear in interface Collection<E>
Copyright © 2008-2010 Multiverse. All Rights Reserved.