Packageflare.query
Classpublic class Literal
InheritanceLiteral Inheritance Expression

Expression operator for a literal value.



Public Properties
 PropertyDefined by
 InheritednumChildren : int
The number of sub-expressions that are children of this expression.
Expression
  value : Object
The literal value of this expression.
Literal
Public Methods
 MethodDefined by
  
Literal(val:Object = null)
Creates a new Literal instance.
Literal
  
Creates a cloned copy of the expression.
Literal
  
eval(o:Object = null):*
Evaluates this expression with the given input object.
Literal
 Inherited
[static] Utility method that maps an input value into an Expression.
Expression
 Inherited
Returns the sub-expression at the given index.
Expression
  
predicate(o:Object):Boolean
Boolean predicate that tests the output of evaluating this expression.
Literal
 Inherited
setChildAt(idx:int, expr:Expression):Boolean
Set the sub-expression at the given index.
Expression
  
toString():String
Returns a string representation of the expression.
Literal
 Inherited
visit(f:Function):Boolean
Sequentially invokes the input function on this expression and all sub-expressions.
Expression
Public Constants
 ConstantDefined by
  FALSE : Literal
[static] The boolean false literal.
Literal
  TRUE : Literal
[static] The boolean true literal.
Literal
Property detail
valueproperty
value:Object  [read-write]

The literal value of this expression.

Implementation
    public function get value():Object
    public function set value(value:Object):void
Constructor detail
Literal()constructor
public function Literal(val:Object = null)

Creates a new Literal instance.

Parameters
val:Object (default = null) — the literal value
Method detail
clone()method
public override function clone():Expression

Creates a cloned copy of the expression. Recursively clones any sub-expressions.

Returns
Expression — the cloned expression.
eval()method 
public override function eval(o:Object = null):*

Evaluates this expression with the given input object.

Parameters
o:Object (default = null) — the input object to this expression

Returns
* — the result of evaluating the expression
predicate()method 
public override function predicate(o:Object):Boolean

Boolean predicate that tests the output of evaluating this expression. Returns true if the expression evaluates to true, or a non-null or non-zero value. Returns false if the expression evaluates to false, or a null or zero value.

Parameters
o:Object — the input object to this expression

Returns
Boolean — the Boolean result of evaluating the expression
toString()method 
public override function toString():String

Returns a string representation of the expression.

Returns
String — this expression as a string value
Constant detail
FALSEconstant
public static const FALSE:Literal

The boolean false literal.

TRUEconstant 
public static const TRUE:Literal

The boolean true literal.