Enum serde_protobuf::descriptor::InternalFieldType[][src]

pub enum InternalFieldType {
Show variants UnresolvedMessage(String), UnresolvedEnum(String), Double, Float, Int64, UInt64, Int32, Fixed64, Fixed32, Bool, String, Group, Message(MessageId), Bytes, UInt32, Enum(EnumId), SFixed32, SFixed64, SInt32, SInt64,
}
Expand description

The internally tracked type of a field.

The type owns all of its data, and can refer to an internally tracked ID for resolved type references. It’s by design not possible to construct those IDs from outside this module.

Variants

UnresolvedMessage(String)
Expand description

A message that is yet to be resolved.

UnresolvedEnum(String)
Expand description

An enum that is yet to be resolved.

Double
Expand description

The double type.

Float
Expand description

The float type.

Int64
Expand description

The int64 type.

UInt64
Expand description

The uint64 type.

Int32
Expand description

The int32 type.

Fixed64
Expand description

The fixed64 type.

Fixed32
Expand description

The fixed32 type.

Bool
Expand description

The bool type.

String
Expand description

The string type.

Group
Expand description

The group type.

Message(MessageId)
Expand description

A resolved message type.

Bytes
Expand description

The bytes type.

UInt32
Expand description

The uint32 type.

Enum(EnumId)
Expand description

A resolved enum type.

SFixed32
Expand description

The sfixed32 type.

SFixed64
Expand description

The sfixed64 type.

SInt32
Expand description

The sint32 type.

SInt64
Expand description

The sint64 type.

Implementations

impl InternalFieldType[src]

pub fn from_proto(
    proto: FieldDescriptorProto_Type,
    type_name: &str
) -> InternalFieldType
[src]

Converts a proto field type into a native field type.

Trait Implementations

impl Debug for InternalFieldType[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl PartialEq<InternalFieldType> for InternalFieldType[src]

fn eq(&self, other: &InternalFieldType) -> bool[src]

This method tests for self and other values to be equal, and is used by ==. Read more

fn ne(&self, other: &InternalFieldType) -> bool[src]

This method tests for !=.

impl Eq for InternalFieldType[src]

impl StructuralEq for InternalFieldType[src]

impl StructuralPartialEq for InternalFieldType[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

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

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

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

Performs the conversion.