59 #ifdef __PCL_BUILDING_PIXINSIGHT_APPLICATION
71 template <
bool>
struct FlagType {};
72 template <>
struct FlagType<true> {
using type = unsigned; };
73 template <>
struct FlagType<false> {
using type = int; };
88 static_assert(
sizeof( E ) <=
sizeof(
int ),
89 "Invalid sizeof( Flags::enum_type ): Must not be larger than sizeof( int )" );
99 using flag_type =
typename FlagType<std::is_unsigned<enum_type>::value>::type;
111 : m_flags( int( e ) )
120 : m_flags( int( m ) )
150 m_flags &= f.m_flags;
161 m_flags &= unsigned( e );
182 m_flags |= f.m_flags;
193 m_flags |= unsigned( e );
215 m_flags ^= f.m_flags;
226 m_flags ^= unsigned( e );
290 constexpr
bool operator !()
const
340 constexpr
Flags operator &(
unsigned m )
const
364 constexpr
Flags operator |(
unsigned m )
const
395 flag_type m_flags = flag_type( 0 );
397 #ifndef __PCL_NO_FLAGS_SETTINGS_IO
401 #ifndef __PCL_NO_FLAGS_FILE_IO
405 #ifdef __PCL_BUILDING_PIXINSIGHT_APPLICATION
406 friend class pi::GlobalSettings;
A platform-independent interface to the local file system.
A type-safe collection of enumerated flags.
Flags(const Flags &)=default
constexpr Flags(flag_type m)
constexpr Flags(enum_type e)
constexpr bool IsFlagSet(enum_type e) const
void ClearFlag(enum_type e)
constexpr flag_type AsInteger() const
void SetFlag(enum_type e, bool on=true)
typename FlagType< std::is_unsigned< enum_type >::value >::type flag_type
Persistent module settings.
Array< T, A > & operator<<(Array< T, A > &x, const V &v)
GenericImage< P > operator^(const GenericImage< P > &image, T scalar)