org.norecess.citkit.tir.expressions
Class LambdaETIR

java.lang.Object
  extended by org.norecess.citkit.tir.expressions.LambdaETIR
All Implemented Interfaces:
ILambdaETIR, ExpressionTIR, HobbesTIR

public class LambdaETIR
extends java.lang.Object
implements ILambdaETIR


Constructor Summary
LambdaETIR(IPosition position, java.lang.String parameter, ExpressionTIR body)
           
LambdaETIR(java.lang.String variable, ExpressionTIR body)
           
 
Method Summary
<A> A
accept(ExpressionTIRVisitor<A> visitor)
          Implements the visitor pattern with ExpressionTIRVisitor.
 boolean equals(java.lang.Object other)
           
 ExpressionTIR getBody()
          Returns the body of the lambda.
 java.lang.String getParameter()
          Returns the single parameter of the lambda.
 IPosition getPosition()
          The position of the TIR in the source code.
 HobbesType getType()
          Retrieves the type of the expression.
 int hashCode()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

LambdaETIR

public LambdaETIR(IPosition position,
                  java.lang.String parameter,
                  ExpressionTIR body)

LambdaETIR

public LambdaETIR(java.lang.String variable,
                  ExpressionTIR body)
Method Detail

getParameter

public java.lang.String getParameter()
Returns the single parameter of the lambda.

Specified by:
getParameter in interface ILambdaETIR
Returns:
the parameter.

getBody

public ExpressionTIR getBody()
Returns the body of the lambda.

Specified by:
getBody in interface ILambdaETIR
Returns:
the body.

equals

public boolean equals(java.lang.Object other)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

accept

public <A> A accept(ExpressionTIRVisitor<A> visitor)
Description copied from interface: ExpressionTIR
Implements the visitor pattern with ExpressionTIRVisitor.

Specified by:
accept in interface ExpressionTIR
Parameters:
visitor - the visitor object.
Returns:
the result of visiting the AST with the visitor.

getType

public HobbesType getType()
Description copied from interface: ExpressionTIR
Retrieves the type of the expression.

Specified by:
getType in interface ExpressionTIR
Returns:
the type of the code.

getPosition

public IPosition getPosition()
Description copied from interface: HobbesTIR
The position of the TIR in the source code.

Specified by:
getPosition in interface HobbesTIR

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object