SourceXtractorPlusPlus 0.21
SourceXtractor++, the next generation SExtractor
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
SourceXtractor::PropertyId Class Reference

Identifier used to set and retrieve properties. More...

#include <PropertyId.h>

Collaboration diagram for SourceXtractor::PropertyId:
Collaboration graph
[legend]

Public Member Functions

bool operator== (PropertyId other) const
 Equality operator is needed to be use PropertyId as key in unordered_map.
 
bool operator< (PropertyId other) const
 Less than operator needed to use PropertyId as key in a std::map.
 
std::type_index getTypeId () const
 
unsigned int getIndex () const
 
std::string getString () const
 

Static Public Member Functions

template<typename T >
static PropertyId create (unsigned int index=0)
 

Private Member Functions

 PropertyId (std::type_index type_id, unsigned int index)
 

Private Attributes

std::type_index m_type_id
 
unsigned int m_index
 

Friends

struct std::hash< SourceXtractor::PropertyId >
 

Detailed Description

Identifier used to set and retrieve properties.

Definition at line 40 of file PropertyId.h.

Constructor & Destructor Documentation

◆ PropertyId()

SourceXtractor::PropertyId::PropertyId ( std::type_index type_id,
unsigned int index )
inlineprivate

Definition at line 77 of file PropertyId.h.

Referenced by create().

Member Function Documentation

◆ create()

template<typename T >
static PropertyId SourceXtractor::PropertyId::create ( unsigned int index = 0)
inlinestatic

Templated factory method used to create a PropertyId based on the type of a property. An optional index parameter is used to make the distinction between several properties of the same type.

Definition at line 45 of file PropertyId.h.

References PropertyId().

Here is the call graph for this function:

◆ getIndex()

unsigned int SourceXtractor::PropertyId::getIndex ( ) const
inline

Definition at line 70 of file PropertyId.h.

References m_index.

◆ getString()

std::string SourceXtractor::PropertyId::getString ( ) const

Definition at line 36 of file PropertyId.cpp.

References m_index, m_type_id, and std::type_index::name().

Here is the call graph for this function:

◆ getTypeId()

std::type_index SourceXtractor::PropertyId::getTypeId ( ) const
inline

Definition at line 66 of file PropertyId.h.

References m_type_id.

◆ operator<()

bool SourceXtractor::PropertyId::operator< ( PropertyId other) const
inline

Less than operator needed to use PropertyId as key in a std::map.

Definition at line 56 of file PropertyId.h.

References m_index, and m_type_id.

◆ operator==()

bool SourceXtractor::PropertyId::operator== ( PropertyId other) const
inline

Equality operator is needed to be use PropertyId as key in unordered_map.

Definition at line 50 of file PropertyId.h.

References m_index, and m_type_id.

Friends And Related Symbol Documentation

◆ std::hash< SourceXtractor::PropertyId >

Definition at line 80 of file PropertyId.h.

Member Data Documentation

◆ m_index

unsigned int SourceXtractor::PropertyId::m_index
private

Definition at line 80 of file PropertyId.h.

Referenced by getIndex(), getString(), operator<(), and operator==().

◆ m_type_id

std::type_index SourceXtractor::PropertyId::m_type_id
private

Definition at line 79 of file PropertyId.h.

Referenced by getString(), getTypeId(), operator<(), and operator==().


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