Interface BusinessNotification.MessageBuilder

Enclosing interface:
BusinessNotification

public static interface BusinessNotification.MessageBuilder
API:
This is a public API.
  • Method Details

    • text

      Defines the text of the notification message.

      Example with simple text:

      BusinessNotification.create().message().text("Order was delivered")...

      Example with message arguments:

      BusinessNotification.create().message().text("Order {0} for customer {1} was delivered", in.orderNr, in.customerName)...
      Parameters:
      message - the message
      args - MessageFormat arguments
      Returns:
      builder for further composition of the notification
      API:
      This public API is available in Java.
    • fromCms

      BusinessNotification.ReceiverOrBuilder fromCms(String cmsNameOrRelativePath, Object... args)
      Defines the path to a message string located in the CMS

      Example with simple text in the CMS:

      CMS:
      /Notification/business/Messages/OrderDelivered > "Order was delivered"
      Code:
      BusinessNotification.create().fromCms("OrderDelivered")...

      Example with message arguments:

      CMS:
      /Notification/business/Messages/OrderDelivered > "Order {0} for customer {1} was delivered"
      Code:
      BusinessNotification.create().fromCms("OrderDelivered", in.orderNr, in.customerName)...
      Parameters:
      cmsNameOrRelativePath - the CMS name of or a relative path to the message string
      args - MessageFormat arguments
      Returns:
      builder for further composition of the notification
      API:
      This public API is available in Java.