Package com.db4o.collections
Class ActivatableHashSet<E>
- java.lang.Object
-
- java.util.AbstractCollection<E>
-
- java.util.AbstractSet<E>
-
- java.util.HashSet<E>
-
- com.db4o.collections.ActivatableHashSet<E>
-
- All Implemented Interfaces:
ActivatableCollection<E>
,ActivatableSet<E>
,Activatable
,java.io.Serializable
,java.lang.Cloneable
,java.lang.Iterable<E>
,java.util.Collection<E>
,java.util.Set<E>
public class ActivatableHashSet<E> extends java.util.HashSet<E> implements ActivatableSet<E>
extends ArrayList with Transparent Activation and Transparent Persistence support- Since:
- 7.9
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ActivatableHashSet()
ActivatableHashSet(int initialCapacity)
ActivatableHashSet(int initialCapacity, float loadFactor)
ActivatableHashSet(java.util.Collection<? extends E> coll)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
activate(ActivationPurpose purpose)
Should be called by every reading field access of an object.boolean
add(E o)
boolean
addAll(java.util.Collection<? extends E> c)
void
bind(Activator activator)
Called by db4o after the object instantiation.void
clear()
java.lang.Object
clone()
boolean
contains(java.lang.Object o)
boolean
containsAll(java.util.Collection<?> c)
boolean
equals(java.lang.Object o)
int
hashCode()
boolean
isEmpty()
java.util.Iterator<E>
iterator()
boolean
remove(java.lang.Object o)
boolean
removeAll(java.util.Collection<?> c)
boolean
retainAll(java.util.Collection<?> c)
int
size()
java.lang.Object[]
toArray()
<T> T[]
toArray(T[] a)
-
-
-
Constructor Detail
-
ActivatableHashSet
public ActivatableHashSet()
-
ActivatableHashSet
public ActivatableHashSet(int initialCapacity)
-
ActivatableHashSet
public ActivatableHashSet(int initialCapacity, float loadFactor)
-
ActivatableHashSet
public ActivatableHashSet(java.util.Collection<? extends E> coll)
-
-
Method Detail
-
activate
public void activate(ActivationPurpose purpose)
Description copied from interface:Activatable
Should be called by every reading field access of an object.
The recommended implementation of this method is to callActivator.activate(ActivationPurpose)
on theActivator
that was previously passed toActivatable.bind(Activator)
.- Specified by:
activate
in interfaceActivatable
- Parameters:
purpose
- Whereever this object is accessed to read or write. SeeActivationPurpose
-
bind
public void bind(Activator activator)
Description copied from interface:Activatable
Called by db4o after the object instantiation. This method is called to bind the object to the current activator
The recommended implementation of this method is to store the passedActivator
in a transient field of the object.- Specified by:
bind
in interfaceActivatable
- Parameters:
activator
- the Activator instance to bind
-
add
public boolean add(E o)
-
addAll
public boolean addAll(java.util.Collection<? extends E> c)
-
clear
public void clear()
-
contains
public boolean contains(java.lang.Object o)
-
containsAll
public boolean containsAll(java.util.Collection<?> c)
-
equals
public boolean equals(java.lang.Object o)
-
hashCode
public int hashCode()
-
isEmpty
public boolean isEmpty()
-
iterator
public java.util.Iterator<E> iterator()
-
remove
public boolean remove(java.lang.Object o)
-
removeAll
public boolean removeAll(java.util.Collection<?> c)
-
retainAll
public boolean retainAll(java.util.Collection<?> c)
-
size
public int size()
-
toArray
public java.lang.Object[] toArray()
-
toArray
public <T> T[] toArray(T[] a)
-
clone
public java.lang.Object clone()
- Overrides:
clone
in classjava.util.HashSet<E>
-
-