OpenTwin 0.1
OpenTwin
 
Loading...
Searching...
No Matches
ot::WidgetBaseCfg Class Referenceabstract

#include "WidgetBaseCfg.h"

Inheritance diagram for ot::WidgetBaseCfg:
ot::Serializable ot::CheckBoxCfg ot::LineEditCfg ot::ToolButtonCfg

Public Member Functions

 WidgetBaseCfg ()
 
 WidgetBaseCfg (const std::string &_name)
 
 WidgetBaseCfg (const WidgetBaseCfg &)=default
 
 WidgetBaseCfg (WidgetBaseCfg &&)=default
 
virtual ~WidgetBaseCfg ()
 
WidgetBaseCfgoperator= (const WidgetBaseCfg &)=default
 
WidgetBaseCfgoperator= (WidgetBaseCfg &&)=default
 
virtual std::string getWidgetBaseTypeString (void) const =0
 
virtual void addToJsonObject (ot::JsonValue &_object, ot::JsonAllocator &_allocator) const override
 Add the object contents to the provided JSON object.
 
virtual void setFromJsonObject (const ot::ConstJsonObject &_object) override
 Set the object contents from the provided JSON object.
 
void setName (const std::string &_name)
 
const std::string & getName (void) const
 
void setToolTip (const std::string &_toolTip)
 
const std::string & getToolTip (void) const
 
- Public Member Functions inherited from ot::Serializable
 Serializable ()
 
virtual ~Serializable ()
 

Static Public Member Functions

static std::string typeStringJsonKey (void)
 

Constructor & Destructor Documentation

◆ WidgetBaseCfg() [1/4]

ot::WidgetBaseCfg::WidgetBaseCfg ( )

◆ WidgetBaseCfg() [2/4]

ot::WidgetBaseCfg::WidgetBaseCfg ( const std::string & _name)

◆ WidgetBaseCfg() [3/4]

ot::WidgetBaseCfg::WidgetBaseCfg ( const WidgetBaseCfg & )
default

◆ WidgetBaseCfg() [4/4]

ot::WidgetBaseCfg::WidgetBaseCfg ( WidgetBaseCfg && )
default

◆ ~WidgetBaseCfg()

ot::WidgetBaseCfg::~WidgetBaseCfg ( )
virtual

Member Function Documentation

◆ addToJsonObject()

void ot::WidgetBaseCfg::addToJsonObject ( ot::JsonValue & _object,
ot::JsonAllocator & _allocator ) const
overridevirtual

Add the object contents to the provided JSON object.

Parameters
_objectJson object reference to write the data to.
_allocatorAllocator.

Implements ot::Serializable.

Reimplemented in ot::CheckBoxCfg, ot::LineEditCfg, and ot::ToolButtonCfg.

◆ getName()

const std::string & ot::WidgetBaseCfg::getName ( void ) const
inline

◆ getToolTip()

const std::string & ot::WidgetBaseCfg::getToolTip ( void ) const
inline

◆ getWidgetBaseTypeString()

virtual std::string ot::WidgetBaseCfg::getWidgetBaseTypeString ( void ) const
pure virtual

◆ operator=() [1/2]

WidgetBaseCfg & ot::WidgetBaseCfg::operator= ( const WidgetBaseCfg & )
default

◆ operator=() [2/2]

WidgetBaseCfg & ot::WidgetBaseCfg::operator= ( WidgetBaseCfg && )
default

◆ setFromJsonObject()

void ot::WidgetBaseCfg::setFromJsonObject ( const ot::ConstJsonObject & _object)
overridevirtual

Set the object contents from the provided JSON object.

Parameters
_objectThe JSON object containing the information.
Exceptions
Maythrow an exception if the provided object is not valid (members missing or invalid types).

Implements ot::Serializable.

Reimplemented in ot::CheckBoxCfg, ot::LineEditCfg, and ot::ToolButtonCfg.

◆ setName()

void ot::WidgetBaseCfg::setName ( const std::string & _name)
inline

◆ setToolTip()

void ot::WidgetBaseCfg::setToolTip ( const std::string & _toolTip)
inline

◆ typeStringJsonKey()

static std::string ot::WidgetBaseCfg::typeStringJsonKey ( void )
inlinestatic

The documentation for this class was generated from the following files: