Defines methods for transferring messages using the WebSocket protocol. More...
Public Member Functions | |
| void | open (java.util.HashMap< String, String > headers) |
| Opens the WebSocket connection. More... | |
| fm.liveswitch.HttpResponseArgs | send (fm.liveswitch.HttpRequestArgs requestArgs) |
| Sends a request synchronously. More... | |
| void | sendAsync (fm.liveswitch.HttpRequestArgs requestArgs, fm.liveswitch.IAction1< fm.liveswitch.HttpResponseArgs > callback) |
| Sends a request asynchronously. More... | |
| void | shutdown () |
| Releases any resources and shuts down. More... | |
| WebSocketWebRequestTransfer (String url) | |
| Creates a new instance of fm.liveswitch.WebSocketWebRequestTransfer. More... | |
Public Member Functions inherited from fm.liveswitch.WebSocketTransfer | |
| int | getHandshakeTimeout () |
| Gets the timeout for the initial handshake (in ms). More... | |
| fm.liveswitch.IAction1< fm.liveswitch.WebSocketOpenFailureArgs > | getOnOpenFailure () |
| Gets the callback to invoke if the handshake fails. More... | |
| fm.liveswitch.IAction1< fm.liveswitch.WebSocketOpenSuccessArgs > | getOnOpenSuccess () |
| Gets the callback to invoke if the handshake succeeds. More... | |
| fm.liveswitch.IAction1< fm.liveswitch.HttpRequestCreatedArgs > | getOnRequestCreated () |
| Gets the callback to invoke when the handshake request is created. More... | |
| fm.liveswitch.IAction1< fm.liveswitch.HttpResponseReceivedArgs > | getOnResponseReceived () |
| Gets the callback to invoke when the handshake response is received. More... | |
| fm.liveswitch.IAction1< fm.liveswitch.WebSocketStreamFailureArgs > | getOnStreamFailure () |
| Gets the callback to invoke if the stream errors out. More... | |
| Object | getSender () |
| Gets the sender of the messages. More... | |
| int | getStreamTimeout () |
| Gets the timeout for the stream (in ms). More... | |
| String | getUrl () |
| Gets the URL. More... | |
| void | setHandshakeTimeout (int value) |
| Sets the timeout for the initial handshake (in ms). More... | |
| void | setOnOpenFailure (fm.liveswitch.IAction1< fm.liveswitch.WebSocketOpenFailureArgs > value) |
| Sets the callback to invoke if the handshake fails. More... | |
| void | setOnOpenSuccess (fm.liveswitch.IAction1< fm.liveswitch.WebSocketOpenSuccessArgs > value) |
| Sets the callback to invoke if the handshake succeeds. More... | |
| void | setOnRequestCreated (fm.liveswitch.IAction1< fm.liveswitch.HttpRequestCreatedArgs > value) |
| Sets the callback to invoke when the handshake request is created. More... | |
| void | setOnResponseReceived (fm.liveswitch.IAction1< fm.liveswitch.HttpResponseReceivedArgs > value) |
| Sets the callback to invoke when the handshake response is received. More... | |
| void | setOnStreamFailure (fm.liveswitch.IAction1< fm.liveswitch.WebSocketStreamFailureArgs > value) |
| Sets the callback to invoke if the stream errors out. More... | |
| void | setSender (Object value) |
| Sets the sender of the messages. More... | |
| void | setStreamTimeout (int value) |
| Sets the timeout for the stream (in ms). More... | |
| void | setUrl (String value) |
| Sets the URL. More... | |
| WebSocketTransfer (String url) | |
| Initializes a new instance of the fm.liveswitch.WebSocketTransfer class. More... | |
Defines methods for transferring messages using the WebSocket protocol.
| fm.liveswitch.WebSocketWebRequestTransfer.WebSocketWebRequestTransfer | ( | String | url | ) |
Creates a new instance of fm.liveswitch.WebSocketWebRequestTransfer.
| url | The URL. |
| void fm.liveswitch.WebSocketWebRequestTransfer.open | ( | java.util.HashMap< String, String > | headers | ) |
Opens the WebSocket connection.
Reimplemented from fm.liveswitch.WebSocketTransfer.
| fm.liveswitch.HttpResponseArgs fm.liveswitch.WebSocketWebRequestTransfer.send | ( | fm.liveswitch.HttpRequestArgs | requestArgs | ) |
Sends a request synchronously.
| requestArgs | The request parameters. |
Reimplemented from fm.liveswitch.WebSocketTransfer.
| void fm.liveswitch.WebSocketWebRequestTransfer.sendAsync | ( | fm.liveswitch.HttpRequestArgs | requestArgs, |
| fm.liveswitch.IAction1< fm.liveswitch.HttpResponseArgs > | callback | ||
| ) |
Sends a request asynchronously.
| requestArgs | The request parameters. |
| callback | The callback to execute with the resulting response. |
Reimplemented from fm.liveswitch.WebSocketTransfer.
| void fm.liveswitch.WebSocketWebRequestTransfer.shutdown | ( | ) |
Releases any resources and shuts down.
Reimplemented from fm.liveswitch.WebSocketTransfer.