A reserved buffer for writing a server-streaming RPC request in place.
Write the request into the buffer and call Commit() with the number of bytes written to send the request and obtain a Reader<Response>. Destroying the reservation without calling Commit() (or calling Drop()) abandons the call without sending anything.
Friends | |
| class | internal::ReserveRequestFutureBase< ServerStreamReservation > |
Additional Inherited Members | |
Public Types inherited from pw::rpc2::internal::WriteReservationBase | |
| using | iterator = ByteSpan::iterator |
| using | const_iterator = ConstByteSpan::iterator |
Public Member Functions inherited from pw::rpc2::internal::RequestReservationBase< Committed > | |
| RequestReservationBase (const RequestReservationBase &)=delete | |
| RequestReservationBase & | operator= (const RequestReservationBase &)=delete |
| RpcResult< Committed > | Commit (size_t size_bytes) |
Public Member Functions inherited from pw::rpc2::internal::WriteReservationBase | |
| WriteReservationBase (const WriteReservationBase &)=delete | |
| WriteReservationBase & | operator= (const WriteReservationBase &)=delete |
| WriteReservationBase (WriteReservationBase &&other) noexcept=default | |
| WriteReservationBase & | operator= (WriteReservationBase &&other) noexcept |
| std::byte * | data () |
| Returns a pointer to the start of the reserved write buffer. | |
| const std::byte * | data () const |
| size_t | size () const |
| Returns the size of the reserved write buffer in bytes. | |
| std::byte & | operator[] (size_t index) |
Accesses the byte at index. | |
| const std::byte & | operator[] (size_t index) const |
| iterator | begin () |
| Returns an iterator to the beginning of the reserved buffer. | |
| const_iterator | begin () const |
| const_iterator | cbegin () const |
| iterator | end () |
| Returns an iterator to the end of the reserved buffer. | |
| const_iterator | end () const |
| const_iterator | cend () const |
| void | Drop () |
| Releases the reservation without sending any data. | |
Protected Member Functions inherited from pw::rpc2::internal::RequestReservationBase< Committed > | |
| RequestReservationBase (WriteReservation &&reservation) | |
| RequestReservationBase (RequestReservationBase &&) noexcept=default | |
| RequestReservationBase & | operator= (RequestReservationBase &&) noexcept=default |
Protected Member Functions inherited from pw::rpc2::internal::WriteReservationBase | |
| WriteReservationBase (transport::WriteReservation &&reservation, OutboundPacket packet, IntrusivePtr< Call > call) | |
| RpcResult< IntrusivePtr< Call > > | CommitAndTakeCall (size_t size_bytes) |