Package com.openfin.desktop.test
Class Test
java.lang.Object
com.openfin.desktop.test.Test
- All Implemented Interfaces:
DesktopStateListener
public class Test extends java.lang.Object implements DesktopStateListener
-
Constructor Summary
Constructors Constructor Description Test()
-
Method Summary
Modifier and Type Method Description void
createChannelClient()
Create a channel client that invokes "getValue", "increment" and "incrementBy n" actionsvoid
createChannelProvider()
Create a provider that supports "getValue", "increment" and "incrementBy n" actionsstatic void
main(java.lang.String[] args)
void
onClose(java.lang.String error)
Callback when connection is closedvoid
onError(java.lang.String reason)
Callback when client cannot start or connect to the Desktop.void
onMessage(java.lang.String message)
Callback when a message is sent to this clientvoid
onOutgoingMessage(java.lang.String message)
Callback when a message is sent from this clientvoid
onReady()
Callback when Desktop is successfully connected and ready to accept commands.
-
Constructor Details
-
Test
public Test()
-
-
Method Details
-
createChannelProvider
public void createChannelProvider()Create a provider that supports "getValue", "increment" and "incrementBy n" actions -
createChannelClient
public void createChannelClient()Create a channel client that invokes "getValue", "increment" and "incrementBy n" actions -
onReady
public void onReady()Description copied from interface:DesktopStateListener
Callback when Desktop is successfully connected and ready to accept commands.- Specified by:
onReady
in interfaceDesktopStateListener
-
onClose
public void onClose(java.lang.String error)Description copied from interface:DesktopStateListener
Callback when connection is closed- Specified by:
onClose
in interfaceDesktopStateListener
- Parameters:
error
- Error message. null for normal close
-
onError
public void onError(java.lang.String reason)Description copied from interface:DesktopStateListener
Callback when client cannot start or connect to the Desktop.- Specified by:
onError
in interfaceDesktopStateListener
- Parameters:
reason
- Error message
-
onMessage
public void onMessage(java.lang.String message)Description copied from interface:DesktopStateListener
Callback when a message is sent to this client- Specified by:
onMessage
in interfaceDesktopStateListener
- Parameters:
message
- Message text
-
onOutgoingMessage
public void onOutgoingMessage(java.lang.String message)Description copied from interface:DesktopStateListener
Callback when a message is sent from this client- Specified by:
onOutgoingMessage
in interfaceDesktopStateListener
- Parameters:
message
- Message text
-
main
public static void main(java.lang.String[] args)
-