pub enum MessageRequest {
FileByFilename(String),
FileContainingSymbol(String),
FileContainingExtension(ExtensionRequest),
AllExtensionNumbersOfType(String),
ListServices(String),
}
Expand description
To use reflection service, the client should set one of the following fields in message_request. The server distinguishes requests by their defined field and then handles them using corresponding methods.
Variants§
FileByFilename(String)
Find a proto file by the file name.
FileContainingSymbol(String)
Find the proto file that declares the given fully-qualified symbol name.
This field should be a fully-qualified symbol name
(e.g.
FileContainingExtension(ExtensionRequest)
Find the proto file which defines an extension extending the given message type with the given field number.
AllExtensionNumbersOfType(String)
Finds the tag numbers used by all known extensions of the given message
type, and appends them to ExtensionNumberResponse in an undefined order.
Its corresponding method is best-effort: it’s not guaranteed that the
reflection service will implement this method, and it’s not guaranteed
that this method will provide all extensions. Returns
StatusCode::UNIMPLEMENTED if it’s not implemented.
This field should be a fully-qualified type name. The format is
ListServices(String)
List the full names of registered services. The content will not be checked.
Implementations§
source§impl MessageRequest
impl MessageRequest
sourcepub fn merge(
field: &mut Option<MessageRequest>,
tag: u32,
wire_type: WireType,
buf: &mut impl Buf,
ctx: DecodeContext,
) -> Result<(), DecodeError>
pub fn merge( field: &mut Option<MessageRequest>, tag: u32, wire_type: WireType, buf: &mut impl Buf, ctx: DecodeContext, ) -> Result<(), DecodeError>
Decodes an instance of the message from a buffer, and merges it into self.
sourcepub fn encoded_len(&self) -> usize
pub fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
Trait Implementations§
source§impl Clone for MessageRequest
impl Clone for MessageRequest
source§fn clone(&self) -> MessageRequest
fn clone(&self) -> MessageRequest
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for MessageRequest
impl Debug for MessageRequest
source§impl PartialEq for MessageRequest
impl PartialEq for MessageRequest
source§fn eq(&self, other: &MessageRequest) -> bool
fn eq(&self, other: &MessageRequest) -> bool
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for MessageRequest
Auto Trait Implementations§
impl Freeze for MessageRequest
impl RefUnwindSafe for MessageRequest
impl Send for MessageRequest
impl Sync for MessageRequest
impl Unpin for MessageRequest
impl UnwindSafe for MessageRequest
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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>
T
in a tonic::Request