This class implements the strategy to iterate with spatial restriction, the iteration occurs inside a polygon. More...
#include <PositionIterator.h>
  
 Public Member Functions | |
| unsigned int | getColumn () const | 
| Returns the current column in iterator.  More... | |
| unsigned int | getRow () const | 
| Returns the current row in iterator.  More... | |
| bool | operator!= (const PolygonIterator< T > &rhs) const | 
| bool | operator!= (const AbstractPositionIterator< T > &rhs) const | 
| Difference operator.  More... | |
| std::complex< T > | operator() (const unsigned int i) const | 
| Returns the complex value in current position (column, row, band) from iterator.  More... | |
| const std::vector< T > | operator* () const | 
| Returns a vector of the values in current position (column, row) from iterator.  More... | |
| void | operator++ () | 
| Advances to the next position.  More... | |
| void | operator-- () | 
| Returns to the previous position.  More... | |
| PolygonIterator & | operator= (const PolygonIterator &rhs) | 
| AbstractPositionIterator< T > & | operator= (const AbstractPositionIterator< T > &rhs) | 
| Assignment operator.  More... | |
| T | operator[] (const unsigned int i) const | 
| Returns the real value in current position (column, row, band) from iterator.  More... | |
| PolygonIterator () | |
| PolygonIterator (const te::rst::Raster *r, const te::gm::Polygon *p) | |
| Constructor.  More... | |
| PolygonIterator (const PolygonIterator &rhs) | |
| Copy constructor.  More... | |
| void | setEnd () | 
| Sets the iterator position to the end of the current band.  More... | |
| void | setNextLine (bool updatecurrline=true) | 
| ~PolygonIterator () | |
Static Public Member Functions | |
| static PolygonIterator | begin (const te::rst::Raster *r, const te::gm::Polygon *p) | 
| Returns an iterator referring to the first value of the band.  More... | |
| static PolygonIterator | end (const te::rst::Raster *r, const te::gm::Polygon *p) | 
| Returns an iterator referring to after the end of the iterator.  More... | |
Protected Member Functions | |
| void | clear () | 
| Clear all internal allocated objects and reset back to the initial state.  More... | |
Protected Attributes | |
| int | m_actualintersection | 
| The actual line of the iterator.  More... | |
| int | m_column | 
| The current column of the iterator.  More... | |
| std::vector< std::pair< int, int > > | m_columns | 
| Coordinates of the columns to be transversed.  More... | |
| te::gm::Line * | m_currline | 
| The current line in the iterator.  More... | |
| int | m_endingcolumn | 
| The column (in current line) to finalize the iteration.  More... | |
| int | m_endingrow | 
| The ending row of the iteration.  More... | |
| int | m_maxcolumns | 
| The number of columns in band.  More... | |
| int | m_maxrows | 
| The number of rows in band.  More... | |
| int | m_nintersections | 
| The number number of intersected lines in current line of the iterator.  More... | |
| double | m_operatorBrackets_value | 
| std::complex< double > | m_operatorParenthesis_value | 
| const te::gm::Polygon * | m_polygon | 
| The spatial restriction to be applied in the iterator.  More... | |
| const te::rst::Raster * | m_raster | 
| The band from where to get the values.  More... | |
| int | m_row | 
| The current row of the iterator.  More... | |
| int | m_startingcolumn | 
| The starting column (in current line) to initialize the iteration.  More... | |
| int | m_startingrow | 
| The starting row of the iteration.  More... | |
| std::unique_ptr< te::rst::TileIndexer > | m_tileIndexer | 
| Tile indexer used to optimize the geometric operations.  More... | |
This class implements the strategy to iterate with spatial restriction, the iteration occurs inside a polygon.
Definition at line 156 of file PositionIterator.h.
| te::rst::PolygonIterator< T >::PolygonIterator | ( | ) | 
Definition at line 407 of file PositionIterator.h.
| te::rst::PolygonIterator< T >::PolygonIterator | ( | const te::rst::Raster * | r, | 
| const te::gm::Polygon * | p | ||
| ) | 
Constructor.
| b | The band to iterate. | 
| p | The polygon from where the iteration will navigate. | 
Definition at line 424 of file PositionIterator.h.
References te::rst::Grid::geoToGrid(), te::rst::Grid::getExtent(), te::rst::Raster::getGrid(), te::gm::Envelope::getLowerLeft(), te::gm::Geometry::getMBR(), te::rst::Grid::getNumberOfRows(), te::rst::Grid::getResolutionY(), te::rst::Raster::getSRID(), te::gm::Geometry::getSRID(), te::gm::Envelope::getUpperRight(), te::gm::LineStringType, te::rst::PolygonIterator< T >::m_column, te::rst::PolygonIterator< T >::m_currline, te::rst::PolygonIterator< T >::m_endingrow, te::gm::Envelope::m_llx, te::gm::Envelope::m_lly, te::rst::PolygonIterator< T >::m_polygon, te::rst::PolygonIterator< T >::m_row, te::rst::PolygonIterator< T >::m_startingcolumn, te::rst::PolygonIterator< T >::m_startingrow, te::rst::PolygonIterator< T >::m_tileIndexer, te::gm::Envelope::m_urx, te::gm::Envelope::m_ury, te::rst::PolygonIterator< T >::setEnd(), te::rst::PolygonIterator< T >::setNextLine(), TE_TR, te::gm::Coord2D::x, and te::gm::Coord2D::y.
| te::rst::PolygonIterator< T >::PolygonIterator | ( | const PolygonIterator< T > & | rhs | ) | 
Copy constructor.
| rhs | The right-hand-side copy used to copy from. | 
Definition at line 506 of file PositionIterator.h.
References te::rst::PolygonIterator< T >::operator=().
| te::rst::PolygonIterator< T >::~PolygonIterator | ( | ) | 
Definition at line 524 of file PositionIterator.h.
      
  | 
  static | 
