EPANET-RTX
1.1
real-time extension for the EPANET toolkit
|
Dma represents a collection of junctions that can be considered together in a control volume. More...
#include <Dma.h>
Public Types | |
typedef boost::shared_ptr< Dma > | sharedPointer |
typedef std::pair < Pipe::sharedPointer, Pipe::direction_t > | pipeDirPair_t |
Public Types inherited from RTX::Element | |
enum | element_t { JUNCTION, TANK, RESERVOIR, PIPE, PUMP, VALVE, DMA } |
typedef boost::shared_ptr < Element > | sharedPointer |
Public Member Functions | |
virtual std::ostream & | toStream (std::ostream &stream) |
Dma (const std::string &name) | |
virtual void | setRecord (PointRecord::sharedPointer record) |
Set the intended PointRecord object for storing data. Defaults to the generic TimeSeries storage mechanism. More... | |
void | initDemandTimeseries (const std::set< Pipe::sharedPointer > &boundarySet) |
void | addJunction (Junction::sharedPointer junction) |
void | removeJunction (Junction::sharedPointer junction) |
Junction::sharedPointer | findJunction (std::string name) |
bool | doesHaveJunction (Junction::sharedPointer j) |
std::set< Junction::sharedPointer > | junctions () |
std::set< Tank::sharedPointer > | tanks () |
std::vector< Dma::pipeDirPair_t > | measuredBoundaryPipes () |
std::vector< Dma::pipeDirPair_t > | closedBoundaryPipes () |
std::vector< Pipe::sharedPointer > | closedInteriorPipes () |
std::vector< Pipe::sharedPointer > | measuredInteriorPipes () |
bool | isMeasuredBoundaryPipe (Pipe::sharedPointer pipe) |
bool | isMeasuredInteriorPipe (Pipe::sharedPointer pipe) |
bool | isMeasuredPipe (Pipe::sharedPointer pipe) |
bool | isClosedBoundaryPipe (Pipe::sharedPointer pipe) |
bool | isClosedInteriorPipe (Pipe::sharedPointer pipe) |
bool | isClosedPipe (Pipe::sharedPointer pipe) |
bool | isBoundaryPipe (Pipe::sharedPointer pipe) |
TimeSeries::sharedPointer | demand () |
void | setDemand (TimeSeries::sharedPointer demand) |
Set the TimeSeries to use as the basis for demand allocation. More... | |
void | setJunctionFlowUnits (Units units) |
virtual void | allocateDemandToJunctions (time_t time) |
Allocate demand from the DMA's demand TimeSeries to the constituent junctions. More... | |
Public Member Functions inherited from RTX::Element | |
element_t | type () |
void | setName (const std::string &newName) |
std::string | name () |
std::string | userDescription () |
void | setUserDescription (const std::string &description) |
Additional Inherited Members | |
Protected Member Functions inherited from RTX::Element | |
Element (const std::string &name) | |
void | setType (element_t type) |
Dma represents a collection of junctions that can be considered together in a control volume.
Derive from the Dma class to implement custom demand allocation schemes.
|
virtual |
Allocate demand from the DMA's demand TimeSeries to the constituent junctions.
time | The time frame for which to perform the allocation. |
void RTX::Dma::setDemand | ( | TimeSeries::sharedPointer | demand | ) |
Set the TimeSeries to use as the basis for demand allocation.
demand | A TimeSeries pointer |
|
virtual |
Set the intended PointRecord object for storing data. Defaults to the generic TimeSeries storage mechanism.
record | The PointRecord pointer |
Reimplemented from RTX::Element.