Public Types | Static Public Member Functions | List of all members
util::quantities::concepts::details::WithCategory< Cat > Struct Template Reference

An object belonging to a category Cat. More...

#include <intervals.h>

Inheritance diagram for util::quantities::concepts::details::WithCategory< Cat >:
util::quantities::concepts::Interval< Q, Cat > util::quantities::concepts::Point< Q, Cat, IV >

Public Types

using category_t = Cat
 The category of this object. More...
 
using traits_t = category_traits< category_t >
 Traits of this category. More...
 

Static Public Member Functions

static constexpr category_t category ()
 Returns an instance of the category of this object. More...
 
static constexpr bool hasCategoryName ()
 Returns whether this category has a name. More...
 
static std::string categoryName ()
 Returns the name of the category of this object. More...
 
template<typename OC >
static constexpr bool same_category_as ()
 Returns whether the type OC belongs to category_t. More...
 
template<typename OC >
static constexpr bool same_category_as (OC const &)
 
template<typename OC >
static constexpr bool category_compatible_with ()
 Returns whether OC has a category compatible with this one. More...
 
template<typename OC >
static constexpr bool category_compatible_with (OC const &)
 

Detailed Description

template<typename Cat>
struct util::quantities::concepts::details::WithCategory< Cat >

An object belonging to a category Cat.

Definition at line 42 of file intervals.h.

Member Typedef Documentation

template<typename Cat >
using util::quantities::concepts::details::WithCategory< Cat >::category_t = Cat

The category of this object.

Definition at line 1088 of file intervals.h.

Traits of this category.

Definition at line 1091 of file intervals.h.

Member Function Documentation

template<typename Cat >
constexpr auto util::quantities::concepts::details::WithCategory< Cat >::category ( )
static

Returns an instance of the category of this object.

Definition at line 1128 of file intervals.h.

1128 { return {}; }
template<typename Cat >
template<typename OC >
constexpr bool util::quantities::concepts::details::WithCategory< Cat >::category_compatible_with ( )
static

Returns whether OC has a category compatible with this one.

Definition at line 1148 of file intervals.h.

1149  { return traits_t::template compatible_with<category_of<OC>>(); }
template<typename Cat >
template<typename OC >
constexpr bool util::quantities::concepts::details::WithCategory< Cat >::category_compatible_with ( OC const &  )
static

Definition at line 1154 of file intervals.h.

1155  { return category_compatible_with<OC>(); }
template<typename Cat >
std::string util::quantities::concepts::details::WithCategory< Cat >::categoryName ( )
static

Returns the name of the category of this object.

Definition at line 1165 of file intervals.h.

1166  { return Cat::name(); }
static QCString name
Definition: declinfo.cpp:673
template<typename Cat >
constexpr bool util::quantities::concepts::details::WithCategory< Cat >::hasCategoryName ( )
static

Returns whether this category has a name.

Definition at line 1159 of file intervals.h.

static constexpr bool has_name
Whether the category supports name() call.
Definition: intervals.h:1065
template<typename Cat >
template<typename OC >
constexpr bool util::quantities::concepts::details::WithCategory< Cat >::same_category_as ( )
static

Returns whether the type OC belongs to category_t.

Definition at line 1134 of file intervals.h.

1134  {
1135  return details::has_category_v<OC>
1136  && std::is_same_v<typename OC::category_t, category_t>;
1137  } // WithCategory<>::same_category_as()
template<typename Cat >
template<typename OC >
constexpr bool util::quantities::concepts::details::WithCategory< Cat >::same_category_as ( OC const &  )
static

Definition at line 1141 of file intervals.h.

1142  { return same_category_as<OC>(); }

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