Refureku v2.2.0
C++17 runtime reflection library.
rfk::Database Class Referencefinal

Public Member Functions

 Database (Database const &)=delete
 
 Database (Database &&)=delete
 
RFK_NODISCARD REFUREKU_API Entity const * getEntityById (std::size_t id) const noexcept
 Retrieve an entity by id. More...
 
RFK_NODISCARD REFUREKU_API Namespace const * getNamespaceById (std::size_t id) const noexcept
 Retrieve a namespace by id. More...
 
RFK_NODISCARD REFUREKU_API Namespace const * getNamespaceByName (char const *name) const
 Retrieve a namespace by name. Can search nested namespaces directly using :: separator. Example: getNamespace("namespace1::namespace2") will get the namespace2 nested inside namespace1 if it exists. More...
 
RFK_NODISCARD REFUREKU_API Namespace const * getFileLevelNamespaceByPredicate (Predicate< Namespace > predicate, void *userData) const
 Retrieve the first file level namespace satisfying the provided predicate. More...
 
RFK_NODISCARD REFUREKU_API Vector< Namespace const * > getFileLevelNamespacesByPredicate (Predicate< Namespace > predicate, void *userData) const
 Retrieve all file level namespaces satisfying the provided predicate. More...
 
REFUREKU_API bool foreachFileLevelNamespace (Visitor< Namespace > visitor, void *userData) const
 Execute the given visitor on all file level namespaces. More...
 
REFUREKU_API std::size_t getFileLevelNamespacesCount () const noexcept
 Get the number of reflected file level namespaces in the database. More...
 
RFK_NODISCARD REFUREKU_API Archetype const * getArchetypeById (std::size_t id) const noexcept
 Retrieve an archetype by id. More...
 
RFK_NODISCARD REFUREKU_API Archetype const * getFileLevelArchetypeByName (char const *name) const noexcept
 Retrieve a file level archetype by name. This method costs heavier performance as it will basically call getClassByName, getStructByName, getEnumByName and then getFundamentalArchetypeByName to find the queried archetype. More...
 
RFK_NODISCARD REFUREKU_API Vector< Archetype const * > getFileLevelArchetypesByPredicate (Predicate< Archetype > predicate, void *userData) const
 Retrieve all file level archetypes satisfying the provided predicate. More...
 
RFK_NODISCARD REFUREKU_API Struct const * getStructById (std::size_t id) const noexcept
 Retrieve a struct by id. More...
 
RFK_NODISCARD REFUREKU_API Struct const * getFileLevelStructByName (char const *name) const noexcept
 Retrieve a file level struct by name. More...
 
RFK_NODISCARD REFUREKU_API Struct const * getFileLevelStructByPredicate (Predicate< Struct > predicate, void *userData) const
 Retrieve the first level struct satisfying the provided predicate. More...
 
RFK_NODISCARD REFUREKU_API Vector< Struct const * > getFileLevelStructsByPredicate (Predicate< Struct > predicate, void *userData) const
 Retrieve all file level structs satisfying the provided predicate. More...
 
REFUREKU_API bool foreachFileLevelStruct (Visitor< Struct > visitor, void *userData) const
 Execute the given visitor on all file level structs. More...
 
REFUREKU_API std::size_t getFileLevelStructsCount () const noexcept
 Get the number of reflected file level structs in the database. More...
 
RFK_NODISCARD REFUREKU_API Class const * getClassById (std::size_t id) const noexcept
 Retrieve a class by id. More...
 
RFK_NODISCARD REFUREKU_API Class const * getFileLevelClassByName (char const *name) const noexcept
 Retrieve a file level class by name. More...
 
RFK_NODISCARD REFUREKU_API Class const * getFileLevelClassByPredicate (Predicate< Class > predicate, void *userData) const
 Retrieve the first level struct satisfying the provided predicate. More...
 
RFK_NODISCARD REFUREKU_API Vector< Class const * > getFileLevelClassesByPredicate (Predicate< Class > predicate, void *userData) const
 Retrieve all file level classes satisfying the provided predicate. More...
 
