org.gnome.unique

## Interface Application.MessageReceived

- Enclosing class:
    org.gnome.unique.Application

      public static interface Application.MessageReceived

  The signal emitted when another instance sends a message to the unique instance.
  Since:
    4.0.12
  Author:
    Andrew Cowie

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `org.gnome.unique.Response` | `onMessageReceived(org.gnome.unique.Application source, org.gnome.unique.Command cmd, org.gnome.unique.MessageData data, int time)` You can compare the Command by reference with the constants in that class.

- - ### Method Detail

    - #### onMessageReceived

          org.gnome.unique.Response onMessageReceived(org.gnome.unique.Application source,
                                                    org.gnome.unique.Command cmd,
                                                    org.gnome.unique.MessageData data,
                                                    int time)

      You can compare the Command by reference with the constants in that class.

      `data` will be `null` if that was what was passed by the calling instance. The `time` paramter is a timestamp.

      In ordinary circumstances you should return `OK`.

      If (for whatever reason) you chose not to handle the message, you can return `PASSTHROUGH` which will cause emission of this signal to continue, letting another handler (in this application instance) deal with the event.