com.togethersoft.openapi.util.enum
Class SingleEnumeration


public class SingleEnumeration
implements Enumeration

Presents enumeration contains only one element as an Object.

Author:
TogetherSoft
Since: Together 4.0

Field Summary
 private ObjectmyValue
           

Constructor Summary
SingleEnumeration(Object value)
          Creates new single enumeration from specified Object.

Method Summary
 booleanhasMoreElements()
          Checks is there more elements in enumeration.
 ObjectnextElement()
          Returns the only element from enumaration.

Field Detail

myValue

private Object myValue
Constructor Detail

SingleEnumeration

public SingleEnumeration(Object value)
Creates new single enumeration from specified Object.
Method Detail

hasMoreElements

public boolean hasMoreElements()
Checks is there more elements in enumeration.
Returns: true if there is ("nextElement" method passed at least ones),
false else.

nextElement

public Object nextElement()
Returns the only element from enumaration.
Returns: Element as an Object.

Association Links

to Class java.lang.Object