EPANET-RTX  1.1
real-time extension for the EPANET toolkit
Public Types | Public Member Functions | List of all members
RTX::Dma Class Reference

Dma represents a collection of junctions that can be considered together in a control volume. More...

#include <Dma.h>

Inheritance diagram for RTX::Dma:
[legend]
Collaboration diagram for RTX::Dma:
[legend]

Public Types

typedef boost::shared_ptr< DmasharedPointer
 
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)
 

Detailed Description

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.

Member Function Documentation

void RTX::Dma::allocateDemandToJunctions ( time_t  time)
virtual

Allocate demand from the DMA's demand TimeSeries to the constituent junctions.

Parameters
timeThe time frame for which to perform the allocation.
See also
TimeSeries Junction
void RTX::Dma::setDemand ( TimeSeries::sharedPointer  demand)

Set the TimeSeries to use as the basis for demand allocation.

Parameters
demandA TimeSeries pointer
See also
TimeSeries
void RTX::Dma::setRecord ( PointRecord::sharedPointer  record)
virtual

Set the intended PointRecord object for storing data. Defaults to the generic TimeSeries storage mechanism.

Parameters
recordThe PointRecord pointer
See also
PointRecord TimeSeries

Reimplemented from RTX::Element.


The documentation for this class was generated from the following files: