public interface ContextSnapshot
ContextManager implementations.ContextManagers.createContextSnapshot() which will include a snapshot
for all supported Context types through their respective managers.
This allows for a generic method to:
ContextSnapshot along to a background job.reactivate the snapshot
for some required code path.Context of its own. Although it does not return any specific
value, it must be closed when the work requiring
the context snapshot is done. This prevents context values leaking in case the used threads
are returned to some pool.
| Modifier and Type | Method and Description |
|---|---|
Context<Void> |
reactivate()
This method activates all contained values by the snapshot in their respective
Context implementations. |
Context<Void> reactivate()
Context implementations.
These reactivated contexts can all be closed at once by closing the returned Void context.
The resulting context is Void, because it does not contain any value itself.
Copyright © 2016–2017 Talsma ICT. All rights reserved.