Package adams.db

Class LogEntry

    • Constructor Detail

      • LogEntry

        public LogEntry()
        Initializes the entry.
    • Method Detail

      • getDateFormat

        protected DateFormat getDateFormat()
        Returns the formatter for the timestamps.
        Returns:
        the formatter
      • setHost

        public void setHost​(String value)
        Sets the host name.
        Parameters:
        value - the host name
      • getHost

        public String getHost()
        Returns the host name.
        Returns:
        the host name, can be null
      • setIP

        public void setIP​(String value)
        Sets the IP address.
        Parameters:
        value - the IP address
      • getIP

        public String getIP()
        Returns the IP address.
        Returns:
        the IP address, can be null
      • setType

        public void setType​(String value)
        Sets the type.
        Parameters:
        value - the type
      • getType

        public String getType()
        Returns the type.
        Returns:
        the type
      • setMessage

        public void setMessage​(String value)
        Sets the message.
        Parameters:
        value - the message
      • setMessage

        public void setMessage​(Properties value)
        Sets the message as properties object.
        Parameters:
        value - the message
      • getMessage

        public String getMessage()
        Returns the message.
        Returns:
        the message
      • getMessageAsProperties

        public Properties getMessageAsProperties()
        Returns the message as properties object.
        Returns:
        the message
      • setGeneration

        public void setGeneration​(Date value)
        Sets the generation timestamp.
        Parameters:
        value - the generation timestamp
      • getGeneration

        public Date getGeneration()
        Returns the generation timestamp.
        Returns:
        the generation timestamp
      • getGenerationAsString

        public String getGenerationAsString()
        Returns the generation timestamp as string.
        Returns:
        the generation timestamp
        See Also:
        TIMESTAMP_FORMAT
      • setSource

        public void setSource​(String value)
        Sets the source.
        Parameters:
        value - the source
      • getSource

        public String getSource()
        Returns the source.
        Returns:
        the source
      • setStatus

        public void setStatus​(String value)
        Sets the status.
        Parameters:
        value - the status
      • getStatus

        public String getStatus()
        Returns the status.
        Returns:
        the status
      • compareTo

        public int compareTo​(LogEntry o)
        Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.
        Specified by:
        compareTo in interface Comparable<LogEntry>
        Parameters:
        o - the object to be compared.
        Returns:
        a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.
      • equals

        public boolean equals​(Object obj)
        Indicates whether some other object is "equal to" this one.
        Overrides:
        equals in class Object
        Parameters:
        obj - the reference object with which to compare.
        Returns:
        true if this object is the same as the obj argument; false otherwise.
      • hashCode

        public int hashCode()
        Hashcode so can be used as hashtable key. Returns the hashcode of the "DBID + Generation" string.
        Overrides:
        hashCode in class Object
        Returns:
        the hashcode
      • toString

        public String toString()
        Returns a short string representation of the container.
        Overrides:
        toString in class Object
        Returns:
        the string representation