MOS Source Code
Loading...
Searching...
No Matches
Flags< E > Struct Template Reference

#include <types.hpp>

Public Member Functions

constexpr Flags (E value=static_cast< E >(0))
 
 ~Flags ()=default
 
 operator U () const
 
Flags operator| (E e) const
 
Flags operator& (E b) const
 
Flags operator& (Flags b) const
 
bool test (E b) const
 
bool test_inverse (E b) const
 
Flags erased (E b) const
 
Flags erased (Flags b) const
 
Flagsoperator|= (E b)
 
Flagsoperator&= (E b)
 
Flagsoperator&= (Flags b)
 
Flags erase (E b)
 
Flags erase (Flags b)
 

Static Public Member Functions

static Flags all ()
 

Private Types

using EnumType = E
 
using U = std::underlying_type_t<E>
 

Private Attributes

value_
 

Detailed Description

template<typename E>
requires std::is_enum_v<E>
struct Flags< E >

Definition at line 139 of file types.hpp.

Member Typedef Documentation

◆ EnumType

template<typename E>
using EnumType = E
private

Definition at line 145 of file types.hpp.

◆ U

template<typename E>
using U = std::underlying_type_t<E>
private

Definition at line 146 of file types.hpp.

Constructor & Destructor Documentation

◆ Flags()

template<typename E>
Flags ( E value = static_cast<E>(0))
inlineconstexpr

Definition at line 149 of file types.hpp.

Referenced by all(), erase(), erase(), erased(), erased(), Flags(), operator&(), operator&(), operator&=(), operator&=(), operator|(), and operator|=().

+ Here is the call graph for this function:

◆ ~Flags()

template<typename E>
~Flags ( )
default

Member Function Documentation

◆ all()

template<typename E>
static Flags all ( )
inlinestatic

Definition at line 156 of file types.hpp.

+ Here is the call graph for this function:

◆ operator U()

template<typename E>
operator U ( ) const
inline

Definition at line 161 of file types.hpp.

◆ operator|()

template<typename E>
Flags operator| ( E e) const
inline

Definition at line 166 of file types.hpp.

+ Here is the call graph for this function:

◆ operator&() [1/2]

template<typename E>
Flags operator& ( E b) const
inline

Definition at line 171 of file types.hpp.

+ Here is the call graph for this function:

◆ operator&() [2/2]

template<typename E>
Flags operator& ( Flags< E > b) const
inline

Definition at line 176 of file types.hpp.

+ Here is the call graph for this function:

◆ test()

template<typename E>
bool test ( E b) const
inline

Definition at line 181 of file types.hpp.

◆ test_inverse()

template<typename E>
bool test_inverse ( E b) const
inline

Definition at line 186 of file types.hpp.

◆ erased() [1/2]

template<typename E>
Flags erased ( E b) const
inline

Definition at line 191 of file types.hpp.

+ Here is the call graph for this function:

◆ erased() [2/2]

template<typename E>
Flags erased ( Flags< E > b) const
inline

Definition at line 196 of file types.hpp.

+ Here is the call graph for this function:

◆ operator|=()

template<typename E>
Flags & operator|= ( E b)
inline

Definition at line 201 of file types.hpp.

+ Here is the call graph for this function:

◆ operator&=() [1/2]

template<typename E>
Flags & operator&= ( E b)
inline

Definition at line 207 of file types.hpp.

+ Here is the call graph for this function:

◆ operator&=() [2/2]

template<typename E>
Flags & operator&= ( Flags< E > b)
inline

Definition at line 213 of file types.hpp.

+ Here is the call graph for this function:

◆ erase() [1/2]

template<typename E>
Flags erase ( E b)
inline

Definition at line 219 of file types.hpp.

+ Here is the call graph for this function:

◆ erase() [2/2]

template<typename E>
Flags erase ( Flags< E > b)
inline

Definition at line 225 of file types.hpp.

+ Here is the call graph for this function:

Member Data Documentation

◆ value_

template<typename E>
E value_
private

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