![]() |
TerraLib 4.1
|
A base class that represents an instance in a time of a spatial object. More...
#include <TeBaseSTInstance.h>
Public Member Functions | |
| TeBaseSTInstance () | |
| Empty constructor. | |
| TeBaseSTInstance (const string &object_id, const vector< string > &prop, TeAttributeList *attList=0, const int &s=-1) | |
| Constructor. | |
| TeBaseSTInstance (const string &object_id, const GeometryType &geometries, const TimeType &time, const int &s=-1) | |
| Constructor. | |
| TeBaseSTInstance (const string &object_id, const vector< string > &prop, TeAttributeList *attList, const GeometryType &geometries, const int &slice, const TimeType &time) | |
| Constructor. | |
| virtual | ~TeBaseSTInstance () |
| Destructor. | |
| virtual bool | operator== (const TeBaseSTInstance< GeometryType, TimeType > &other) |
| Equal operator. | |
| virtual string | getObjectId () |
| Returns the object identification. | |
| virtual void | setObjectId (const string &id) |
| Sets the object identification. | |
| virtual string | objectId () |
| Deprecated: Returns the object identification. | |
| virtual void | objectId (const string &id) |
| Deprecated: Sets the object identification. | |
| virtual vector< string > & | getUniqueId () |
| Returns the unique identification in all attribute tables. | |
| virtual string | getUniqueId (const int &i) |
| Returns the unique identification of the i-th attribute table. | |
| virtual void | setUniqueId (const vector< string > &id) |
| Sets the unique identification in all attribute tables. | |
| virtual void | addUniqueId (const string &id) |
| Adds an unique identification. | |
| virtual vector< string > & | uniqueId () |
| Deprecated: Returns the instance identification in all attribute tables. | |
| virtual string | uniqueId (int index) |
| Deprecated: Returns the instance identification in the index-th attribute table. | |
| virtual void | uniqueId (const vector< string > &ids) |
| Deprecated: Sets the instance identifications in all attribute tables. | |
| virtual TimeType | getTime () |
| Returns the valid time. | |
| virtual void | setTime (const TimeType &t) |
| Sets the valid time. | |
| virtual void | setProperties (const vector< string > &p) |
| Sets the property value vector. | |
| virtual void | setProperties (TePropertyVector &p) |
| Deprecated: Sets the property vector to the ST instance. | |
| virtual bool | setPropertyValue (const int &i, const string &val) |
| Sets the value (as a string) of the i-th property. | |
| virtual bool | setPropertyValue (const string &name, const string &val) |
| Sets the value (as a string) of a property named 'name'. | |
| virtual void | addPropertyValue (const string &val) |
| Adds a new property value. | |
| virtual bool | removePropertyValue (const int &i) |
| Removes the i-th property value. | |
| virtual bool | addProperty (TeProperty &prop) |
| Adds a new property or set its value. | |
| virtual bool | addProperty (TeAttribute &rep) |
| Adds a new attribute in the attribute list. | |
| virtual vector< string > & | getProperties () |
| Returns the property value vector. | |
| virtual void | getPropertyVector (TePropertyVector &propVec) |
| Gets the property vector. | |
| TePropertyVector | getPropertyVector () |
| Deprecated: Returns the property vector from the ST instance. | |
| virtual bool | getProperty (TeProperty &prop, unsigned int i=0) |
| Gets the i-th property. | |
| virtual bool | getProperty (TeProperty &prop, string name) |
| Gets the property named "name". | |
| virtual bool | getPropertyValue (string &val, const int &i=0) |
| Gets the value (as a string) of the i-th property. | |
| virtual bool | getPropertyValue (const string &name, string &val) |
| Gets the the value (as a string) of a property named "name". | |
| virtual double | operator[] (int i) |
| Returns the value (as a double) of the i-th property. | |
| virtual void | properties (TePropertyVector &p) |
| Deprecated: Sets the property vector to the ST instance. | |
| virtual GeometryType & | getGeometries () |
| Returns the geometries. | |
| virtual void | setGeometry (const GeometryType &g) |
| Sets the geometries. | |
| virtual GeometryType & | geometries () |
| Deprecated: Returns the geometries. | |
| virtual void | setSlice (int s) |
| Sets the group or slice that contains this instance. | |
| virtual int | getSlice () |
| Returns the group or slice that contains this instance. | |
| virtual void | slice (int s) |
| Deprecated: Sets the group or slice that contains this instance. | |
| virtual int | slice () |
| Deprecated: Returns the group or slice that contains this instance. | |
| const TeAttributeList * | getAttrList () |
| Gets a pointer to attribute desciptions. | |
| void | setAttrList (const TeAttributeList &attList) |
| Creates a new internal copy of the attribute description. | |
| void | setAttrList (TeSharedPtr< TeAttributeList > &attrList) |
| Sets a shared pointer to attribute descriptions. | |
| virtual void | clear () |
| Clears the instance, its attributes. It must be implemented by specialized classes to clear its geometries. | |
| virtual TeCoord2D | getCentroid () |
| Returns a centroid associated to the geometries of the instance. | |
| virtual double | getArea () |
| Returns an area the geometries of the instance. | |
| virtual bool | isTimeValid () |
| Verifies if the time associated with this instance is valid. It must be implemented by specialized classes. | |
| virtual TeTheme * | theme () |
| Deprecated: Returns the theme pointer that contains this instance. | |
| virtual void | theme (TeTheme *) |
| Deprecated: Sets the theme that contains this instance. | |
Protected Attributes | |
| string | object_id_ |
| object identification | |
| vector< string > | unique_id_ |
| unique identification in each attribute table | |
| vector< string > | properties_ |
| set of properties or attributes values | |
| GeometryType | geometries_ |
| geometries | |
| TimeType | time_ |
| valid time | |
| int | slice_ |
| the slice or group that contains this instance | |
| TeSharedPtr< TeAttributeList > | attrList_ |
| a shared pointer to the descriptions of all attributes | |
A base class that represents an instance in a time of a spatial object.
A spatio-temporal instance (STInstance) is composite of an attribute set and geometries of a spatial element or object that are valid in a specific time. This class implements a base generic spatio-temporal instance that can be specialized according to the types that represent its geometries and its valid time.
| TeBaseSTInstance< GeometryType, TimeType >::TeBaseSTInstance | ( | ) | [inline] |
Empty constructor.
| TeBaseSTInstance< GeometryType, TimeType >::TeBaseSTInstance | ( | const string & | object_id, |
| const vector< string > & | prop, | ||
| TeAttributeList * | attList = 0, |
||
| const int & | s = -1 |
||
| ) | [inline] |
Constructor.
| TeBaseSTInstance< GeometryType, TimeType >::TeBaseSTInstance | ( | const string & | object_id, |
| const GeometryType & | geometries, | ||
| const TimeType & | time, | ||
| const int & | s = -1 |
||
| ) | [inline] |
Constructor.
| TeBaseSTInstance< GeometryType, TimeType >::TeBaseSTInstance | ( | const string & | object_id, |
| const vector< string > & | prop, | ||
| TeAttributeList * | attList, | ||
| const GeometryType & | geometries, | ||
| const int & | slice, | ||
| const TimeType & | time | ||
| ) | [inline] |
Constructor.
| virtual TeBaseSTInstance< GeometryType, TimeType >::~TeBaseSTInstance | ( | ) | [inline, virtual] |
Destructor.
| bool TeBaseSTInstance< GeometryType, TimeType >::addProperty | ( | TeProperty & | prop | ) | [virtual] |
Adds a new property or set its value.
Verifies if there is this property in the attribute list. If not, adds it in the ST instance and in the attribute list. Otherwise, set the property value
| bool TeBaseSTInstance< GeometryType, TimeType >::addProperty | ( | TeAttribute & | rep | ) | [virtual] |
Adds a new attribute in the attribute list.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::addPropertyValue | ( | const string & | val | ) | [inline, virtual] |
Adds a new property value.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::addUniqueId | ( | const string & | id | ) | [inline, virtual] |
Adds an unique identification.
| void TeBaseSTInstance< GeometryType, TimeType >::clear | ( | ) | [virtual] |
Clears the instance, its attributes. It must be implemented by specialized classes to clear its geometries.
Reimplemented in TeSTEvent, and TeSTInstance.
| virtual GeometryType& TeBaseSTInstance< GeometryType, TimeType >::geometries | ( | ) | [inline, virtual] |
Deprecated: Returns the geometries.
| double TeBaseSTInstance< GeometryType, TimeType >::getArea | ( | ) | [virtual] |
Returns an area the geometries of the instance.
| const TeAttributeList* TeBaseSTInstance< GeometryType, TimeType >::getAttrList | ( | ) | [inline] |
Gets a pointer to attribute desciptions.
| TeCoord2D TeBaseSTInstance< GeometryType, TimeType >::getCentroid | ( | ) | [virtual] |
Returns a centroid associated to the geometries of the instance.
| virtual GeometryType& TeBaseSTInstance< GeometryType, TimeType >::getGeometries | ( | ) | [inline, virtual] |
Returns the geometries.
| virtual string TeBaseSTInstance< GeometryType, TimeType >::getObjectId | ( | ) | [inline, virtual] |
Returns the object identification.
| virtual vector<string>& TeBaseSTInstance< GeometryType, TimeType >::getProperties | ( | ) | [inline, virtual] |
Returns the property value vector.
| bool TeBaseSTInstance< GeometryType, TimeType >::getProperty | ( | TeProperty & | prop, |
| unsigned int | i = 0 |
||
| ) | [virtual] |
Gets the i-th property.
| bool TeBaseSTInstance< GeometryType, TimeType >::getProperty | ( | TeProperty & | prop, |
| string | name | ||
| ) | [virtual] |
Gets the property named "name".
| bool TeBaseSTInstance< GeometryType, TimeType >::getPropertyValue | ( | string & | val, |
| const int & | i = 0 |
||
| ) | [virtual] |
Gets the value (as a string) of the i-th property.
| bool TeBaseSTInstance< GeometryType, TimeType >::getPropertyValue | ( | const string & | name, |
| string & | val | ||
| ) | [virtual] |
Gets the the value (as a string) of a property named "name".
| void TeBaseSTInstance< GeometryType, TimeType >::getPropertyVector | ( | TePropertyVector & | propVec | ) | [virtual] |
Gets the property vector.
| TePropertyVector TeBaseSTInstance< GeometryType, TimeType >::getPropertyVector | ( | ) |
Deprecated: Returns the property vector from the ST instance.
| virtual int TeBaseSTInstance< GeometryType, TimeType >::getSlice | ( | ) | [inline, virtual] |
Returns the group or slice that contains this instance.
| virtual TimeType TeBaseSTInstance< GeometryType, TimeType >::getTime | ( | ) | [inline, virtual] |
Returns the valid time.
| virtual vector<string>& TeBaseSTInstance< GeometryType, TimeType >::getUniqueId | ( | ) | [inline, virtual] |
Returns the unique identification in all attribute tables.
| string TeBaseSTInstance< GeometryType, TimeType >::getUniqueId | ( | const int & | i | ) | [virtual] |
Returns the unique identification of the i-th attribute table.
| virtual bool TeBaseSTInstance< GeometryType, TimeType >::isTimeValid | ( | ) | [inline, virtual] |
Verifies if the time associated with this instance is valid. It must be implemented by specialized classes.
Reimplemented in TeSTEvent, and TeSTInstance.
| virtual string TeBaseSTInstance< GeometryType, TimeType >::objectId | ( | ) | [inline, virtual] |
Deprecated: Returns the object identification.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::objectId | ( | const string & | id | ) | [inline, virtual] |
Deprecated: Sets the object identification.
| bool TeBaseSTInstance< GeometryType, TimeType >::operator== | ( | const TeBaseSTInstance< GeometryType, TimeType > & | other | ) | [virtual] |
Equal operator.
| double TeBaseSTInstance< GeometryType, TimeType >::operator[] | ( | int | i | ) | [virtual] |
Returns the value (as a double) of the i-th property.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::properties | ( | TePropertyVector & | p | ) | [inline, virtual] |
Deprecated: Sets the property vector to the ST instance.
| bool TeBaseSTInstance< GeometryType, TimeType >::removePropertyValue | ( | const int & | i | ) | [virtual] |
Removes the i-th property value.
| void TeBaseSTInstance< GeometryType, TimeType >::setAttrList | ( | const TeAttributeList & | attList | ) |
Creates a new internal copy of the attribute description.
| void TeBaseSTInstance< GeometryType, TimeType >::setAttrList | ( | TeSharedPtr< TeAttributeList > & | attrList | ) |
Sets a shared pointer to attribute descriptions.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::setGeometry | ( | const GeometryType & | g | ) | [inline, virtual] |
Sets the geometries.
Reimplemented in TeSTInstance.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::setObjectId | ( | const string & | id | ) | [inline, virtual] |
Sets the object identification.
| void TeBaseSTInstance< GeometryType, TimeType >::setProperties | ( | TePropertyVector & | p | ) | [virtual] |
Deprecated: Sets the property vector to the ST instance.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::setProperties | ( | const vector< string > & | p | ) | [inline, virtual] |
Sets the property value vector.
| bool TeBaseSTInstance< GeometryType, TimeType >::setPropertyValue | ( | const int & | i, |
| const string & | val | ||
| ) | [virtual] |
Sets the value (as a string) of the i-th property.
| bool TeBaseSTInstance< GeometryType, TimeType >::setPropertyValue | ( | const string & | name, |
| const string & | val | ||
| ) | [virtual] |
Sets the value (as a string) of a property named 'name'.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::setSlice | ( | int | s | ) | [inline, virtual] |
Sets the group or slice that contains this instance.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::setTime | ( | const TimeType & | t | ) | [inline, virtual] |
Sets the valid time.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::setUniqueId | ( | const vector< string > & | id | ) | [inline, virtual] |
Sets the unique identification in all attribute tables.
| virtual int TeBaseSTInstance< GeometryType, TimeType >::slice | ( | ) | [inline, virtual] |
Deprecated: Returns the group or slice that contains this instance.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::slice | ( | int | s | ) | [inline, virtual] |
Deprecated: Sets the group or slice that contains this instance.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::theme | ( | TeTheme * | ) | [inline, virtual] |
Deprecated: Sets the theme that contains this instance.
| virtual TeTheme* TeBaseSTInstance< GeometryType, TimeType >::theme | ( | ) | [inline, virtual] |
Deprecated: Returns the theme pointer that contains this instance.
| virtual string TeBaseSTInstance< GeometryType, TimeType >::uniqueId | ( | int | index | ) | [inline, virtual] |
Deprecated: Returns the instance identification in the index-th attribute table.
| virtual vector<string>& TeBaseSTInstance< GeometryType, TimeType >::uniqueId | ( | ) | [inline, virtual] |
Deprecated: Returns the instance identification in all attribute tables.
| virtual void TeBaseSTInstance< GeometryType, TimeType >::uniqueId | ( | const vector< string > & | ids | ) | [inline, virtual] |
Deprecated: Sets the instance identifications in all attribute tables.
TeSharedPtr<TeAttributeList> TeBaseSTInstance< GeometryType, TimeType >::attrList_ [protected] |
a shared pointer to the descriptions of all attributes
GeometryType TeBaseSTInstance< GeometryType, TimeType >::geometries_ [protected] |
geometries
string TeBaseSTInstance< GeometryType, TimeType >::object_id_ [protected] |
object identification
vector<string> TeBaseSTInstance< GeometryType, TimeType >::properties_ [protected] |
set of properties or attributes values
int TeBaseSTInstance< GeometryType, TimeType >::slice_ [protected] |
the slice or group that contains this instance
TimeType TeBaseSTInstance< GeometryType, TimeType >::time_ [protected] |
valid time
vector<string> TeBaseSTInstance< GeometryType, TimeType >::unique_id_ [protected] |
unique identification in each attribute table