Returns an iterator referring to the first value of the band.
Definition at line 952 of file PositionIterator.h.
      
  | 
  protected | 
Clear all internal allocated objects and reset back to the initial state.
Definition at line 978 of file PositionIterator.h.
      
  | 
  static | 
Returns an iterator referring to after the end of the iterator.
Definition at line 957 of file PositionIterator.h.
References te::rst::PolygonIterator< T >::setEnd().
      
  | 
  virtual | 
Returns the current column in iterator.
Implements te::rst::AbstractPositionIterator< T >.
Definition at line 852 of file PositionIterator.h.
      
  | 
  virtual | 
Returns the current row in iterator.
Implements te::rst::AbstractPositionIterator< T >.
Definition at line 847 of file PositionIterator.h.
| bool te::rst::PolygonIterator< T >::operator!= | ( | const PolygonIterator< T > & | rhs | ) | const | 
Definition at line 966 of file PositionIterator.h.
References te::rst::PolygonIterator< T >::m_column, and te::rst::PolygonIterator< T >::m_row.
      
  | 
  virtual | 
Difference operator.
| rhs | The right-hand side to compare. | 
Implements te::rst::AbstractPositionIterator< T >.
Definition at line 972 of file PositionIterator.h.
References operator!=().
      
  | 
  virtual | 
Returns the complex value in current position (column, row, band) from iterator.
| i | The band index. | 
Implements te::rst::AbstractPositionIterator< T >.
Definition at line 840 of file PositionIterator.h.
      
  | 
  virtual | 
Returns a vector of the values in current position (column, row) from iterator.
Implements te::rst::AbstractPositionIterator< T >.
Definition at line 819 of file PositionIterator.h.
      
  | 
  virtual | 
Advances to the next position.
Implements te::rst::AbstractPositionIterator< T >.
Definition at line 857 of file PositionIterator.h.
      
  | 
  virtual | 
Returns to the previous position.
Implements te::rst::AbstractPositionIterator< T >.
Definition at line 881 of file PositionIterator.h.
References TE_TR.
| te::rst::PolygonIterator< T > & te::rst::PolygonIterator< T >::operator= | ( | const PolygonIterator< T > & | rhs | ) | 
Definition at line 908 of file PositionIterator.h.
References te::gm::Line::clone(), te::rst::PolygonIterator< T >::m_actualintersection, te::rst::PolygonIterator< T >::m_column, te::rst::PolygonIterator< T >::m_currline, te::rst::PolygonIterator< T >::m_endingcolumn, te::rst::PolygonIterator< T >::m_endingrow, te::rst::PolygonIterator< T >::m_maxcolumns, te::rst::PolygonIterator< T >::m_maxrows, te::rst::PolygonIterator< T >::m_nintersections, te::rst::PolygonIterator< T >::m_polygon, te::rst::PolygonIterator< T >::m_row, te::rst::PolygonIterator< T >::m_startingcolumn, te::rst::PolygonIterator< T >::m_startingrow, and te::rst::AbstractPositionIterator< T >::operator=().
Referenced by te::rst::PolygonIterator< T >::PolygonIterator().
      
  | 
  virtual | 
