Package io.grpc.alts.internal
Class AltsProtocolNegotiator.LazyChannel
- java.lang.Object
-
- io.grpc.alts.internal.AltsProtocolNegotiator.LazyChannel
-
- Enclosing class:
- AltsProtocolNegotiator
static final class AltsProtocolNegotiator.LazyChannel extends java.lang.Object
Channel created from a channel pool lazily.
-
-
Field Summary
Fields Modifier and Type Field Description private io.grpc.Channel
channel
private io.grpc.internal.ObjectPool<io.grpc.Channel>
channelPool
-
Constructor Summary
Constructors Constructor Description LazyChannel(io.grpc.internal.ObjectPool<io.grpc.Channel> channelPool)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) void
close()
Returns the cached channel to the channel pool.(package private) io.grpc.Channel
get()
If channel is null, gets a channel from the channel pool, otherwise, returns the cached channel.
-