java.lang.Object
com.singularsys.jep.configurableparser.tokens.Token
com.singularsys.jep.configurableparser.tokens.SymbolToken
All Implemented Interfaces:
Serializable

public class SymbolToken extends Token
A simple type of token which represents a fixed string of characters. These tokens are returned by the SymbolTokenMatcher.
See Also:
  • Constructor Details

    • SymbolToken

      public SymbolToken(String source)
    • SymbolToken

      public SymbolToken(String source, boolean implicitMul)
      Construct a symbol token with a specified value for the implicit multiplication flag.
      Parameters:
      source - matched text
      implicitMul - where the token can appear on the right-hand side of implicit multiplication.
  • Method Details

    • isSymbol

      public boolean isSymbol()
      Overrides:
      isSymbol in class Token
    • isImplicitMulRhs

      public boolean isImplicitMulRhs()
      Description copied from class: Token
      Whether the token can appear on the right-hand side of implicit multiplication '2 x'.
      Overrides:
      isImplicitMulRhs in class Token
      Returns:
      boolean value corresponding to the result.
    • isRhsImpMul

      public boolean isRhsImpMul()
    • setRhsImpMul

      public void setRhsImpMul(boolean rhsImpMul)
    • cloneToken

      public Token cloneToken()
    • toString

      public String toString()
      Overrides:
      toString in class Token