REFUREKU_API bool foreachFileLevelClass (Visitor< Class > visitor, void *userData) const
 Execute the given visitor on all file level classes. More...
 
REFUREKU_API std::size_t getFileLevelClassesCount () const noexcept
 Get the number of reflected file level classes in the database. More...
 
RFK_NODISCARD REFUREKU_API Enum const * getEnumById (std::size_t id) const noexcept
 Retrieve an enum by id. More...
 
RFK_NODISCARD REFUREKU_API Enum const * getFileLevelEnumByName (char const *name) const noexcept
 Retrieve a file level enum by name. More...
 
RFK_NODISCARD REFUREKU_API Enum const * getFileLevelEnumByPredicate (Predicate< Enum > predicate, void *userData) const
 Retrieve the first file level enum satisfying the provided predicate. More...
 
RFK_NODISCARD REFUREKU_API Vector< Enum const * > getFileLevelEnumsByPredicate (Predicate< Enum > predicate, void *userData) const
 Retrieve all file level enums satisfying the provided predicate. More...
 
REFUREKU_API bool foreachFileLevelEnum (Visitor< Enum > visitor, void *userData) const
 Execute the given visitor on all file level enums. More...
 
REFUREKU_API std::size_t getFileLevelEnumsCount () const noexcept
 Get the number of reflected file level classes in the database. More...
 
RFK_NODISCARD REFUREKU_API FundamentalArchetype const * getFundamentalArchetypeById (std::size_t id) const noexcept
 Retrieve a fundamental archetype by id. More...
 
RFK_NODISCARD REFUREKU_API FundamentalArchetype const * getFundamentalArchetypeByName (char const *name) const noexcept
 Retrieve a fundamental archetype by name. More...
 
RFK_NODISCARD REFUREKU_API Variable const * getVariableById (std::size_t id) const noexcept
 Retrieve a variable by id. More...
 
RFK_NODISCARD REFUREKU_API Variable const * getFileLevelVariableByName (char const *name, EVarFlags flags=EVarFlags::Default) const noexcept
 Retrieve a file level (non-member) variable by name. More...
 
RFK_NODISCARD REFUREKU_API Variable const * getFileLevelVariableByPredicate (Predicate< Variable > predicate, void *userData) const
 Retrieve the first file level variable satisfying the provided predicate. More...
 
RFK_NODISCARD REFUREKU_API Vector< Variable const * > getFileLevelVariablesByPredicate (Predicate< Variable > predicate, void *userData) const
 Retrieve all file level variables satisfying the provided predicate. More...
 
REFUREKU_API bool foreachFileLevelVariable (Visitor< Variable > visitor, void *userData) const
 Execute the given visitor on all file level variables. More...
 
REFUREKU_API std::size_t getFileLevelVariablesCount () const noexcept
 Get the number of reflected file level variables in the database. More...
 
RFK_NODISCARD REFUREKU_API Function const * getFunctionById (std::size_t id) const noexcept
 Retrieve a function by id. More...
 
template<typename FunctionSignature >
RFK_NODISCARD Function const * getFileLevelFunctionByName (char const *name, EFunctionFlags flags=EFunctionFlags::Default) const noexcept
 Retrieve a file level function by name and signature. More...
 
RFK_NODISCARD REFUREKU_API Function const * getFileLevelFunctionByName (char const *name, EFunctionFlags flags=EFunctionFlags::Default) const noexcept
 Retrieve a file level function by name. More...
 
RFK_NODISCARD REFUREKU_API Vector< Function const * > getFileLevelFunctionsByName (char const *name, EFunctionFlags flags=EFunctionFlags::Default) const noexcept
 Retrieve all file level functions by name. More...
 
RFK_NODISCARD REFUREKU_API Function const * getFileLevelFunctionByPredicate (Predicate< Function > predicate, void *userData) const
 Retrieve the first file level function satisfying the provided predicate. More...
 
