diff --git a/src/objective-c/GRPCClient/GRPCCall.h b/src/objective-c/GRPCClient/GRPCCall.h index 8e02ada38d5..97ece7e0c9b 100644 --- a/src/objective-c/GRPCClient/GRPCCall.h +++ b/src/objective-c/GRPCClient/GRPCCall.h @@ -269,6 +269,12 @@ extern NSString *const kGRPCTrailersKey; */ - (void)finish; +/** + * Tell gRPC to receive the next N gRPC message from gRPC core. + * + * This method should only be used when flow control is enabled. When flow control is not enabled, + * this method is a no-op. + */ - (void)receiveNextMessages:(NSUInteger)numberOfMessages; /** diff --git a/src/objective-c/ProtoRPC/ProtoRPC.h b/src/objective-c/ProtoRPC/ProtoRPC.h index 78d1bd3df37..12db46adeda 100644 --- a/src/objective-c/ProtoRPC/ProtoRPC.h +++ b/src/objective-c/ProtoRPC/ProtoRPC.h @@ -138,16 +138,22 @@ NS_ASSUME_NONNULL_BEGIN - (void)finish; /** - * Tell gRPC to receive the next message. If flow control is enabled, the messages received from the - * server are buffered in gRPC until the user want to receive the next message. If flow control is - * not enabled, messages will be automatically received after the previous one is delivered. + * Tell gRPC to receive another message. + * + * This method should only be used when flow control is enabled. If flow control is enabled, gRPC + * will only receive additional messages after the user indicates so by using either + * receiveNextMessage: or receiveNextMessages: methods. If flow control is not enabled, messages + * will be automatically received after the previous one is delivered. */ - (void)receiveNextMessage; /** - * Tell gRPC to receive the next N message. If flow control is enabled, the messages received from - * the server are buffered in gRPC until the user want to receive the next message. If flow control - * is not enabled, messages will be automatically received after the previous one is delivered. + * Tell gRPC to receive another N message. + * + * This method should only be used when flow control is enabled. If flow control is enabled, the + * messages received from the server are buffered in gRPC until the user want to receive the next + * message. If flow control is not enabled, messages will be automatically received after the + * previous one is delivered. */ - (void)receiveNextMessages:(NSUInteger)numberOfMessages;