Expression

com.phasmidsoftware.lascala.parser.Expression
trait Expression

Separated from RuleParser by scalaprof on 7/8/16 at which time evaluate and asQuotedString added.

TODO Trait Expression which needs a better description

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class RuleParser.this.Expr
class RuleParser.this.ExprFactor
class RuleParser.this.Literal
class RuleParser.this.Number
class RuleParser.this.Variable
class RuleParser.this.ExprTerm
Show all

Members list

Value members

Abstract methods

def asQuotedString: Option[String]

Attributes

Returns

Some(string) if this Expression represents a single, quoted string. Otherwise, None.

def asString: String
def toRPN: List[String]

Concrete methods

def evaluate[X](implicit evidence$1: Valuable[X], lookup: String => Option[X]): Try[Either[String, X]]

Evaluate this expression as either an X, a String or (failing) a Throwable

Evaluate this expression as either an X, a String or (failing) a Throwable

Type parameters

X

the underlying type of the Valuable result

Attributes

Returns

Either a Throwable or Either a String or an X