Class Message

  • All Implemented Interfaces:

    
    public final class Message
    
                        
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      final String getId() A unique identifier for this message.
      final String getComponent() The component the message is sent from (e.g.
      final String getEvent() The event that this message is about: "submit", "display", "send"
      final Metadata getMetadata() The metadata associated with the message, which includes its url
      final String getJsonData() Data, represented in a json object string, to send along with the message.
      final Message replacing(String event, String jsonData) Convenience method for creating a new message from an existing message, replacing its event and/or jsonData.
      final <T extends Any> Message replacing(String event, T data)
      final <T extends Any> T data()
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • getId

         final String getId()

        A unique identifier for this message. When you reply to the web with a message, this identifier is used to find its previously sent message.

      • getComponent

         final String getComponent()

        The component the message is sent from (e.g. - "form", "page", etc)

      • getEvent

         final String getEvent()

        The event that this message is about: "submit", "display", "send"

      • getMetadata

         final Metadata getMetadata()

        The metadata associated with the message, which includes its url

      • getJsonData

         final String getJsonData()

        Data, represented in a json object string, to send along with the message. For a "page" component, this might be {"title": "Page Title"}

      • replacing

         final Message replacing(String event, String jsonData)

        Convenience method for creating a new message from an existing message, replacing its event and/or jsonData. The new message can be sent back to the over the bridge to notify the web of a change/action.