Scope
scope::ScopeString Class Reference

#include <ScopeString.h>

Inherits scope::ScopeValue< std::wstring >, and scope::ScopeValueBase.

Public Member Functions

 ScopeString (const std::wstring &_str=L"", const std::wstring &_name=L"None")
 
 ScopeString (const ScopeString &origstr)
 
Addition operator

For convenient string concatenation

ScopeStringoperator+= (const ScopeString &r)
 
ScopeStringoperator+= (const std::wstring &r)
 
const ScopeString operator+ (const ScopeString &r) const
 
const ScopeString operator+ (const std::wstring &r) const
 
Comparison operator

For convenient string comparisons

bool operator== (const ScopeString &r) const
 
bool operator!= (const ScopeString &r) const
 
bool operator== (const std::wstring &r) const
 
bool operator!= (const std::wstring &r) const
 
- Public Member Functions inherited from scope::ScopeValue< std::wstring >
 ScopeValue (const std::wstring &_value=std::wstring(0), const std::wstring &_name=L"None")
 
ScopeValueoperator= (const ScopeValue &v)
 
ScopeValueoperator= (const std::wstring &v)
 
std::wstring Value () const
 
std::wstring operator() () const
 
 operator std::wstring () const
 
virtual std::wstring Set (const std::wstring &_v, const bool &_callguisignal=true, const bool &_callothersignal=true, const bool &_callatnochange=false)
 
void SetFromString (const std::wstring &str)
 
std::wstring ToChar () const
 
void AddToPropertyTree (boost::property_tree::wptree &pt) const
 
void SetFromPropertyTree (const boost::property_tree::wptree &pt)
 
- Public Member Functions inherited from scope::ScopeValueBase
 ScopeValueBase (const std::wstring &_name=L"None")
 
 ScopeValueBase (const ScopeValueBase &_svb)
 
ScopeValueBaseoperator= (const ScopeValueBase &_svb)
 
virtual ~ScopeValueBase ()
 
std::wstring Name () const
 
void SetName (const std::wstring &_name)
 
void SetRWState (const bool &_state)
 
bool GetRWState () const
 
boost::signals2::connection ConnectGUI (signalchange_t::slot_type slot)
 
boost::signals2::connection ConnectOther (signalchange_t::slot_type slot)
 
boost::signals2::connection ConnectState (signalstate_t::slot_type slot)
 

Additional Inherited Members

- Protected Types inherited from scope::ScopeValueBase
typedef boost::signals2::signal< void()> signalchange_t
 
typedef boost::signals2::signal< void(bool)> signalstate_t
 
- Protected Member Functions inherited from scope::ScopeValue< std::wstring >
virtual std::wstring CoerceValue (const std::wstring &v) const
 
- Protected Attributes inherited from scope::ScopeValue< std::wstring >
std::wstring value
 
- Protected Attributes inherited from scope::ScopeValueBase
std::wstring name
 
std::mutex mutex
 
bool readwrite
 
signalchange_t changesiggui
 
signalchange_t changesigother
 
signalstate_t statesig
 

Detailed Description

A templated class for a thread-safe std::wstring, with signals that are called on value changes.

Definition at line 8 of file ScopeString.h.

Constructor & Destructor Documentation

scope::ScopeString::ScopeString ( const std::wstring &  _str = L"",
const std::wstring &  _name = L"None" 
)
inline
Parameters
[in]_strinitial value
[in]_namename of this string variable

Definition at line 15 of file ScopeString.h.

scope::ScopeString::ScopeString ( const ScopeString origstr)
inline

Safe copy constructor.

Definition at line 21 of file ScopeString.h.


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