Aimsun Next Scripting
22
|
Public Member Functions | |
GKTSDescription (GKColumn *col, const QString &) | |
~GKTSDescription () | |
void | setTime (const QDateTime &, const QDateTime &, const GKTimeDuration &) |
void | setFromTime (const QDateTime &) |
void | setToTime (const QDateTime &) |
void | setIntervalTime (const GKTimeDuration &) |
void | expand (const QDateTime &) |
void | setToTimeKnow (bool) |
const QDateTime & | getFromTime () const |
const QDateTime & | getToTime () const |
const GKTimeDuration & | getIntervalTime () const |
QDateTime | getTimeFromInterval (int pos) const |
const GKTimeDuration | getDuration (const GKTimeSerie *) const |
int | getInterval (const QDateTime &) const |
int | getInterval (const QTime &) const |
bool | isMultidimensional () const |
void | setMultidimensional (bool value) |
int | dimensions () const |
GKContext | toContext () const |
const QString & | getTypeName () const |
void | setTypeName (const QString &) |
void | setAggregationType (GK::AggregationType type) |
GK::AggregationType | getAggregationType () const |
void | setConversion (const GK::Conversion) |
const GK::Conversion | getConversion () const |
void | setNullValue (double) |
bool | hasNullValue () const |
double | getNullValue () const |
bool | isNull (double) const |
void | setMinMax (double, double) |
void | expandMaxMin (double) |
void | resetMinMax () |
double | getMinimum () const |
double | getMaximum () const |
GKTimeSerie::ExtraInfo | getExtraInfo () const |
void | setExtraInfo (GKTimeSerie::ExtraInfo avalue) |
const QString & | getUniqueName () const |
Static Public Member Functions | |
static GKTSDescription * | getCreateDescription (GKColumn *col, const QString &uniqueName) |
static void | findCommonDates (const GKTSDescription *t1, const GKTSDescription *t2, QDateTime &from, QDateTime &to) |
static void | findCommonTimes (const GKTSDescription *t1, const GKTSDescription *t2, QTime &from, QTime &to) |
Each time series (GKTimeSerie) has an associated description. Two (or more) time series can share the same description if their data is compatible (same time intervals and duration, same data type).
GKTSDescription::GKTSDescription | ( | GKColumn * | col, |
const QString & | |||
) |
GKTSDescription::~GKTSDescription | ( | ) |
int GKTSDescription::dimensions | ( | ) | const |
Returns max number of the dimensions used by TS with this description.
void GKTSDescription::expand | ( | const QDateTime & | ) |
void GKTSDescription::expandMaxMin | ( | double | ) |
Recalculates the maximum and minimum values taking into account value (that is a value in that has been added to a time series).
|
static |
Find common dates (from, to) in to Timeseries that have a common interval.
|
static |
Find common times (from, to) in to Timeseries that have a common interval. The date in the date and time information is not used.
GK::AggregationType GKTSDescription::getAggregationType | ( | ) | const |
When aggregating data, gives what is relevant: the mean or the sum.
const GK::Conversion GKTSDescription::getConversion | ( | ) | const |
Units of this TS.
|
static |
Find (and create a new one if none is found) a TS description by uniqueName.
const GKTimeDuration GKTSDescription::getDuration | ( | const GKTimeSerie * | ) | const |
Calculates the duration of a TS based on its from and to data or the interval.
GKTimeSerie::ExtraInfo GKTSDescription::getExtraInfo | ( | ) | const |
Has deviation or bands for each value in the time series?
const QDateTime & GKTSDescription::getFromTime | ( | ) | const |
int GKTSDescription::getInterval | ( | const QDateTime & | ) | const |
Returns the interval (the position in the time series array of value) in where time is truncated to the nearest integer.
If time is not in the interval -1 is returned.
int GKTSDescription::getInterval | ( | const QTime & | ) | const |
Returns the interval (the position in the time series array of value) in where time is truncated to the nearest integer. QDate info is not used in the from and to times, only the QTime part.
If time is not in the interval -1 is returned.
const GKTimeDuration & GKTSDescription::getIntervalTime | ( | ) | const |
double GKTSDescription::getMaximum | ( | ) | const |
Returns the maximum value of all the TS that uses this description.
double GKTSDescription::getMinimum | ( | ) | const |
Returns the minimum value of all the TS that uses this description.
double GKTSDescription::getNullValue | ( | ) | const |
Returns the NULL value for this TS description. Test firts if a NULL has been defined using GKTSDescription::hasNullValue
QDateTime GKTSDescription::getTimeFromInterval | ( | int | pos | ) | const |
Returns the time for a given interval position (based on from time and interval time)
const QDateTime & GKTSDescription::getToTime | ( | ) | const |
const QString & GKTSDescription::getTypeName | ( | ) | const |
const QString & GKTSDescription::getUniqueName | ( | ) | const |
bool GKTSDescription::hasNullValue | ( | ) | const |
Returns true if a NULL value for this TS description has been set.
bool GKTSDescription::isMultidimensional | ( | ) | const |
Is the associated Time Series multidimensional?
bool GKTSDescription::isNull | ( | double | ) | const |
Returns true if "value" is a NULL (as defined with GKTSDescription::setNullValue).
void GKTSDescription::resetMinMax | ( | ) |
Resets the maximum and minimum values
void GKTSDescription::setAggregationType | ( | GK::AggregationType | type | ) |
When aggregating data, sets what is relevant: the mean or the sum.
void GKTSDescription::setConversion | ( | const GK::Conversion | ) |
Units of this TS.
void GKTSDescription::setExtraInfo | ( | GKTimeSerie::ExtraInfo | avalue | ) |
Has deviation or bands for each value in the time series? Called automatically by the time series when a value with deviation or band is set.
void GKTSDescription::setFromTime | ( | const QDateTime & | ) |
void GKTSDescription::setIntervalTime | ( | const GKTimeDuration & | ) |
void GKTSDescription::setMinMax | ( | double | , |
double | |||
) |
Sets the maximum and minimum values of the time series.
void GKTSDescription::setMultidimensional | ( | bool | value | ) |
Set to true if the Time Series is multidimensional, false otherwise.
void GKTSDescription::setNullValue | ( | double | ) |
Sets the valuev to be used as NULL (no value)
void GKTSDescription::setTime | ( | const QDateTime & | , |
const QDateTime & | , | ||
const GKTimeDuration & | |||
) |
void GKTSDescription::setToTime | ( | const QDateTime & | ) |
void GKTSDescription::setToTimeKnow | ( | bool | ) |
If true the end time will be used (even if no data is found) when computing the duration (in GKTSDescription::getDuration). If false the duration will be computed using the the interval time and the data in the TS.
Set it to true (the default) when the end time is well known, to false when the TS is dynamic and the end time is not known.
void GKTSDescription::setTypeName | ( | const QString & | ) |