RFK_NODISCARD REFUREKU_API Vector< Function const * > getFileLevelFunctionsByPredicate (Predicate< Function > predicate, void *userData) const
 Retrieve all file level functions satisfying the provided predicate. More...
 
REFUREKU_API bool foreachFileLevelFunction (Visitor< Function > visitor, void *userData) const
 Execute the given visitor on all file level functions. More...
 
REFUREKU_API std::size_t getFileLevelFunctionsCount () const noexcept
 Get the number of reflected file level functions in the database. More...
 
RFK_NODISCARD REFUREKU_API Method const * getMethodById (std::size_t id) const noexcept
 Retrieve a method by id. More...
 
RFK_NODISCARD REFUREKU_API StaticMethod const * getStaticMethodById (std::size_t id) const noexcept
 Retrieve a static method by id. More...
 
RFK_NODISCARD REFUREKU_API Field const * getFieldById (std::size_t id) const noexcept
 Retrieve a field by id. More...
 
RFK_NODISCARD REFUREKU_API StaticField const * getStaticFieldById (std::size_t id) const noexcept
 Retrieve a static field by id. More...
 
RFK_NODISCARD REFUREKU_API EnumValue const * getEnumValueById (std::size_t id) const noexcept
 Retrieve an enum value by id. More...
 

Friends

REFUREKU_API Database const & getDatabase () noexcept
 Get a reference to the database of this program. More...
 

Member Function Documentation

◆ foreachFileLevelClass()

REFUREKU_API bool rfk::Database::foreachFileLevelClass ( Visitor< Class visitor,
void *  userData 
) const

Execute the given visitor on all file level classes.

Parameters
visitorVisitor function to call. Return false to abort the foreach loop.
userDataOptional user data forwarded to the visitor.
Returns
The last visitor result before exiting the loop. If the visitor is nullptr, return false.
Exceptions
Anyexception potentially thrown from the provided visitor.

◆ foreachFileLevelEnum()

REFUREKU_API bool rfk::Database::foreachFileLevelEnum ( Visitor< Enum visitor,
void *  userData 
) const

Execute the given visitor on all file level enums.

Parameters
visitorVisitor function to call. Return false to abort the foreach loop.
userDataOptional user data forwarded to the visitor.
Returns
The last visitor result before exiting the loop. If the visitor is nullptr, return false.
Exceptions
Anyexception potentially thrown from the provided visitor.

◆ foreachFileLevelFunction()

REFUREKU_API bool rfk::Database::foreachFileLevelFunction ( Visitor< Function visitor,
void *  userData 
) const

Execute the given visitor on all file level functions.

Parameters
visitorVisitor function to call. Return false to abort the foreach loop.
userDataOptional user data forwarded to the visitor.
Returns
The last visitor result before exiting the loop. If the visitor is nullptr, return false.
Exceptions
Anyexception potentially thrown from the provided visitor.

◆ foreachFileLevelNamespace()

REFUREKU_API bool rfk::Database::foreachFileLevelNamespace ( Visitor< Namespace visitor,
void *  userData 
) const

Execute the given visitor on all file level namespaces.

Parameters
visitorVisitor function to call. Return false to abort the foreach loop.
userDataOptional user data forwarded to the visitor.
Returns
The last visitor result before exiting the loop. If the visitor is nullptr, return false.
Exceptions
Anyexception potentially thrown from the provided visitor.

◆ foreachFileLevelStruct()

REFUREKU_API bool rfk::Database::foreachFileLevelStruct ( Visitor< Struct visitor,
void *  userData 
) const

Execute the given visitor on all file level structs.

Parameters
visitorVisitor function to call. Return false to abort the foreach loop.
userDataOptional user data forwarded to the visitor.
Returns
The last visitor result before exiting the loop. If the visitor is nullptr, return false.
Exceptions
Anyexception potentially thrown from the provided visitor.

◆ foreachFileLevelVariable()

REFUREKU_API bool rfk::Database::foreachFileLevelVariable ( Visitor< Variable visitor,
void *  userData 
) const

Execute the given visitor on all file level variables.

