OpenTwin 0.1
OpenTwin
 
Loading...
Searching...
No Matches
OnePropertyDialogCfg.h
Go to the documentation of this file.
1
4// ###########################################################################################################################################################################################################################################################################################################################
5
6#pragma once
7
8// OpenTwin header
9#include "OTGui/DialogCfg.h"
10
11namespace ot {
12
13 class Property;
14
17 public:
18 OnePropertyDialogCfg(Property* _property = (Property*)nullptr);
19 OnePropertyDialogCfg(const std::string& _title, Property* _property = (Property*)nullptr);
20 virtual ~OnePropertyDialogCfg();
21
25 virtual void addToJsonObject(ot::JsonValue& _object, ot::JsonAllocator& _allocator) const override;
26
30 virtual void setFromJsonObject(const ot::ConstJsonObject& _object) override;
31
34 void setProperty(Property* _property);
35 Property* getProperty(void) const { return m_property; };
36
38 Property* takeProperty(void);
39
40 private:
41 Property* m_property;
42 };
43
44}
#define OT_DECL_NOCOPY(___class)
Removes the default copy constructor and assignment operator.
Definition OTClassHelper.h:14
#define OT_GUI_API_EXPORT
Definition OTGuiAPIExport.h:9
Definition DialogCfg.h:22
Definition OnePropertyDialogCfg.h:15
Property * getProperty(void) const
Definition OnePropertyDialogCfg.h:35
The Property class is used as a base class for all Properties that can be displayed and modified in t...
Definition Property.h:21
Definition Connector.h:8
rapidjson::Value JsonValue
Writable JSON value.
Definition JSON.h:27
rapidjson::GenericObject< true, rapidjson::GenericValue< rapidjson::UTF8<>, rapidjson::MemoryPoolAllocator< rapidjson::CrtAllocator > > > ConstJsonObject
Read only JSON Object.
Definition JSON.h:35
rapidjson::MemoryPoolAllocator< rapidjson::CrtAllocator > JsonAllocator
Allocator used for writing to JSON values.
Definition JSON.h:30