lrs.visitor
Class Nth
java.lang.Object
   lrs.visitor.Nth
lrs.visitor.Nth
- All Implemented Interfaces: 
- IAlgo
- public class Nth 
- extends java.lang.Object- implements IAlgo
Returns the nth element in a LRS.
 
| Constructor Summary | 
| private  | Nth()
 | 
 
| Method Summary | 
|  java.lang.Object | emptyCase(LRStruct host,
                   java.lang.Object... param)Operates on an empty LRStruct host, given an input object.
 | 
|  java.lang.Object | nonEmptyCase(LRStruct host,
                         java.lang.Object... param)Operates on a non-empty LRStruct host, given an input object.
 | 
 
| Methods inherited from class java.lang.Object | 
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
 
Singleton
public static final Nth Singleton
counterAlgo
private static final ICounterAlgo counterAlgo
Nth
private Nth()
emptyCase
public java.lang.Object emptyCase(LRStruct host,
                                  java.lang.Object... param)
- Description copied from interface: IAlgo
- Operates on an empty LRStruct host, given an input object.
 
- 
- Specified by:
- emptyCasein interface- IAlgo
 
- 
- Parameters:
- host- an empty LRStruct.
- param- variable input list of objects needed by this IVisitor.
- Returns:
- an appropriate output object.
 
nonEmptyCase
public java.lang.Object nonEmptyCase(LRStruct host,
                                     java.lang.Object... param)
- Description copied from interface: IAlgo
- Operates on a non-empty LRStruct host, given an input object.
 
- 
- Specified by:
- nonEmptyCasein interface- IAlgo
 
- 
- Parameters:
- host- a non-empty LRStruct.
- param- variable input list of objects needed by this IVisitor.
- Returns:
- an appropriate output object.