Parameters
visitorVisitor function to call. Return false to abort the foreach loop.
userDataOptional user data forwarded to the visitor.
Returns
The last visitor result before exiting the loop. If the visitor is nullptr, return false.
Exceptions
Anyexception potentially thrown from the provided visitor.

◆ getArchetypeById()

RFK_NODISCARD REFUREKU_API Archetype const * rfk::Database::getArchetypeById ( std::size_t  id) const
noexcept

Retrieve an archetype by id.

Parameters
idThe id of the archetype.
Returns
A constant pointer to the queried archetype if it exists, else nullptr.

◆ getClassById()

RFK_NODISCARD REFUREKU_API Class const * rfk::Database::getClassById ( std::size_t  id) const
noexcept

Retrieve a class by id.

Parameters
idThe id of the class.
Returns
A constant pointer to the queried class if it exists, else nullptr.

◆ getEntityById()

RFK_NODISCARD REFUREKU_API Entity const * rfk::Database::getEntityById ( std::size_t  id) const
noexcept

Retrieve an entity by id.

Parameters
idThe id of the entity.
Returns
A constant pointer to the queried entity if it exists, else nullptr.

◆ getEnumById()

RFK_NODISCARD REFUREKU_API Enum const * rfk::Database::getEnumById ( std::size_t  id) const
noexcept

Retrieve an enum by id.

Parameters
idThe id of the enum.
Returns
A constant pointer to the queried enum if it exists, else nullptr.

◆ getEnumValueById()

RFK_NODISCARD REFUREKU_API EnumValue const * rfk::Database::getEnumValueById ( std::size_t  id) const
noexcept

Retrieve an enum value by id.

Parameters
idThe id of the enum value.
Returns
A constant pointer to the queried enum value if it exists, else nullptr.

◆ getFieldById()

RFK_NODISCARD REFUREKU_API Field const * rfk::Database::getFieldById ( std::size_t  id) const
noexcept

Retrieve a field by id.

Parameters
idThe id of the field.
Returns
A constant pointer to the queried field if it exists, else nullptr.

◆ getFileLevelArchetypeByName()

RFK_NODISCARD REFUREKU_API Archetype const * rfk::Database::getFileLevelArchetypeByName ( char const *  name) const
noexcept

Retrieve a file level archetype by name. This method costs heavier performance as it will basically call getClassByName, getStructByName, getEnumByName and then getFundamentalArchetypeByName to find the queried archetype.

Parameters
archetypeNameName of the archetype.
Returns
A constant pointer to the queried archetype if it exists, else nullptr.

◆ getFileLevelArchetypesByPredicate()

RFK_NODISCARD REFUREKU_API Vector< Archetype const * > rfk::Database::getFileLevelArchetypesByPredicate ( Predicate< Archetype predicate,
void *  userData 
) const

Retrieve all file level archetypes satisfying the provided predicate.

Parameters
predicatePredicate defining a valid archetype.
userDataUser data forwarded to the predicate calls.
Returns
All file level archetypes satisfying the predicate.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelClassByName()

RFK_NODISCARD REFUREKU_API Class const * rfk::Database::getFileLevelClassByName ( char const *  name) const
noexcept

Retrieve a file level class by name.

Parameters
nameThe name of the class.
Returns
A constant pointer to the queried class if it exists, else nullptr.

◆ getFileLevelClassByPredicate()

RFK_NODISCARD REFUREKU_API Class const * rfk::Database::getFileLevelClassByPredicate ( Predicate< Class predicate,
void *  userData 
) const

Retrieve the first level struct satisfying the provided predicate.

Parameters
predicatePredicate defining a valid struct.
userDataUser data forwarded to the predicate calls.
Returns
The first file level struct satisfying the predicate.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelClassesByPredicate()

RFK_NODISCARD REFUREKU_API Vector< Class const * > rfk::Database::getFileLevelClassesByPredicate ( Predicate< Class predicate,
void *  userData 
) const

Retrieve all file level classes satisfying the provided predicate.

