10 #include "GDCore/Project/Variable.h"
11 #include "GDCore/String.h"
13 class SerializerElement;
47 SourceType GetSourceType()
const {
return sourceType; }
79 const Variable& Get(std::size_t index)
const;
91 std::size_t position);
96 std::size_t
Count()
const {
return variables.size(); };
101 const gd::String& GetNameAt(std::size_t index)
const;
107 std::size_t GetPosition(
const gd::String& name)
const;
138 void Swap(std::size_t firstVariableIndex, std::size_t secondVariableIndex);
143 void Move(std::size_t oldIndex, std::size_t newIndex);
148 inline void Clear() { variables.clear(); }
190 SourceType sourceType = Unknown;
191 std::vector<std::pair<gd::String, std::shared_ptr<gd::Variable>>> variables;
Represent a layout ( also called a scene ) of a project.
Definition: Layout.h:40
Represent an object of a platform.
Definition: Object.h:37
A generic container that can represent a value ( containing a string, double, bool or int),...
Definition: SerializerElement.h:37
String represents an UTF8 encoded string.
Definition: String.h:33
Defines a variable which can be used by an object, a layout or a project.
Definition: Variable.h:29
Class defining a container for gd::Variable.
Definition: VariablesContainer.h:28
const gd::String & GetPersistentUuid() const
Get the persistent UUID used to recognize the same variables between serialization.
Definition: VariablesContainer.h:186
void Clear()
Clear all variables of the container.
Definition: VariablesContainer.h:148
std::size_t Count() const
Return the number of variables.
Definition: VariablesContainer.h:96
Definition: CommonTools.h:24