A B C D E F G H I J L M O P R S T U V W
All Classes All Packages
All Classes All Packages
All Classes All Packages
A
- alwaysContinue() - Static method in class com.launchdarkly.eventsource.ErrorStrategy
-
Specifies that EventSource should never throw an exception, but should return all errors as
FaultEvent
s. - alwaysThrow() - Static method in class com.launchdarkly.eventsource.ErrorStrategy
-
Specifies that EventSource should always throw an exception if there is an error.
- anyEvents() - Method in class com.launchdarkly.eventsource.EventSource
-
Returns an iterable sequence of events.
- apply(long) - Method in class com.launchdarkly.eventsource.DefaultRetryDelayStrategy
- apply(long) - Method in class com.launchdarkly.eventsource.RetryDelayStrategy
-
Applies the strategy to compute the appropriate retry delay.
- apply(StreamException) - Method in class com.launchdarkly.eventsource.ErrorStrategy
-
Applies the strategy to determine whether to retry after a failure.
- awaitClosed(long) - Method in class com.launchdarkly.eventsource.ConnectStrategy.Client
- awaitClosed(long, TimeUnit) - Method in class com.launchdarkly.eventsource.EventSource
-
Blocks until all underlying threads have terminated and resources have been released.
B
- BackgroundEventHandler - Interface in com.launchdarkly.eventsource.background
-
Interface for an object that will receive SSE events from
BackgroundEventSource
. - BackgroundEventSource - Class in com.launchdarkly.eventsource.background
-
A wrapper for
EventSource
that reads the stream on a worker thread, pushing events to a handler that the caller provides. - BackgroundEventSource.Builder - Class in com.launchdarkly.eventsource.background
-
Builder for configuring
BackgroundEventSource
. - backoffMultiplier(float) - Method in class com.launchdarkly.eventsource.DefaultRetryDelayStrategy
-
Returns a modified strategy with a specific backoff multipler.
- build() - Method in class com.launchdarkly.eventsource.background.BackgroundEventSource.Builder
-
Creates a
BackgroundEventSource
with this configuration. - build() - Method in class com.launchdarkly.eventsource.EventSource.Builder
-
Constructs an
EventSource
using the builder's current properties. - Builder(BackgroundEventHandler, EventSource.Builder) - Constructor for class com.launchdarkly.eventsource.background.BackgroundEventSource.Builder
-
Creates a builder.
- Builder(ConnectStrategy) - Constructor for class com.launchdarkly.eventsource.EventSource.Builder
-
Creates a new builder, specifying how it will connect to a stream.
- Builder(URI) - Constructor for class com.launchdarkly.eventsource.EventSource.Builder
-
Creates a new builder that connects via HTTP, specifying only the stream URI.
- Builder(URL) - Constructor for class com.launchdarkly.eventsource.EventSource.Builder
-
Creates a new builder that connects via HTTP, specifying only the stream URI.
- Builder(HttpUrl) - Constructor for class com.launchdarkly.eventsource.EventSource.Builder
-
Creates a new builder that connects via HTTP, specifying only the stream URI.
C
- Client() - Constructor for class com.launchdarkly.eventsource.ConnectStrategy.Client
- clientBuilderActions(HttpConnectStrategy.ClientConfigurer) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Specifies any type of configuration actions you want to perform on the OkHttpClient builder.
- close() - Method in class com.launchdarkly.eventsource.background.BackgroundEventSource
-
Shuts down the BackgroundEventSource and the underlying EventSource.
- close() - Method in class com.launchdarkly.eventsource.EventSource
-
Permanently shuts down the EventSource.
- close() - Method in class com.launchdarkly.eventsource.MessageEvent
-
Indicates that you are finished with this message.
- CLOSED - com.launchdarkly.eventsource.ReadyState
-
The connection has been closed or has failed, and the EventSource will attempt to reconnect.
- com.launchdarkly.eventsource - package com.launchdarkly.eventsource
-
A client implementation for the Server-Sent Events (SSE) protocol.
- com.launchdarkly.eventsource.background - package com.launchdarkly.eventsource.background
-
A wrapper for using EventSource with a push model and a worker thread.
- CommentEvent - Class in com.launchdarkly.eventsource
-
Describes a comment line received from the stream.
- CommentEvent(String) - Constructor for class com.launchdarkly.eventsource.CommentEvent
-
Creates an instance.
- configure(OkHttpClient.Builder) - Method in interface com.launchdarkly.eventsource.HttpConnectStrategy.ClientConfigurer
-
This method is called with the OkHttp
OkHttpClient.Builder
that will be used for the EventSource, allowing you to call any configuration methods you want. - connect(String) - Method in class com.launchdarkly.eventsource.ConnectStrategy.Client
-
Attempts to connect to a stream.
- CONNECTING - com.launchdarkly.eventsource.ReadyState
-
The EventSource is attempting to make a connection.
- connectionErrorHandler(ConnectionErrorHandler) - Method in class com.launchdarkly.eventsource.background.BackgroundEventSource.Builder
-
Sets the
ConnectionErrorHandler
that should process connection errors. - ConnectionErrorHandler - Interface in com.launchdarkly.eventsource.background
-
Interface for an object that will be notified when
BackgroundEventSource
encounters a network error or receives an error response. - ConnectionErrorHandler.Action - Enum in com.launchdarkly.eventsource.background
-
Return values of
ConnectionErrorHandler.onConnectionError(Throwable)
indicating what action theBackgroundEventSource
should take after an error. - ConnectStrategy - Class in com.launchdarkly.eventsource
-
An abstraction of how
EventSource
should obtain an input stream. - ConnectStrategy() - Constructor for class com.launchdarkly.eventsource.ConnectStrategy
- ConnectStrategy.Client - Class in com.launchdarkly.eventsource
-
An object provided by
ConnectStrategy
that is retained by a singleEventSource
instance to perform all connection attempts by that instance. - ConnectStrategy.Client.Result - Class in com.launchdarkly.eventsource
-
The return type of
ConnectStrategy.Client.connect(String)
. - connectTimeout(long, TimeUnit) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Specifies the connection timeout.
- CONTINUE - com.launchdarkly.eventsource.ErrorStrategy.Action
-
Indicates that EventSource should not throw an exception, but instead return a
FaultEvent
to the caller. - continueWithMaxAttempts(int) - Static method in class com.launchdarkly.eventsource.ErrorStrategy
-
Specifies that EventSource should automatically retry after a failure for up to this number of consecutive attempts, but should throw an exception after that point.
- continueWithTimeLimit(long, TimeUnit) - Static method in class com.launchdarkly.eventsource.ErrorStrategy
-
Specifies that EventSource should automatically retry after a failure and can retry repeatedly until this amount of time has elapsed, but should throw an exception after that point.
- createClient(LDLogger) - Method in class com.launchdarkly.eventsource.ConnectStrategy
-
Creates a client instance.
- createClient(LDLogger) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
- createSocket(String, int) - Method in class com.launchdarkly.eventsource.ModernTLSSocketFactory
- createSocket(String, int, InetAddress, int) - Method in class com.launchdarkly.eventsource.ModernTLSSocketFactory
- createSocket(InetAddress, int) - Method in class com.launchdarkly.eventsource.ModernTLSSocketFactory
- createSocket(InetAddress, int, InetAddress, int) - Method in class com.launchdarkly.eventsource.ModernTLSSocketFactory
- createSocket(Socket, String, int, boolean) - Method in class com.launchdarkly.eventsource.ModernTLSSocketFactory
D
- DEFAULT_BACKOFF_MULTIPLIER - Static variable in class com.launchdarkly.eventsource.DefaultRetryDelayStrategy
-
The default value for
DefaultRetryDelayStrategy.backoffMultiplier(float)
: 2. - DEFAULT_CONNECT_TIMEOUT_MILLIS - Static variable in class com.launchdarkly.eventsource.HttpConnectStrategy
-
The default value for
HttpConnectStrategy.connectTimeout(long, TimeUnit)
: 10 seconds. - DEFAULT_EVENT_NAME - Static variable in class com.launchdarkly.eventsource.MessageEvent
-
The default value of
MessageEvent.getEventName()
for all SSE messages that did not have anevent
field. - DEFAULT_JITTER_MULTIPLIER - Static variable in class com.launchdarkly.eventsource.DefaultRetryDelayStrategy
-
The default value for
DefaultRetryDelayStrategy.jitterMultiplier(float)
: 0.5. - DEFAULT_MAX_DELAY_MILLIS - Static variable in class com.launchdarkly.eventsource.DefaultRetryDelayStrategy
-
The default value for
DefaultRetryDelayStrategy.maxDelay(long, TimeUnit)
: 30 seconds. - DEFAULT_READ_BUFFER_SIZE - Static variable in class com.launchdarkly.eventsource.EventSource
-
The default value for
EventSource.Builder.readBufferSize(int)
. - DEFAULT_READ_TIMEOUT_MILLIS - Static variable in class com.launchdarkly.eventsource.HttpConnectStrategy
-
The default value for
HttpConnectStrategy.readTimeout(long, TimeUnit)
: 5 minutes. - DEFAULT_RETRY_DELAY_MILLIS - Static variable in class com.launchdarkly.eventsource.EventSource
-
The default value for
EventSource.Builder.retryDelay(long, TimeUnit)
: 1 second. - DEFAULT_RETRY_DELAY_RESET_THRESHOLD_MILLIS - Static variable in class com.launchdarkly.eventsource.EventSource
-
The default value for
EventSource.Builder.retryDelayResetThreshold(long, TimeUnit)
: 60 seconds. - DEFAULT_THREAD_BASE_NAME - Static variable in class com.launchdarkly.eventsource.background.BackgroundEventSource
-
Default value for
BackgroundEventSource.Builder.threadBaseName(String)
. - DEFAULT_WRITE_TIMEOUT_MILLIS - Static variable in class com.launchdarkly.eventsource.HttpConnectStrategy
-
The default value for
HttpConnectStrategy.writeTimeout(long, TimeUnit)
: 5 seconds. - DefaultRetryDelayStrategy - Class in com.launchdarkly.eventsource
-
Default implementation of the retry delay strategy, providing exponential backoff and jitter.
- defaultStrategy() - Static method in class com.launchdarkly.eventsource.RetryDelayStrategy
-
Returns the default implementation, configured to use the default backoff and jitter.
E
- equals(Object) - Method in class com.launchdarkly.eventsource.CommentEvent
- equals(Object) - Method in class com.launchdarkly.eventsource.FaultEvent
- equals(Object) - Method in class com.launchdarkly.eventsource.MessageEvent
- equals(Object) - Method in class com.launchdarkly.eventsource.StartedEvent
- equals(Object) - Method in exception com.launchdarkly.eventsource.StreamClosedByCallerException
- equals(Object) - Method in exception com.launchdarkly.eventsource.StreamClosedByServerException
- equals(Object) - Method in exception com.launchdarkly.eventsource.StreamException
- equals(Object) - Method in exception com.launchdarkly.eventsource.StreamIOException
- errorStrategy(ErrorStrategy) - Method in class com.launchdarkly.eventsource.EventSource.Builder
-
Specifies a strategy for determining whether to handle errors transparently or throw them as exceptions.
- ErrorStrategy - Class in com.launchdarkly.eventsource
-
An abstraction of how to determine whether a stream failure should be thrown to the caller as an exception, or treated as an event.
- ErrorStrategy() - Constructor for class com.launchdarkly.eventsource.ErrorStrategy
- ErrorStrategy.Action - Enum in com.launchdarkly.eventsource
-
Describes the possible actions EventSource could take after an error.
- ErrorStrategy.Result - Class in com.launchdarkly.eventsource
-
The return type of
ErrorStrategy.apply(StreamException)
. - eventsExecutor(Executor) - Method in class com.launchdarkly.eventsource.background.BackgroundEventSource.Builder
-
Specifies a custom executor to use for dispatching events.
- EventSource - Class in com.launchdarkly.eventsource
-
The SSE client.
- EventSource.Builder - Class in com.launchdarkly.eventsource
-
Builder for configuring
EventSource
. - expectFields(String...) - Method in class com.launchdarkly.eventsource.EventSource.Builder
-
Specifies that the application expects the server to send certain fields in every event.
F
- FaultEvent - Class in com.launchdarkly.eventsource
-
Describes a failure in the stream.
- FaultEvent(StreamException) - Constructor for class com.launchdarkly.eventsource.FaultEvent
-
Creates an instance.
G
- getAction() - Method in class com.launchdarkly.eventsource.ErrorStrategy.Result
-
Returns the action that EventSource should take.
- getBaseRetryDelayMillis() - Method in class com.launchdarkly.eventsource.EventSource
-
Returns the current base retry delay.
- getCause() - Method in class com.launchdarkly.eventsource.FaultEvent
-
Returns a
StreamException
describing the cause of the failure. - getCloser() - Method in class com.launchdarkly.eventsource.ConnectStrategy.Client.Result
-
An object that
EventSource
can use to close the connection. - getCode() - Method in exception com.launchdarkly.eventsource.StreamHttpErrorException
-
Returns the HTTP status code.
- getData() - Method in class com.launchdarkly.eventsource.MessageEvent
-
Returns the event data as a string.
- getDataReader() - Method in class com.launchdarkly.eventsource.MessageEvent
-
Returns a single-use
Reader
for consuming the event data. - getDefaultCipherSuites() - Method in class com.launchdarkly.eventsource.ModernTLSSocketFactory
- getDelayMillis() - Method in class com.launchdarkly.eventsource.RetryDelayStrategy.Result
-
Returns the computed delay.
- getEventName() - Method in class com.launchdarkly.eventsource.MessageEvent
-
Returns the event name.
- getEventSource() - Method in class com.launchdarkly.eventsource.background.BackgroundEventSource
-
Returns the underlying EventSource.
- getInputStream() - Method in class com.launchdarkly.eventsource.ConnectStrategy.Client.Result
-
The input stream that
EventSource
should read from. - getIOException() - Method in exception com.launchdarkly.eventsource.StreamIOException
-
Returns the original error as an
IOException
. - getLastEventId() - Method in class com.launchdarkly.eventsource.EventSource
-
Returns the ID value, if any, of the last known event.
- getLastEventId() - Method in class com.launchdarkly.eventsource.MessageEvent
-
Returns the event ID, if any.
- getLogger() - Method in class com.launchdarkly.eventsource.EventSource
-
Returns the logger that this EventSource is using.
- getNext() - Method in class com.launchdarkly.eventsource.ErrorStrategy.Result
-
Returns the strategy instance to be used for the next retry, or null to use the same instance as last time.
- getNext() - Method in class com.launchdarkly.eventsource.RetryDelayStrategy.Result
-
Returns the strategy instance to be used for the next retry, or null to use the same instance as last time.
- getNextRetryDelayMillis() - Method in class com.launchdarkly.eventsource.EventSource
-
Returns the retry delay that will be used for the next reconnection, if the stream has failed.
- getOrigin() - Method in class com.launchdarkly.eventsource.ConnectStrategy.Client
-
Returns the expected URI of the stream.
- getOrigin() - Method in class com.launchdarkly.eventsource.ConnectStrategy.Client.Result
-
The origin URI that should be included in every
MessageEvent
. - getOrigin() - Method in class com.launchdarkly.eventsource.EventSource
-
Returns the stream URI.
- getOrigin() - Method in class com.launchdarkly.eventsource.MessageEvent
-
Returns the endpoint of the stream that generated the event.
- getState() - Method in class com.launchdarkly.eventsource.EventSource
-
Returns an enum indicating the current status of the connection.
- getSupportedCipherSuites() - Method in class com.launchdarkly.eventsource.ModernTLSSocketFactory
- getText() - Method in class com.launchdarkly.eventsource.CommentEvent
-
Returns the comment text, not including the leading colon.
H
- hashCode() - Method in class com.launchdarkly.eventsource.CommentEvent
- hashCode() - Method in class com.launchdarkly.eventsource.FaultEvent
- hashCode() - Method in class com.launchdarkly.eventsource.MessageEvent
- hashCode() - Method in class com.launchdarkly.eventsource.StartedEvent
- hashCode() - Method in exception com.launchdarkly.eventsource.StreamClosedByCallerException
- hashCode() - Method in exception com.launchdarkly.eventsource.StreamClosedByServerException
- hashCode() - Method in exception com.launchdarkly.eventsource.StreamException
- hashCode() - Method in exception com.launchdarkly.eventsource.StreamIOException
- header(String, String) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Sets a custom header to be included in each request.
- headers(Headers) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Sets custom headers to be included in each request.
- http(URI) - Static method in class com.launchdarkly.eventsource.ConnectStrategy
-
Returns the default HTTP implementation, specifying a stream URI.
- http(URL) - Static method in class com.launchdarkly.eventsource.ConnectStrategy
-
Returns the default HTTP implementation, specifying a stream URL.
- http(HttpUrl) - Static method in class com.launchdarkly.eventsource.ConnectStrategy
-
Returns the default HTTP implementation, specifying a stream URI.
- httpClient(OkHttpClient) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Set a custom HTTP client that will be used to make the EventSource connection.
- HttpConnectStrategy - Class in com.launchdarkly.eventsource
-
Allows configuration of HTTP request behavior for
EventSource
. - HttpConnectStrategy.ClientConfigurer - Interface in com.launchdarkly.eventsource
-
An interface for use with
HttpConnectStrategy.clientBuilderActions(ClientConfigurer)
. - HttpConnectStrategy.RequestTransformer - Interface in com.launchdarkly.eventsource
-
An interface for use with
HttpConnectStrategy.requestTransformer(RequestTransformer)
.
I
- interrupt() - Method in class com.launchdarkly.eventsource.EventSource
-
Stops the stream connection if it is currently active.
- isStreamingData() - Method in class com.launchdarkly.eventsource.MessageEvent
-
Returns
true
if this event was dispatched with streaming data behavior rather than pre-read data.
J
- jitterMultiplier(float) - Method in class com.launchdarkly.eventsource.DefaultRetryDelayStrategy
-
Returns a modified strategy with a specific jitter multipler.
L
- lastEventId(String) - Method in class com.launchdarkly.eventsource.EventSource.Builder
-
Sets the ID value of the last event received.
- logger(LDLogger) - Method in class com.launchdarkly.eventsource.EventSource.Builder
-
Specifies a custom logger to receive EventSource logging.
M
- maxDelay(long, TimeUnit) - Method in class com.launchdarkly.eventsource.DefaultRetryDelayStrategy
-
Returns a modified strategy with a specific maximum delay.
- maxEventTasksInFlight(int) - Method in class com.launchdarkly.eventsource.background.BackgroundEventSource.Builder
-
Specifies the maximum number of tasks that can be "in-flight" for the thread executing
BackgroundEventHandler
. - MessageEvent - Class in com.launchdarkly.eventsource
-
Information about a message received from the stream.
- MessageEvent(String) - Constructor for class com.launchdarkly.eventsource.MessageEvent
-
Simple constructor with event data only, using the default event name.
- MessageEvent(String, Reader, String, URI) - Constructor for class com.launchdarkly.eventsource.MessageEvent
-
Constructs a new instance with lazy-loading behavior.
- MessageEvent(String, String) - Constructor for class com.launchdarkly.eventsource.MessageEvent
-
Constructs a new instance.
- MessageEvent(String, String, String, URI) - Constructor for class com.launchdarkly.eventsource.MessageEvent
-
Constructs a new instance.
- MessageEvent(String, String, URI) - Constructor for class com.launchdarkly.eventsource.MessageEvent
-
Constructs a new instance with the default event name.
- messages() - Method in class com.launchdarkly.eventsource.EventSource
-
Returns an iterable sequence of SSE messages.
- methodAndBody(String, RequestBody) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Specifies the request method and body to be used for HTTP requests.
- ModernTLSSocketFactory - Class in com.launchdarkly.eventsource
-
An
SSLSocketFactory
that tries to ensure modern TLS versions are used.
O
- onClosed() - Method in interface com.launchdarkly.eventsource.background.BackgroundEventHandler
-
BackgroundEventSource calls this method when the stream connection has been closed.
- onComment(String) - Method in interface com.launchdarkly.eventsource.background.BackgroundEventHandler
-
EventSource calls this method when it has received a comment line from the stream (any line starting with a colon).
- onConnectionError(Throwable) - Method in interface com.launchdarkly.eventsource.background.ConnectionErrorHandler
-
This method is called synchronously for all exceptions that occur on the socket connection (including a
StreamHttpErrorException
if the server returns an unexpected HTTP status, orEOFException
if the streaming response has ended). - onError(Throwable) - Method in interface com.launchdarkly.eventsource.background.BackgroundEventHandler
-
This method will be called for all exceptions that occur on the socket connection (including an
StreamHttpErrorException
if the server returns an unexpected HTTP status), but only after theConnectionErrorHandler
(if any) has processed it. - onMessage(String, MessageEvent) - Method in interface com.launchdarkly.eventsource.background.BackgroundEventHandler
-
EventSource calls this method when it has received a new event from the stream.
- onOpen() - Method in interface com.launchdarkly.eventsource.background.BackgroundEventHandler
-
EventSource calls this method when the stream connection has been opened.
- OPEN - com.launchdarkly.eventsource.ReadyState
-
The connection is active and the EventSource is listening for events.
P
- PROCEED - com.launchdarkly.eventsource.background.ConnectionErrorHandler.Action
-
Specifies that the error should be logged normally and dispatched to the
BackgroundEventHandler
. - proxy(String, int) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Specifies a web proxy to be used for all HTTP connections.
- proxy(Proxy) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Specifies a web proxy to be used for all HTTP connections.
- proxyAuthenticator(Authenticator) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Specifies a web proxy authenticator to be used for all HTTP connections.
R
- RAW - com.launchdarkly.eventsource.ReadyState
-
The EventSource's
EventSource.start()
method has not yet been called. - readAnyEvent() - Method in class com.launchdarkly.eventsource.EventSource
-
Attempts to receive an event of any kind from the stream.
- readBufferSize(int) - Method in class com.launchdarkly.eventsource.EventSource.Builder
-
Specifies the fixed size of the buffer that EventSource uses to parse incoming data.
- readMessage() - Method in class com.launchdarkly.eventsource.EventSource
-
Attempts to receive a message from the stream.
- readTimeout(long, TimeUnit) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Sets the read timeout.
- ReadyState - Enum in com.launchdarkly.eventsource
-
Enum values that can be returned by
EventSource.getState()
. - requestTransformer(HttpConnectStrategy.RequestTransformer) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Specifies an object that will be used to customize outgoing requests.
- Result(long, RetryDelayStrategy) - Constructor for class com.launchdarkly.eventsource.RetryDelayStrategy.Result
-
Constructs an instance.
- Result(ErrorStrategy.Action, ErrorStrategy) - Constructor for class com.launchdarkly.eventsource.ErrorStrategy.Result
-
Constructs an instance.
- Result(InputStream, URI, Closeable) - Constructor for class com.launchdarkly.eventsource.ConnectStrategy.Client.Result
-
Creates an instance.
- retryDelay(long, TimeUnit) - Method in class com.launchdarkly.eventsource.EventSource.Builder
-
Sets the base delay between connection attempts.
- retryDelayResetThreshold(long, TimeUnit) - Method in class com.launchdarkly.eventsource.EventSource.Builder
-
Sets the minimum amount of time that a connection must stay open before the EventSource resets its delay strategy.
- retryDelayStrategy(RetryDelayStrategy) - Method in class com.launchdarkly.eventsource.EventSource.Builder
-
Specifies a strategy for determining the retry delay after an error.
- RetryDelayStrategy - Class in com.launchdarkly.eventsource
-
RetryDelayStrategy is an abstraction of how EventSource should determine the delay between retry attempts when a stream fails.
- RetryDelayStrategy() - Constructor for class com.launchdarkly.eventsource.RetryDelayStrategy
- RetryDelayStrategy.Result - Class in com.launchdarkly.eventsource
-
The return type of
RetryDelayStrategy.apply(long)
.
S
- SHUTDOWN - com.launchdarkly.eventsource.background.ConnectionErrorHandler.Action
-
Specifies that the connection should be immediately shut down and not retried.
- SHUTDOWN - com.launchdarkly.eventsource.ReadyState
-
The connection has been permanently closed and will not reconnect.
- start() - Method in class com.launchdarkly.eventsource.background.BackgroundEventSource
-
Starts the worker thread to consume the stream and dispatch events.
- start() - Method in class com.launchdarkly.eventsource.EventSource
-
Attempts to start the stream if it is not already active.
- StartedEvent - Class in com.launchdarkly.eventsource
-
Represents the beginning of a stream.
- StartedEvent() - Constructor for class com.launchdarkly.eventsource.StartedEvent
- stop() - Method in class com.launchdarkly.eventsource.EventSource
-
Stops the stream connection if it is currently active.
- StreamClosedByCallerException - Exception in com.launchdarkly.eventsource
-
An exception indicating that the stream stopped because you explicitly stopped it.
- StreamClosedByCallerException() - Constructor for exception com.launchdarkly.eventsource.StreamClosedByCallerException
-
Constructs an instance.
- StreamClosedByServerException - Exception in com.launchdarkly.eventsource
-
An exception indicating that the stream stopped because the server closed the connection.
- StreamClosedByServerException() - Constructor for exception com.launchdarkly.eventsource.StreamClosedByServerException
-
Constructs an instance.
- StreamClosedWithIncompleteMessageException - Exception in com.launchdarkly.eventsource
- StreamClosedWithIncompleteMessageException() - Constructor for exception com.launchdarkly.eventsource.StreamClosedWithIncompleteMessageException
- StreamEvent - Interface in com.launchdarkly.eventsource
-
A marker interface for all types of stream information that can be returned by
EventSource.readAnyEvent()
andEventSource.messages()
. - streamEventData(boolean) - Method in class com.launchdarkly.eventsource.EventSource.Builder
-
Specifies whether EventSource should send a
MessageEvent
to the handler as soon as it receives the beginning of the event data, allowing the handler to read the data incrementally withMessageEvent.getDataReader()
. - StreamException - Exception in com.launchdarkly.eventsource
-
Base class for all exceptions thrown by
EventSource
. - StreamException(Exception) - Constructor for exception com.launchdarkly.eventsource.StreamException
-
Base class constructor.
- StreamException(String) - Constructor for exception com.launchdarkly.eventsource.StreamException
-
Base class constructor.
- streamExecutor(Executor) - Method in class com.launchdarkly.eventsource.background.BackgroundEventSource.Builder
-
Specifies a custom executor to use for running the stream-reading task.
- StreamHttpErrorException - Exception in com.launchdarkly.eventsource
-
An exception indicating that the remote server returned an HTTP error.
- StreamHttpErrorException(int) - Constructor for exception com.launchdarkly.eventsource.StreamHttpErrorException
-
Constructs an instance.
- StreamIOException - Exception in com.launchdarkly.eventsource
-
An exception indicating that a connection could not be made, or that an existing connection failed with a network error.
- StreamIOException(IOException) - Constructor for exception com.launchdarkly.eventsource.StreamIOException
-
Constructs an instance.
T
- threadBaseName(String) - Method in class com.launchdarkly.eventsource.background.BackgroundEventSource.Builder
-
Set the name for this BackgroundEventSource to be used when naming thread pools, when BackgroundEventSource is using its default executors.
- threadPriority(Integer) - Method in class com.launchdarkly.eventsource.background.BackgroundEventSource.Builder
-
Specifies the priority for threads created by BackgroundEventSource using its default executors.
- THROW - com.launchdarkly.eventsource.ErrorStrategy.Action
-
Indicates that EventSource should throw a
StreamException
from whatever reading method was called (EventSource.start()
,EventSource.readMessage()
, etc.). - toString() - Method in class com.launchdarkly.eventsource.CommentEvent
- toString() - Method in class com.launchdarkly.eventsource.FaultEvent
- toString() - Method in class com.launchdarkly.eventsource.MessageEvent
- toString() - Method in class com.launchdarkly.eventsource.StartedEvent
- transformRequest(Request) - Method in interface com.launchdarkly.eventsource.HttpConnectStrategy.RequestTransformer
-
Returns a request that is either the same as the input request or based on it.
U
- uri(URI) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Specifies a different stream URI.
V
- valueOf(String) - Static method in enum com.launchdarkly.eventsource.background.ConnectionErrorHandler.Action
-
Returns the enum constant of this type with the specified name.
- valueOf(String) - Static method in enum com.launchdarkly.eventsource.ErrorStrategy.Action
-
Returns the enum constant of this type with the specified name.
- valueOf(String) - Static method in enum com.launchdarkly.eventsource.ReadyState
-
Returns the enum constant of this type with the specified name.
- values() - Static method in enum com.launchdarkly.eventsource.background.ConnectionErrorHandler.Action
-
Returns an array containing the constants of this enum type, in the order they are declared.
- values() - Static method in enum com.launchdarkly.eventsource.ErrorStrategy.Action
-
Returns an array containing the constants of this enum type, in the order they are declared.
- values() - Static method in enum com.launchdarkly.eventsource.ReadyState
-
Returns an array containing the constants of this enum type, in the order they are declared.
W
- writeTimeout(long, TimeUnit) - Method in class com.launchdarkly.eventsource.HttpConnectStrategy
-
Sets the write timeout.
All Classes All Packages