pub struct KitchenSink {Show 52 fields
pub i32: i32,
pub optional_i32: Option<i32>,
pub repeated_i32: Vec<i32>,
pub u32: u32,
pub optional_u32: Option<u32>,
pub repeated_u32: Vec<u32>,
pub i64: i64,
pub optional_i64: Option<i64>,
pub repeated_i64: Vec<i64>,
pub u64: u64,
pub optional_u64: Option<u64>,
pub repeated_u64: Vec<u64>,
pub value: i32,
pub optional_value: Option<i32>,
pub repeated_value: Vec<i32>,
pub prefix: i32,
pub empty: Option<Empty>,
pub string_dict: HashMap<String, String>,
pub message_dict: HashMap<String, Empty>,
pub enum_dict: HashMap<String, i32>,
pub int64_dict: HashMap<i64, i32>,
pub int32_dict: HashMap<i32, i32>,
pub integer_dict: HashMap<i32, u64>,
pub bool: bool,
pub optional_bool: Option<bool>,
pub repeated_bool: Vec<bool>,
pub bytes: Bytes,
pub optional_bytes: Option<Bytes>,
pub repeated_bytes: Vec<Bytes>,
pub string: String,
pub optional_string: Option<String>,
pub duration: Option<Duration>,
pub timestamp: Option<Timestamp>,
pub external_message: Option<ExternMessage>,
pub external_enum: i32,
pub common_message: Option<CommonMessage>,
pub common_enum: i32,
pub mixed_case: i32,
pub string_bytes_dict: HashMap<String, Bytes>,
pub int_bytes_dict: HashMap<i32, Bytes>,
pub bool_value: Option<BoolValue>,
pub bytes_value: Option<BytesValue>,
pub double_value: Option<DoubleValue>,
pub float_value: Option<FloatValue>,
pub int32_value: Option<Int32Value>,
pub int64_value: Option<Int64Value>,
pub string_value: Option<StringValue>,
pub uint32_value: Option<UInt32Value>,
pub uint64_value: Option<UInt64Value>,
pub repeated_int32_value: Vec<Int32Value>,
pub map_int32_value: HashMap<String, Int32Value>,
pub one_of: Option<OneOf>,
}Fields§
§i32: i32§optional_i32: Option<i32>§repeated_i32: Vec<i32>§u32: u32§optional_u32: Option<u32>§repeated_u32: Vec<u32>§i64: i64§optional_i64: Option<i64>§repeated_i64: Vec<i64>§u64: u64§optional_u64: Option<u64>§repeated_u64: Vec<u64>§value: i32§optional_value: Option<i32>§repeated_value: Vec<i32>§prefix: i32§empty: Option<Empty>§string_dict: HashMap<String, String>§message_dict: HashMap<String, Empty>§enum_dict: HashMap<String, i32>§int64_dict: HashMap<i64, i32>§int32_dict: HashMap<i32, i32>§integer_dict: HashMap<i32, u64>§bool: bool§optional_bool: Option<bool>§repeated_bool: Vec<bool>§bytes: Bytes§optional_bytes: Option<Bytes>§repeated_bytes: Vec<Bytes>§string: String§optional_string: Option<String>§duration: Option<Duration>§timestamp: Option<Timestamp>§external_message: Option<ExternMessage>An externally defined message
external_enum: i32§common_message: Option<CommonMessage>Messages from an external package
common_enum: i32§mixed_case: i32§string_bytes_dict: HashMap<String, Bytes>§int_bytes_dict: HashMap<i32, Bytes>§bool_value: Option<BoolValue>§bytes_value: Option<BytesValue>§double_value: Option<DoubleValue>§float_value: Option<FloatValue>§int32_value: Option<Int32Value>§int64_value: Option<Int64Value>§string_value: Option<StringValue>§uint32_value: Option<UInt32Value>§uint64_value: Option<UInt64Value>§repeated_int32_value: Vec<Int32Value>§map_int32_value: HashMap<String, Int32Value>§one_of: Option<OneOf>Implementations§
Source§impl KitchenSink
impl KitchenSink
Sourcepub fn optional_i32(&self) -> i32
pub fn optional_i32(&self) -> i32
Returns the value of optional_i32, or the default value if optional_i32 is unset.
Sourcepub fn optional_u32(&self) -> u32
pub fn optional_u32(&self) -> u32
Returns the value of optional_u32, or the default value if optional_u32 is unset.
Sourcepub fn optional_i64(&self) -> i64
pub fn optional_i64(&self) -> i64
Returns the value of optional_i64, or the default value if optional_i64 is unset.
Sourcepub fn optional_u64(&self) -> u64
pub fn optional_u64(&self) -> u64
Returns the value of optional_u64, or the default value if optional_u64 is unset.
Sourcepub fn value(&self) -> Value
pub fn value(&self) -> Value
Returns the enum value of value, or the default if the field is set to an invalid enum value.
Sourcepub fn optional_value(&self) -> Value
pub fn optional_value(&self) -> Value
Returns the enum value of optional_value, or the default if the field is unset or set to an invalid enum value.
Sourcepub fn set_optional_value(&mut self, value: Value)
pub fn set_optional_value(&mut self, value: Value)
Sets optional_value to the provided enum value.
Sourcepub fn repeated_value(
&self,
) -> FilterMap<Cloned<Iter<'_, i32>>, fn(i32) -> Option<Value>>
pub fn repeated_value( &self, ) -> FilterMap<Cloned<Iter<'_, i32>>, fn(i32) -> Option<Value>>
Returns an iterator which yields the valid enum values contained in repeated_value.
Sourcepub fn push_repeated_value(&mut self, value: Value)
pub fn push_repeated_value(&mut self, value: Value)
Appends the provided enum value to repeated_value.
Sourcepub fn prefix(&self) -> Prefix
pub fn prefix(&self) -> Prefix
Returns the enum value of prefix, or the default if the field is set to an invalid enum value.
Sourcepub fn set_prefix(&mut self, value: Prefix)
pub fn set_prefix(&mut self, value: Prefix)
Sets prefix to the provided enum value.
Sourcepub fn get_enum_dict(&self, key: &str) -> Option<Prefix>
pub fn get_enum_dict(&self, key: &str) -> Option<Prefix>
Returns the enum value for the corresponding key in enum_dict, or None if the entry does not exist or it is not a valid enum value.
Sourcepub fn insert_enum_dict(&mut self, key: String, value: Prefix) -> Option<Prefix>
pub fn insert_enum_dict(&mut self, key: String, value: Prefix) -> Option<Prefix>
Inserts a key value pair into enum_dict.
Sourcepub fn get_int64_dict(&self, key: i64) -> Option<Prefix>
pub fn get_int64_dict(&self, key: i64) -> Option<Prefix>
Returns the enum value for the corresponding key in int64_dict, or None if the entry does not exist or it is not a valid enum value.
Sourcepub fn insert_int64_dict(&mut self, key: i64, value: Prefix) -> Option<Prefix>
pub fn insert_int64_dict(&mut self, key: i64, value: Prefix) -> Option<Prefix>
Inserts a key value pair into int64_dict.
Sourcepub fn get_int32_dict(&self, key: i32) -> Option<Prefix>
pub fn get_int32_dict(&self, key: i32) -> Option<Prefix>
Returns the enum value for the corresponding key in int32_dict, or None if the entry does not exist or it is not a valid enum value.
Sourcepub fn insert_int32_dict(&mut self, key: i32, value: Prefix) -> Option<Prefix>
pub fn insert_int32_dict(&mut self, key: i32, value: Prefix) -> Option<Prefix>
Inserts a key value pair into int32_dict.
Sourcepub fn optional_bool(&self) -> bool
pub fn optional_bool(&self) -> bool
Returns the value of optional_bool, or the default value if optional_bool is unset.
Sourcepub fn optional_bytes(&self) -> &[u8] ⓘ
pub fn optional_bytes(&self) -> &[u8] ⓘ
Returns the value of optional_bytes, or the default value if optional_bytes is unset.
Sourcepub fn optional_string(&self) -> &str
pub fn optional_string(&self) -> &str
Returns the value of optional_string, or the default value if optional_string is unset.
Sourcepub fn external_enum(&self) -> ExternEnumeration
pub fn external_enum(&self) -> ExternEnumeration
Returns the enum value of external_enum, or the default if the field is set to an invalid enum value.
Sourcepub fn set_external_enum(&mut self, value: ExternEnumeration)
pub fn set_external_enum(&mut self, value: ExternEnumeration)
Sets external_enum to the provided enum value.
Sourcepub fn common_enum(&self) -> CommonEnumeration
pub fn common_enum(&self) -> CommonEnumeration
Returns the enum value of common_enum, or the default if the field is set to an invalid enum value.
Sourcepub fn set_common_enum(&mut self, value: CommonEnumeration)
pub fn set_common_enum(&mut self, value: CommonEnumeration)
Sets common_enum to the provided enum value.
Sourcepub fn mixed_case(&self) -> MixedCase
pub fn mixed_case(&self) -> MixedCase
Returns the enum value of mixed_case, or the default if the field is set to an invalid enum value.
Sourcepub fn set_mixed_case(&mut self, value: MixedCase)
pub fn set_mixed_case(&mut self, value: MixedCase)
Sets mixed_case to the provided enum value.
Trait Implementations§
Source§impl Clone for KitchenSink
impl Clone for KitchenSink
Source§fn clone(&self) -> KitchenSink
fn clone(&self) -> KitchenSink
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for KitchenSink
impl Debug for KitchenSink
Source§impl Default for KitchenSink
impl Default for KitchenSink
§impl<'de> Deserialize<'de> for KitchenSink
impl<'de> Deserialize<'de> for KitchenSink
§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Source§impl Message for KitchenSink
impl Message for KitchenSink
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.