|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjavax.websocket.DefaultClientConfiguration
public class DefaultClientConfiguration
The DefaultClientConfiguration is a concrete implementation of a client configuration. Developers may subclass this class in order to provide their own custom configuration behaviors.
| Constructor Summary | |
|---|---|
DefaultClientConfiguration()
Creates a client configuration with no preferred sub protocols, extensions, decoders or encoders. |
|
| Method Summary | |
|---|---|
void |
afterResponse(HandshakeResponse hr)
The default implementation of this method performs no actions on the HandshakeResponse. |
void |
beforeRequest(Map<String,List<String>> hr)
The default implementation of this method performs no actions on the HandshakeRequest headers. |
List<Decoder> |
getDecoders()
Return the (unmodifiable) list of decoders this client will use. |
List<Encoder> |
getEncoders()
Return the (unmodifiable) list of encoders this client will use. |
List<Extension> |
getExtensions()
Return the extensions, in order of preference, favorite first, that this client would like to use for its sessions. |
List<String> |
getPreferredSubprotocols()
Return the protocols, in order of preference, favorite first, that this client would like to use for its sessions. |
DefaultClientConfiguration |
setDecoders(List<Decoder> decoders)
Assign the list of decoders this client will use. |
DefaultClientConfiguration |
setEncoders(List<Encoder> encoders)
Assign the list of encoders this client will use. |
DefaultClientConfiguration |
setExtensions(List<Extension> extensions)
Assign the List of preferred extensions that this client would like to use. |
DefaultClientConfiguration |
setPreferredSubprotocols(List<String> preferredSubprotocols)
Assign the List of preferred subprotocols that this client would like to use. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultClientConfiguration()
| Method Detail |
|---|
public List<String> getPreferredSubprotocols()
getPreferredSubprotocols in interface ClientEndpointConfigurationpublic DefaultClientConfiguration setPreferredSubprotocols(List<String> preferredSubprotocols)
preferredSubprotocols - the preferred subprotocols.
public List<Extension> getExtensions()
getExtensions in interface ClientEndpointConfigurationpublic DefaultClientConfiguration setExtensions(List<Extension> extensions)
extensions - the extensions, cannot be null.
public List<Encoder> getEncoders()
getEncoders in interface EndpointConfigurationpublic DefaultClientConfiguration setEncoders(List<Encoder> encoders)
encoders - the encoders to use, cannot be null.
public List<Decoder> getDecoders()
getDecoders in interface EndpointConfigurationpublic DefaultClientConfiguration setDecoders(List<Decoder> decoders)
decoders - the extensions, cannot be null.
public void beforeRequest(Map<String,List<String>> hr)
beforeRequest in interface ClientEndpointConfigurationhr - handshake request the implementation has formulated.public void afterResponse(HandshakeResponse hr)
afterResponse in interface ClientEndpointConfigurationhr - the handshake response sent by the server.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||