Class BuildCollectionApplicator


  • public class BuildCollectionApplicator
    extends Applicator
    An applicator which collects the RHS values which need a build and pushes the related match variable values into the given runtime environment.
    Author:
    Holger Eichelberger
    • Field Detail

      • rhsObjects

        private java.util.List<java.util.List<java.lang.Object>> rhsObjects
    • Constructor Detail

      • BuildCollectionApplicator

        public BuildCollectionApplicator​(RuntimeEnvironment environment)
        Creates a build collection applicator for a given runtime environment.
        Parameters:
        environment - the environment to
    • Method Detail

      • apply

        public void apply​(java.lang.Object expectedLhsValue,
                          java.lang.Object rhsValue,
                          int index)
                   throws VilException
        Description copied from class: Applicator
        Apply this applicator for one combination which requires building. This may be due to the fact that rhsValue
        • is newer than expectedLhsValue
        • exists but expectedLhsValue does not exist
        • exists but no LHS is specified (expectedLhsValue is null)
        Specified by:
        apply in class Applicator
        Parameters:
        expectedLhsValue - the expected result after building rhsValue (may be null)
        rhsValue - the value determined for the right side as part of a match
        index - the 0-based index of the RHS match condition in the specifying rule (Applicator.getElementCount()
        Throws:
        VilException - in case that executing parts of a rule or setting variable values fails
      • conditionLoopFinished

        public void conditionLoopFinished()
                                   throws VilException
        Sets the results of the MATCH-variables in environment.
        Overrides:
        conditionLoopFinished in class Applicator
        Throws:
        VilException - in case that setting the a value fails (e.g., redefining a constant)