MDC

scribe.mdc.MDC
See theMDC companion object
trait MDC

Attributes

Companion
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class MDCMap

Members list

Value members

Abstract methods

def clear(): Unit

Clears all values from this MDC

Clears all values from this MDC

Attributes

def contains(key: String): Boolean

True if this MDC contains the specified key

True if this MDC contains the specified key

Attributes

def context[Return](values: (String, MDCValue)*)(f: => Return): Return

Contextualizes setting multiple values similar to update, but returns them to their previous value upon completion of the context function f.

Contextualizes setting multiple values similar to update, but returns them to their previous value upon completion of the context function f.

Attributes

def get(key: String): Option[() => Any]

Gets the value function for this key if set

Gets the value function for this key if set

Attributes

def map: Map[String, () => Any]

Retrieves the functional map

Retrieves the functional map

Attributes

def remove(key: String): Option[Any]

Removes a key from this MDC instance

Removes a key from this MDC instance

Attributes

def set(key: String, value: Option[Any]): Option[Any]

Sets the value for the specified key. This method differs from update by taking an Option that will remove the key if set to None. Returns the previous value for this key.

Sets the value for the specified key. This method differs from update by taking an Option that will remove the key if set to None. Returns the previous value for this key.

Attributes

def update(key: String, value: => Any): Option[Any]

Updates the value for the specified key. The context method should be preferred to avoid leaving MDC values set forever. Returns the previous value for this key.

Updates the value for the specified key. The context method should be preferred to avoid leaving MDC values set forever. Returns the previous value for this key.

Attributes

Concrete methods

def elapsed(key: String, timeFunction: () => Long): Unit

Applies an elapsed function as an MDC value. This represents a dynamically changing value of time elapsed since the this was set.

Applies an elapsed function as an MDC value. This represents a dynamically changing value of time elapsed since the this was set.

Attributes