| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.shapelogic.streams.BaseListCommonStream<E>
org.shapelogic.streams.BaseListStreamList<In,E>
public abstract class BaseListStreamList<In,E>
Implementation of ListStream. 
 
 Close to
 
 1: a lazy stream.
 2: a UNIX pipe.
 
 This is close to org.apache.commons.collections.list.LazyList,
 but that takes a factory to calculate next element, and that works badly here.
 
 How should a step work?
 Normally call the hasNext, in order for this to work it would have to do the 
 calculation.
 
 So _current should be the last element that has been returned.
 
 So when you call hasNext it will add that element to the list.
 When you call next it will bump the counter up one element if goes too high 
 then do the calculation.
 
 At the end it will get to a point where the calculation fails. 
 At that point last will be set to the current element.
 
 I will ignore synchronization to begin with.
| Field Summary | |
|---|---|
| protected  java.util.List<NumberedStream<In>> | _inputStreamDoes not always exist. | 
| Fields inherited from class org.shapelogic.streams.BaseListCommonStream | 
|---|
| _context, _current, _dirty, _last, _list, _maxLast, _name, _nullLegalValue, _parentContext, _query, _value | 
| Constructor Summary | |
|---|---|
| BaseListStreamList() | |
| BaseListStreamList(java.util.List<NumberedStream<In>> inputStream) | |
| BaseListStreamList(java.util.List<NumberedStream<In>> inputStream,
                   int maxLast) | |
| Method Summary | |
|---|---|
|  int | getDimension()How many input streams you have. | 
|  java.util.List<In> | getInput(int index) | 
|  java.util.List<NumberedStream<In>> | getInputStream()Stream that this stream is connected to. | 
|  java.util.List<E> | getList()Get underlying list. | 
|  boolean | hasNext() | 
|  E | invokeIndex(int index)Calculate the value at an index. | 
| protected  void | setLastFromInput() | 
|  void | setList(java.util.List<E> list)Get underlying list. | 
| Methods inherited from class org.shapelogic.streams.BaseListCommonStream | 
|---|
| calcAddNext, get, getContext, getCurrentSize, getInContext, getIndex, getLast, getMaxLast, getName, getParentContext, getValue, hasNextBase, isCached, isDeterministic, isDirty, isNullLegalValue, isRandomAccess, iterator, next, remove, setMaxLast, setNullLegalValue, setup | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Methods inherited from interface org.shapelogic.calculation.CalcList | 
|---|
| invoke | 
| Field Detail | 
|---|
protected java.util.List<NumberedStream<In>> _inputStream
| Constructor Detail | 
|---|
public BaseListStreamList(java.util.List<NumberedStream<In>> inputStream,
                          int maxLast)
public BaseListStreamList(java.util.List<NumberedStream<In>> inputStream)
public BaseListStreamList()
| Method Detail | 
|---|
public E invokeIndex(int index)
BaseListCommonStream
invokeIndex in class BaseListCommonStream<E>public java.util.List<E> getList()
ListStream
getList in interface ListStream<E>getList in class BaseListCommonStream<E>public void setList(java.util.List<E> list)
ListStream
setList in interface ListStream<E>setList in class BaseListCommonStream<E>public java.util.List<NumberedStream<In>> getInputStream()
InputStreamList
getInputStream in interface InputStreamList<In,E>public java.util.List<In> getInput(int index)
getInput in interface InputStreamList<In,E>public int getDimension()
InputStreamList
getDimension in interface InputStreamList<In,E>public boolean hasNext()
hasNext in interface java.util.Iterator<E>hasNext in class BaseListCommonStream<E>protected void setLastFromInput()
setLastFromInput in class BaseListCommonStream<E>| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||