string
|
The string function converts an argument {obj} into a String object.
If the argument is a native data type such as: #void, Error, Boolean, Character,
Integer, Number, Integer, Money, Percent, Text, or Character, the string
function converts the native data type into a String. Complex and String data types
are also converted into a String. If the argument is any other heap object such as
Symbol, Pair, Vector, Structure, or Dictionary, the string function returns
the object's external object id, i.e. #<Vector 1234>.
If the optional {true} argument is specified, the string function will
attempt to convert the object into the same external display string as the
writeln function.
The string function converts a complex number into to a string.
Usage The string function is used to coerce an object into a String or Text.
Any character string that is 15 characters is assigned to a Text data type.
If a character string containing more than 15 characters is assigned to a
String object.
The string function is used for displaying complex numbers.
Complex
Complex
(string obj) (string obj true) The result string (string X) A string in the standard literal format representing the value of the complex argument.
Expression:
Arguments
Name
Type
Description Argument: obj Error Void Character String Symbol Vector BitVector ByteVector IntVector
FltVector ObjVector Structure Dictionary DirectoryPair
Matrix NumMatrix Integer Float Number Complex
The object to be coerced Argument: true Boolean
Optional argument. If present and the obj argument is a heap object, string function
will return the object value instead of the object's external id which is converted
to a string.
Returns:
Expression:
Arguments
Name
Type
Description Argument: X Complex
A complex number.
Returns:
Here are a number of links to Lambda coding examples which contain this instruction in various use cases.
Here are the links to the data types of the function arguments.
Error | Void | Character | String |
Symbol | Vector | BitVector | ByteVector |
IntVector | FltVector | ObjVector | Structure |
Dictionary | Directory | Pair | Matrix |
NumMatrix | Integer | Float | Number |
Complex |
Here are also a number of links to functions having arguments with any of these data types.
Analytic Information Server (AIS)AIS Component Systems
|