Struct protobuf::reflect::FieldDescriptor [−][src]
Dynamic field
Implementations
impl FieldDescriptor
[src]
pub fn proto(&self) -> &'static FieldDescriptorProto
[src]
Protobuf field descriptor
pub fn name(&self) -> &'static str
[src]
Field protobuf name
pub fn is_repeated(&self) -> bool
[src]
If field repeated?
pub fn has_field(&self, m: &dyn Message) -> bool
[src]
Is field set?
pub fn len_field(&self, m: &dyn Message) -> usize
[src]
Get length of repeated
or map
field
pub fn get_message<'a>(&self, m: &'a dyn Message) -> &'a dyn Message
[src]
Get singular message
pub fn get_enum(&self, m: &dyn Message) -> &'static EnumValueDescriptor
[src]
Get singular enum
pub fn get_str<'a>(&self, m: &'a dyn Message) -> &'a str
[src]
Get singular string
pub fn get_bytes<'a>(&self, m: &'a dyn Message) -> &'a [u8]ⓘ
[src]
Get singular bytes
pub fn get_u32(&self, m: &dyn Message) -> u32
[src]
Get singular u32
pub fn get_u64(&self, m: &dyn Message) -> u64
[src]
Get singular u64
pub fn get_i32(&self, m: &dyn Message) -> i32
[src]
Get singular i32
pub fn get_i64(&self, m: &dyn Message) -> i64
[src]
Get singular i64
pub fn get_bool(&self, m: &dyn Message) -> bool
[src]
Get singular bool
pub fn get_f32(&self, m: &dyn Message) -> f32
[src]
Get singular f32
pub fn get_f64(&self, m: &dyn Message) -> f64
[src]
Get singular f64
pub fn get_reflect<'a>(&self, m: &'a dyn Message) -> ReflectFieldRef<'a>
[src]
Get a field
Auto Trait Implementations
impl !RefUnwindSafe for FieldDescriptor
impl !Send for FieldDescriptor
impl !Sync for FieldDescriptor
impl Unpin for FieldDescriptor
impl !UnwindSafe for FieldDescriptor
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
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]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,