All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
te::rst::RasterSummaryManager Class Reference

A singleton for keeping raster summaries (most statistics). It stores an internal map of raster references and their respective summaries. More...

#include <RasterSummaryManager.h>

Inheritance diagram for te::rst::RasterSummaryManager:
te::common::Singleton< RasterSummaryManager >

Public Member Functions

void add (const Raster *raster, RasterSummary *summary)
 Adds a new entry in the summary manager. More...
 
const RasterSummaryfind (const Raster *raster) const
 It searches for a raster summary. More...
 
const RasterSummaryget (const Raster *raster, const SummaryTypes st)
 It searches for a raster summary. If not found it creates the summary and returns it. More...
 
void remove (const Raster *raster)
 Removes the summary from the specified raster. More...
 
 ~RasterSummaryManager ()
 Destructor. More...
 

Static Public Member Functions

static RasterSummaryManagergetInstance ()
 It returns a reference to the singleton instance. More...
 

Protected Member Functions

 RasterSummaryManager ()
 Constructor. More...
 

Private Attributes

boost::ptr_map< const Raster
*, RasterSummary
m_rasterSummaries
 A map of rasters and their respective summaries. More...
 

Friends

class te::common::Singleton< RasterSummaryManager >
 

Detailed Description

A singleton for keeping raster summaries (most statistics). It stores an internal map of raster references and their respective summaries.

See also
RasterSummary, BandSummary.

Definition at line 56 of file RasterSummaryManager.h.

Constructor & Destructor Documentation

te::rst::RasterSummaryManager::~RasterSummaryManager ( )

Destructor.

Definition at line 133 of file RasterSummaryManager.cpp.

te::rst::RasterSummaryManager::RasterSummaryManager ( )
protected

Constructor.

Definition at line 137 of file RasterSummaryManager.cpp.

Member Function Documentation

void te::rst::RasterSummaryManager::add ( const Raster raster,
RasterSummary summary 
)

Adds a new entry in the summary manager.

Parameters
rasterThe raster to be added.
summaryThe raster summary of the respective raster. The manager will take its ownership.
Note
If the raster was already added, the summary will be replaced.

Definition at line 35 of file RasterSummaryManager.cpp.

References m_rasterSummaries.

const te::rst::RasterSummary * te::rst::RasterSummaryManager::find ( const Raster raster) const

It searches for a raster summary.

Parameters
rasterThe raster to be found.
Returns
The calculated raster summary, or a null summary otherwise.

Definition at line 43 of file RasterSummaryManager.cpp.

void te::rst::RasterSummaryManager::remove ( const Raster raster)

Removes the summary from the specified raster.

Parameters
rasterThe raster to remove the summary.

Definition at line 51 of file RasterSummaryManager.cpp.

Friends And Related Function Documentation

Definition at line 58 of file RasterSummaryManager.h.

Member Data Documentation

boost::ptr_map<const Raster*, RasterSummary> te::rst::RasterSummaryManager::m_rasterSummaries
private

A map of rasters and their respective summaries.

Definition at line 109 of file RasterSummaryManager.h.

Referenced by add().


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