OpenTwin 0.1
OpenTwin
 
Loading...
Searching...
No Matches
ot::VersionGraphVersionCfg Class Reference

#include "VersionGraphVersionCfg.h"

Public Member Functions

 VersionGraphVersionCfg ()
 
 VersionGraphVersionCfg (const std::string &_name, const std::string &_label=std::string(), const std::string &_description=std::string())
 
 VersionGraphVersionCfg (const VersionGraphVersionCfg &_other)
 
virtual ~VersionGraphVersionCfg ()
 
VersionGraphVersionCfg & operator= (const VersionGraphVersionCfg &_other)
 
void addToJsonObject (ot::JsonValue &_object, ot::JsonAllocator &_allocator, const std::string &_customParentVersion) const
 
bool setFromJsonObject (const ot::ConstJsonObject &_object, VersionGraphCfg *_graph)
 
void setName (const std::string &_name)
 
const std::string & getName (void) const
 Returns the version name. The name is used to identify the version in a graph. The name will be displayed on the version.
 
void setLabel (const std::string &_title)
 
const std::string & getLabel (void) const
 Returns the version label. The label will be displayed on the version if it is not empty.
 
void setDescription (const std::string &_description)
 
const std::string & getDescription (void) const
 
VersionGraphVersionCfg * addChildVersion (const std::string &_name, const std::string &_label=std::string(), const std::string &_description=std::string())
 
void addChildVersion (VersionGraphVersionCfg *_child)
 Adds the provided version as a child. This version takes ownership of the provided child version.
 
void setChildVersions (const std::list< VersionGraphVersionCfg * > &_versions)
 
const std::list< VersionGraphVersionCfg * > & getChildVersions (void) const
 Returns the child versions. This version keeps ownership of the versions.
 
VersionGraphVersionCfg * findVersion (const std::string &_versionName)
 Returns the version with the given name. The version may be this version.
 
const VersionGraphVersionCfg * findVersion (const std::string &_versionName) const
 Returns the version with the given name. The version may be this version.
 
bool versionStartingWithNameExists (const std::string &_prefix) const
 Returns true if a version with the given name prefix exists in any of the versions childs. Also checks this version.
 
VersionGraphVersionCfg * getLastBranchVersion (void)
 Returns the last version in this branch (first child versions).
 
void setDirectParentIsHidden (bool _isHidden)
 
bool getDirectParentIsHidden (void) const
 If the direct parent is hidden the connection line will be displayed as a dashed line.
 
void applyConfigOnly (const VersionGraphVersionCfg &_other)
 Copy data excluding child versions.
 
VersionGraphVersionCfg * getParentVersion (void)
 
const VersionGraphVersionCfg * getParentVersion (void) const
 

Constructor & Destructor Documentation

◆ VersionGraphVersionCfg() [1/3]

ot::VersionGraphVersionCfg::VersionGraphVersionCfg ( )

◆ VersionGraphVersionCfg() [2/3]

ot::VersionGraphVersionCfg::VersionGraphVersionCfg ( const std::string & _name,
const std::string & _label = std::string(),
const std::string & _description = std::string() )

◆ VersionGraphVersionCfg() [3/3]

ot::VersionGraphVersionCfg::VersionGraphVersionCfg ( const VersionGraphVersionCfg & _other)

◆ ~VersionGraphVersionCfg()

ot::VersionGraphVersionCfg::~VersionGraphVersionCfg ( )
virtual

Member Function Documentation

◆ addChildVersion() [1/2]

ot::VersionGraphVersionCfg * ot::VersionGraphVersionCfg::addChildVersion ( const std::string & _name,
const std::string & _label = std::string(),
const std::string & _description = std::string() )

◆ addChildVersion() [2/2]

void ot::VersionGraphVersionCfg::addChildVersion ( VersionGraphVersionCfg * _child)

Adds the provided version as a child. This version takes ownership of the provided child version.

◆ addToJsonObject()

void ot::VersionGraphVersionCfg::addToJsonObject ( ot::JsonValue & _object,
ot::JsonAllocator & _allocator,
const std::string & _customParentVersion ) const

◆ applyConfigOnly()

void ot::VersionGraphVersionCfg::applyConfigOnly ( const VersionGraphVersionCfg & _other)

Copy data excluding child versions.

◆ findVersion() [1/2]

ot::VersionGraphVersionCfg * ot::VersionGraphVersionCfg::findVersion ( const std::string & _versionName)

Returns the version with the given name. The version may be this version.

◆ findVersion() [2/2]

const ot::VersionGraphVersionCfg * ot::VersionGraphVersionCfg::findVersion ( const std::string & _versionName) const

Returns the version with the given name. The version may be this version.

◆ getChildVersions()

const std::list< VersionGraphVersionCfg * > & ot::VersionGraphVersionCfg::getChildVersions ( void ) const
inline

Returns the child versions. This version keeps ownership of the versions.

◆ getDescription()

const std::string & ot::VersionGraphVersionCfg::getDescription ( void ) const
inline

◆ getDirectParentIsHidden()

bool ot::VersionGraphVersionCfg::getDirectParentIsHidden ( void ) const
inline

If the direct parent is hidden the connection line will be displayed as a dashed line.

◆ getLabel()

const std::string & ot::VersionGraphVersionCfg::getLabel ( void ) const
inline

Returns the version label. The label will be displayed on the version if it is not empty.

◆ getLastBranchVersion()

ot::VersionGraphVersionCfg * ot::VersionGraphVersionCfg::getLastBranchVersion ( void )

Returns the last version in this branch (first child versions).

◆ getName()

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

Returns the version name. The name is used to identify the version in a graph. The name will be displayed on the version.

◆ getParentVersion() [1/2]

VersionGraphVersionCfg * ot::VersionGraphVersionCfg::getParentVersion ( void )
inline

◆ getParentVersion() [2/2]

const VersionGraphVersionCfg * ot::VersionGraphVersionCfg::getParentVersion ( void ) const
inline

◆ operator=()

ot::VersionGraphVersionCfg & ot::VersionGraphVersionCfg::operator= ( const VersionGraphVersionCfg & _other)

◆ setChildVersions()

void ot::VersionGraphVersionCfg::setChildVersions ( const std::list< VersionGraphVersionCfg * > & _versions)

◆ setDescription()

void ot::VersionGraphVersionCfg::setDescription ( const std::string & _description)
inline

◆ setDirectParentIsHidden()

void ot::VersionGraphVersionCfg::setDirectParentIsHidden ( bool _isHidden)
inline

◆ setFromJsonObject()

bool ot::VersionGraphVersionCfg::setFromJsonObject ( const ot::ConstJsonObject & _object,
VersionGraphCfg * _graph )
Returns
Returns true if the version was added to the version graph.

◆ setLabel()

void ot::VersionGraphVersionCfg::setLabel ( const std::string & _title)
inline
See also
getLabel

◆ setName()

void ot::VersionGraphVersionCfg::setName ( const std::string & _name)
inline
See also
getName

◆ versionStartingWithNameExists()

bool ot::VersionGraphVersionCfg::versionStartingWithNameExists ( const std::string & _prefix) const

Returns true if a version with the given name prefix exists in any of the versions childs. Also checks this version.


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