Class EventSender.Result

java.lang.Object
com.launchdarkly.sdk.server.interfaces.EventSender.Result
Enclosing interface:
EventSender

public static final class EventSender.Result
extends java.lang.Object
Encapsulates the results of a call to EventSender.sendEventData(EventDataKind, String, int, URI).
  • Constructor Summary

    Constructors 
    Constructor Description
    Result​(boolean success, boolean mustShutDown, java.util.Date timeFromServer)
    Constructs an instance.
  • Method Summary

    Modifier and Type Method Description
    java.util.Date getTimeFromServer()
    Returns the parsed value of an HTTP Date header received from the remote server, if any.
    boolean isMustShutDown()
    Returns true if an unrecoverable error (such as an HTTP 401 error, implying that the SDK key is invalid) means the SDK should permanently stop trying to send events
    boolean isSuccess()
    Returns true if the events were delivered.

    Methods inherited from class java.lang.Object

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

    • Result

      public Result​(boolean success, boolean mustShutDown, java.util.Date timeFromServer)
      Constructs an instance.
      Parameters:
      success - true if the events were delivered
      mustShutDown - true if an unrecoverable error (such as an HTTP 401 error, implying that the SDK key is invalid) means the SDK should permanently stop trying to send events
      timeFromServer - the parsed value of an HTTP Date header received from the remote server, if any; this is used to compensate for differences between the application's time and server time
  • Method Details

    • isSuccess

      public boolean isSuccess()
      Returns true if the events were delivered.
      Returns:
      true if the events were delivered
    • isMustShutDown

      public boolean isMustShutDown()
      Returns true if an unrecoverable error (such as an HTTP 401 error, implying that the SDK key is invalid) means the SDK should permanently stop trying to send events
      Returns:
      true if event delivery should shut down
    • getTimeFromServer

      public java.util.Date getTimeFromServer()
      Returns the parsed value of an HTTP Date header received from the remote server, if any. This is used to compensate for differences between the application's time and server time.
      Returns:
      a date value or null