play.api

Logger

object Logger extends LoggerLike

High-level API for logging operations.

For example, logging with the default application logger:

Logger.info("Hello!")

Logging with a custom logger:

Logger("my.logger").info("Hello!")
Linear Supertypes
LoggerLike, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Logger
  2. LoggerLike
  3. AnyRef
  4. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Type Members

  1. class ColoredLevel extends ClassicConverter

    A logback converter generating colored, lower-case level names.

    A logback converter generating colored, lower-case level names.

    Used for example as:

    %coloredLevel %logger{15} - %message%n%xException{5}

Value Members

  1. final def !=(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  4. def apply[T](clazz: Class[T]): Logger

    Obtains a logger instance.

    Obtains a logger instance.

    clazz

    a class whose name will be used as logger name

    returns

    a logger

  5. def apply(name: String): Logger

    Obtains a logger instance.

    Obtains a logger instance.

    name

    the name of the logger

    returns

    a logger

  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. def configure(properties: Map[String, String] = Map.empty, levels: Map[String, Level] = Map.empty, mode: Mode.Value): Unit

    Reconfigures the underlying logback infrastructure.

    Reconfigures the underlying logback infrastructure.

    properties

    these properties will be added to the logger context (for example application.home)

    levels

    the log levels

    mode

    the application mode

    See also

    http://logback.qos.ch/

  9. def debug(message: ⇒ String, error: ⇒ Throwable): Unit

    Logs a message with the DEBUG level.

    Logs a message with the DEBUG level.

    message

    the message to log

    error

    the associated exception

    Definition Classes
    LoggerLike
  10. def debug(message: ⇒ String): Unit

    Logs a message with the DEBUG level.

    Logs a message with the DEBUG level.

    message

    the message to log

    Definition Classes
    LoggerLike
  11. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  12. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  13. def error(message: ⇒ String, error: ⇒ Throwable): Unit

    Logs a message with the ERROR level.

    Logs a message with the ERROR level.

    message

    the message to log

    error

    the associated exception

    Definition Classes
    LoggerLike
  14. def error(message: ⇒ String): Unit

    Logs a message with the ERROR level.

    Logs a message with the ERROR level.

    message

    the message to log

    Definition Classes
    LoggerLike
  15. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  16. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  17. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  18. def info(message: ⇒ String, error: ⇒ Throwable): Unit

    Logs a message with the INFO level.

    Logs a message with the INFO level.

    message

    the message to log

    error

    the associated exception

    Definition Classes
    LoggerLike
  19. def info(message: ⇒ String): Unit

    Logs a message with the INFO level.

    Logs a message with the INFO level.

    message

    the message to log

    Definition Classes
    LoggerLike
  20. def init(home: File): Unit

    Initialize the Logger in a brut way.

  21. def isDebugEnabled: Boolean

    true if the logger instance is enabled for the DEBUG level.

    true if the logger instance is enabled for the DEBUG level.

    Definition Classes
    LoggerLike
  22. def isErrorEnabled: Boolean

    true if the logger instance is enabled for the ERROR level.

    true if the logger instance is enabled for the ERROR level.

    Definition Classes
    LoggerLike
  23. def isInfoEnabled: Boolean

    true if the logger instance is enabled for the INFO level.

    true if the logger instance is enabled for the INFO level.

    Definition Classes
    LoggerLike
  24. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  25. def isTraceEnabled: Boolean

    true if the logger instance is enabled for the TRACE level.

    true if the logger instance is enabled for the TRACE level.

    Definition Classes
    LoggerLike
  26. def isWarnEnabled: Boolean

    true if the logger instance is enabled for the WARN level.

    true if the logger instance is enabled for the WARN level.

    Definition Classes
    LoggerLike
  27. val logger: org.slf4j.Logger

    The 'application' logger.

    The 'application' logger.

    Definition Classes
    LoggerLoggerLike
  28. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  29. final def notify(): Unit

    Definition Classes
    AnyRef
  30. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  31. def shutdown(): Unit

    Shutdown the logger infrastructure.

  32. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  33. def toString(): String

    Definition Classes
    AnyRef → Any
  34. def trace(message: ⇒ String, error: ⇒ Throwable): Unit

    Logs a message with the TRACE level.

    Logs a message with the TRACE level.

    message

    the message to log

    error

    the associated exception

    Definition Classes
    LoggerLike
  35. def trace(message: ⇒ String): Unit

    Logs a message with the TRACE level.

    Logs a message with the TRACE level.

    message

    the message to log

    Definition Classes
    LoggerLike
  36. lazy val underlyingLogger: org.slf4j.Logger

    The underlying SLF4J Logger.

    The underlying SLF4J Logger.

    Definition Classes
    LoggerLike
  37. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  38. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  39. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  40. def warn(message: ⇒ String, error: ⇒ Throwable): Unit

    Logs a message with the WARN level.

    Logs a message with the WARN level.

    message

    the message to log

    error

    the associated exception

    Definition Classes
    LoggerLike
  41. def warn(message: ⇒ String): Unit

    Logs a message with the WARN level.

    Logs a message with the WARN level.

    message

    the message to log

    Definition Classes
    LoggerLike

Inherited from LoggerLike

Inherited from AnyRef

Inherited from Any

Ungrouped