Struct protobuf_native::DescriptorProto

source ·
pub struct DescriptorProto { /* private fields */ }
Expand description

Describes a message type.

Implementations§

source§

impl DescriptorProto

source

pub fn name(&self) -> &[u8]

Returns the name of tis message.

Trait Implementations§

source§

impl Drop for DescriptorProto

source§

fn drop(&mut self)

Executes the destructor for this type. Read more
source§

impl MessageLite for DescriptorProto

source§

fn new(&self) -> Pin<Box<dyn MessageLite>>

Constructs a new instance of the same type.
source§

fn clear(self: Pin<&mut Self>)

Clears all fields of the message and set them to their default values. Read more
source§

fn is_initialized(&self) -> bool

Quickly checks if all required fields have been set.
source§

fn merge_from_coded_stream( self: Pin<&mut Self>, input: Pin<&mut CodedInputStream<'_>>, ) -> Result<(), OperationFailedError>

Reads a protocol buffer from the stream and merges it into this message. Read more
source§

fn serialize_to_coded_stream( &self, output: Pin<&mut CodedOutputStream<'_>>, ) -> Result<(), OperationFailedError>

Writes a protocol buffer of this message to the given output. Read more
source§

fn serialize_to_zero_copy_stream( &self, output: Pin<&mut dyn ZeroCopyOutputStream>, ) -> Result<(), OperationFailedError>

Writes the message to the given zero-copy output stream. Read more
source§

fn serialize_to_writer( &self, output: &mut dyn Write, ) -> Result<(), OperationFailedError>

Writes the message to the given Write implementor. Read more
source§

fn serialize(&self) -> Result<Vec<u8>, OperationFailedError>

Serializes the message to a byte vector. Read more
source§

fn byte_size(&self) -> usize

Computes the serialized size of the message. Read more
source§

impl Message for DescriptorProto

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.