org.eclipse.viatra.query.runtime.localsearch.operations.extend

## Class IterateOverChildren

- java.lang.Object
- - org.eclipse.viatra.query.runtime.localsearch.operations.extend.ExtendOperation<org.eclipse.emf.ecore.EObject>
  - - org.eclipse.viatra.query.runtime.localsearch.operations.extend.IterateOverChildren

- All Implemented Interfaces:
    ISearchOperation

      public class IterateOverChildren
      extends ExtendOperation<org.eclipse.emf.ecore.EObject>

  Iterates all child elements of a selected EObjects.

- - ### Field Summary

    - ### Fields inherited from class org.eclipse.viatra.query.runtime.localsearch.operations.extend.ExtendOperation

      `it, position`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `IterateOverChildren(int position, int sourcePosition, boolean transitive)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.util.List<java.lang.Integer>` | `getVariablePositions()`
    `void` | `onInitialize(MatchingFrame frame, ISearchContext context)` During the execution of the corresponding plan, the onInitialize callback is evaluated before the execution of the operation may begin.
    `java.lang.String` | `toString()`

    - ### Methods inherited from class org.eclipse.viatra.query.runtime.localsearch.operations.extend.ExtendOperation

      `execute, onBacktrack`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### IterateOverChildren

          public IterateOverChildren(int position,
                                     int sourcePosition,
                                     boolean transitive)

      Parameters:
        `position` - the position of the variable storing the child elements
        `sourcePosition` - the position of the variable storing the parent root; must be bound
        `transitive` - if true, child elements are iterated over transitively

  - ### Method Detail

    - #### onInitialize

          public void onInitialize(MatchingFrame frame,
                                   ISearchContext context)

      Description copied from interface: `ISearchOperation`
      During the execution of the corresponding plan, the onInitialize callback is evaluated before the execution of the operation may begin. Operations may use this method to initialize its internal data structures.

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`

    - #### getVariablePositions

          public java.util.List<java.lang.Integer> getVariablePositions()

      Returns:
        the ordered list of the variable numbers that are affected by the search operation