soot.toolkits.scalar
Class ArrayFlowUniverse<E>

java.lang.Object
  extended by soot.toolkits.scalar.ArrayFlowUniverse<E>
All Implemented Interfaces:
FlowUniverse<E>

public class ArrayFlowUniverse<E>
extends Object
implements FlowUniverse<E>

Provides an implementation of a flow universe, wrapping arrays.


Constructor Summary
ArrayFlowUniverse(E[] elements)
           
 
Method Summary
 Iterator<E> iterator()
          returns an iterator over the elements of the universe.
 int size()
          returns the number of elements of the universe.
 E[] toArray()
          returns the elements of the universe in form of an array.
The returned array could be backed or not.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ArrayFlowUniverse

public ArrayFlowUniverse(E[] elements)
Method Detail

size

public int size()
Description copied from interface: FlowUniverse
returns the number of elements of the universe.

Specified by:
size in interface FlowUniverse<E>
Returns:
the size of the universe.

iterator

public Iterator<E> iterator()
Description copied from interface: FlowUniverse
returns an iterator over the elements of the universe.

Specified by:
iterator in interface FlowUniverse<E>
Returns:
an Iterator over the elements.

toArray

public E[] toArray()
Description copied from interface: FlowUniverse
returns the elements of the universe in form of an array.
The returned array could be backed or not. If you want to be sure that it is unbacked, clone() it.

Specified by:
toArray in interface FlowUniverse<E>
Returns:
the elements of the universe.