Package com.openfin.desktop
Class DesktopUtils
- java.lang.Object
-
- com.openfin.desktop.DesktopUtils
-
public class DesktopUtils extends java.lang.ObjectHelper methods- Since:
- 12/8/14
- Author:
- wche
-
-
Constructor Summary
Constructors Constructor Description DesktopUtils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidaddEventListener(Window window, java.lang.String evenType, EventListener eventListener)Add event listener to a window.static voiderrorAck(AckListener callback, Ack ack)static voiderrorAckOnException(AckListener ackListener, java.lang.Object source, java.lang.Exception ex)Call onError of an AckListen for an exceptionstatic AckgetNack(java.lang.Object source, java.lang.Exception ex)static AckgetNack(java.lang.Object source, java.lang.String reason)static booleanisMac()static booleanisUnix()static booleanisWindows()static voidsuccessAck(AckListener ackListener, Ack ack)Call onSuccess of an AckListen
-
-
-
Method Detail
-
errorAckOnException
public static void errorAckOnException(AckListener ackListener, java.lang.Object source, java.lang.Exception ex)
Call onError of an AckListen for an exception- Parameters:
ackListener- AckListener to be calledsource- Source of the Ackex- Exception for the Ack- See Also:
Ack,AckListener
-
getNack
public static Ack getNack(java.lang.Object source, java.lang.Exception ex)
-
getNack
public static Ack getNack(java.lang.Object source, java.lang.String reason)
-
successAck
public static void successAck(AckListener ackListener, Ack ack)
Call onSuccess of an AckListen- Parameters:
ackListener- AckListener to be calledack- an instance of Ack to be passed to ackListener- See Also:
Ack,AckListener
-
errorAck
public static void errorAck(AckListener callback, Ack ack)
-
addEventListener
public static void addEventListener(Window window, java.lang.String evenType, EventListener eventListener) throws java.lang.Exception
Add event listener to a window. Since this blocks for response, it should NOT called on websocket read thread.- Parameters:
window- an instance of WindowevenType- type of eventeventListener- EventListner to be added- Throws:
java.lang.Exception- if this method fails to add event listener
-
isWindows
public static boolean isWindows()
-
isMac
public static boolean isMac()
-
isUnix
public static boolean isUnix()
-
-