JTemporal Home
Tutorial

net.sf.jtemporal.util
Class EmptySet

java.lang.Object
  extended by java.util.AbstractCollection<E>
      extended by java.util.AbstractSet
          extended by net.sf.jtemporal.util.EmptySet
All Implemented Interfaces:
java.io.Serializable, java.lang.Iterable, java.util.Collection, java.util.Set

public class EmptySet
extends java.util.AbstractSet
implements java.io.Serializable

Immutable empty read-only set (singleton).
For methods description, see java.util.Set

Version:
$Id: EmptySet.java,v 1.2 2005/06/11 19:59:21 tabeck Exp $
See Also:
Serialized Form

Method Summary
 boolean add(java.lang.Object o)
           
 boolean addAll(java.util.Collection parm1)
           
 void clear()
           
 boolean contains(java.lang.Object o)
           
 boolean containsAll(java.util.Collection parm1)
           
static EmptySet getInstance()
           
 boolean isEmpty()
           
 java.util.Iterator iterator()
           
 boolean remove(java.lang.Object o)
           
 int size()
           
 java.lang.Object[] toArray()
           
 
Methods inherited from class java.util.AbstractSet
equals, hashCode, removeAll
 
Methods inherited from class java.util.AbstractCollection
retainAll, toArray, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.Set
retainAll, toArray
 

Method Detail

getInstance

public static EmptySet getInstance()

contains

public boolean contains(java.lang.Object o)
Specified by:
contains in interface java.util.Collection
Specified by:
contains in interface java.util.Set
Overrides:
contains in class java.util.AbstractCollection

remove

public boolean remove(java.lang.Object o)
Specified by:
remove in interface java.util.Collection
Specified by:
remove in interface java.util.Set
Overrides:
remove in class java.util.AbstractCollection

isEmpty

public boolean isEmpty()
Specified by:
isEmpty in interface java.util.Collection
Specified by:
isEmpty in interface java.util.Set
Overrides:
isEmpty in class java.util.AbstractCollection

add

public boolean add(java.lang.Object o)
Specified by:
add in interface java.util.Collection
Specified by:
add in interface java.util.Set
Overrides:
add in class java.util.AbstractCollection

size

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

containsAll

public boolean containsAll(java.util.Collection parm1)
Specified by:
containsAll in interface java.util.Collection
Specified by:
containsAll in interface java.util.Set
Overrides:
containsAll in class java.util.AbstractCollection

toArray

public java.lang.Object[] toArray()
Specified by:
toArray in interface java.util.Collection
Specified by:
toArray in interface java.util.Set
Overrides:
toArray in class java.util.AbstractCollection

clear

public void clear()
Specified by:
clear in interface java.util.Collection
Specified by:
clear in interface java.util.Set
Overrides:
clear in class java.util.AbstractCollection

iterator

public java.util.Iterator iterator()
Specified by:
iterator in interface java.lang.Iterable
Specified by:
iterator in interface java.util.Collection
Specified by:
iterator in interface java.util.Set
Specified by:
iterator in class java.util.AbstractCollection

addAll

public boolean addAll(java.util.Collection parm1)
Specified by:
addAll in interface java.util.Collection
Specified by:
addAll in interface java.util.Set
Overrides:
addAll in class java.util.AbstractCollection

JTemporal Home
Tutorial