Uses of Class
io.grpc.Context
-
Packages that use Context Package Description io.grpc The gRPC core public API. -
-
Uses of Context in io.grpc
Subclasses of Context in io.grpc Modifier and Type Class Description static classContext.CancellableContextA context which inherits cancellation from its parent but which can also be independently cancelled and which will propagate cancellation to its descendants.Fields in io.grpc declared as Context Modifier and Type Field Description static ContextContext. ROOTThe logical root context which is the ultimate ancestor of all contexts.Methods in io.grpc that return Context Modifier and Type Method Description ContextContext. attach()Attach this context, thus enter a new scope within which this context iscurrent().ContextContext.CancellableContext. attach()static ContextContext. current()Return the context associated with the current scope, will never returnnull.abstract ContextContext.Storage. current()Implementscurrent().abstract ContextContext.Storage. doAttach(Context toAttach)Implementsattach().ContextServerStreamTracer. filterContext(Context context)Called before the interceptors and the call handlers and make changes to the Context object if needed.ContextContext. fork()Create a new context which propagates the values of this context but does not cascade its cancellation.<V> ContextContext. withValue(Context.Key<V> k1, V v1)Create a new context with the given key value set.<V1,V2>
ContextContext. withValues(Context.Key<V1> k1, V1 v1, Context.Key<V2> k2, V2 v2)Create a new context with the given key value set.<V1,V2,V3>
ContextContext. withValues(Context.Key<V1> k1, V1 v1, Context.Key<V2> k2, V2 v2, Context.Key<V3> k3, V3 v3)Create a new context with the given key value set.<V1,V2,V3,V4>
ContextContext. withValues(Context.Key<V1> k1, V1 v1, Context.Key<V2> k2, V2 v2, Context.Key<V3> k3, V3 v3, Context.Key<V4> k4, V4 v4)Create a new context with the given key value set.Methods in io.grpc with parameters of type Context Modifier and Type Method Description voidContext.CancellationListener. cancelled(Context context)Notifies that a context was cancelled.voidContext.CancellableContext. detach(Context toAttach)voidContext. detach(Context toAttach)Reverse anattach(), restoring the previous context and exiting the current scope.abstract voidContext.Storage. detach(Context toDetach, Context toRestore)Implementsdetach(io.grpc.Context).voidContext.CancellableContext. detachAndCancel(Context toAttach, Throwable cause)Cancel this context and detach it as the current context.abstract ContextContext.Storage. doAttach(Context toAttach)Implementsattach().ContextServerStreamTracer. filterContext(Context context)Called before the interceptors and the call handlers and make changes to the Context object if needed.TContext.Key. get(Context context)Get the value from the specified context for this key.static <ReqT,RespT>
ServerCall.Listener<ReqT>Contexts. interceptCall(Context context, ServerCall<ReqT,RespT> call, Metadata headers, ServerCallHandler<ReqT,RespT> next)static StatusContexts. statusFromCancelled(Context context)Returns theStatusof a cancelled context ornullif the context is not cancelled.
-