it.unimi.dsi.fastutil.objects
Class ObjectCollections.IterableCollection<K>

java.lang.Object
  extended by java.util.AbstractCollection<K>
      extended by it.unimi.dsi.fastutil.objects.AbstractObjectCollection<K>
          extended by it.unimi.dsi.fastutil.objects.ObjectCollections.IterableCollection<K>
All Implemented Interfaces:
ObjectCollection<K>, ObjectIterable<K>, java.io.Serializable, java.lang.Iterable<K>, java.util.Collection<K>
Enclosing class:
ObjectCollections

public static class ObjectCollections.IterableCollection<K>
extends AbstractObjectCollection<K>
implements java.io.Serializable

A collection wrapper class for iterables.

See Also:
Serialized Form

Method Summary
 boolean isEmpty()
           
 ObjectIterator<K> iterator()
          Returns a type-specific iterator on the elements of this collection.
 ObjectIterator<K> objectIterator()
          Deprecated. 
 int size()
           
 
Methods inherited from class it.unimi.dsi.fastutil.objects.AbstractObjectCollection
add, addAll, containsAll, removeAll, retainAll, toArray, toArray, toString
 
Methods inherited from class java.util.AbstractCollection
clear, contains, remove
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.Collection
clear, contains, equals, hashCode, remove
 

Method Detail

size

public int size()
Specified by:
size in interface java.util.Collection<K>
Specified by:
size in class java.util.AbstractCollection<K>

isEmpty

public boolean isEmpty()
Specified by:
isEmpty in interface java.util.Collection<K>
Overrides:
isEmpty in class AbstractObjectCollection<K>

iterator

public ObjectIterator<K> iterator()
Description copied from interface: ObjectCollection
Returns a type-specific iterator on the elements of this collection.

Note that this specification strengthens the one given in Iterable.iterator(), which was already strengthened in the corresponding type-specific class, but was weakened by the fact that this interface extends Collection.

Specified by:
iterator in interface ObjectCollection<K>
Specified by:
iterator in interface ObjectIterable<K>
Specified by:
iterator in interface java.lang.Iterable<K>
Specified by:
iterator in interface java.util.Collection<K>
Specified by:
iterator in class AbstractObjectCollection<K>
Returns:
a type-specific iterator on the elements of this collection.

objectIterator

@Deprecated
public ObjectIterator<K> objectIterator()
Deprecated. 

Description copied from class: AbstractObjectCollection
Delegates to the new covariantly stronger generic method.

Specified by:
objectIterator in interface ObjectCollection<K>
Overrides:
objectIterator in class AbstractObjectCollection<K>
See Also:
ObjectCollection.iterator()