org.eclipse.emf.henshin.interpreter
Interface Assignment

All Known Subinterfaces:
Match
All Known Implementing Classes:
AssignmentImpl, MatchImpl

public interface Assignment

Interface for parameter assignments. Used for storing parameter values.


Method Summary
 void clear()
          Clear all values stored in this assignment.
 Object getParameterValue(Parameter param)
          Get the value assigned to a parameter.
 List<Object> getParameterValues()
          Get all parameter values.
 Unit getUnit()
          Get the unit that this assignment refers to.
 boolean isEmpty()
          Check whether this assignment is empty.
 boolean isResult()
          Checks whether this is an assignment for a result of a unit application.
 void setParameterValue(Parameter param, Object value)
          Set the assigned value for a parameter.
 

Method Detail

getUnit

Unit getUnit()
Get the unit that this assignment refers to.

Returns:
The unit.

getParameterValue

Object getParameterValue(Parameter param)
Get the value assigned to a parameter.

Parameters:
param - The parameter.
Returns:
The assigned value or null.

setParameterValue

void setParameterValue(Parameter param,
                       Object value)
Set the assigned value for a parameter.

Parameters:
param - The parameter.
value - The value to be assigned with the parameter.

getParameterValues

List<Object> getParameterValues()
Get all parameter values.

Returns:
List of all parameter values.

isEmpty

boolean isEmpty()
Check whether this assignment is empty.

Returns:
true of no values are assigned.

clear

void clear()
Clear all values stored in this assignment.


isResult

boolean isResult()
Checks whether this is an assignment for a result of a unit application.

Returns:
true if it is a result assignment.