class SSymbol(object):
Known subclasses: acme.helpers.interpreter.Types.SBooleanSymbol, acme.helpers.interpreter.Types.SJsonSymbol, acme.helpers.interpreter.Types.SLambdaSymbol, acme.helpers.interpreter.Types.SListCharSymbol, acme.helpers.interpreter.Types.SListQuoteSymbol, acme.helpers.interpreter.Types.SListSymbol, acme.helpers.interpreter.Types.SNilSymbol, acme.helpers.interpreter.Types.SNumberSymbol, acme.helpers.interpreter.Types.SStringSymbol, acme.helpers.interpreter.Types.SSymbolQuoteSymbol, acme.helpers.interpreter.Types.SSymbolSymbol, acme.helpers.interpreter.Types.STSymbol
Constructors: SSymbol.symbolFromValue(value), SSymbol(typ, parent)
The basic class to store and handle symbols, lists, and values in the Interpreter.
| Class Method | symbol |
Create a new SSymbol object from a value. |
| Method | __contains__ |
Check whether an object is contained within the value. |
| Method | __eq__ |
Check whether two SSymbol objects are equal. |
| Method | __getitem__ |
Return an element or a slice from a list, or a character from a string. |
| Method | __gt__ |
Check whether the value is greater than another value. |
| Method | __init__ |
Initialization of a SSymbol object or one of its sub-classes. |
| Method | __len__ |
Return the length of the value. |
| Method | __lt__ |
Check whether the value is less than another value. |
| Method | __repr__ |
Nicely printable version of value. |
| Method | __str__ |
Nicely printable version of value. |
| Method | print |
Print the hierarchy in reverse order (parent first) with reversed indentation. |
| Method | raw |
The Python "raw" value. |
| Method | to |
Return a string representation of the value. |
| Class Variable | __slots__ |
Slots of class attributes. |
| Instance Variable | length |
The length of the symbol. Could be the length of a string, number of items in a list etc. |
| Instance Variable | parent |
Parent SSymbol object. |
| Instance Variable | type |
SType to indicate the type. |
| Instance Variable | value |
The actual stored value. This is either one of the the basic data typs, of a SSymbol, list of SSymbol, dictionary, etc. |
Check whether an object is contained within the value.
This works for characters and strings, and elements and lists.
| Parameters | |
obj:Any | Object to check. |
| Returns | |
bool | True if the object is contained, False otherwise. |
Check whether two SSymbol objects are equal.
| Parameters | |
other:Any | The other object to compare. |
| Returns | |
bool | True if the two objects are equal, False otherwise. |
Check whether the value is greater than another value.
| Parameters | |
other:Any | The other object to compare. |
| Returns | |
bool | True if the value is greater, False otherwise. |
acme.helpers.interpreter.Types.SBooleanSymbol, acme.helpers.interpreter.Types.SJsonSymbol, acme.helpers.interpreter.Types.SLambdaSymbol, acme.helpers.interpreter.Types.SListCharSymbol, acme.helpers.interpreter.Types.SListQuoteSymbol, acme.helpers.interpreter.Types.SListSymbol, acme.helpers.interpreter.Types.SNilSymbol, acme.helpers.interpreter.Types.SNumberSymbol, acme.helpers.interpreter.Types.SStringSymbol, acme.helpers.interpreter.Types.SSymbolQuoteSymbol, acme.helpers.interpreter.Types.SSymbolSymbol, acme.helpers.interpreter.Types.STSymbolCheck whether the value is less than another value.
| Parameters | |
other:Any | The other object to compare. |
| Returns | |
bool | True if the value is less, False otherwise. |
Print the hierarchy in reverse order (parent first) with reversed indentation.
| Parameters | |
depth:int | Current depth level. |
maxint | Maximum depth level. |
| Returns | |
str | Parent hierarchy as a string. |
The Python "raw" value.
| Returns | |
Any | The raw value. For types that could not be converted directly the stringified version is returned. |
acme.helpers.interpreter.Types.SBooleanSymbol, acme.helpers.interpreter.Types.SJsonSymbol, acme.helpers.interpreter.Types.SLambdaSymbol, acme.helpers.interpreter.Types.SListQuoteSymbol, acme.helpers.interpreter.Types.SListSymbol, acme.helpers.interpreter.Types.SNilSymbol, acme.helpers.interpreter.Types.SStringSymbol, acme.helpers.interpreter.Types.SSymbolQuoteSymbol, acme.helpers.interpreter.Types.STSymbolReturn a string representation of the value.
| Parameters | |
quotebool | Quote strings. |
pythonbool | Return a Python list representation. |
| Returns | |
str | A string representation of the value. |
acme.helpers.interpreter.Types.SBooleanSymbol, acme.helpers.interpreter.Types.SJsonSymbol, acme.helpers.interpreter.Types.SLambdaSymbol, acme.helpers.interpreter.Types.SListCharSymbol, acme.helpers.interpreter.Types.SListQuoteSymbol, acme.helpers.interpreter.Types.SListSymbol, acme.helpers.interpreter.Types.SNilSymbol, acme.helpers.interpreter.Types.SNumberSymbol, acme.helpers.interpreter.Types.SStringSymbol, acme.helpers.interpreter.Types.SSymbolQuoteSymbol, acme.helpers.interpreter.Types.SSymbolSymbol, acme.helpers.interpreter.Types.STSymbolThe length of the symbol. Could be the length of a string, number of items in a list etc.
acme.helpers.interpreter.Types.SBooleanSymbol, acme.helpers.interpreter.Types.SJsonSymbol, acme.helpers.interpreter.Types.SLambdaSymbol, acme.helpers.interpreter.Types.SListCharSymbol, acme.helpers.interpreter.Types.SListQuoteSymbol, acme.helpers.interpreter.Types.SListSymbol, acme.helpers.interpreter.Types.SNilSymbol, acme.helpers.interpreter.Types.SNumberSymbol, acme.helpers.interpreter.Types.SStringSymbol, acme.helpers.interpreter.Types.SSymbolQuoteSymbol, acme.helpers.interpreter.Types.SSymbolSymbol, acme.helpers.interpreter.Types.STSymbol