A token that contains a string, or more specifically, a reference
to an instance of String. The reference is never null, although it may
be an empty string ("").
Note that when this token is cloned, the clone will refer to exactly
the same String object. However, a String object in Java is immutable,
so there is no risk when two tokens refer to the same string that
one of the strings will be changed.
A token that represents a missing value.
Null or missing tokens are common in analytical systems
like R and SAS where they are used to handle sparsely populated data
sources. In database parlance, missing tokens are sometimes called
null tokens. Since null is a Java keyword, we use the term "nil".
The toString() method on a nil token returns the string "nil".
Construct a token with an empty string.
public StringToken(java.lang.String value)
Construct a token with the specified string.
If the value argument is null then the empty string is created.
If the value argument is the string "nil", then the Token is not a
nil token it is the string "nil".
Convert the specified token into an instance of StringToken.
This method does lossless conversion.
If the argument is already an instance of StringToken,
it is returned without any change.
If the argument is a nil token, then
NIL is returned.
Otherwise, if the argument is below StringToken in the type
hierarchy, it is converted to an instance of StringToken or
one of the subclasses of StringToken and returned. If none of
the above condition is met, an exception is thrown.
token - The token to be converted to a StringToken.
Return the string that this token contains. Note that this is
different than the toString method, which returns a string expression
that has double quotes around it.
The contained string.
public java.lang.String toString()
Return the value of this Token as a string. If the value of
the Token contains double quotes, then a backslash is inserted
before each double quote and then double quotes are added to
the beginning and the end, indicating a string constant in the
Return a new token whose value is the value of this token
multiplied by the value of the argument token. It is assumed
that the type of the argument is StringToken.
classes to provide type specific actions for multiply.