Class LogMessage

All Implemented Interfaces:
Serializable, Cloneable, Map<String,Object>

public class LogMessage extends HashMap<String,Object>
Class that extends HashMap used to map the message of the logs
See Also:
  • Constructor Details

    • LogMessage

      public LogMessage(String text)
      Creates an instance of LogMessage
      Parameters:
      text - String containing the message of the log
  • Method Details

    • getText

      public String getText()
      Returns the text of the message
      Returns:
      The text of the message
    • with

      public LogMessage with(String name, Object value)
      Adds to the LogMessage the key:"name" and the value:"value"
      Parameters:
      name - The name of the key of the map
      value - The value to add
      Returns:
      The LogMessage with name:value
    • getJsonWriter

      public static ObjectWriter getJsonWriter()
      Returns:
      a object writer to transform objects in json format
    • toString

      public String toString()
      Overrides:
      toString in class AbstractMap<String,Object>