Public Member Functions | List of all members
sdf::v9::Atmosphere Class Reference

The Atmosphere class contains information about an atmospheric model and related parameters such as temperature and pressure at sea level. More...

#include <Atmosphere.hh>

Public Member Functions

 Atmosphere ()
 Default constructor. More...
 
 Atmosphere (const Atmosphere &_atmosphere)
 Copy constructor. More...
 
 Atmosphere (Atmosphere &&_atmosphere) noexcept
 Move constructor. More...
 
 ~Atmosphere ()
 Destructor. More...
 
Errors Load (ElementPtr _sdf)
 Load the atmosphere based on a element pointer. More...
 
Atmosphereoperator= (Atmosphere &&_atmosphere)
 Move assignment operator. More...
 
Atmosphereoperator= (const Atmosphere &_atmosphere)
 Copy assignment operator. More...
 
bool operator== (const Atmosphere &_atmosphere)
 Equality operator that returns true if this atmosphere instance equals the given atmosphere instance. More...
 
double Pressure () const
 Get the pressure at sea level in pascals. More...
 
void SetPressure (const double _pressure)
 Set the pressure at sea level in pascals. More...
 
void SetTemperature (const ignition::math::Temperature &_temp)
 Set the temperature at sea level. More...
 
void SetTemperatureGradient (const double _gradient)
 Set the temperature gradient with respect to increasing altitude in units of K/m. More...
 
void SetType (const AtmosphereType _type)
 Set the type of the atmospheric model. More...
 
ignition::math::Temperature Temperature () const
 Get the temperature at sea level. More...
 
double TemperatureGradient () const
 Get the temperature gradient with respect to increasing altitude in units of K/m. More...
 
AtmosphereType Type () const
 Get the type of the atmospheric model. More...
 

Detailed Description

The Atmosphere class contains information about an atmospheric model and related parameters such as temperature and pressure at sea level.

An Atmosphere instance is optionally part of a World.

Constructor & Destructor Documentation

◆ Atmosphere() [1/3]

sdf::v9::Atmosphere::Atmosphere ( )

Default constructor.

◆ Atmosphere() [2/3]

sdf::v9::Atmosphere::Atmosphere ( const Atmosphere _atmosphere)

Copy constructor.

Parameters
[in]_atmosphereAtmosphere to copy.

◆ Atmosphere() [3/3]

sdf::v9::Atmosphere::Atmosphere ( Atmosphere &&  _atmosphere)
noexcept

Move constructor.

Parameters
[in]_atmosphereAtmosphere to move.

◆ ~Atmosphere()

sdf::v9::Atmosphere::~Atmosphere ( )

Destructor.

Member Function Documentation

◆ Load()

Errors sdf::v9::Atmosphere::Load ( ElementPtr  _sdf)

Load the atmosphere based on a element pointer.

This is not the usual entry point. Typical usage of the SDF DOM is through the Root object.

Parameters
[in]_sdfThe SDF Element pointer
Returns
Errors, which is a vector of Error objects. Each Error includes an error code and message. An empty vector indicates no error.

◆ operator=() [1/2]

Atmosphere& sdf::v9::Atmosphere::operator= ( Atmosphere &&  _atmosphere)

Move assignment operator.

Parameters
[in]_atmosphereAtmosphere to move.
Returns
Reference to this.

◆ operator=() [2/2]

Atmosphere& sdf::v9::Atmosphere::operator= ( const Atmosphere _atmosphere)

Copy assignment operator.

Parameters
[in]_atmosphereAtmosphere to copy.
Returns
Reference to this.

◆ operator==()

bool sdf::v9::Atmosphere::operator== ( const Atmosphere _atmosphere)

Equality operator that returns true if this atmosphere instance equals the given atmosphere instance.

Parameters
[in]_atmosphereAtmosphere instance to compare.
Returns
True if this instance equals the given atmosphere.

◆ Pressure()

double sdf::v9::Atmosphere::Pressure ( ) const

Get the pressure at sea level in pascals.

Returns
The pressure at sea level in pascals.

◆ SetPressure()

void sdf::v9::Atmosphere::SetPressure ( const double  _pressure)

Set the pressure at sea level in pascals.

Parameters
[in]_pressureThe pressure at sea level in pascals.

◆ SetTemperature()

void sdf::v9::Atmosphere::SetTemperature ( const ignition::math::Temperature &  _temp)

Set the temperature at sea level.

Parameters
[in]_tempThe temperature at sea level.

◆ SetTemperatureGradient()

void sdf::v9::Atmosphere::SetTemperatureGradient ( const double  _gradient)

Set the temperature gradient with respect to increasing altitude in units of K/m.

Parameters
[in]_gradientThe temperature gradient in K/m.

◆ SetType()

void sdf::v9::Atmosphere::SetType ( const AtmosphereType  _type)

Set the type of the atmospheric model.

Parameters
[in]_typeThe type of atmosphere engine.

◆ Temperature()

ignition::math::Temperature sdf::v9::Atmosphere::Temperature ( ) const

Get the temperature at sea level.

Returns
The temperature at sea level.

◆ TemperatureGradient()

double sdf::v9::Atmosphere::TemperatureGradient ( ) const

Get the temperature gradient with respect to increasing altitude in units of K/m.

Returns
The temperature gradient in K/m.

◆ Type()

AtmosphereType sdf::v9::Atmosphere::Type ( ) const

Get the type of the atmospheric model.

Returns
The type of atmosphere engine, which defaults to adiabatic.

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