GL Studio C++ Runtime API
GlsPropString Class Reference

#include <util.h>

Public Member Functions

 GlsPropString ()
 Default constructor. Creates an empty GlsPropString.
 
 GlsPropString (const std::string &str)
 
 GlsPropString (const char *str)
 
 operator std::string () const
 
std::string & String ()
 

Public Attributes

std::string _string
 The underlying wrapped string.
 

Friends

bool operator== (const GlsPropString &str1, const GlsPropString &str2)
 
bool operator!= (const GlsPropString &str1, const GlsPropString &str2)
 

Detailed Description

GlsPropString is designed to be used as a string in GL Studio Class Properties. It writes itself out as a single line, and will read in up to the next newline. It will attempt to convert itself to and from std::strings. If it is used in a GlsMultiVal, there must be only one, and it must be the last entry in the GlsMultiVal instance. See GlsPropStringQuoted for more usefulness in GlsMultiVal.

Constructor & Destructor Documentation

◆ GlsPropString() [1/2]

GlsPropString ( const std::string &  str)
inline

Create a new GlsPropString using the provided std string.

Parameters
strThe std::string to use to create the GlsPropString.

◆ GlsPropString() [2/2]

GlsPropString ( const char *  str)
inline

Create a new GlsPropString using the provided C-style string.

Parameters
strThe C-style string to use to create the GlsPropString.

Member Function Documentation

◆ operator std::string()

operator std::string ( ) const
inline
Returns
The underlying string value for this object.

◆ String()

std::string & String ( )
inline

Get the string value for this object.

Returns
std::string containing the string value for this object.

Friends And Related Function Documentation

◆ operator!=

bool operator!= ( const GlsPropString str1,
const GlsPropString str2 
)
friend

Checks lexicographic inequality of the two arguments.

Parameters
str1One object to compare.
str2The other object to compare.
Returns
True if the objects are not equal.

◆ operator==

bool operator== ( const GlsPropString str1,
const GlsPropString str2 
)
friend

Checks lexicographic equality of the two arguments.

Parameters
str1One object to compare.
str2The other object to compare.
Returns
True if the objects are equal.

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