Class MultiServiceInvocationHandler.IntermediateMethodResultListener<T>

    • Constructor Summary

      Constructors 
      Constructor Description
      IntermediateMethodResultListener​(Future fut, java.lang.reflect.Method method, java.lang.Object[] args, java.lang.reflect.Method muxmethod)
      Create a new listener.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void exceptionOccurred​(java.lang.Exception exception)
      Called when an exception has occurred.
      void finished()
      Called when all services have been found.
      void intermediateResultAvailable​(T result)
      Called when a service has been found.
      void maxResultCountAvailable​(int max)
      Declare that the future result count is available.
      void resultAvailable​(java.util.Collection<T> result)
      Called when services have been found.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • IntermediateMethodResultListener

        public IntermediateMethodResultListener​(Future fut,
                                                java.lang.reflect.Method method,
                                                java.lang.Object[] args,
                                                java.lang.reflect.Method muxmethod)
        Create a new listener.
    • Method Detail

      • resultAvailable

        public void resultAvailable​(java.util.Collection<T> result)
        Called when services have been found.
        Specified by:
        resultAvailable in interface IResultListener<T>
        Parameters:
        result - The result.
      • exceptionOccurred

        public void exceptionOccurred​(java.lang.Exception exception)
        Called when an exception has occurred.
        Specified by:
        exceptionOccurred in interface IResultListener<T>
        Parameters:
        exception - The exception.
      • maxResultCountAvailable

        public void maxResultCountAvailable​(int max)
        Description copied from interface: IIntermediateResultListener
        Declare that the future result count is available. This method is only called for intermediate futures, i.e. when this method is called it is guaranteed that the intermediateResultAvailable method will be called as often as the result count indicates except an exception occurs.
        Specified by:
        maxResultCountAvailable in interface IIntermediateResultListener<T>