PropertyNode Class Reference

An element of the property. More...

#include <property.h>

Inheritance diagram for PropertyNode:
Component SIMDAlignedType

Public Member Functions

 LM_INTERFACE_CLASS (PropertyNode, Component, 10)
 
 LM_DISABLE_COPY_AND_MOVE (PropertyNode)
 
 LM_INTERFACE_F (0, Tree, const PropertyTree *())
 Get the tree associated to the node.
 
 LM_INTERFACE_F (1, Type, PropertyNodeType())
 Get the current node type.
 
 LM_INTERFACE_F (2, Line, int())
 Get the current line in the loaded property node.
 
 LM_INTERFACE_F (3, Key, std::string())
 Key of the node.
 
 LM_INTERFACE_F (4, Scalar, std::string())
 Scalar value of the node.
 
 LM_INTERFACE_F (5, RawScalar, const char *())
 Scalar value of the node (raw version)
 
 LM_INTERFACE_F (6, Size, int())
 Get a number of child elements.
 
 LM_INTERFACE_F (7, Child, const PropertyNode *(const std::string &))
 Find a child by name.
 
 LM_INTERFACE_F (8, At, const PropertyNode *(int))
 Get a child by index.
 
 LM_INTERFACE_F (9, Parent, const PropertyNode *())
 Parent node (nullptr for root node)
 
template<typename T >
auto ChildAs (const std::string &name, const T &def) const -> T
 
template<typename T >
auto As () const -> T
 
template<>
auto As () const -> const char *
 
template<>
auto As () const -> int
 
template<>
auto As () const -> long long
 
template<>
auto As () const -> double
 
template<>
auto As () const -> float
 
template<>
auto As () const -> Vec3
 
template<>
auto As () const -> Vec4
 
template<>
auto As () const -> Mat3
 
template<>
auto As () const -> Mat4
 
- Public Member Functions inherited from SIMDAlignedType
void * operator new (std::size_t size) throw (std::bad_alloc)
 
void operator delete (void *p)
 

Detailed Description

An element of the property.