OTB
9.0.0
Orfeo Toolbox
|
#include <otbDataNode.h>
Classes | |
struct | DataType |
Public Types | |
typedef itk::SmartPointer< const Self > | ConstPointer |
typedef itk::SmartPointer< Self > | Pointer |
typedef DataNode | Self |
typedef itk::Object | Superclass |
typedef TPrecision | PrecisionType |
typedef TValuePrecision | ValuePrecisionType |
typedef itk::Point< PrecisionType, VDimension > | PointType |
typedef otb::PolyLineParametricPathWithValue< ValuePrecisionType, VDimension > | LineType |
typedef LineType::Pointer | LinePointerType |
typedef LineType::ConstPointer | LineConstPointerType |
typedef Polygon< ValuePrecisionType > | PolygonType |
typedef PolygonType::VertexListType | VertexListType |
typedef VertexListType::ConstPointer | VertexListConstPointerType |
typedef PolygonType::Pointer | PolygonPointerType |
typedef PolygonType::ConstPointer | PolygonConstPointerType |
typedef ObjectList< PolygonType > | PolygonListType |
typedef PolygonListType::Pointer | PolygonListPointerType |
typedef PolygonListType::ConstPointer | PolygonListConstPointerType |
static const unsigned int | Dimension = VDimension |
NodeType | m_NodeType |
std::string | m_NodeId |
DataType | m_Data |
static Pointer | New () |
virtual ::itk::LightObject::Pointer | CreateAnother (void) const |
virtual const char * | GetNameOfClass () const |
virtual NodeType | GetNodeType () const |
virtual const char * | GetNodeId () const |
virtual void | SetNodeId (const char *_arg) |
void | SetNodeType (NodeType type) |
std::string | GetNodeTypeAsString () const |
PointType | GetPoint () const |
LinePointerType | GetLine () const |
PolygonPointerType | GetPolygonExteriorRing () const |
PolygonListPointerType | GetPolygonInteriorRings () const |
void | SetPoint (PointType point) |
void | SetLine (LineType *line) |
void | SetPolygonExteriorRing (PolygonType *polygon) |
void | SetPolygonInteriorRings (PolygonListType *polygonList) |
bool | IsDocument () const |
bool | IsRoot () const |
bool | IsFolder () const |
bool | IsPointFeature () const |
bool | IsLineFeature () const |
bool | IsPolygonFeature () const |
bool | IsMultiPointFeature () const |
bool | IsMultiLineFeature () const |
bool | IsMultiPolygonFeature () const |
bool | IsCollectionFeature () const |
void | SetFieldAsString (const std::string &key, const std::string &value) |
std::string | GetFieldAsString (const std::string &key) const |
void | SetFieldAsInt (const std::string &key, int value) |
int | GetFieldAsInt (const std::string &key) const |
void | SetFieldAsDouble (const std::string &key, double value) |
double | GetFieldAsDouble (const std::string &key) const |
bool | HasField (const std::string &key) const |
void | CopyFieldList (const DataNode *dataNode) |
std::vector< std::string > | GetFieldList () const |
double | EuclideanDistanceMetric (const DataNode *node) |
double | EuclideanDistanceMetric (const PointType point) |
bool | Intersects (const DataNode *node) |
bool | Within (const DataNode *node) |
DataNode () | |
~DataNode () override | |
void | PrintSelf (std::ostream &os, itk::Indent indent) const override |
OGRGeometry * | ConvertDataNodeToOGRGeometry (const DataNode *dataNode) |
DataNode (const Self &)=delete | |
void | operator= (const Self &)=delete |
This class represents a node of data in a vector data hierarchy.
A DataNode has a type represented by the NodeType enumeration. Depending on its type, it can have associated data such as Point, Line or Polygon.
A flag indicates if the data are valid or not.
A DataNode has also a dictionary of fields which can be used to store associated data. Depending on the writing vector data file format, fields will be used by the writing driver.
The three templates indicate
Definition at line 73 of file otbDataNode.h.
typedef itk::SmartPointer<const Self> otb::DataNode< TPrecision, VDimension, TValuePrecision >::ConstPointer |
Definition at line 80 of file otbDataNode.h.
typedef LineType::ConstPointer otb::DataNode< TPrecision, VDimension, TValuePrecision >::LineConstPointerType |
Template parameters typedefs
Definition at line 96 of file otbDataNode.h.
typedef LineType::Pointer otb::DataNode< TPrecision, VDimension, TValuePrecision >::LinePointerType |
Template parameters typedefs
Definition at line 95 of file otbDataNode.h.
typedef otb::PolyLineParametricPathWithValue<ValuePrecisionType, VDimension> otb::DataNode< TPrecision, VDimension, TValuePrecision >::LineType |
Template parameters typedefs
Definition at line 94 of file otbDataNode.h.
typedef itk::SmartPointer<Self> otb::DataNode< TPrecision, VDimension, TValuePrecision >::Pointer |
Definition at line 79 of file otbDataNode.h.
typedef itk::Point<PrecisionType, VDimension> otb::DataNode< TPrecision, VDimension, TValuePrecision >::PointType |
Internal data typedef
Definition at line 93 of file otbDataNode.h.
typedef PolygonType::ConstPointer otb::DataNode< TPrecision, VDimension, TValuePrecision >::PolygonConstPointerType |
Template parameters typedefs
Definition at line 101 of file otbDataNode.h.
typedef PolygonListType::ConstPointer otb::DataNode< TPrecision, VDimension, TValuePrecision >::PolygonListConstPointerType |
Template parameters typedefs
Definition at line 104 of file otbDataNode.h.
typedef PolygonListType::Pointer otb::DataNode< TPrecision, VDimension, TValuePrecision >::PolygonListPointerType |
Template parameters typedefs
Definition at line 103 of file otbDataNode.h.
typedef ObjectList<PolygonType> otb::DataNode< TPrecision, VDimension, TValuePrecision >::PolygonListType |
Template parameters typedefs
Definition at line 102 of file otbDataNode.h.
typedef PolygonType::Pointer otb::DataNode< TPrecision, VDimension, TValuePrecision >::PolygonPointerType |
Template parameters typedefs
Definition at line 100 of file otbDataNode.h.
typedef Polygon<ValuePrecisionType> otb::DataNode< TPrecision, VDimension, TValuePrecision >::PolygonType |
Template parameters typedefs
Definition at line 97 of file otbDataNode.h.
typedef TPrecision otb::DataNode< TPrecision, VDimension, TValuePrecision >::PrecisionType |
Template parameters typedefs
Definition at line 84 of file otbDataNode.h.
typedef DataNode otb::DataNode< TPrecision, VDimension, TValuePrecision >::Self |
Standard class typedef
Definition at line 77 of file otbDataNode.h.
typedef itk::Object otb::DataNode< TPrecision, VDimension, TValuePrecision >::Superclass |
Definition at line 78 of file otbDataNode.h.
typedef TValuePrecision otb::DataNode< TPrecision, VDimension, TValuePrecision >::ValuePrecisionType |
Template parameters typedefs
Definition at line 89 of file otbDataNode.h.
typedef VertexListType::ConstPointer otb::DataNode< TPrecision, VDimension, TValuePrecision >::VertexListConstPointerType |
Template parameters typedefs
Definition at line 99 of file otbDataNode.h.
typedef PolygonType::VertexListType otb::DataNode< TPrecision, VDimension, TValuePrecision >::VertexListType |
Template parameters typedefs
Definition at line 98 of file otbDataNode.h.
|
protected |
|
inlineoverrideprotected |
Destructor
Definition at line 315 of file otbDataNode.h.
|
privatedelete |
Template parameters typedefs
|
protected |
Template parameters typedefs
Definition at line 453 of file otbDataNode.hxx.
References otb::FEATURE_LINE, otb::FEATURE_POINT, otb::FEATURE_POLYGON, otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetLine(), otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetNodeType(), otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetPoint(), and otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetPolygonExteriorRing().
void otb::DataNode< TPrecision, VDimension, TValuePrecision >::CopyFieldList | ( | const DataNode< TPrecision, VDimension, TValuePrecision > * | dataNode | ) |
Copy the field list from a DataNode
dataNode | datanode where to get the keywordlist to copy. |
Definition at line 361 of file otbDataNode.hxx.
References otb::VectorDataKeywordlist::CopyFieldList(), and otb::MetaDataKey::VectorDataKeywordlistKey.
virtual::itk::LightObject::Pointer otb::DataNode< TPrecision, VDimension, TValuePrecision >::CreateAnother | ( | void | ) | const |
Template parameters typedefs
double otb::DataNode< TPrecision, VDimension, TValuePrecision >::EuclideanDistanceMetric | ( | const DataNode< TPrecision, VDimension, TValuePrecision > * | node | ) |
Definition at line 524 of file otbDataNode.hxx.
double otb::DataNode< TPrecision, VDimension, TValuePrecision >::EuclideanDistanceMetric | ( | const PointType | point | ) |
Template parameters typedefs
Definition at line 535 of file otbDataNode.hxx.
double otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetFieldAsDouble | ( | const std::string & | key | ) | const |
Returns the value associated with a field name.
key | The name of the field. |
Definition at line 250 of file otbDataNode.hxx.
References otb::VectorDataKeywordlist::GetFieldAsDouble(), and otb::MetaDataKey::VectorDataKeywordlistKey.
int otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetFieldAsInt | ( | const std::string & | key | ) | const |
Returns the value associated with a field name.
key | The name of the field. |
Definition at line 291 of file otbDataNode.hxx.
References otb::VectorDataKeywordlist::GetFieldAsInt(), and otb::MetaDataKey::VectorDataKeywordlistKey.
std::string otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetFieldAsString | ( | const std::string & | key | ) | const |
Returns the value associated with a field name.
key | The name of the field. |
Definition at line 279 of file otbDataNode.hxx.
References otb::VectorDataKeywordlist::GetFieldAsString(), and otb::MetaDataKey::VectorDataKeywordlistKey.
std::vector< std::string > otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetFieldList |
Definition at line 375 of file otbDataNode.hxx.
References otb::VectorDataKeywordlist::GetFieldList(), and otb::MetaDataKey::VectorDataKeywordlistKey.
DataNode< TPrecision, VDimension, TValuePrecision >::LinePointerType otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetLine |
Get the line data, when valid.
Definition at line 97 of file otbDataNode.hxx.
Referenced by otb::DataNode< TPrecision, VDimension, TValuePrecision >::ConvertDataNodeToOGRGeometry().
|
virtual |
Template parameters typedefs
|
virtual |
Template parameters typedefs
|
virtual |
Fields typedef Accessors
Referenced by otb::DataNode< TPrecision, VDimension, TValuePrecision >::ConvertDataNodeToOGRGeometry().
std::string otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetNodeTypeAsString |
Definition at line 146 of file otbDataNode.hxx.
References otb::DOCUMENT, otb::FEATURE_COLLECTION, otb::FEATURE_LINE, otb::FEATURE_MULTILINE, otb::FEATURE_MULTIPOINT, otb::FEATURE_MULTIPOLYGON, otb::FEATURE_POINT, otb::FEATURE_POLYGON, otb::FOLDER, otb::ROOT, and otb::MetaDataKey::VectorDataKeywordlistKey.
DataNode< TPrecision, VDimension, TValuePrecision >::PointType otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetPoint |
Get the point data, when valid.
Definition at line 84 of file otbDataNode.hxx.
Referenced by otb::DataNode< TPrecision, VDimension, TValuePrecision >::ConvertDataNodeToOGRGeometry().
DataNode< TPrecision, VDimension, TValuePrecision >::PolygonPointerType otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetPolygonExteriorRing |
Get the polygon exterior ring data, when valid.
Definition at line 111 of file otbDataNode.hxx.
Referenced by otb::DataNode< TPrecision, VDimension, TValuePrecision >::ConvertDataNodeToOGRGeometry().
DataNode< TPrecision, VDimension, TValuePrecision >::PolygonListPointerType otb::DataNode< TPrecision, VDimension, TValuePrecision >::GetPolygonInteriorRings |
Get the polygon interior rings data, when valid.
Definition at line 126 of file otbDataNode.hxx.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::HasField | ( | const std::string & | key | ) | const |
Remove the field associated with the given key, if possible.
key | The name of the field. |
key | The name of the field. |
Definition at line 321 of file otbDataNode.hxx.
References otb::VectorDataKeywordlist::HasField(), and otb::MetaDataKey::VectorDataKeywordlistKey.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::Intersects | ( | const DataNode< TPrecision, VDimension, TValuePrecision > * | node | ) |
Definition at line 550 of file otbDataNode.hxx.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::IsCollectionFeature |
Definition at line 446 of file otbDataNode.hxx.
References otb::FEATURE_COLLECTION.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::IsDocument |
Definition at line 397 of file otbDataNode.hxx.
References otb::DOCUMENT.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::IsFolder |
Definition at line 407 of file otbDataNode.hxx.
References otb::FOLDER.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::IsLineFeature |
Definition at line 417 of file otbDataNode.hxx.
References otb::FEATURE_LINE.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::IsMultiLineFeature |
Definition at line 434 of file otbDataNode.hxx.
References otb::FEATURE_MULTILINE.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::IsMultiPointFeature |
Definition at line 428 of file otbDataNode.hxx.
References otb::FEATURE_MULTIPOINT.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::IsMultiPolygonFeature |
Definition at line 440 of file otbDataNode.hxx.
References otb::FEATURE_MULTIPOLYGON.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::IsPointFeature |
Definition at line 412 of file otbDataNode.hxx.
References otb::FEATURE_POINT.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::IsPolygonFeature |
Definition at line 422 of file otbDataNode.hxx.
References otb::FEATURE_POLYGON.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::IsRoot |
Definition at line 402 of file otbDataNode.hxx.
References otb::ROOT.
|
static |
Standard macro
|
privatedelete |
Template parameters typedefs
|
overrideprotected |
PrintSelf method
Definition at line 140 of file otbDataNode.hxx.
void otb::DataNode< TPrecision, VDimension, TValuePrecision >::SetFieldAsDouble | ( | const std::string & | key, |
double | value | ||
) |
Add a field to the node.
key | The name of the field. |
value | The value of the field. |
Definition at line 240 of file otbDataNode.hxx.
References otb::VectorDataKeywordlist::SetFieldAsDouble(), and otb::MetaDataKey::VectorDataKeywordlistKey.
void otb::DataNode< TPrecision, VDimension, TValuePrecision >::SetFieldAsInt | ( | const std::string & | key, |
int | value | ||
) |
Add a field to the node.
key | The name of the field. |
value | The value of the field. |
Definition at line 231 of file otbDataNode.hxx.
References otb::VectorDataKeywordlist::SetFieldAsInt(), and otb::MetaDataKey::VectorDataKeywordlistKey.
void otb::DataNode< TPrecision, VDimension, TValuePrecision >::SetFieldAsString | ( | const std::string & | key, |
const std::string & | value | ||
) |
Add a field to the node.
key | The name of the field. |
value | The value of the field. |
Definition at line 222 of file otbDataNode.hxx.
References otb::VectorDataKeywordlist::SetFieldAsString(), and otb::MetaDataKey::VectorDataKeywordlistKey.
void otb::DataNode< TPrecision, VDimension, TValuePrecision >::SetLine | ( | LineType * | line | ) |
Set the line data. Node type is automatically set to FEATURE_LINE.
line | The line. |
Definition at line 53 of file otbDataNode.hxx.
References otb::FEATURE_LINE.
|
virtual |
Template parameters typedefs
void otb::DataNode< TPrecision, VDimension, TValuePrecision >::SetNodeType | ( | NodeType | type | ) |
void otb::DataNode< TPrecision, VDimension, TValuePrecision >::SetPoint | ( | PointType | point | ) |
Set the point data. Node type is automatically set to FEATURE_POINT.
point | the point. |
Definition at line 45 of file otbDataNode.hxx.
References otb::FEATURE_POINT.
void otb::DataNode< TPrecision, VDimension, TValuePrecision >::SetPolygonExteriorRing | ( | PolygonType * | polygon | ) |
Set the polygon exterior ring. Node type is automatically set to FEATURE_POLYGON.
polygon | The polygon exterior ring. |
Definition at line 60 of file otbDataNode.hxx.
References otb::FEATURE_POLYGON.
void otb::DataNode< TPrecision, VDimension, TValuePrecision >::SetPolygonInteriorRings | ( | PolygonListType * | polygonList | ) |
Set the polygon interior rings. Node type is automatically set to FEATURE_POLYGON.
polygonList | The polygon interior rings list. |
Definition at line 72 of file otbDataNode.hxx.
References otb::FEATURE_POLYGON.
bool otb::DataNode< TPrecision, VDimension, TValuePrecision >::Within | ( | const DataNode< TPrecision, VDimension, TValuePrecision > * | node | ) |
Definition at line 561 of file otbDataNode.hxx.
|
static |
Template parameters typedefs
Definition at line 90 of file otbDataNode.h.
|
private |
The data associated with the node
Definition at line 345 of file otbDataNode.h.
|
private |
The node id
Definition at line 342 of file otbDataNode.h.
|
private |
The node type
Definition at line 339 of file otbDataNode.h.