OSSIM - Open Source Software Image Map  Version 1.9.0 (20180803)
Public Member Functions | Protected Attributes | List of all members
ossimplugins::EnvisatAsarRecordFactory Class Reference

This class is a factory able to construct Record base classes given the id of the record wanted. More...

#include <EnvisatAsarRecordFactory.h>

Inheritance diagram for ossimplugins::EnvisatAsarRecordFactory:
ossimplugins::EnvisatAsarDataFactory

Public Member Functions

 EnvisatAsarRecordFactory ()
 Constructor. More...
 
 ~EnvisatAsarRecordFactory ()
 Destructor. More...
 
void RegisterRecord (std::string id, EnvisatAsarRecord *record)
 Adds a new Record type available in this factory. More...
 
EnvisatAsarRecordInstanciate (std::string id)
 Instanciatse a new Record. More...
 

Protected Attributes

std::map< std::string, EnvisatAsarRecord * > _availableRecords
 Contains all the available Records for the factory. More...
 

Detailed Description

This class is a factory able to construct Record base classes given the id of the record wanted.

Definition at line 26 of file EnvisatAsarRecordFactory.h.

Constructor & Destructor Documentation

◆ EnvisatAsarRecordFactory()

ossimplugins::EnvisatAsarRecordFactory::EnvisatAsarRecordFactory ( )

Constructor.

Definition at line 16 of file EnvisatAsarRecordFactory.cpp.

17 {
18 }

◆ ~EnvisatAsarRecordFactory()

ossimplugins::EnvisatAsarRecordFactory::~EnvisatAsarRecordFactory ( )

Destructor.

Definition at line 20 of file EnvisatAsarRecordFactory.cpp.

21 {
22 }

Member Function Documentation

◆ Instanciate()

EnvisatAsarRecord * ossimplugins::EnvisatAsarRecordFactory::Instanciate ( std::string  id)

Instanciatse a new Record.

Parameters
idId of the Record we want to instanciate

Definition at line 24 of file EnvisatAsarRecordFactory.cpp.

References _availableRecords, and ossimplugins::EnvisatAsarRecord::Instanciate().

Referenced by ossimplugins::operator>>().

25 {
26  EnvisatAsarRecord* record = _availableRecords[id];
27  if(record == NULL)
28  {
29  return NULL;
30  }
31  else
32  {
33  return record->Instanciate();
34  }
35 }
std::map< std::string, EnvisatAsarRecord * > _availableRecords
Contains all the available Records for the factory.

◆ RegisterRecord()

void ossimplugins::EnvisatAsarRecordFactory::RegisterRecord ( std::string  id,
EnvisatAsarRecord record 
)

Adds a new Record type available in this factory.

Parameters
recordRecord to add in the factory
idId of the new avalaible Record

Definition at line 37 of file EnvisatAsarRecordFactory.cpp.

References _availableRecords.

Referenced by ossimplugins::EnvisatAsarDataFactory::EnvisatAsarDataFactory().

38 {
39  _availableRecords[id] = record;
40 }
std::map< std::string, EnvisatAsarRecord * > _availableRecords
Contains all the available Records for the factory.

Member Data Documentation

◆ _availableRecords

std::map<std::string, EnvisatAsarRecord*> ossimplugins::EnvisatAsarRecordFactory::_availableRecords
protected

Contains all the available Records for the factory.

Definition at line 55 of file EnvisatAsarRecordFactory.h.

Referenced by Instanciate(), and RegisterRecord().


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