casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Private Attributes
asdmbinaries::Optional< Enum, EnumHelper > Class Template Reference

A class to embed optional information. More...

#include <SDMDataObject.h>

List of all members.

Public Member Functions

 Optional ()
 The empty constructor.
 Optional (Enum literal)
 The full constructor.
bool present () const
 Test of presence.
Enum literal () const
 Returns the optional value.
 Optional ()
 The empty constructor.
 Optional (Enum literal)
 The full constructor.
bool present () const
 Test of presence.
Enum literal () const
 Returns the optional value.

Private Attributes

bool present_
Enum literal_

Detailed Description

template<class Enum, class EnumHelper>
class asdmbinaries::Optional< Enum, EnumHelper >

A class to embed optional information.

Definition at line 192 of file SDMDataObject.h.


Constructor & Destructor Documentation

template<class Enum, class EnumHelper>
asdmbinaries::Optional< Enum, EnumHelper >::Optional ( ) [inline]

The empty constructor.

To be used whenever an optional value has to be declared as absent.

Definition at line 203 of file SDMDataObject.h.

template<class Enum, class EnumHelper>
asdmbinaries::Optional< Enum, EnumHelper >::Optional ( Enum  literal) [inline]

The full constructor.

To be used whenever an optional value has to be declared as present.

Parameters:
literalthe value of type Enum to embed in the Optional class.

Definition at line 214 of file SDMDataObject.h.

template<class Enum, class EnumHelper>
asdmbinaries::Optional< Enum, EnumHelper >::Optional ( ) [inline]

The empty constructor.

To be used whenever an optional value has to be declared as absent.

Definition at line 203 of file SDMDataObject.h.

template<class Enum, class EnumHelper>
asdmbinaries::Optional< Enum, EnumHelper >::Optional ( Enum  literal) [inline]

The full constructor.

To be used whenever an optional value has to be declared as present.

Parameters:
literalthe value of type Enum to embed in the Optional class.

Definition at line 214 of file SDMDataObject.h.


Member Function Documentation

template<class Enum, class EnumHelper>
Enum asdmbinaries::Optional< Enum, EnumHelper >::literal ( ) const [inline]

Returns the optional value.

Returns:
an Enum
Note:
the returned value is meaningful if and only if present() == true !

Definition at line 234 of file SDMDataObject.h.

Referenced by asdmbinaries::Optional< SpectralResolutionType, CSpectralResolutionType >::Optional().

template<class Enum, class EnumHelper>
Enum asdmbinaries::Optional< Enum, EnumHelper >::literal ( ) const [inline]

Returns the optional value.

Returns:
an Enum
Note:
the returned value is meaningful if and only if present() == true !

Definition at line 234 of file SDMDataObject.h.

template<class Enum, class EnumHelper>
bool asdmbinaries::Optional< Enum, EnumHelper >::present ( ) const [inline]

Test of presence.

Returns:
true (resp. false) if this represents a present (resp. false) optional value.

Definition at line 224 of file SDMDataObject.h.

template<class Enum, class EnumHelper>
bool asdmbinaries::Optional< Enum, EnumHelper >::present ( ) const [inline]

Test of presence.

Returns:
true (resp. false) if this represents a present (resp. false) optional value.

Definition at line 224 of file SDMDataObject.h.


Member Data Documentation

template<class Enum, class EnumHelper>
Enum asdmbinaries::Optional< Enum, EnumHelper >::literal_ [private]
template<class Enum, class EnumHelper>
bool asdmbinaries::Optional< Enum, EnumHelper >::present_ [private]

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