Assignment operator.
| rhs | The right-hand-side copy used to copy from. | 
Reimplemented from te::rst::AbstractPositionIterator< T >.
Definition at line 940 of file PositionIterator.h.
      
  | 
  virtual | 
Returns the real value in current position (column, row, band) from iterator.
| i | The band index. | 
Implements te::rst::AbstractPositionIterator< T >.
Definition at line 833 of file PositionIterator.h.
      
  | 
  virtual | 
Sets the iterator position to the end of the current band.
| b | The band to retrieve the end information. | 
Implements te::rst::AbstractPositionIterator< T >.
Definition at line 946 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::end(), and te::rst::PolygonIterator< T >::PolygonIterator().
| void te::rst::PolygonIterator< T >::setNextLine | ( | bool | updatecurrline = true | ) | 
Definition at line 529 of file PositionIterator.h.
References te::gm::LineString::getEndPoint(), te::gm::Geometry::getSRID(), te::gm::LineString::getStartPoint(), te::gm::LineString::getX(), te::gm::LineString::getY(), te::gm::LineStringType, te::gm::Multi2Single(), te::gm::PointType, te::rst::StdSortPointPointerComparison(), and TE_LOG_WARN.
Referenced by te::rst::PolygonIterator< T >::PolygonIterator().
      
  | 
  protected | 
The actual line of the iterator.
Definition at line 225 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::operator=().
      
  | 
  protected | 
The current column of the iterator.
Definition at line 217 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::operator!=(), te::rst::PolygonIterator< T >::operator=(), and te::rst::PolygonIterator< T >::PolygonIterator().
      
  | 
  protected | 
Coordinates of the columns to be transversed.
Definition at line 228 of file PositionIterator.h.
      
  | 
  protected | 
The current line in the iterator.
Definition at line 216 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::operator=(), and te::rst::PolygonIterator< T >::PolygonIterator().
      
  | 
  protected | 
The column (in current line) to finalize the iteration.
Definition at line 220 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::operator=().
      
  | 
  protected | 
The ending row of the iteration.
Definition at line 222 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::operator=(), and te::rst::PolygonIterator< T >::PolygonIterator().
      
  | 
  protected | 
The number of columns in band.
Definition at line 223 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::operator=().
      
  | 
  protected | 
The number of rows in band.
Definition at line 224 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::operator=().
      
  | 
  protected | 
The number number of intersected lines in current line of the iterator.
Definition at line 226 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::operator=().
      
  | 
  mutableprotected | 
Definition at line 231 of file PositionIterator.h.
      
  | 
  mutableprotected | 
Definition at line 232 of file PositionIterator.h.
      
  | 
  protected | 
The spatial restriction to be applied in the iterator.
Definition at line 215 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::operator=(), and te::rst::PolygonIterator< T >::PolygonIterator().
      
  | 
  protected | 
The band from where to get the values.
Definition at line 214 of file PositionIterator.h.
      
  | 
  protected | 
The current row of the iterator.
Definition at line 218 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::operator!=(), te::rst::PolygonIterator< T >::operator=(), and te::rst::PolygonIterator< T >::PolygonIterator().
      
  | 
  protected | 
The starting column (in current line) to initialize the iteration.
Definition at line 219 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::operator=(), and te::rst::PolygonIterator< T >::PolygonIterator().
      
  | 
  protected | 
The starting row of the iteration.
Definition at line 221 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::operator=(), and te::rst::PolygonIterator< T >::PolygonIterator().
      
  | 
  protected | 
Tile indexer used to optimize the geometric operations.
Definition at line 227 of file PositionIterator.h.
Referenced by te::rst::PolygonIterator< T >::PolygonIterator().