MIP_SDK  v3.0.0
MicroStrain Communications Library for embedded systems
Public Member Functions | List of all members
microstrain::Id Class Reference

Representes an ID number ranging from 1..N including N. More...

#include <index.hpp>

Public Member Functions

constexpr Id (unsigned int id)
 
constexpr Id ()
 
constexpr IdsetFromIndex (unsigned int index)
 
constexpr IdsetFromId (unsigned int id)
 
constexpr unsigned int index () const
 
constexpr unsigned int id () const
 
constexpr bool operator== (const Id &other) const
 
constexpr bool operator!= (const Id &other) const
 
constexpr bool isAssigned () const
 
constexpr bool isValid (size_t max_count) const
 
constexpr void clear ()
 
Idoperator++ ()
 
Idoperator-- ()
 
Id operator++ (int)
 
Id operator-- (int)
 
constexpr Id (const Index &other)
 
constexpr Idoperator= (const Index &other)
 

Detailed Description

Representes an ID number ranging from 1..N including N.

This is interchangeable with the Index class.

Constructor & Destructor Documentation

◆ Id() [1/3]

constexpr microstrain::Id::Id ( unsigned int  id)
inlineexplicitconstexpr

◆ Id() [2/3]

constexpr microstrain::Id::Id ( )
inlineconstexpr

◆ Id() [3/3]

constexpr microstrain::Id::Id ( const Index other)
inlineconstexpr

Member Function Documentation

◆ clear()

constexpr void microstrain::Id::clear ( )
inlineconstexpr

◆ id()

constexpr unsigned int microstrain::Id::id ( ) const
inlineconstexpr

◆ index()

constexpr unsigned int microstrain::Id::index ( ) const
inlineconstexpr

◆ isAssigned()

constexpr bool microstrain::Id::isAssigned ( ) const
inlineconstexpr

◆ isValid()

constexpr bool microstrain::Id::isValid ( size_t  max_count) const
inlineconstexpr

◆ operator!=()

constexpr bool microstrain::Id::operator!= ( const Id other) const
inlineconstexpr

◆ operator++() [1/2]

Id& microstrain::Id::operator++ ( )
inline

◆ operator++() [2/2]

Id microstrain::Id::operator++ ( int  )
inline

◆ operator--() [1/2]

Id& microstrain::Id::operator-- ( )
inline

◆ operator--() [2/2]

Id microstrain::Id::operator-- ( int  )
inline

◆ operator=()

constexpr Id& microstrain::Id::operator= ( const Index other)
inlineconstexpr

◆ operator==()

constexpr bool microstrain::Id::operator== ( const Id other) const
inlineconstexpr

◆ setFromId()

constexpr Id& microstrain::Id::setFromId ( unsigned int  id)
inlineconstexpr

◆ setFromIndex()

constexpr Id& microstrain::Id::setFromIndex ( unsigned int  index)
inlineconstexpr

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