Semantic Object String.
More...
#include <sox.h>
|
| SOS (string p_s) |
| ctor.
|
|
| ~SOS ()=default |
| dtor.
|
|
public_accessor string | getString () const |
| Getter for the string value.
|
|
public_virtual SOS * | dup () const override |
| Creates a new instance as copy following the PostScript definition. More...
|
|
SOS * | clone () const override |
| Creates a new instance as copy with deep cloning. More...
|
|
string | opequal () const override |
| For operators '=' and 'stack'. More...
|
|
string | opequalequal (Context &) const override |
| For operators '==' and 'pstack'. More...
|
|
OTCode | ot () const override |
| Returns an OTCode. More...
|
|
bool | equal (const SO *p_other) const override |
| Equality. More...
|
|
size_t | getSize () const override |
| Getter for the number of characters or number of objects. More...
|
|
public_other void | setch (size_t index, int ch) |
| Sets a single character within the string. More...
|
|
void | erase0 () |
| Erases the fist character of the String.
|
|
| SO (bool p_exec=false) |
| Ctor.
|
|
virtual | ~SO () |
| Virtual dtor. More...
|
|
public_accessor bool | getExec () const |
| Getter for exec_.
|
|
void | setExec (bool p_exec) |
| Setter for exec_.
|
|
virtual size_t | getSize () const |
| Getter for the number of characters or number of objects. More...
|
|
virtual public_virtual SO * | dup () const =0 |
| Creates a new instance as copy following the PostScript definition. More...
|
|
virtual SO * | clone () const |
| Creates a new instance as copy with deep cloning. More...
|
|
virtual string | opequal () const =0 |
| For operators '=' and 'stack'. More...
|
|
virtual string | opequalequal (class Context &) const |
| For operators '==' and 'pstack'. More...
|
|
virtual OTCode | ot () const =0 |
| Returns an OTCode. More...
|
|
virtual bool | equal (const SO *p_other) const =0 |
| Equality. More...
|
|
| Counter () |
| Ctor.
|
|
|
| SOS (shared_ptr< string > p_s) |
| Private ctor for dup()
|
|
|
shared_ptr< string > | s_ |
| the string value
|
|
|
static int | getTotalCounter () |
| Static getter for created objects.
|
|
static int | getAliveCounter () |
| Static getter for objects alive.
|
|
bool | exec_ = false |
| All SOs have executive vs. More...
|
|
◆ clone()
SOS * SOS::clone |
( |
| ) |
const |
|
inlineoverridevirtual |
Creates a new instance as copy with deep cloning.
Reimplemented from SO.
◆ dup()
Creates a new instance as copy following the PostScript definition.
Implements SO.
◆ equal()
bool SOS::equal |
( |
const SO * |
p_other | ) |
const |
|
inlineoverridevirtual |
Equality.
Equality means: For SOD, share_ptr<> points to the same object.
For SOA, share_ptr<> points to the same object, but empty arrays are equal nonetheless.
SO0 und SOM are always equal.
For SOO and SOo the function pointer must be the same.
Otherwise the value must be the same, even for SOS with shared_ptr<>.
- Returns
- bool ... true if the SO's are of the same type and equal
Implements SO.
◆ getSize()
size_t SOS::getSize |
( |
| ) |
const |
|
inlineoverridevirtual |
Getter for the number of characters or number of objects.
Reimplemented from SO.
◆ opequal()
string SOS::opequal |
( |
| ) |
const |
|
inlineoverridevirtual |
For operators '=' and 'stack'.
Implements SO.
◆ opequalequal()
string SOS::opequalequal |
( |
Context & |
| ) |
const |
|
inlineoverridevirtual |
For operators '==' and 'pstack'.
Reimplemented from SO.
◆ ot()
Returns an OTCode.
A "manual" implementation of polymorphism, where C++-polymorphisms fail
- Returns
- char ... OTCode of the SO
Implements SO.
◆ setch()
Sets a single character within the string.
- Note
- TODO: range checks or prerequisites!?
The documentation for this class was generated from the following file: