GRPC C++  1.26.0
Public Member Functions
grpc_impl::internal::AsyncReaderInterface< R > Class Template Referenceabstract

An interface that yields a sequence of messages of type R. More...

#include <async_stream_impl.h>

Public Member Functions

virtual ~AsyncReaderInterface ()
 
virtual void Read (R *msg, void *tag)=0
 Read a message of type R into msg. More...
 

Detailed Description

template<class R>
class grpc_impl::internal::AsyncReaderInterface< R >

An interface that yields a sequence of messages of type R.

Constructor & Destructor Documentation

◆ ~AsyncReaderInterface()

template<class R >
virtual grpc_impl::internal::AsyncReaderInterface< R >::~AsyncReaderInterface ( )
inlinevirtual

Member Function Documentation

◆ Read()

template<class R >
virtual void grpc_impl::internal::AsyncReaderInterface< R >::Read ( R *  msg,
void *  tag 
)
pure virtual

Read a message of type R into msg.

Completion will be notified by tag on the associated completion queue. This is thread-safe with respect to Write or WritesDone methods. It should not be called concurrently with other streaming APIs on the same stream. It is not meaningful to call it concurrently with another AsyncReaderInterface::Read on the same stream since reads on the same stream are delivered in order.

Parameters
[out]msgWhere to eventually store the read message.
[in]tagThe tag identifying the operation.

Side effect: note that this method attempt to receive initial metadata for a stream if it hasn't yet been received.

Implemented in grpc_impl::ServerAsyncReaderWriter< W, R >, grpc_impl::ServerAsyncReader< W, R >, grpc_impl::ClientAsyncReaderWriter< W, R >, and grpc_impl::ClientAsyncReader< R >.


The documentation for this class was generated from the following file: