Embedded Template Library 1.0
Loading...
Searching...
No Matches
etl::optional< T > Class Template Reference

#include <optional.h>

Public Types

typedef T value_type
typedef T * iterator
typedef const T * const_iterator

Public Member Functions

 optional (etl::nullopt_t)
 Constructor with nullopt.
 optional (const optional &other)
 Copy constructor.
 optional (const T &value_)
 Construct from value type.
optional & operator= (etl::nullopt_t)
 Assignment operator from nullopt.
optional & operator= (const optional &other)
 Assignment operator from optional.
optional & operator= (const T &value_)
 Assignment operator from value type.
ETL_CONSTEXPR20_STL iterator begin () ETL_NOEXCEPT
 Returns an iterator to the beginning of the optional.
ETL_CONSTEXPR20_STL const_iterator begin () const ETL_NOEXCEPT
 Returns a const iterator to the beginning of the optional.
ETL_CONSTEXPR20_STL iterator end () ETL_NOEXCEPT
 Returns an iterator to the end of the optional.
ETL_CONSTEXPR20_STL const_iterator end () const ETL_NOEXCEPT
 Returns a const iterator to the end of the optional.

Detailed Description

template<typename T>
class etl::optional< T >

An optional type. If the optional type is not initialised then a type is not constructed. See http://en.cppreference.com/w/cpp/utility/optional

Template Parameters
TThe type to store.

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