Class FeedbackMessage

    • Constructor Detail

      • FeedbackMessage

        public FeedbackMessage​(Component reporter,
                               Serializable message,
                               int level)
        Construct using fields.
        Parameters:
        reporter - The message reporter
        message - The actual message. Must not be null.
        level - The level of the message
    • Method Detail

      • isRendered

        public final boolean isRendered()
        Gets whether or not this message has been rendered
        Returns:
        true if this message has been rendered, false otherwise
      • markRendered

        public final void markRendered()
        Marks this message as rendered.
      • getLevel

        public final int getLevel()
        Gets the message level; can be used by rendering components. Note that what actually happens with the level indication is totally up to the components that render feedback messages.
        Returns:
        The message level indicator.
      • getLevelAsString

        public String getLevelAsString()
        Gets the current level as a String
        Returns:
        The current level as a String
      • getReporter

        public final Component getReporter()
        Gets the reporting component.
        Returns:
        the reporting component.
      • isDebug

        public final boolean isDebug()
        Gets whether the current level is DEBUG or up.
        Returns:
        whether the current level is DEBUG or up.
      • isInfo

        public final boolean isInfo()
        Gets whether the current level is INFO or up.
        Returns:
        whether the current level is INFO or up.
      • isSuccess

        public final boolean isSuccess()
        Gets whether the current level is SUCCESS or up.
        Returns:
        whether the current level is SUCCESS or up.
      • isWarning

        public final boolean isWarning()
        Gets whether the current level is WARNING or up.
        Returns:
        whether the current level is WARNING or up.
      • isError

        public final boolean isError()
        Gets whether the current level is ERROR or up.
        Returns:
        whether the current level is ERROR or up.
      • isFatal

        public final boolean isFatal()
        Gets whether the current level is FATAL or up.
        Returns:
        whether the current level is FATAL or up.
      • isLevel

        public final boolean isLevel​(int level)
        Returns whether this level is greater than or equal to the given level.
        Parameters:
        level - the level
        Returns:
        whether this level is greater than or equal to the given level
      • isUndefined

        public final boolean isUndefined()
        Gets whether the current level is UNDEFINED.
        Returns:
        whether the current level is UNDEFINED.
      • detach

        public void detach()
        Description copied from interface: IDetachable
        Detaches model after use. This is generally used to null out transient references that can be re-attached later.
        Specified by:
        detach in interface IDetachable