Class AbstractListMediator

    • Field Detail

      • msgBuildFailureExpattern

        protected Pattern msgBuildFailureExpattern
      • mediators

        protected final List<Mediator> mediators
        the list of child mediators held. These are executed sequentially
    • Constructor Detail

      • AbstractListMediator

        public AbstractListMediator()
    • Method Detail

      • mediate

        public boolean mediate​(MessageContext synCtx)
        Description copied from interface: Mediator
        Invokes the mediator passing the current message for mediation. Each mediator performs its mediation action, and returns true if mediation should continue, or false if further mediation should be aborted.
        Specified by:
        mediate in interface Mediator
        Parameters:
        synCtx - the current message for mediation
        Returns:
        true if further mediation should continue
      • mediate

        public boolean mediate​(MessageContext synCtx,
                               int mediatorPosition)
      • getList

        public List<Mediator> getList()
        Description copied from interface: ListMediator
        Return the list of mediators of this List mediator instance
        Specified by:
        getList in interface ListMediator
        Returns:
        the child/sub mediator list
      • addChild

        public boolean addChild​(Mediator m)
        Description copied from interface: ListMediator
        Appends the specified mediator to the end of this mediator's (children) list
        Specified by:
        addChild in interface ListMediator
        Parameters:
        m - the mediator to be added
        Returns:
        true (as per the general contract of the Collection.add method)
      • addChild

        public void addChild​(int index,
                             Mediator m)
      • addAll

        public boolean addAll​(List<Mediator> c)
        Description copied from interface: ListMediator
        Appends all of the mediators in the specified collection to the end of this mediator's (children) list, in the order that they are returned by the specified collection's iterator
        Specified by:
        addAll in interface ListMediator
        Parameters:
        c - the list of mediators to be added
        Returns:
        true if this list changed as a result of the call
      • getChild

        public Mediator getChild​(int pos)
        Description copied from interface: ListMediator
        Returns the mediator at the specified position
        Specified by:
        getChild in interface ListMediator
        Parameters:
        pos - index of mediator to return
        Returns:
        the mediator at the specified position in this list
      • removeChild

        public boolean removeChild​(Mediator m)
        Description copied from interface: ListMediator
        Removes the first occurrence in this list of the specified mediator
        Specified by:
        removeChild in interface ListMediator
        Parameters:
        m - mediator to be removed from this list, if present
        Returns:
        true if this list contained the specified mediator
      • removeChild

        public Mediator removeChild​(int pos)
        Description copied from interface: ListMediator
        Removes the mediator at the specified position in this list
        Specified by:
        removeChild in interface ListMediator
        Parameters:
        pos - the index of the mediator to remove
        Returns:
        the mediator previously at the specified position
      • destroy

        public void destroy()
        Destroy child mediators recursively
        Specified by:
        destroy in interface ManagedLifecycle
      • setStatisticIdForMediators

        public void setStatisticIdForMediators​(ArtifactHolder holder)