| TerraLib 4.1

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files
- Examples

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Protected Member Functions
TeCoverageDecoderDatabase< T > Class Template Reference

Class to decode a generic Coverage from a TerraLib database. More...

`#include <TeCoverageDecoderDatabase.h>`

Inheritance diagram for TeCoverageDecoderDatabase< T >:

List of all members.

## Public Member Functions

| TeCoverageDecoderDatabase (TeCoverageParams &params)
| Constructor from parameters.
virtual void | init ()
| Initialize internal structures.
void | selectBlocks (const TePolygon &poly, const TeSpatialRelation relation, std::vector< TeCoverageBlock< T > > &selected, std::set< int > &dontSelect)
| Select generic coverage blocks from the database.

## Protected Member Functions

TeGeomValuePair< T > | decodeGeomValuePair (unsigned char *&data, std::vector< TeCoverageDimension > &dimensions)
| Decode a generic geometry-value pair.
TeCoverageBlock< T > | decodeCoverageBlock (unsigned char *&data, const long dataSize, std::vector< TeCoverageDimension > &dimensions)
| Decode a generic coverage block.

## Detailed Description

### template<class T>
class TeCoverageDecoderDatabase< T >

Class to decode a generic Coverage from a TerraLib database.

## Constructor & Destructor Documentation

template<class T >

TeCoverageDecoderDatabase< T >::TeCoverageDecoderDatabase | ( | TeCoverageParams & | params | ) | `[inline]`

Constructor from parameters.

## Member Function Documentation

template<class T >

TeCoverageBlock<T> TeCoverageDecoderDatabase< T >::decodeCoverageBlock | ( | unsigned char *& | data,
|  | const long | dataSize,
|  | std::vector< TeCoverageDimension > & | dimensions
| ) |  | `[inline, protected]`

Decode a generic coverage block.

Decode coverage block contents that are stored in the database
  as raw binary data. As a side effect, the pointer to the data is moved forward to the end of the decoded chunk.

Parameters:

  data | pointer to the memory location where the raw data starts
  dataSize | size of the raw data block to be decoded
  dimensions | information about the coverage dimensions

Returns:
  a generic coverage block

template<class T >

TeGeomValuePair< TePolygon > TeCoverageDecoderDatabase< T >::decodeGeomValuePair | ( | unsigned char *& | data,
|  | std::vector< TeCoverageDimension > & | dimensions
| ) |  | `[protected]`

Decode a generic geometry-value pair.

Specialization for decoding a TePolygon instead of a generic geometry.

Specialization for decoding a TeLine2D instead of a generic geometry.

Specialization for decoding a TePoint instead of a generic geometry.

Decode a generic geometry-value pair from a block of raw data.
  As a side effect, the pointer to the data is moved forward to the end of the decoded chunk.

Parameters:

  data | pointer to the memory location where the raw data starts
  dimensions | information about the coverage dimensions

Returns:
  a generic geometry-value pair

template<class T >

virtual void TeCoverageDecoderDatabase< T >::init | ( |  | ) | `[inline, virtual]`

Initialize internal structures.

Instantiate internal structures, must be called before any attempt to access the coverage data.

Reimplemented from TeCoverageDecoder< T >.

template<class T >

void TeCoverageDecoderDatabase< T >::selectBlocks | ( | const TePolygon & | poly,
|  | const TeSpatialRelation | relation,
|  | std::vector< TeCoverageBlock< T > > & | selected,
|  | std::set< int > & | dontSelect
| ) |  | `[inline, virtual]`

Select generic coverage blocks from the database.

Select generic coverage blocks from a TerraLib database. Uses
  a TeBlockLoader object for retrieving blocks from the database.

The polygon parameter defines a selection area and the relation
  parameter specifies the kind of relation (e.g. intersection, crossing, overlapping) that holds between the selection area and at least one geometry in each block to be selected.

Parameters:

  poly | an instance of TePolygon representing a selection area
  relation | a spatial relation
  dontSelect | list IDs of blocks that must not be retrieved

See also:
  TeCoverageBlock TeSpatialRelation TeBlockLoader

Implements TeCoverageDecoder< T >.

The documentation for this class was generated from the following file:

- E:/Projetos_Primeiro_Semestre_2012/TerraView/terralib/src/terralib/kernel/TeCoverageDecoderDatabase.h

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines