Package io.opencensus.common
Interface Scope
- All Superinterfaces:
AutoCloseable,Closeable,NonThrowingCloseable
- All Known Implementing Classes:
CurrentSpanUtils.ScopeInSpan,CurrentTagMapUtils.WithTagMap,NoopScope,NoopScope
A
Closeable that represents a change to the current context over a scope of code.
close() cannot throw a checked exception.
Example of usage:
try (Scope ctx = tryEnter()) {
...
}
- Since:
- 0.6
-
Method Summary
-
Method Details
-
close
void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Specified by:
closein interfaceNonThrowingCloseable
-