ndn::SimpleTag< T, TypeId > Class Template Reference

provides a tag type for simple types More...

#include <ndn-cxx/tag.hpp>

+ Inheritance diagram for ndn::SimpleTag< T, TypeId >:
+ Collaboration diagram for ndn::SimpleTag< T, TypeId >:

Public Member Functions

constexpr SimpleTag (const T &value) noexcept
 explicitly convertible from T More...
 
constexpr const T & get () const noexcept
 
 operator T () const
 implicitly convertible to T More...
 

Static Public Member Functions

static constexpr int getTypeId () noexcept
 

Detailed Description

template<typename T, int TypeId>
class ndn::SimpleTag< T, TypeId >

provides a tag type for simple types

Template Parameters
Tthe value type
TypeIdthe TypeId

Definition at line 58 of file tag.hpp.

Constructor & Destructor Documentation

◆ SimpleTag()

template<typename T , int TypeId>
constexpr ndn::SimpleTag< T, TypeId >::SimpleTag ( const T &  value)
inlineexplicitconstexprnoexcept

explicitly convertible from T

Definition at line 70 of file tag.hpp.

Member Function Documentation

◆ get()

template<typename T , int TypeId>
constexpr const T& ndn::SimpleTag< T, TypeId >::get ( ) const
inlineconstexprnoexcept
Returns
the enclosed value

Definition at line 86 of file tag.hpp.

◆ getTypeId()

template<typename T , int TypeId>
static constexpr int ndn::SimpleTag< T, TypeId >::getTypeId ( )
inlinestaticconstexprnoexcept

Definition at line 62 of file tag.hpp.

◆ operator T()

template<typename T , int TypeId>
ndn::SimpleTag< T, TypeId >::operator T ( ) const
inline

implicitly convertible to T

Returns
a copy of the enclosed value

Definition at line 78 of file tag.hpp.