Attributes
- Companion
- trait
- Graph
-
- Supertypes
- Self type
-
MarkerContext.type
Members list
Value members
Concrete methods
Provides an instance of a MarkerContext from a Marker. The explicit form is useful when you want to explicitly tag a log message with a particular Marker and you already have a Marker in implicit scope.
Provides an instance of a MarkerContext from a Marker. The explicit form is useful when you want to explicitly tag a log message with a particular Marker and you already have a Marker in implicit scope.
implicit val implicitContext: MarkerContext = ...
val explicitContext: MarkerContext = MarkerContext(MarkerFactory.getMarker("EXPLICITMARKER"))
// do not use the implicit MarkerContext
log.error("This message is logged with EXPLICITMARKER")(explicitContext)
Value parameters
- marker
-
the marker to wrap in DefaultMarkerContext
Attributes
- Returns
-
an instance of DefaultMarkerContext.
Implicits
Inherited implicits
A MarkerContext that returns None. This is used as the "default" marker context if no implicit MarkerContext is found in local scope (meaning there is nothing defined through import or "implicit val").
A MarkerContext that returns None. This is used as the "default" marker context if no implicit MarkerContext is found in local scope (meaning there is nothing defined through import or "implicit val").
Attributes
- Inherited from:
- LowPriorityMarkerContextImplicits
Enables conversion from a marker to a MarkerContext:
Enables conversion from a marker to a MarkerContext:
val mc: MarkerContext = MarkerFactory.getMarker("SOMEMARKER")
Value parameters
- marker
-
the SLF4J marker to convert
Attributes
- Returns
-
the result of
MarkerContext.apply(marker) - Inherited from:
- LowPriorityMarkerContextImplicits