World Ocean Simulation System (WOSS) library
woss::WossManagerResDb Class Reference

Abstract class that implements WossManager. It adds computed results dbs control. More...

#include <woss-manager.h>

Inheritance diagram for woss::WossManagerResDb:
Inheritance graph
Collaboration diagram for woss::WossManagerResDb:
Collaboration graph

Public Member Functions

virtual PressuregetWossPressure (const CoordZ &tx_coordz, const CoordZ &rx_coordz, double start_frequency, double end_frequency, const Time &time_value)
 
virtual TimeArrgetWossTimeArr (const CoordZ &tx_coordz, const CoordZ &rx_coordz, double start_frequency, double end_frequency, const Time &time_value)
 
WossManagerResDbsetWossDbManager (const WossDbManager *const ptr)
 
- Public Member Functions inherited from woss::WossManager
 WossManager ()
 
virtual const WossgetActiveWoss (const CoordZ &tx, const CoordZ &rx, double start_frequency, double end_frequency) const
 
virtual WossManagereraseActiveWoss (const CoordZ &tx, const CoordZ &rx, double start_frequency, double end_frequency)=0
 
virtual PressuregetWossPressure (const CoordZ &tx_coordz, const CoordZ &rx_coordz, double start_frequency, double end_frequency, double time_value=0.0)
 
virtual PressureVector getWossPressure (const CoordZPairVect &coordinates, double start_frequency, double end_frequency, const Time &time_value)
 
virtual PressureVector getWossPressure (const CoordZPairVect &coordinates, double start_frequency, double end_frequency, double time_value=0.0)
 
virtual TimeArrgetWossTimeArr (const CoordZ &tx_coordz, const CoordZ &rx_coordz, double start_frequency, double end_frequency, double time_value=0.0)
 
virtual TimeArrVector getWossTimeArr (const CoordZPairVect &coordinates, double start_frequency, double end_frequency, const Time &time_value)
 
virtual TimeArrVector getWossTimeArr (const CoordZPairVect &coordinates, double start_frequency, double end_frequency, double time_value=0.0)
 
virtual bool reset ()=0
 
virtual bool timeEvolve (const Time &time_value)=0
 
WossManagersetWossCreator (const WossCreator *const ptr)
 
void setTimeEvolutionActiveFlag (bool flag)
 
void setDebugFlag (bool flag)
 
const WossCreator *const getWossCreator ()
 
bool getTimeEvolutionActiveFlag ()
 
bool getDebugFlag ()
 

Protected Member Functions

TimeArrdbGetTimeArr (const CoordZ &tx, const CoordZ &rx, double frequency, const Time &time_value) const
 
void dbInsertTimeArr (const CoordZ &tx, const CoordZ &rx, double frequency, const Time &time_value, const TimeArr &channel) const
 
PressuredbGetPressure (const CoordZ &tx, const CoordZ &rx, double frequency, const Time &time_value) const
 
void dbInsertPressure (const CoordZ &tx, const CoordZ &rx, double frequency, const Time &time_value, const Pressure &press) const
 
- Protected Member Functions inherited from woss::WossManager
virtual Woss *const getWoss (const CoordZ &tx, const CoordZ &rx, double start_frequency, double end_frequency)=0
 

Protected Attributes

const WossDbManagerwoss_db_manager
 
- Protected Attributes inherited from woss::WossManager
const WossCreatorwoss_creator
 
bool debug
 
bool is_time_evolution_active
 

Additional Inherited Members

- Static Protected Attributes inherited from woss::WossManager
static const Time NO_EVOLUTION_TIME = Time(1,1,1901,1,1,1)
 

Detailed Description

Abstract class that implements WossManager. It adds computed results dbs control.

WossManagerResDb adds control over optional computed dbs control. If dbs are present and valid requested TimeArr or Pressure is returned, no channel simulator is run

Member Function Documentation

◆ dbGetPressure()

Pressure * woss::WossManagerResDb::dbGetPressure ( const CoordZ tx,
const CoordZ rx,
double  frequency,
const Time time_value 
) const
inlineprotected

Returns a Pressure* from a WossPressureDb for given parameters. User is responsible of pointer's ownership

Parameters
txconst reference to a valid CoordZ object ( transmitter )
rxconst reference to a valid CoordZ object ( receiver )
frequencyfrequency [Hz]
time_valueconst reference to a valid Time oject
Returns
Pressure value

References woss::Pressure::createNotValid(), woss::WossDbManager::getPressure(), woss::Singleton< T >::instance(), and woss_db_manager.

Referenced by getWossPressure(), and woss::WossManagerResDbMT::getWossPressure().

Here is the call graph for this function:

◆ dbGetTimeArr()

TimeArr * woss::WossManagerResDb::dbGetTimeArr ( const CoordZ tx,
const CoordZ rx,
double  frequency,
const Time time_value 
) const
inlineprotected

Returns a TimeArr* from a WossResTimeArrDb for given parameters. User is responsible of pointer's ownership

Parameters
txconst reference to a valid CoordZ object ( transmitter )
rxconst reference to a valid CoordZ object ( receiver )
frequencyfrequency [Hz]
time_valueconst reference to a valid Time oject
Returns
TimeArr value

References woss::TimeArr::createNotValid(), woss::WossDbManager::getTimeArr(), woss::Singleton< T >::instance(), and woss_db_manager.

Referenced by getWossTimeArr(), and woss::WossManagerResDbMT::getWossTimeArr().

