Go to the documentation of this file.
26 #ifndef __TERRALIB_ST_INTERNAL_TIMESERIES_H
27 #define __TERRALIB_ST_INTERNAL_TIMESERIES_H
35 #include "../../../datatype/Enums.h"
38 #include "../../Config.h"
42 namespace te {
namespace dt {
class AbstractData;
class DateTime;
class DateTimePeriod; } }
43 namespace te {
namespace gm {
class Geometry; } }
50 class AbstractTimeSeriesInterp;
455 std::vector<TimeSeriesPatch>& result)
const;
493 std::vector<TimeSeriesPatch>& result)
const;
540 #endif // __TERRALIB_ST_INTERNAL_TIMESERIES_H
void getValueExtent(double &minValue, double &maxValue)
It returns the minimal and maximun values of the time series.
A class to traverse the observations of a TimeSeries.
int getInt(te::dt::DateTime *t) const
It returns the value as an integer associated to a given date and time.
virtual ~TimeSeries()
It returns time series subsets that satisfy the given relations.
TimeSeries(AbstractTimeSeriesInterp *interp, const std::string &id)
Empty constructor.
std::string getId() const
It returns the time series identifier.
This file contains a time series iterator.
TimeSeriesPatch getPatch(const te::dt::DateTime &dt, te::dt::TemporalRelation r=te::dt::DURING) const
It returns a time series subset that satisfies a given temporal relation.
void getPatches(const double &v, te::dt::BasicRelation r, std::vector< TimeSeriesPatch > &result) const
It returns time series subsets that satisfy a given relation.
TimeSeries(const std::string &id)
Empty constructor.
std::unique_ptr< te::gm::Geometry > m_location
The time series location.
void add(te::dt::DateTime *time, const std::string &value)
It adds an observation (time and attribute value as string) into the time series.
AbstractTimeSeriesInterp * getInterpolator() const
It returns the interpolator associated to the time series.
std::size_t size() const
It returns the size of the time series observation set.
A struct to represent a patch or a continuous piece of a time series.
TimeSeriesIterator at(te::dt::DateTime *t) const
It returns an iterator that points to an observation at a given time.
void setInterpolator(AbstractTimeSeriesInterp *interp)
It sets the interpolator associated to the time series.
TimeSeriesIterator begin() const
It returns an iterator that points to the first observation of the time series.
TimeSeries(const TimeSeriesPatch &patch, AbstractTimeSeriesInterp *interp, const std::string &id, te::gm::Geometry *geom)
It constructs a time series from a patch.
TimeSeries * clone() const
It returns a clone of this time series.
TimeSeries(const TimeSeriesObservationSet &obs, AbstractTimeSeriesInterp *interp, const std::string &id, te::gm::Geometry *geom)
Constructor.
A class to represent time series.
TimeSeries(const TimeSeries &ts)
Copy constructor.
void add(const TimeSeriesObservation &item)
It adds an observation (time and attribute value) into the time series.
void getValueExtent(int &minValue, int &maxValue)
It returns the minimal and maximun values of the time series.
TimeSeriesObservationSet m_observations
The time series observations.
te::gm::Geometry * getLocation() const
It returns the time series location.
const TimeSeriesObservationSet & getObservations() const
It returns the time series observations.
void getResultOrderedByTime(const double &v, te::dt::BasicRelation r, std::map< te::dt::DateTime *, te::dt::AbstractData *, te::dt::CompareDateTime > &result) const
It returns the result of a basic relation ordered by time.
void getValueExtent(std::string &minValue, std::string &maxValue)
It returns the minimal and maximun values of the time series.
double getDouble(te::dt::DateTime *t) const
It returns the value as a double associated to a given date and time.
void add(te::dt::DateTime *time, te::dt::AbstractData *value)
It adds an observation (time and attribute value) into the time series.
void add(te::dt::DateTime *time, int value)
It adds an observation (time and attribute value as integer) into the time series.
void getPatches(const double &v, te::dt::BasicRelation r, const te::dt::DateTime &dt, te::dt::TemporalRelation tr, std::vector< TimeSeriesPatch > &result) const
It returns time series subsets that satisfy a given relation.
void setLocation(te::gm::Geometry *geom)
It sets the time series location.
A class to represent an observation (time and value) of a time series.
AbstractTimeSeriesInterp * m_interpolator
The interpolator used to estimate values at non-observed times.
TimeSeries()
Empty constructor.
std::unique_ptr< te::dt::DateTimePeriod > getTemporalExtent() const
It returns the temporal extent or range of the time series.
std::unique_ptr< te::dt::AbstractData > getValue(te::dt::DateTime *t) const
It returns the value associated to a given date and time.
#define TESTEXPORT
You can use this macro in order to export/import classes and functions from this module.
BasicRelation
Relations between simple attribute values.
A base class for values that can be retrieved from the data access module.
An abstract class for an interpolation function or interpolator that estimate a value at non-observav...
TimeSeries(AbstractTimeSeriesInterp *interp, const std::string &id, te::gm::Geometry *geom)
Empty constructor.
std::string getString(te::dt::DateTime *t) const
It returns the value as a string associated to a given date and time.
std::string m_id
The time series identification.
boost::multi_index_container< TimeSeriesObservation, boost::multi_index::indexed_by< boost::multi_index::ordered_unique< boost::multi_index::identity< TimeSeriesObservation > >, boost::multi_index::ordered_non_unique< boost::multi_index::const_mem_fun< TimeSeriesObservation, double, &TimeSeriesObservation::getDouble > >, boost::multi_index::ordered_non_unique< boost::multi_index::const_mem_fun< TimeSeriesObservation, std::string, &TimeSeriesObservation::getString > > > > TimeSeriesObservationSet
Geometry is the root class of the geometries hierarchy, it follows OGC and ISO standards.
void setId(const std::string &id)
It sets the time series identifier.
TimeSeries & operator=(const TimeSeries &other)
Copy assignment operator.
TemporalRelation
Temporal relations between date and time (Source: Allen, 1991).
TimeSeriesIterator end() const
It returns an iterator that points to the end of the time series.
void add(te::dt::DateTime *time, double value)
It adds an observation (time and attribute value as double) into the time series.