Class ResultDeliveryStrategyImpl

java.lang.Object
com.espertech.esper.runtime.internal.subscriber.ResultDeliveryStrategyImpl
All Implemented Interfaces:
ResultDeliveryStrategy

public class ResultDeliveryStrategyImpl extends Object implements ResultDeliveryStrategy
A result delivery strategy that uses a matching "update" method and optional start, end, and updateRStream methods, to deliver column-wise to parameters of the update method.
  • Constructor Details

    • ResultDeliveryStrategyImpl

      public ResultDeliveryStrategyImpl(EPStatement statement, Object subscriber, DeliveryConvertor deliveryConvertor, Method method, Method startMethod, Method endMethod, Method rStreamMethod, com.espertech.esper.common.internal.settings.ClasspathImportService classpathImportService)
      Ctor.
      Parameters:
      subscriber - is the subscriber receiving method invocations
      deliveryConvertor - for converting individual rows
      method - to deliver the insert stream to
      startMethod - to call to indicate when delivery starts, or null if no such indication is required
      endMethod - to call to indicate when delivery ends, or null if no such indication is required
      rStreamMethod - to deliver the remove stream to, or null if no such indication is required
      statement - statement
      classpathImportService - runtime imports
  • Method Details

    • execute

      public void execute(com.espertech.esper.common.internal.collection.UniformPair<com.espertech.esper.common.client.EventBean[]> result)
      Description copied from interface: ResultDeliveryStrategy
      Execute the dispatch.
      Specified by:
      execute in interface ResultDeliveryStrategy
      Parameters:
      result - is the insert and remove stream to indicate
    • handle

      protected static void handle(String statementName, org.slf4j.Logger logger, ReflectiveOperationException e, Object[] parameters, Object subscriber, Method method)
      Handle the exception, displaying a nice message and converting to EPException.
      Parameters:
      logger - is the logger to use for error logging
      e - is the exception
      parameters - the method parameters
      subscriber - the object to deliver to
      method - the method to call
      statementName - statement name
      Throws:
      com.espertech.esper.common.client.EPException - converted from the passed invocation exception
    • handleThrowable

      protected static void handleThrowable(org.slf4j.Logger logger, Throwable t, Object[] parameters, Object subscriber, Method method)
      Handle the exception, displaying a nice message and converting to EPException.
      Parameters:
      logger - is the logger to use for error logging
      t - is the throwable
      parameters - the method parameters
      subscriber - the object to deliver to
      method - the method to call
      Throws:
      com.espertech.esper.common.client.EPException - converted from the passed invocation exception