Interface ThreadContext<T>

All Known Implementing Classes:
ResteasyThreadContext

public interface ThreadContext<T>
A utility used to capture the current context and set it on a thread before it's execute. Finally resetting the context.
Since:
5.0.0
Author:
James R. Perkins
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    Captures the current context to be passed to push(Object) before a thread executes.
    void
    push(T context)
    Pushes the context previously captured to the currently running thread.
    void
    reset(T context)
    Resets the context on the current thread.
  • Method Details

    • capture

      T capture()
      Captures the current context to be passed to push(Object) before a thread executes.
      Returns:
      the current context
    • push

      void push(T context)
      Pushes the context previously captured to the currently running thread.
      Parameters:
      context - the captured context to push
    • reset

      void reset(T context)
      Resets the context on the current thread.
      Parameters:
      context - the captured context to reset