soot.util
Class SingletonList

java.lang.Object
  extended byjava.util.AbstractCollection
      extended byjava.util.AbstractList
          extended bysoot.util.SingletonList
All Implemented Interfaces:
Collection, List

public class SingletonList
extends AbstractList

A list containing exactly one object, immutable.

Author:
Ondrej Lhotak

Field Summary
 
Fields inherited from class java.util.AbstractList
modCount
 
Constructor Summary
SingletonList(Object o)
           
 
Method Summary
 boolean contains(Object other)
           
 Object get(int index)
           
 int size()
           
 
Methods inherited from class java.util.AbstractList
add, add, addAll, clear, equals, hashCode, indexOf, iterator, lastIndexOf, listIterator, listIterator, remove, removeRange, set, subList
 
Methods inherited from class java.util.AbstractCollection
addAll, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
addAll, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray
 

Constructor Detail

SingletonList

public SingletonList(Object o)
Method Detail

size

public int size()

contains

public boolean contains(Object other)

get

public Object get(int index)