Parameters
predicatePredicate defining a valid class.
userDataUser data forwarded to the predicate calls.
Returns
All file level classes satisfying the predicate.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelClassesCount()

REFUREKU_API std::size_t rfk::Database::getFileLevelClassesCount ( ) const
noexcept

Get the number of reflected file level classes in the database.

Returns
The number of reflected file level classes in the database.

◆ getFileLevelEnumByName()

RFK_NODISCARD REFUREKU_API Enum const * rfk::Database::getFileLevelEnumByName ( char const *  name) const
noexcept

Retrieve a file level enum by name.

Parameters
nameThe name of the enum.
Returns
A constant pointer to the queried enum if it exists, else nullptr.

◆ getFileLevelEnumByPredicate()

RFK_NODISCARD REFUREKU_API Enum const * rfk::Database::getFileLevelEnumByPredicate ( Predicate< Enum predicate,
void *  userData 
) const

Retrieve the first file level enum satisfying the provided predicate.

Parameters
predicatePredicate defining a valid enum.
userDataUser data forwarded to the predicate calls.
Returns
The first file level enum satisfying the predicate.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelEnumsByPredicate()

RFK_NODISCARD REFUREKU_API Vector< Enum const * > rfk::Database::getFileLevelEnumsByPredicate ( Predicate< Enum predicate,
void *  userData 
) const

Retrieve all file level enums satisfying the provided predicate.

Parameters
predicatePredicate defining a valid enum.
userDataUser data forwarded to the predicate calls.
Returns
All file level enums satisfying the predicate.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelEnumsCount()

REFUREKU_API std::size_t rfk::Database::getFileLevelEnumsCount ( ) const
noexcept

Get the number of reflected file level classes in the database.

Returns
The number of reflected file level classes in the database.

◆ getFileLevelFunctionByName() [1/2]

template<typename FunctionSignature >
RFK_NODISCARD Function const * rfk::Database::getFileLevelFunctionByName ( char const *  name,
EFunctionFlags  flags = EFunctionFlags::Default 
) const
noexcept

Retrieve a file level function by name and signature.

Parameters
nameThe name of the function.
flagsFlags describing the queried function. The result function will have at least the provided flags.
Returns
A constant pointer to the first function matching the name and flags if it exists, else nullptr.

◆ getFileLevelFunctionByName() [2/2]

RFK_NODISCARD REFUREKU_API Function const * rfk::Database::getFileLevelFunctionByName ( char const *  name,
EFunctionFlags  flags = EFunctionFlags::Default 
) const
noexcept

Retrieve a file level function by name.

Parameters
nameThe name of the function.
flagsFlags describing the queried function. The result function will have at least the provided flags.
Returns
A constant pointer to the first function matching the name and flags if it exists, else nullptr.

◆ getFileLevelFunctionByPredicate()

RFK_NODISCARD REFUREKU_API Function const * rfk::Database::getFileLevelFunctionByPredicate ( Predicate< Function predicate,
void *  userData 
) const

Retrieve the first file level function satisfying the provided predicate.

Parameters
predicatePredicate defining a valid function.
userDataUser data forwarded to the predicate calls.
Returns
The first file level function satisfying the predicate.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelFunctionsByName()

RFK_NODISCARD REFUREKU_API Vector< Function const * > rfk::Database::getFileLevelFunctionsByName ( char const *  name,
EFunctionFlags  flags = EFunctionFlags::Default 
) const
noexcept

Retrieve all file level functions by name.

Parameters
nameThe name of the function.
flagsFlags describing the queried function. The result function will have at least the provided flags.
Returns
All file level functions by name.

◆ getFileLevelFunctionsByPredicate()

RFK_NODISCARD REFUREKU_API Vector< Function const * > rfk::Database::getFileLevelFunctionsByPredicate ( Predicate< Function predicate,
void *  userData 
) const

Retrieve all file level functions satisfying the provided predicate.

Parameters
predicatePredicate defining a valid function.
userDataUser data forwarded to the predicate calls.
Returns
All file level functions satisfying the predicate.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelFunctionsCount()

