Package org.goplanit.od.demand
Class OdDemandMatrix
- java.lang.Object
-
- org.goplanit.utils.id.IdAbleImpl
-
- org.goplanit.utils.od.OdDataImpl<T>
-
- org.goplanit.utils.od.OdMatrixImpl<T,org.ojalgo.array.Array2D<T>>
-
- org.goplanit.utils.od.OdPrimitiveMatrix<Double>
-
- org.goplanit.od.demand.OdDemandMatrix
-
- All Implemented Interfaces:
Cloneable,Comparable<IdAble>,Iterable<Double>,OdDemands,IdAble,OdData<Double>,OdMatrix<Double,org.ojalgo.array.Array2D<Double>>
public class OdDemandMatrix extends OdPrimitiveMatrix<Double> implements OdDemands
This class handles the OD demand matrix.- Author:
- gman6028, markr
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classOdDemandMatrix.OdDemandMatrixIteratorWrapper around primitive matrix iterator
-
Field Summary
-
Fields inherited from class org.goplanit.utils.od.OdMatrixImpl
matrixContents
-
Fields inherited from class org.goplanit.utils.od.OdDataImpl
zones
-
-
Constructor Summary
Constructors Constructor Description OdDemandMatrix(OdDemandMatrix odDemandMatrix)Copy constructorOdDemandMatrix(OdZones zones)Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description OdDemandMatrixclone()Create a shallow copy of this entityOdDemandMatrix.OdDemandMatrixIteratoriterator()Returns an iterator which can iterate through all the origin-destination cells in the matrix-
Methods inherited from class org.goplanit.utils.od.OdPrimitiveMatrix
getValue, getValue, setValue
-
Methods inherited from class org.goplanit.utils.od.OdDataImpl
getNumberOfOdZones, getOdZones
-
Methods inherited from class org.goplanit.utils.id.IdAbleImpl
equals, generateAndSetId, generateId, getId, hashCode, setId
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.goplanit.utils.id.IdAble
compareTo, getId, idEquals, idHashCode
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Methods inherited from interface org.goplanit.utils.od.OdData
getNumberOfOdZones, getValue, getValue, setValue
-
Methods inherited from interface org.goplanit.od.demand.OdDemands
forEachNonZeroDestinationDemand, forEachNonZeroOdDemand
-
-
-
-
Constructor Detail
-
OdDemandMatrix
public OdDemandMatrix(OdZones zones)
Constructor- Parameters:
zones- holds the zones defined in the network
-
OdDemandMatrix
public OdDemandMatrix(OdDemandMatrix odDemandMatrix)
Copy constructor- Parameters:
odDemandMatrix- to copy
-
-
Method Detail
-
iterator
public OdDemandMatrix.OdDemandMatrixIterator iterator()
Returns an iterator which can iterate through all the origin-destination cells in the matrix- Specified by:
iteratorin interfaceIterable<Double>- Specified by:
iteratorin interfaceOdData<Double>- Specified by:
iteratorin interfaceOdMatrix<Double,org.ojalgo.array.Array2D<Double>>- Specified by:
iteratorin classOdPrimitiveMatrix<Double>- Returns:
- iterator through all the origin-destination cells
-
clone
public OdDemandMatrix clone()
Create a shallow copy of this entity- Specified by:
clonein interfaceIdAble- Specified by:
clonein classOdPrimitiveMatrix<Double>- Returns:
- shallow copy of entity
-
-