|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.glassfish.tyrus.platform.WebSocketEndpointImpl
public class WebSocketEndpointImpl
Handles the registered application class. There is one WebSocketEndpoint for each application class, which handles all the methods (even for various dynamic paths).
| Constructor Summary | |
|---|---|
WebSocketEndpointImpl(ServerContainerImpl containerContext,
java.lang.String path,
Model model,
java.lang.Boolean server)
Creates new endpoint - see above. |
|
WebSocketEndpointImpl(javax.net.websocket.ServerContainer containerContext,
java.lang.String path,
Model model)
Creates new endpoint. |
|
| Method Summary | |
|---|---|
boolean |
checkHandshake(SPIHandshakeRequest hr)
|
protected boolean |
doesPathMatch(java.lang.String remoteUri,
java.lang.String dynamicPath)
Checks whether the provided dynamicPath matches with this endpoint, i.e. |
javax.net.websocket.ServerContainer |
getContainerContext()
|
protected RemoteEndpointWrapper |
getPeer(SPIRemoteEndpoint gs)
|
java.util.List<java.lang.String> |
getSupportedProtocols(java.util.List<java.lang.String> subProtocol)
|
void |
handleGeneratedBeanException(javax.net.websocket.RemoteEndpoint peer,
java.lang.Exception e)
|
void |
onClose(SPIRemoteEndpoint gs)
|
void |
onConnect(SPIRemoteEndpoint gs)
|
void |
onGeneratedBeanClose(RemoteEndpointWrapper peer)
|
void |
onGeneratedBeanConnect(RemoteEndpointWrapper peer)
|
void |
onMessage(SPIRemoteEndpoint gs,
byte[] messageBytes)
|
void |
onMessage(SPIRemoteEndpoint gs,
java.lang.String messageString)
|
void |
remove()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public WebSocketEndpointImpl(javax.net.websocket.ServerContainer containerContext,
java.lang.String path,
Model model)
containerContext - container context.path - address of this endpoint as annotated by WebSocketEndpoint annotation.model - model of the application class.
public WebSocketEndpointImpl(ServerContainerImpl containerContext,
java.lang.String path,
Model model,
java.lang.Boolean server)
containerContext - container context.path - address of this endpoint as annotated by WebSocketEndpoint annotation.model - model of the application class.server - server / client endpoint.| Method Detail |
|---|
protected boolean doesPathMatch(java.lang.String remoteUri,
java.lang.String dynamicPath)
remoteUri - path to be checked.dynamicPath - taken from the WebSocketMessage method annotation.
true if the paths match, false otherwise.public boolean checkHandshake(SPIHandshakeRequest hr)
checkHandshake in interface SPIEndpointpublic java.util.List<java.lang.String> getSupportedProtocols(java.util.List<java.lang.String> subProtocol)
getSupportedProtocols in interface SPIEndpointpublic void remove()
remove in interface SPIEndpointpublic void onConnect(SPIRemoteEndpoint gs)
onConnect in interface SPIEndpoint
public void onMessage(SPIRemoteEndpoint gs,
byte[] messageBytes)
onMessage in interface SPIEndpoint
public void onMessage(SPIRemoteEndpoint gs,
java.lang.String messageString)
onMessage in interface SPIEndpointpublic void onClose(SPIRemoteEndpoint gs)
onClose in interface SPIEndpoint
public void handleGeneratedBeanException(javax.net.websocket.RemoteEndpoint peer,
java.lang.Exception e)
public void onGeneratedBeanConnect(RemoteEndpointWrapper peer)
public void onGeneratedBeanClose(RemoteEndpointWrapper peer)
protected final RemoteEndpointWrapper getPeer(SPIRemoteEndpoint gs)
public javax.net.websocket.ServerContainer getContainerContext()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||