60 template<CommentType T>
class Comment;
96 Base& operator=(const
Base& base) noexcept = default;
115 bool operator==(const
Base& base) const noexcept;
122 bool operator!=(const
Base& base) const noexcept;
144 void Name(std::string_view name);
156 constexpr
std::string_view TypeToString() const noexcept {
157 return Item::TypeToString(this->
Type());
179 template<
class T>
decltype(
auto)
As();
186 template<
class T>
decltype(
auto)
As()
const;
Base class for all configuration items.
Definition base.hxx:66
virtual bool Equals(const Base &base) const =0
Equals.
decltype(auto) As()
Typed view of this item.
Base() noexcept
Constructor.
static bool IsNameValid(const StormByte::String::String &name) noexcept
Checks if name is valid.
static bool IsNameValid(std::string_view name) noexcept
Checks if name is valid.
decltype(auto) As() const
Typed view of this item.
constexpr void Name(const StormByte::String::String &name)
Sets the name of the item.
Definition base.hxx:136
void Name(std::string_view name)
Sets the name of the item.
StormByte::String::String m_name
Name of the item.
Definition base.hxx:196
virtual constexpr Item::Type Type() const noexcept=0
Gets the type of the item.
virtual StormByte::String::String Serialize(const int &indent_level=0) const
Serializes the item as text.
Configuration items (values, comments, groups, lists).
Definition hook.hxx:50
Type
Node kind in the document tree.
Definition type.hxx:57
@ Container
Group or list.
@ Value
Any leaf (Value node). Not used on the wire.
@ Group
Group of named items.
@ List
List of unnamed items.
#define STORMBYTE_CONFIG_PUBLIC
Definition visibility.h:53