Here is the call graph for this function:

◆ dbInsertPressure()

void woss::WossManagerResDb::dbInsertPressure ( const CoordZ tx,
const CoordZ rx,
double  frequency,
const Time time_value,
const Pressure press 
) const
inlineprotected

Inserts a Pressure in a WossResPressureDb

Parameters
txconst reference to a valid CoordZ object ( transmitter )
rxconst reference to a valid CoordZ object ( receiver )
frequencyfrequency [Hz]
time_valueconst reference to a valid Time oject
pressconst reference to a valid Pressure to be inserted

References woss::WossDbManager::insertPressure(), and woss_db_manager.

Referenced by getWossPressure(), and woss::WossManagerResDbMT::getWossPressure().

Here is the call graph for this function:

◆ dbInsertTimeArr()

void woss::WossManagerResDb::dbInsertTimeArr ( const CoordZ tx,
const CoordZ rx,
double  frequency,
const Time time_value,
const TimeArr channel 
) const
inlineprotected

Inserts a TimeArr in a WossResTimeArrDb

Parameters
txconst reference to a valid CoordZ object ( transmitter )
rxconst reference to a valid CoordZ object ( receiver )
frequencyfrequency [Hz]
time_valueconst reference to a valid Time oject
channelconst reference to a valid TimeArr to be inserted

References woss::WossDbManager::insertTimeArr(), and woss_db_manager.

Referenced by getWossTimeArr(), and woss::WossManagerResDbMT::getWossTimeArr().

Here is the call graph for this function:

◆ getWossPressure()

Pressure * WossManagerResDb::getWossPressure ( const CoordZ tx_coordz,
const CoordZ rx_coordz,
double  start_frequency,
double  end_frequency,
const Time time_value 
)
virtual

Returns a valid Pressure for given parameters

Parameters
txconst reference to a valid CoordZ object ( transmitter )
rxconst reference to a valid CoordZ object ( receiver )
start_freqstart frequency [Hz]
end_freqend frequency [Hz]
time_valueconst reference to a valid Time object
Returns
valid Pressure value

Implements woss::WossManager.

Reimplemented in woss::WossManagerResDbMT.

References woss::TimeArr::clear(), woss::Pressure::create(), woss::TimeArr::create(), dbGetPressure(), dbInsertPressure(), woss::WossManager::debug, woss::Woss::freq_lower_bound(), woss::Woss::getAvgPressure(), woss::CoordZ::getCartDistance(), woss::CoordZ::getDepth(), woss::WossCreator::getFrequencyStep(), woss::WossManager::getWoss(), woss::Singleton< T >::instance(), woss::Pressure::isValid(), woss::TimeArr::isValid(), woss::Woss::run(), woss::Woss::timeEvolve(), and woss::WossManager::woss_creator.

Referenced by woss::WossManagerResDbMT::getWossPressure().

Here is the call graph for this function:

◆ getWossTimeArr()

TimeArr * WossManagerResDb::getWossTimeArr ( const CoordZ tx_coordz,
const CoordZ rx_coordz,
double  start_frequency,
double  end_frequency,
const Time time_value 
)
virtual

Returns a valid Pressure for given parameters

Parameters
txconst reference to a valid CoordZ object ( transmitter )
rxconst reference to a valid CoordZ object ( receiver )
start_freqstart frequency [Hz]
end_freqend frequency [Hz]
time_valuenumber of seconds after start time
Returns
valid Pressure value Returns a valid TimeArr for given parameters
Parameters
txconst reference to a valid CoordZ object ( transmitter )
rxconst reference to a valid CoordZ object ( receiver )
start_freqstart frequency [Hz]
end_freqend frequency [Hz]
time_valueconst reference to a valid Time& object
Returns
valid TimeArr value

Implements woss::WossManager.

Reimplemented in woss::WossManagerResDbMT.

References woss::TimeArr::clear(), woss::TimeArr::createImpulse(), dbGetTimeArr(), dbInsertTimeArr(), woss::WossManager::debug, woss::Woss::freq_lower_bound(), woss::CoordZ::getCartDistance(), woss::CoordZ::getDepth(), woss::WossCreator::getFrequencyStep(), woss::Coord::getGreatCircleDistance(), woss::Woss::getTimeArr(), woss::WossManager::getWoss(), woss::Singleton< T >::instance(), woss::TimeArr::isValid(), woss::Woss::run(), woss::Woss::timeEvolve(), and woss::WossManager::woss_creator.

Referenced by woss::WossManagerResDbMT::getWossTimeArr().

Here is the call graph for this function:

◆ setWossDbManager()

WossManagerResDb & woss::WossManagerResDb::setWossDbManager ( const WossDbManager *const  ptr)
inline

Returns a valid TimeArr for given parameters

Parameters
txconst reference to a valid CoordZ object ( transmitter )
rxconst reference to a valid CoordZ object ( receiver )
start_freqstart frequency [Hz]
end_freqend frequency [Hz]
time_valuenumber of seconds after start time
Returns
valid TimeArr value Sets a pointer to a WossDbManager instance, for db query purposes
Parameters
ptrconst pointer to a const WossDbManager instance
Returns
reference to *this

References woss_db_manager.

Referenced by woss::WossController::initialize().

Member Data Documentation

◆ woss_db_manager

const WossDbManager* woss::WossManagerResDb::woss_db_manager
protected

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