REFUREKU_API std::size_t rfk::Database::getFileLevelFunctionsCount ( ) const
noexcept

Get the number of reflected file level functions in the database.

Returns
The number of reflected file level functions in the database.

◆ getFileLevelNamespaceByPredicate()

RFK_NODISCARD REFUREKU_API Namespace const * rfk::Database::getFileLevelNamespaceByPredicate ( Predicate< Namespace predicate,
void *  userData 
) const

Retrieve the first file level namespace satisfying the provided predicate.

Parameters
predicatePredicate defining a valid namespace.
userDataUser data forwarded to the predicate calls.
Returns
The first file level namespace satisfying the predicate if any, else nullptr.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelNamespacesByPredicate()

RFK_NODISCARD REFUREKU_API Vector< Namespace const * > rfk::Database::getFileLevelNamespacesByPredicate ( Predicate< Namespace predicate,
void *  userData 
) const

Retrieve all file level namespaces satisfying the provided predicate.

Parameters
predicatePredicate defining a valid namespace.
userDataUser data forwarded to the predicate calls.
Returns
All file level namespaces satisfying the predicate.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelNamespacesCount()

REFUREKU_API std::size_t rfk::Database::getFileLevelNamespacesCount ( ) const
noexcept

Get the number of reflected file level namespaces in the database.

Returns
The number of reflected file level namespaces in the database.

◆ getFileLevelStructByName()

RFK_NODISCARD REFUREKU_API Struct const * rfk::Database::getFileLevelStructByName ( char const *  name) const
noexcept

Retrieve a file level struct by name.

Parameters
nameThe name of the struct.
Returns
A constant pointer to the queried struct if it exists, else nullptr.

◆ getFileLevelStructByPredicate()

RFK_NODISCARD REFUREKU_API Struct const * rfk::Database::getFileLevelStructByPredicate ( Predicate< Struct predicate,
void *  userData 
) const

Retrieve the first level struct satisfying the provided predicate.

Parameters
predicatePredicate defining a valid struct.
userDataUser data forwarded to the predicate calls.
Returns
The first file level struct satisfying the predicate.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelStructsByPredicate()

RFK_NODISCARD REFUREKU_API Vector< Struct const * > rfk::Database::getFileLevelStructsByPredicate ( Predicate< Struct predicate,
void *  userData 
) const

Retrieve all file level structs satisfying the provided predicate.

Parameters
predicatePredicate defining a valid struct.
userDataUser data forwarded to the predicate calls.
Returns
All file level structs satisfying the predicate.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelStructsCount()

REFUREKU_API std::size_t rfk::Database::getFileLevelStructsCount ( ) const
noexcept

Get the number of reflected file level structs in the database.

Returns
The number of reflected file level structs in the database.

◆ getFileLevelVariableByName()

RFK_NODISCARD REFUREKU_API Variable const * rfk::Database::getFileLevelVariableByName ( char const *  name,
EVarFlags  flags = EVarFlags::Default 
) const
noexcept

Retrieve a file level (non-member) variable by name.

Parameters
nameThe name of the variable.
flagsFlags describing the queried variable. The result variable will have at least the provided flags.
Returns
A constant pointer to the queried variable if it exists, else nullptr.

◆ getFileLevelVariableByPredicate()

RFK_NODISCARD REFUREKU_API Variable const * rfk::Database::getFileLevelVariableByPredicate ( Predicate< Variable predicate,
void *  userData 
) const

Retrieve the first file level variable satisfying the provided predicate.

Parameters
predicatePredicate defining a valid variable.
userDataUser data forwarded to the predicate calls.
Returns
The first file level variable satisfying the predicate.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelVariablesByPredicate()

RFK_NODISCARD REFUREKU_API Vector< Variable const * > rfk::Database::getFileLevelVariablesByPredicate ( Predicate< Variable predicate,
void *  userData 
) const

Retrieve all file level variables satisfying the provided predicate.

