pub struct DynamicCodec { /* private fields */ }Expand description
A gRPC codec for prost-reflect DynamicMessage.
Unlike tonic’s ProstCodec which works with compile-time generated types, this codec works with runtime-resolved message descriptors, enabling dynamic RPC invocation without pre-compiled service stubs.
Implementations§
Source§impl DynamicCodec
impl DynamicCodec
pub fn new( request_desc: MessageDescriptor, response_desc: MessageDescriptor, ) -> Self
Trait Implementations§
Source§impl Codec for DynamicCodec
impl Codec for DynamicCodec
Source§type Encode = DynamicMessage
type Encode = DynamicMessage
The encodable message.
Source§type Decode = DynamicMessage
type Decode = DynamicMessage
The decodable message.
Source§type Encoder = DynamicEncoder
type Encoder = DynamicEncoder
The encoder that can encode a message.
Source§type Decoder = DynamicDecoder
type Decoder = DynamicDecoder
The decoder that can decode a message.
Auto Trait Implementations§
impl Freeze for DynamicCodec
impl RefUnwindSafe for DynamicCodec
impl Send for DynamicCodec
impl Sync for DynamicCodec
impl Unpin for DynamicCodec
impl UnsafeUnpin for DynamicCodec
impl UnwindSafe for DynamicCodec
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request