Class UserNotification

java.lang.Object
org.opentcs.data.notification.UserNotification
All Implemented Interfaces:
Serializable

public class UserNotification extends Object implements Serializable
A notification to be read by a user.
See Also:
  • Constructor Details

    • UserNotification

      public UserNotification(@Nullable String source, String text, UserNotification.Level level)
      Creates a new Message.
      Parameters:
      source - An identifier of the notification's source.
      text - The actual message text.
      level - The new message's level.
    • UserNotification

      public UserNotification(String text, UserNotification.Level level)
      Creates a new Message.
      Parameters:
      text - The actual message text.
      level - The new message's level.
  • Method Details

    • getSource

      @Nullable public String getSource()
      Returns this notification's (optional) source.
      Returns:
      This notification's (optional) source.
    • getText

      public String getText()
      Returns this message's text.
      Returns:
      This message's text.
    • getLevel

      public UserNotification.Level getLevel()
      Returns this message's type.
      Returns:
      This message's type.
    • getTimestamp

      public Instant getTimestamp()
      Returns this message's creation timestamp.
      Returns:
      This message's creation timestamp.
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object