Parameters
predicatePredicate defining a valid variable.
userDataUser data forwarded to the predicate calls.
Returns
All file level variables satisfying the predicate.
Exceptions
Anyexception potentially thrown from the provided predicate.

◆ getFileLevelVariablesCount()

REFUREKU_API std::size_t rfk::Database::getFileLevelVariablesCount ( ) const
noexcept

Get the number of reflected file level variables in the database.

Returns
The number of reflected file level variables in the database.

◆ getFunctionById()

RFK_NODISCARD REFUREKU_API Function const * rfk::Database::getFunctionById ( std::size_t  id) const
noexcept

Retrieve a function by id.

Parameters
idThe id of the function.
Returns
A constant pointer to the queried function if it exists, else nullptr.

◆ getFundamentalArchetypeById()

RFK_NODISCARD REFUREKU_API FundamentalArchetype const * rfk::Database::getFundamentalArchetypeById ( std::size_t  id) const
noexcept

Retrieve a fundamental archetype by id.

Parameters
idThe id of the fundamental archetype.
Returns
A constant pointer to the queried fundamental archetype if it exists, else nullptr.

◆ getFundamentalArchetypeByName()

RFK_NODISCARD REFUREKU_API FundamentalArchetype const * rfk::Database::getFundamentalArchetypeByName ( char const *  name) const
noexcept

Retrieve a fundamental archetype by name.

Parameters
nameThe name of the fundamental archetype.
Returns
A constant pointer to the queried fundamental archetype if it exists, else nullptr.

◆ getMethodById()

RFK_NODISCARD REFUREKU_API Method const * rfk::Database::getMethodById ( std::size_t  id) const
noexcept

Retrieve a method by id.

Parameters
idThe id of the method.
Returns
A constant pointer to the queried method if it exists, else nullptr.

◆ getNamespaceById()

RFK_NODISCARD REFUREKU_API Namespace const * rfk::Database::getNamespaceById ( std::size_t  id) const
noexcept

Retrieve a namespace by id.

Parameters
idThe id of the namespace.
Returns
A constant pointer to the queried namespace if it exists, else nullptr.

◆ getNamespaceByName()

RFK_NODISCARD REFUREKU_API Namespace const * rfk::Database::getNamespaceByName ( char const *  name) const

Retrieve a namespace by name. Can search nested namespaces directly using :: separator. Example: getNamespace("namespace1::namespace2") will get the namespace2 nested inside namespace1 if it exists.

Parameters
nameThe name of the namespace.
Returns
A constant pointer to the queried namespace if it exists, else nullptr.
Exceptions
BadNamespaceFormatif the provided namespace name has : instead of :: as a separator, or starts/ends with :.

◆ getStaticFieldById()

RFK_NODISCARD REFUREKU_API StaticField const * rfk::Database::getStaticFieldById ( std::size_t  id) const
noexcept

Retrieve a static field by id.

Parameters
idThe id of the static field.
Returns
A constant pointer to the queried static field if it exists, else nullptr.

◆ getStaticMethodById()

RFK_NODISCARD REFUREKU_API StaticMethod const * rfk::Database::getStaticMethodById ( std::size_t  id) const
noexcept

Retrieve a static method by id.

Parameters
idThe id of the static method.
Returns
A constant pointer to the queried static method if it exists, else nullptr.

◆ getStructById()

RFK_NODISCARD REFUREKU_API Struct const * rfk::Database::getStructById ( std::size_t  id) const
noexcept

Retrieve a struct by id.

Parameters
idThe id of the struct.
Returns
A constant pointer to the queried struct if it exists, else nullptr.

◆ getVariableById()

RFK_NODISCARD REFUREKU_API Variable const * rfk::Database::getVariableById ( std::size_t  id) const
noexcept

Retrieve a variable by id.

Parameters
idThe id of the variable.
Returns
A constant pointer to the queried variable if it exists, else nullptr.

Friends And Related Function Documentation

◆ getDatabase

REFUREKU_API Database const & getDatabase ( )
friend

Get a reference to the database of this program.

Returns
A reference to the database of this program.

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