diff options
author | 2018-10-16 18:10:02 -0700 | |
---|---|---|
committer | 2018-10-16 18:10:02 -0700 | |
commit | 62fb609df7b9534f188804c43401f6219345577c (patch) | |
tree | b258a31c1d0407ac56b332eacd3dcb49d84d8a2d /src/objective-c/GRPCClient/private/GRPCChannel.m | |
parent | 6032e960d43af5912d06553adc22012d3f7c758a (diff) |
rename kChannelPool->gChannelPool
Diffstat (limited to 'src/objective-c/GRPCClient/private/GRPCChannel.m')
-rw-r--r-- | src/objective-c/GRPCClient/private/GRPCChannel.m | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/objective-c/GRPCClient/private/GRPCChannel.m b/src/objective-c/GRPCClient/private/GRPCChannel.m index cf44b96e22..ae90821de0 100644 --- a/src/objective-c/GRPCClient/private/GRPCChannel.m +++ b/src/objective-c/GRPCClient/private/GRPCChannel.m @@ -64,7 +64,7 @@ } - (void)unmanagedCallUnref { - [kChannelPool unrefChannelWithConfiguration:_configuration]; + [gChannelPool unrefChannelWithConfiguration:_configuration]; } - (nullable instancetype)initWithUnmanagedChannel:(nullable grpc_channel *)unmanagedChannel @@ -94,12 +94,12 @@ } static dispatch_once_t initChannelPool; -static GRPCChannelPool *kChannelPool; +static GRPCChannelPool *gChannelPool; + (nullable instancetype)channelWithHost:(NSString *)host callOptions:(GRPCCallOptions *)callOptions { dispatch_once(&initChannelPool, ^{ - kChannelPool = [[GRPCChannelPool alloc] init]; + gChannelPool = [[GRPCChannelPool alloc] init]; }); NSURL *hostURL = [NSURL URLWithString:[@"https://" stringByAppendingString:host]]; @@ -109,7 +109,7 @@ static GRPCChannelPool *kChannelPool; GRPCChannelConfiguration *channelConfig = [[GRPCChannelConfiguration alloc] initWithHost:host callOptions:callOptions]; - return [kChannelPool channelWithConfiguration:channelConfig + return [gChannelPool channelWithConfiguration:channelConfig createChannel:^{ return [GRPCChannel createChannelWithConfiguration:channelConfig]; @@ -117,7 +117,7 @@ static GRPCChannelPool *kChannelPool; } + (void)closeOpenConnections { - [kChannelPool clear]; + [gChannelPool clear]; } @end |