org.fourthline.cling.transport.impl.jetty
Class StreamClientImpl
java.lang.Object
org.fourthline.cling.transport.spi.AbstractStreamClient<StreamClientConfigurationImpl,StreamClientImpl.HttpContentExchange>
org.fourthline.cling.transport.impl.jetty.StreamClientImpl
- All Implemented Interfaces:
- StreamClient<StreamClientConfigurationImpl>
public class StreamClientImpl
- extends AbstractStreamClient<StreamClientConfigurationImpl,StreamClientImpl.HttpContentExchange>
Implementation based on Jetty 8 client API.
This implementation works on Android, dependencies are the jetty-client
Maven module.
- Author:
- Christian Bauer
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
configuration
protected final StreamClientConfigurationImpl configuration
client
protected final org.eclipse.jetty.client.HttpClient client
StreamClientImpl
public StreamClientImpl(StreamClientConfigurationImpl configuration)
throws InitializationException
- Throws:
InitializationException
getConfiguration
public StreamClientConfigurationImpl getConfiguration()
- Returns:
- This service's configuration.
createRequest
protected StreamClientImpl.HttpContentExchange createRequest(StreamRequestMessage requestMessage)
- Description copied from class:
AbstractStreamClient
- Create a proprietary representation of this request, log warnings and
return
null
if creation fails.
- Specified by:
createRequest
in class AbstractStreamClient<StreamClientConfigurationImpl,StreamClientImpl.HttpContentExchange>
createCallable
protected Callable<StreamResponseMessage> createCallable(StreamRequestMessage requestMessage,
StreamClientImpl.HttpContentExchange exchange)
- Description copied from class:
AbstractStreamClient
- Create a callable procedure that will execute the request.
- Specified by:
createCallable
in class AbstractStreamClient<StreamClientConfigurationImpl,StreamClientImpl.HttpContentExchange>
abort
protected void abort(StreamClientImpl.HttpContentExchange exchange)
- Description copied from class:
AbstractStreamClient
- Cancel and abort the request immediately, with the proprietary API.
- Specified by:
abort
in class AbstractStreamClient<StreamClientConfigurationImpl,StreamClientImpl.HttpContentExchange>
logExecutionException
protected boolean logExecutionException(Throwable t)
- Specified by:
logExecutionException
in class AbstractStreamClient<StreamClientConfigurationImpl,StreamClientImpl.HttpContentExchange>
- Returns:
true
if no more logging of this exception should be done.
stop
public void stop()
- Description copied from interface:
StreamClient
- Stops the service, closes any connection pools etc.
Copyright © 2013 4th Line GmbH, Switzerland. All Rights Reserved.