All Downloads are FREE. Search and download functionalities are using the official Maven repository.

biz.paluch.logging.gelf.LogEvent Maven / Gradle / Ivy

There is a newer version: 1.15.1
Show newest version
package biz.paluch.logging.gelf;

/**
 * 
 * Generic Log Event.
 * 
 * @author Mark Paluch
 * @since 26.09.13 15:16
 */
public interface LogEvent {

    /**
     * 
     * @return the rendered message.
     */
    String getMessage();

    /**
     * 
     * @return array of parameters, if available, else empty object array.
     */
    Object[] getParameters();

    /**
     * 
     * @return throwable, if available, else null.
     */
    Throwable getThrowable();

    /**
     * 
     * @return timestamp of the log event.
     */
    long getLogTimestamp();

    /**
     * 
     * @return numeric syslog level.
     */
    String getSyslogLevel();

    /**
     * 
     * @param field
     * @return values for the requested field.
     */
    Values getValues(MessageField field);

    /**
     *
     * @param mdcName Name of the MDC entry.
     * @return one MDC value (or null)
     */
    String getMdcValue(String mdcName);

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy