An interface for configuration implementations which support registration of event listeners.
Through the methods provided by this interface it is possible to register and remove listeners for different events supported by this library. The event type to be handled by a listener must be provided; the specified event listener must be compatible with this event type. By using generic type parameters, the compiler can check this.
@version $Id: EventSource.java 1624601 2014-09-12 18:04:36Z oheger $ @since 2.0In case you are using Jersey event source with a Jersey client {@link org.glassfish.jersey.client.ClientConfig#connectorProvider(org.glassfish.jersey.client.spi.ConnectorProvider)}connector provider configured to use some other client {@code ConnectorProvider} implementation able to reliablymanage persistent HTTP connections (such as {@code org.glassfish.jersey.grizzly.connector.GrizzlyConnectorProvider} or{@code org.glassfish.jersey.apache.connector.ApacheConnectorProvider}), or in case you simply need to use persistent HTTP connections, you may do so by invoking the {@link Builder#usePersistentConnections() usePersistentConnections()} methodon an event source builder prior to creating a new event source instance.
@author Pavel Bucek (pavel.bucek at oracle.com) @author Marek Potociar (marek.potociar at oracle.com)
|
|