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

Aggregates (and optionally scales) arbitrary many input time series. More...

#include <AggregatorTimeSeries.h>

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

Classes

struct  AggregatorSource
 

Public Types

typedef boost::shared_ptr
< AggregatorTimeSeries
sharedPointer
 
- Public Types inherited from RTX::Resampler
enum  interpolateMode_t { linear, step }
 
typedef std::vector< Point >
::const_iterator 
pVec_cIt
 
typedef boost::shared_ptr
< Resampler
sharedPointer
 
- Public Types inherited from RTX::ModularTimeSeries
typedef boost::shared_ptr
< ModularTimeSeries
sharedPointer
 
- Public Types inherited from RTX::TimeSeries
typedef boost::shared_ptr
< TimeSeries
sharedPointer
 

Public Member Functions

TimeSeries::sharedPointer source ()
 Get the source of this time series. More...
 
virtual void setSource (TimeSeries::sharedPointer source)
 Set the upstream TimeSeries object. More...
 
virtual bool doesHaveSource ()
 Does this Modular time series have an upstream source? More...
 
virtual std::ostream & toStream (std::ostream &stream)
 
void addSource (TimeSeries::sharedPointer timeSeries, double multiplier=1.) throw (RtxException)
 
void removeSource (TimeSeries::sharedPointer timeSeries)
 
std::vector< AggregatorSourcesources ()
 
void setMultiplierForSource (TimeSeries::sharedPointer timeSeries, double multiplier)
 
virtual Point point (time_t time)
 option to add lots of (un)ordered points all at once. More...
 
virtual Point pointBefore (time_t time)
 
virtual Point pointAfter (time_t time)
 
- Public Member Functions inherited from RTX::Resampler
interpolateMode_t mode ()
 
void setMode (interpolateMode_t mode)
 
- Public Member Functions inherited from RTX::ModularTimeSeries
virtual TimeSeries::sharedPointer rootTimeSeries ()
 
virtual std::vector< Pointpoints (time_t start, time_t end)
 Get a vector of Points within a specific time range. More...
 
virtual void setUnits (Units newUnits)
 
virtual void resetCache ()
 
virtual bool canAlterDimension ()
 
- Public Member Functions inherited from RTX::TimeSeries
virtual void insert (Point aPoint)
 
virtual void insertPoints (std::vector< Point >)
 
virtual Point pointAtOrBefore (time_t time)
 
virtual Point interpolatedPoint (time_t time)
 
virtual std::pair< Point, PointadjacentPoints (time_t time)
 
virtual time_t period ()
 
virtual std::string name ()
 1/frequency (# seconds between data points)
 
PointRecord::sharedPointer record ()
 
TimeSeries::Statistics summary (time_t start, time_t end)
 
TimeSeries::Statistics gapsSummary (time_t start, time_t end)
 
std::vector< Pointgaps (time_t start, time_t end)
 
virtual void setName (const std::string &name)
 
void setRecord (PointRecord::sharedPointer record)
 
virtual void setClock (Clock::sharedPointer clock)
 
Clock::sharedPointer clock ()
 
Units units ()
 
void setFirstTime (time_t time)
 
void setLastTime (time_t time)
 
time_t firstTime ()
 
time_t lastTime ()
 

Protected Member Functions

virtual std::vector< PointfilteredPoints (TimeSeries::sharedPointer sourceTs, time_t fromTime, time_t toTime)
 
- Protected Member Functions inherited from RTX::Resampler
virtual bool canAlterClock ()
 
virtual int margin ()
 
virtual Point filteredSingle (pVec_cIt &vecStart, pVec_cIt &vecEnd, pVec_cIt &vecPos, time_t t, Units fromUnits)
 
bool alignVectorIterators (pVec_cIt &start, pVec_cIt &end, pVec_cIt &pos, time_t t, pVec_cIt &back, pVec_cIt &fwd)
 
std::pair< time_t, time_t > expandedRange (TimeSeries::sharedPointer sourceTs, time_t start, time_t end)
 
- Protected Member Functions inherited from RTX::ModularTimeSeries
virtual bool isCompatibleWith (TimeSeries::sharedPointer withTimeSeries)
 

Detailed Description

Aggregates (and optionally scales) arbitrary many input time series.

Use addSource to add an input time series, with optional multiplier (-1 for subtraction).

Member Function Documentation

bool AggregatorTimeSeries::doesHaveSource ( )
virtual

Does this Modular time series have an upstream source?

Returns
true / false

Reimplemented from RTX::ModularTimeSeries.

Point AggregatorTimeSeries::point ( time_t  time)
virtual

option to add lots of (un)ordered points all at once.

Get a Point at a specific time.

Parameters
timeThe requested time.
Returns
The requested Point, or the Point just prior to the passed time value.
See also
Point

Reimplemented from RTX::Resampler.

void AggregatorTimeSeries::setSource ( TimeSeries::sharedPointer  source)
virtual

Set the upstream TimeSeries object.

Parameters
sourceA shared pointer to the intended upstream TimeSeries object.

Reimplemented from RTX::ModularTimeSeries.

TimeSeries::sharedPointer AggregatorTimeSeries::source ( )
virtual

Get the source of this time series.

Returns
A shared pointer to a TimeSeries (or derived) object.
See also
TimeSeries

Reimplemented from RTX::ModularTimeSeries.


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