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

org.slf4j.spi.MDCAdapter Maven / Gradle / Ivy

The newest version!
package org.slf4j.spi;

/**
 * This interface abstracts the service offered by various MDC
 * implementations.
 * 
 * @author Ceki Gülcü
 * @since 1.4.1
 */
public interface MDCAdapter {

  /**
   * Put a context value (the val parameter) as identified with
   * the key parameter into the current thread's context map. 
   * The key parameter cannot be null. The code>val parameter 
   * can be null only if the underlying implementation supports it.
   * 
   * 

If the current thread does not have a context map it is created as a side * effect of this call. */ public void put(String key, String val); /** * Get the context identified by the key parameter. * The key parameter cannot be null. * * @return the string value identified by the key parameter. */ public String get(String key); /** * Remove the the context identified by the key parameter. * The key parameter cannot be null. * *

* This method does nothing if there is no previous value * associated with key. */ public void remove(String key); /** * Clear all entries in the MDC. */ public void clear(); }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy