Class DequeueContext


  • public final class DequeueContext
    extends Object
    Context for component dequeueing. Keeps track of markup position and container stack.
    Author:
    igor
    • Method Detail

      • save

        public DequeueContext.Bookmark save()
        Saves the state of the context into a bookmark which can later be used to restore it.
      • restore

        public void restore​(DequeueContext.Bookmark bookmark)
        Restores the state of the context from the bookmark
        Parameters:
        bookmark -
      • peekTag

        public ComponentTag peekTag()
        Peeks markup tag that would be retrieved by call to takeTag()
        Returns:
      • takeTag

        public ComponentTag takeTag()
        Retrieves the next markup tag
        Returns:
      • skipToCloseTag

        public void skipToCloseTag()
        Skips to the closing tag of the tag retrieved from last call to takeTag()
      • isAtOpenOrOpenCloseTag

        public boolean isAtOpenOrOpenCloseTag()
        Checks if the tag returned by peekTag() is either open or open-close.
        Returns:
      • peekContainer

        public MarkupContainer peekContainer()
        Retrieves the container on the top of the containers stack
        Returns:
      • pushContainer

        public void pushContainer​(MarkupContainer container)
        Pushes a container onto the container stack
        Parameters:
        container -
      • popContainer

        public MarkupContainer popContainer()
        Pops a container from the container stack
        Returns:
      • findComponentToDequeue

        public Component findComponentToDequeue​(ComponentTag tag)
        Searches the container stack for a component that can be dequeude
        Parameters:
        tag -
        Returns: