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

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

#include <RadarSatRecordFactory.h>

Inheritance diagram for ossimplugins::RadarSatRecordFactory:
ossimplugins::DataFactory ossimplugins::LeaderFactory ossimplugins::TrailerFactory ossimplugins::VolumeDirFactory

Public Member Functions

 RadarSatRecordFactory ()
 Constructor. More...
 
 ~RadarSatRecordFactory ()
 Destructor. More...
 
void RegisterRecord (int id, RadarSatRecord *record)
 Add a new Record type available in this factory. More...
 
RadarSatRecordInstanciate (int id)
 Instanciates a new Record. More...
 

Protected Attributes

std::map< int, RadarSatRecord * > _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 wanted record.

Definition at line 26 of file RadarSatRecordFactory.h.

Constructor & Destructor Documentation

◆ RadarSatRecordFactory()

ossimplugins::RadarSatRecordFactory::RadarSatRecordFactory ( )

Constructor.

Definition at line 16 of file RadarSatRecordFactory.cpp.

17 {
18 }

◆ ~RadarSatRecordFactory()

ossimplugins::RadarSatRecordFactory::~RadarSatRecordFactory ( )

Destructor.

Definition at line 20 of file RadarSatRecordFactory.cpp.

21 {
22 }

Member Function Documentation

◆ Instanciate()

RadarSatRecord * ossimplugins::RadarSatRecordFactory::Instanciate ( int  id)

Instanciates a new Record.

Parameters
idId of the Record we want to instanciate

Definition at line 24 of file RadarSatRecordFactory.cpp.

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

Referenced by ossimplugins::ossimRadarSatModel::open(), and ossimplugins::operator>>().

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

◆ RegisterRecord()

void ossimplugins::RadarSatRecordFactory::RegisterRecord ( int  id,
RadarSatRecord record 
)

Add a new Record type available in this factory.

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

Definition at line 37 of file RadarSatRecordFactory.cpp.

References _availableRecords.

Referenced by ossimplugins::DataFactory::DataFactory(), ossimplugins::LeaderFactory::LeaderFactory(), ossimplugins::TrailerFactory::TrailerFactory(), and ossimplugins::VolumeDirFactory::VolumeDirFactory().

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

Member Data Documentation

◆ _availableRecords

std::map<int, RadarSatRecord*> ossimplugins::RadarSatRecordFactory::_availableRecords
protected

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