Improve links and header hierarchy
Project: http://git-wip-us.apache.org/repos/asf/logging-log4j-scala/repo Commit: http://git-wip-us.apache.org/repos/asf/logging-log4j-scala/commit/a5510391 Tree: http://git-wip-us.apache.org/repos/asf/logging-log4j-scala/tree/a5510391 Diff: http://git-wip-us.apache.org/repos/asf/logging-log4j-scala/diff/a5510391 Branch: refs/heads/master Commit: a551039140608e9f59e3aa7f4e5ed2a937753f19 Parents: a5726de Author: Matt Sicker <[email protected]> Authored: Sat Mar 31 20:22:50 2018 -0500 Committer: Matt Sicker <[email protected]> Committed: Sat Mar 31 20:22:50 2018 -0500 ---------------------------------------------------------------------- src/asciidoctor/usage.adoc | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/logging-log4j-scala/blob/a5510391/src/asciidoctor/usage.adoc ---------------------------------------------------------------------- diff --git a/src/asciidoctor/usage.adoc b/src/asciidoctor/usage.adoc index 93381a4..528e999 100644 --- a/src/asciidoctor/usage.adoc +++ b/src/asciidoctor/usage.adoc @@ -16,7 +16,7 @@ //// == Usage -Using the Scala API is as simple as mixing in the `Logging` trait to your class. Example: +Using the Scala API is as simple as mixing in the https://logging.apache.org/log4j/scala/log4j-api-scala_2.12/scaladocs/org/apache/logging/log4j/scala/[`Logging`] trait to your class. Example: [source,scala] ---- @@ -42,21 +42,21 @@ class MyClass extends BaseClass with Logging { |Scala Version |API Link |Scala 2.10 -|https://logging.apache.org/log4j/scala/log4j-api-scala_2.10/scaladocs/[ScalaDocs] +|https://logging.apache.org/log4j/scala/log4j-api-scala_2.10/scaladocs/#org.apache.logging.log4j.scala.package[ScalaDocs] |Scala 2.11 -|https://logging.apache.org/log4j/scala/log4j-api-scala_2.11/scaladocs/[ScalaDocs] +|https://logging.apache.org/log4j/scala/log4j-api-scala_2.11/scaladocs/#org.apache.logging.log4j.scala.package[ScalaDocs] |Scala 2.12 -|https://logging.apache.org/log4j/scala/log4j-api-scala_2.12/scaladocs/[ScalaDocs] +|https://logging.apache.org/log4j/scala/log4j-api-scala_2.12/scaladocs/org/apache/logging/log4j/scala/[ScalaDocs] |=== -== Configuration +=== Configuration Log4j Scala API uses https://logging.apache.org/log4j/2.x/manual/configuration.html[Log4j configuration] by default. This supports XML, properties files, and Java-based builders, as well as JSON and YAML with additional dependencies. -== Substituting Parameters +=== Substituting Parameters Unlike in Java, Scala provides native functionality for string interpolation https://docs.scala-lang.org/overviews/core/string-interpolation.html[beginning in Scala 2.10]. As all logger calls are implemented as macros, using string interpolation directly does not require additional if checks. @@ -67,7 +67,7 @@ For example: logger.debug(s"Logging in user ${user.getName} with birthday ${user.calcBirthday}") ---- -== Logger Names +=== Logger Names Most logging implementations use a hierarchical scheme for matching logger names with logging configuration. In this scheme the logger name hierarchy is represented by '.' characters in the logger name, in a fashion very similar to the hierarchy used for Java/Scala package names.
