Class Loggable

java.lang.Object
org.glassfish.internal.logging.Loggable

public class Loggable extends Object
Loggable objects are used when there is a need to collect log entry data without actually logging the message until a later time. Type casting is weak for the log parameters provided when constructing. The user must ensure that the arguments associated with a particular log message are of the appropriate type and in the correct order.
  • Constructor Details

  • Method Details

    • log

      public String log()
      Log the message.
    • getMessageBody

      public String getMessageBody()
      Gets the contents of the message body without appending a stack trace. This is particularly useful when using the value of a loggables message as the value when creating an exception.
    • getMessage

      public String getMessage()
      Get the message in current locale with [subsytem:id] prefix.
    • getMessageText

      public String getMessageText()
      Get the message in current locale, no prefix.
    • getId

      public String getId()
      Get the message id.