Class FreezeBlock

All Implemented Interfaces:
IDatatypeVisitable, IModelElement

public class FreezeBlock extends EvaluationBlock
Handles frozen elements.
Author:
Marcel Lueder, Holger Eichelberger
  • Field Details

  • Constructor Details

    • FreezeBlock

      FreezeBlock()
      Constructor for serialization.
    • FreezeBlock

      public FreezeBlock(IFreezable[] freezables, DecisionVariableDeclaration iter, ConstraintSyntaxTree selector, IModelElement parent)
      Constructor for containable model element.
      Parameters:
      freezables - the elements which may be frozen (depends on buts)
      iter - the iterator variable for selector, may be null
      selector - the selector expression using iter, may be null
      parent - the object, in which this specific one is embedded
  • Method Details

    • accept

      public void accept(IModelVisitor visitor)
      Description copied from interface: IModelElement
      Accept method for the visitor.
      Parameters:
      visitor - The visitor, which should process this model element.
    • getType

      public IDatatype getType()
      Returns the internal type of this block.
      Returns:
      the internal type
    • getSelector

      public ConstraintSyntaxTree getSelector()
      Returns the selector.
      Returns:
      the selector (may be null)
    • getIter

      public DecisionVariableDeclaration getIter()
      Returns the iterator variable.
      Returns:
      the iterator variable (may be null)
    • getFreezableCount

      public int getFreezableCount()
      Returns the number of freezables.
      Returns:
      the number of freezables
    • getFreezable

      public IFreezable getFreezable(int index)
      Returns a specific freezable.
      Parameters:
      index - the index of the freezable
      Returns:
      the freezable
      Throws:
      IndexOutOfBoundsException - if index<0 || index>=getFreezableCount()
    • toString

      public String toString()
      Overrides:
      toString in class ModelElement