|
ActiveLib
|
#include <XMLValueSetting.h>


Public Types | |
| enum | FieldIndex { name , valGuid , columns , type , className , value } |
| Serialisaton fields. | |
| using | base = std::reference_wrapper<setting::ValueSetting> |
Public Types inherited from active::serialise::Package | |
| using | Unique = std::unique_ptr<Package> |
| Unique pointer. | |
| using | Shared = std::shared_ptr<Package> |
| Shared pointer. | |
Public Types inherited from active::serialise::Cargo | |
| using | Unique = std::unique_ptr<Cargo> |
| Unique pointer. | |
| using | Shared = std::shared_ptr<Cargo> |
| Shared pointer. | |
| using | size_type = std::string::size_type |
| Class size type. | |
| using | sizeOption = std::optional<size_type> |
| Optional size type (used to indicate an unspecified or non-existant position) | |
Public Member Functions | |
| XMLValueSetting (setting::ValueSetting &setting, bool isTyped=false, std::optional< utility::String > className=std::nullopt) | |
| XMLValueSetting (const setting::ValueSetting &setting, bool isTyped=false, std::optional< utility::String > className=std::nullopt) | |
| XMLValueSetting (setting::ValueSetting &setting, const utility::String &customTag, bool isTyped=false, std::optional< utility::String > className=std::nullopt) | |
| XMLValueSetting (const setting::ValueSetting &setting, const utility::String &customTag, bool isTyped=false, std::optional< utility::String > className=std::nullopt) | |
| virtual bool | fillInventory (Inventory &inventory) const override |
| virtual Cargo::Unique | getCargo (const Inventory::Item &item) const override |
| virtual void | setDefault () override |
| virtual bool | validate () override |
| virtual bool | insert (Cargo::Unique &&cargo, const Inventory::Item &item) override |
Public Member Functions inherited from active::serialise::Package | |
| bool | isRoot () const |
| virtual bool | isAttributeFirst () const |
| virtual bool | read (const utility::String &source) |
| void | setRoot (bool state) |
| virtual bool | finaliseAttributes () |
Public Member Functions inherited from active::serialise::Cargo | |
| Cargo () | |
| Cargo (const Cargo &source) | |
| virtual | ~Cargo ()=default |
| virtual void | clear () |
Static Public Attributes | |
| static utility::String | tag = "setting" |
| The default element tag. | |
A serialisation wrapper for a setting containing a value, e.g. string, bool etc (potentially multiple values)
| XMLValueSetting::XMLValueSetting | ( | setting::ValueSetting & | setting, |
| bool | isTyped = false, | ||
| std::optional< utility::String > | className = std::nullopt ) |
Constructor
| setting | The setting to wrap for (de)serialisation |
| isTyped | True if the value is serialised as a specific type |
| className | Optional class name for the value container |

|
inline |
Constructor
| setting | The setting to wrap for (de)serialisation |
| isTyped | True if the value is serialised as a specific type |
| className | Optional class name for the value container |
| XMLValueSetting::XMLValueSetting | ( | setting::ValueSetting & | setting, |
| const utility::String & | customTag, | ||
| bool | isTyped = false, | ||
| std::optional< utility::String > | className = std::nullopt ) |
Constructor
| setting | The setting to wrap for (de)serialisation |
| customTag | A custom tag (overrides the default tag) |
| isTyped | True if the value is serialised as a specific type |
| className | Optional class name for the value container |

|
inline |
Constructor
| setting | The setting to wrap for (de)serialisation |
| customTag | A custom tag (overrides the default tag) |
| isTyped | True if the value is serialised as a specific type |
| className | Optional class name for the value container |
|
overridevirtual |
Fill an inventory with the package items
| inventory | The inventory to receive the package items |
Implements active::serialise::Cargo.

|
overridevirtual |
Get the specified cargo
| item | The inventory item to retrieve |
Implements active::serialise::Cargo.
|
overridevirtual |
Insert specified cargo into the package - used for cargo with many instances sharing the same ID (e.g. from an array/map)
| cargo | The cargo to insert |
| item | The inventory item linked with the cargo |
Reimplemented from active::serialise::Package.
|
overridevirtual |
Set to the default package content
Reimplemented from active::serialise::Package.

|
overridevirtual |
Validate the cargo data
Reimplemented from active::serialise::Cargo.
