ALib C++ Library
Library Version: 2510 R0
Documentation generated by doxygen
Loading...
Searching...
No Matches
alib::enumrecords::detail::EnumRecordHook< TEnum > Struct Template Reference

Description:

template<typename TEnum>
struct alib::enumrecords::detail::EnumRecordHook< TEnum >

This is the internal singleton that provides a link to the first ALib Enum Record. The class inherit's Singleton and has a private default constructor, what makes this type a strict singleton.

Because enum record types are ensured to be trivially destructible types, no destructor is given.

Template Parameters
TEnumThe enumeration type associated with enum records.

Definition at line 95 of file records.inl.

Inheritance diagram for alib::enumrecords::detail::EnumRecordHook< TEnum >:
[legend]
Collaboration diagram for alib::enumrecords::detail::EnumRecordHook< TEnum >:
[legend]

Inner Type Index:

struct  Node
 A node of the forward list that contains the custom record data. More...
 

Public Type Index:

using TIntegral = typename std::underlying_type<TEnum>::type
 The enum's underlying integer type.
 
using TRecord = typename RecordsTraits<TEnum>::Type
 The enum's associated record type.
 

Public Field Index:

Nodefirst
 The hook to the first record defined.
 

Public Method Index:

Node ** getPointerToLast ()
 
- Public Method Index: inherited from alib::singletons::Singleton< T >
virtual ~Singleton ()
 Virtual destructor.
 
virtual ~Singleton ()
 Virtual destructor.
 

Private Method Index:

 EnumRecordHook ()
 

Additional Inherited Members

- Public Static Method Index: inherited from alib::singletons::Singleton< T >
static T & GetSingleton ()
 
static T & GetSingleton ()
 

Type Definition Details:

◆ TIntegral

template<typename TEnum>
using alib::enumrecords::detail::EnumRecordHook< TEnum >::TIntegral = typename std::underlying_type<TEnum>::type

The enum's underlying integer type.

Definition at line 102 of file records.inl.

◆ TRecord

template<typename TEnum>
using alib::enumrecords::detail::EnumRecordHook< TEnum >::TRecord = typename RecordsTraits<TEnum>::Type

The enum's associated record type.

Definition at line 105 of file records.inl.

Field Details:

◆ first

template<typename TEnum>
Node* alib::enumrecords::detail::EnumRecordHook< TEnum >::first

The hook to the first record defined.

Definition at line 138 of file records.inl.

Constructor(s) / Destructor Details:

◆ EnumRecordHook()

template<typename TEnum>
alib::enumrecords::detail::EnumRecordHook< TEnum >::EnumRecordHook ( )
inlineprivate

Private default constructor, what makes this type a strict singleton.

Note
As enum record types are trivially destructible types, no destructor is given.

Definition at line 158 of file records.inl.

Method Details:

◆ getPointerToLast()

template<typename TEnum>
Node ** alib::enumrecords::detail::EnumRecordHook< TEnum >::getPointerToLast ( )
inline

Helper methods that returns the address of field EnumRecordHook::Node::next the last element contained in the list. If no elements have been initialized, yet, the address of field first is returned.

Returns
A pointer to the pointer of the last element or this hook.

Definition at line 145 of file records.inl.

Here is the call graph for this function:

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