net.sourceforge.combean.mathprog.linalg
Class AbstractComposedSparseVec<Label>
java.lang.Object
net.sourceforge.combean.mathprog.linalg.AbstractComposedSparseVec<Label>
- All Implemented Interfaces:
- SparseVec<Label>
- Direct Known Subclasses:
- CombinedSparseVec
public abstract class AbstractComposedSparseVec<Label>
- extends Object
- implements SparseVec<Label>
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
vecs
protected LinkedList<SparseVec<Label>> vecs
AbstractComposedSparseVec
public AbstractComposedSparseVec()
getInnerVecs
protected Collection<SparseVec<Label>> getInnerVecs()
addVector
public void addVector(SparseVec<Label> newVec)
iterator
public abstract VectorIterator<Label> iterator()
- Description copied from interface:
SparseVec
- Get an iterator which iterates through all non-zero entries
of the vector. The iteration must stop after exactly
getNumNonZeroEntries() steps.
An implementation may choose to also return zero entries
during the iteration. In that case, these entries must also
be counted by getNumIterations();
The iteration does not have to return the values in order of
increasing indices.
- Specified by:
iterator
in interface SparseVec<Label>
- Returns:
- an iterator for the non-zero entries.