Class RuntimeKeyGenerator

java.lang.Object
com.aquima.interactions.composer.model.AbstractVisitor
com.aquima.interactions.composer.model.RuntimeKeyGenerator
All Implemented Interfaces:
IVisitor

public class RuntimeKeyGenerator extends AbstractVisitor
Visitor for generating unique runtime keys for every element.
Since:
5.0
Author:
o.kerpershoek, Jon van Leuven
  • Constructor Details

    • RuntimeKeyGenerator

      public RuntimeKeyGenerator()
      Default constructor for the runtime key generator. For internal use only.
    • RuntimeKeyGenerator

      public RuntimeKeyGenerator(RuntimeKey parentKey)
      Constructor for the runtime key generator. For internal use only.
      Parameters:
      parentKey - The runtime key to start with.
  • Method Details

    • acceptContainer

      public IVisitor acceptContainer(IContainer container)
      Specified by:
      acceptContainer in class AbstractVisitor
    • accept

      public IVisitor accept(IElement element)
      Description copied from interface: IVisitor
      This method will be invoked for each element that is encountered during the visit. The return type of this method is the visitor that should be used to process the child elements of the current element. When the current element does not have any children, or when the child elements should not be processed, this method should return a null value as result. The returned visitor may either be a new visitor, for instance with specific context information for the element, or the same visitor.
      Specified by:
      accept in interface IVisitor
      Overrides:
      accept in class AbstractVisitor
      Parameters:
      element - The current element that is encountered by the visitor.
      Returns:
      A visitor that should be used to process child elements.
    • acceptCustomElement

      public IVisitor acceptCustomElement(IElement element)
      Specified by:
      acceptCustomElement in class AbstractVisitor
    • acceptButton

      public void acceptButton(IButton button)
      Specified by:
      acceptButton in class AbstractVisitor
    • acceptField

      public void acceptField(IField field)
      Specified by:
      acceptField in class AbstractVisitor
    • acceptText

      public void acceptText(IAsset text)
      Specified by:
      acceptText in class AbstractVisitor
    • acceptPage

      public IVisitor acceptPage(IPage page)
      Specified by:
      acceptPage in class AbstractVisitor
    • acceptImage

      protected void acceptImage(IImage image)
      Specified by:
      acceptImage in class AbstractVisitor
    • acceptDocument

      public IVisitor acceptDocument(IDocument document)
      Specified by:
      acceptDocument in class AbstractVisitor
    • leave

      public void leave(ICompositeElement container, IVisitor childVisitor)
      Description copied from interface: IVisitor
      This method will be invoked after all the children of the specified container have been processed with the childVisitor. The implementation of this method may choose to merge the results of the child visitor with this visitor.
      Parameters:
      container - The container of whom the child visitor has completed.
      childVisitor - The child visitor that was used to evaluate the children of the container.
    • generateId

      protected String generateId(IElement element, int index)