de.lmu.ifi.dbs.elki.database.ids.generic
Class GenericArrayModifiableDBIDs

java.lang.Object
  extended by java.util.AbstractCollection<E>
      extended by java.util.AbstractList<E>
          extended by java.util.ArrayList<DBID>
              extended by de.lmu.ifi.dbs.elki.database.ids.generic.GenericArrayModifiableDBIDs
All Implemented Interfaces:
ArrayDBIDs, ArrayModifiableDBIDs, DBIDs, ModifiableDBIDs, Serializable, Cloneable, Iterable<DBID>, Collection<DBID>, List<DBID>, RandomAccess

public class GenericArrayModifiableDBIDs
extends ArrayList<DBID>
implements ArrayModifiableDBIDs

Array-oriented implementation of a modifiable DBID collection. This should only be instantiated by a DBIDFactory! Use DBIDUtil.newArray()!

See Also:
Serialized Form

Field Summary
private static long serialVersionUID
          Serial version
 
Fields inherited from class java.util.AbstractList
modCount
 
Constructor Summary
GenericArrayModifiableDBIDs()
          Constructor without extra hints
GenericArrayModifiableDBIDs(DBIDs c)
          Constructor from existing DBIDs.
GenericArrayModifiableDBIDs(int initialCapacity)
          Constructor with size hint.
 
Method Summary
 boolean addDBIDs(DBIDs ids)
          Add DBIDs to collection.
 Collection<DBID> asCollection()
          Retrieve collection access to the IDs
 boolean removeDBIDs(DBIDs ids)
          Remove DBIDs from collection.
 
Methods inherited from class java.util.ArrayList
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, get, indexOf, isEmpty, lastIndexOf, remove, remove, removeRange, set, size, toArray, toArray, trimToSize
 
Methods inherited from class java.util.AbstractList
equals, hashCode, iterator, listIterator, listIterator, subList
 
Methods inherited from class java.util.AbstractCollection
containsAll, removeAll, retainAll, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface de.lmu.ifi.dbs.elki.database.ids.DBIDs
contains, isEmpty, iterator, size
 
Methods inherited from interface java.util.List
add, add, addAll, addAll, clear, contains, containsAll, equals, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, size, subList, toArray, toArray
 

Field Detail

serialVersionUID

private static final long serialVersionUID
Serial version

See Also:
Constant Field Values
Constructor Detail

GenericArrayModifiableDBIDs

public GenericArrayModifiableDBIDs(int initialCapacity)
Constructor with size hint.

Parameters:
initialCapacity - Size hint

GenericArrayModifiableDBIDs

public GenericArrayModifiableDBIDs()
Constructor without extra hints


GenericArrayModifiableDBIDs

public GenericArrayModifiableDBIDs(DBIDs c)
Constructor from existing DBIDs.

Parameters:
c - Existing DBIDs.
Method Detail

asCollection

public Collection<DBID> asCollection()
Description copied from interface: DBIDs
Retrieve collection access to the IDs

Specified by:
asCollection in interface DBIDs
Returns:
a collection of IDs

addDBIDs

public boolean addDBIDs(DBIDs ids)
Description copied from interface: ModifiableDBIDs
Add DBIDs to collection.

Specified by:
addDBIDs in interface ModifiableDBIDs
Parameters:
ids - IDs to add.
Returns:
true when modified

removeDBIDs

public boolean removeDBIDs(DBIDs ids)
Description copied from interface: ModifiableDBIDs
Remove DBIDs from collection.

Specified by:
removeDBIDs in interface ModifiableDBIDs
Parameters:
ids - IDs to remove.
Returns:
true when modified

Release 0.4.0 (2011-09-20_1324)