sbepp
Loading...
Searching...
No Matches
sbepp::float_opt_t Class Reference

Built-in float optional type. More...

#include <sbepp.hpp>

Inheritance diagram for sbepp::float_opt_t:
sbepp::detail::optional_base< float, float_opt_t >

Static Public Member Functions

static constexpr value_type min_value () noexcept
 Returns minValue attribute.
 
static constexpr value_type max_value () noexcept
 Returns maxValue attribute.
 
static constexpr value_type null_value () noexcept
 Returns nullValue attribute.
 

Additional Inherited Members

- Public Types inherited from sbepp::detail::optional_base< float, float_opt_t >
using value_type
 Underlying type.
 
- Public Member Functions inherited from sbepp::detail::optional_base< float, float_opt_t >
 optional_base ()=default
 Constructs null object.
 
constexpr optional_base (nullopt_t) noexcept
 Constructs null object.
 
constexpr optional_base (value_type val) noexcept
 Constructs object from given value.
 
constexpr value_type value () const noexcept
 Returns underlying value.
 
constexpr value_typeoperator* () noexcept
 Returns reference to underlying value.
 
constexpr value_type operator* () const noexcept
 Returns underlying value.
 
constexpr bool in_range () const noexcept
 Checks if value is in [Derived::min_value(); Derived::max_value()] range.
 
constexpr value_type value_or (float default_value) const noexcept
 Returns value if not null, default_value otherwise.
 
constexpr bool has_value () const noexcept
 Checks if has value.
 
constexpr operator bool () const noexcept
 Checks if has value.
 

Detailed Description

Built-in float optional type.

Also works as a tag for its traits


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