public final class

UnmodifiableSet

extends AbstractSerializableSetDecorator
implements Unmodifiable
java.lang.Object
   ↳ org.apache.commons.collections.collection.AbstractCollectionDecorator
     ↳ org.apache.commons.collections.set.AbstractSetDecorator
       ↳ org.apache.commons.collections.set.AbstractSerializableSetDecorator
         ↳ org.apache.commons.collections.set.UnmodifiableSet

Class Overview

Decorates another Set to ensure it can't be altered.

This class is Serializable from Commons Collections 3.1.

Summary

[Expand]
Inherited Fields
From class org.apache.commons.collections.collection.AbstractCollectionDecorator
Public Methods
boolean add(Object object)
boolean addAll(Collection coll)
void clear()
static Set decorate(Set set)
Factory method to create an unmodifiable set.
Iterator iterator()
boolean remove(Object object)
boolean removeAll(Collection coll)
boolean retainAll(Collection coll)
[Expand]
Inherited Methods
From class org.apache.commons.collections.set.AbstractSetDecorator
From class org.apache.commons.collections.collection.AbstractCollectionDecorator
From class java.lang.Object
From interface java.lang.Iterable
From interface java.util.Collection
From interface java.util.Set

Public Methods

public boolean add (Object object)

public boolean addAll (Collection coll)

public void clear ()

public static Set decorate (Set set)

Factory method to create an unmodifiable set.

Parameters
set the set to decorate, must not be null
Throws
IllegalArgumentException if set is null

public Iterator iterator ()

public boolean remove (Object object)

public boolean removeAll (Collection coll)

public boolean retainAll (Collection coll)