[][src]Struct tensorflow_proto::tensorflow::test::TestAllTypes

pub struct TestAllTypes {
    pub optional_int32: i32,
    pub optional_int64: i64,
    pub optional_uint32: u32,
    pub optional_uint64: u64,
    pub optional_sint32: i32,
    pub optional_sint64: i64,
    pub optional_fixed32: u32,
    pub optional_fixed64: u64,
    pub optional_sfixed32: i32,
    pub optional_sfixed64: i64,
    pub optional_float: f32,
    pub optional_double: f64,
    pub optional_bool: bool,
    pub optional_string: String,
    pub optional_bytes: Vec<u8>,
    pub optional_nested_message: Option<NestedMessage>,
    pub optional_foreign_message: Option<ForeignMessage>,
    pub optional_nested_enum: i32,
    pub optional_foreign_enum: i32,
    pub optional_cord: String,
    pub repeated_int32: Vec<i32>,
    pub repeated_int64: Vec<i64>,
    pub repeated_uint32: Vec<u32>,
    pub repeated_uint64: Vec<u64>,
    pub repeated_sint32: Vec<i32>,
    pub repeated_sint64: Vec<i64>,
    pub repeated_fixed32: Vec<u32>,
    pub repeated_fixed64: Vec<u64>,
    pub repeated_sfixed32: Vec<i32>,
    pub repeated_sfixed64: Vec<i64>,
    pub repeated_float: Vec<f32>,
    pub repeated_double: Vec<f64>,
    pub repeated_bool: Vec<bool>,
    pub repeated_string: Vec<String>,
    pub repeated_bytes: Vec<Vec<u8>>,
    pub repeated_nested_message: Vec<NestedMessage>,
    pub repeated_nested_enum: Vec<i32>,
    pub repeated_cord: Vec<String>,
    pub map_string_to_message: HashMap<String, NestedMessage>,
    pub map_int32_to_message: HashMap<i32, NestedMessage>,
    pub map_int64_to_message: HashMap<i64, NestedMessage>,
    pub map_bool_to_message: HashMap<bool, NestedMessage>,
    pub map_string_to_int64: HashMap<String, i64>,
    pub map_int64_to_string: HashMap<i64, String>,
    pub another_map_string_to_message: HashMap<String, NestedMessage>,
    pub packed_repeated_int64: Vec<i64>,
    pub oneof_field: Option<OneofField>,
}

Fields

optional_int32: i32

Singular

use large tag to test output order.

optional_int64: i64optional_uint32: u32optional_uint64: u64

use large tag to test output order.

optional_sint32: i32optional_sint64: i64optional_fixed32: u32optional_fixed64: u64optional_sfixed32: i32optional_sfixed64: i64optional_float: f32optional_double: f64optional_bool: booloptional_string: Stringoptional_bytes: Vec<u8>optional_nested_message: Option<NestedMessage>optional_foreign_message: Option<ForeignMessage>optional_nested_enum: i32optional_foreign_enum: i32optional_cord: Stringrepeated_int32: Vec<i32>

Repeated

repeated_int64: Vec<i64>repeated_uint32: Vec<u32>repeated_uint64: Vec<u64>repeated_sint32: Vec<i32>repeated_sint64: Vec<i64>repeated_fixed32: Vec<u32>repeated_fixed64: Vec<u64>repeated_sfixed32: Vec<i32>repeated_sfixed64: Vec<i64>repeated_float: Vec<f32>repeated_double: Vec<f64>repeated_bool: Vec<bool>repeated_string: Vec<String>repeated_bytes: Vec<Vec<u8>>repeated_nested_message: Vec<NestedMessage>repeated_nested_enum: Vec<i32>repeated_cord: Vec<String>map_string_to_message: HashMap<String, NestedMessage>map_int32_to_message: HashMap<i32, NestedMessage>map_int64_to_message: HashMap<i64, NestedMessage>map_bool_to_message: HashMap<bool, NestedMessage>map_string_to_int64: HashMap<String, i64>map_int64_to_string: HashMap<i64, String>another_map_string_to_message: HashMap<String, NestedMessage>packed_repeated_int64: Vec<i64>oneof_field: Option<OneofField>

Implementations

impl TestAllTypes[src]

pub fn optional_nested_enum(&self) -> NestedEnum[src]

Returns the enum value of optional_nested_enum, or the default if the field is set to an invalid enum value.

pub fn set_optional_nested_enum(&mut self, value: NestedEnum)[src]

Sets optional_nested_enum to the provided enum value.

pub fn optional_foreign_enum(&self) -> ForeignEnum[src]

Returns the enum value of optional_foreign_enum, or the default if the field is set to an invalid enum value.

pub fn set_optional_foreign_enum(&mut self, value: ForeignEnum)[src]

Sets optional_foreign_enum to the provided enum value.

pub fn repeated_nested_enum(
    &self
) -> FilterMap<Cloned<Iter<'_, i32>>, fn(_: i32) -> Option<NestedEnum>>
[src]

Returns an iterator which yields the valid enum values contained in repeated_nested_enum.

pub fn push_repeated_nested_enum(&mut self, value: NestedEnum)[src]

Appends the provided enum value to repeated_nested_enum.

Trait Implementations

impl Clone for TestAllTypes[src]

impl Debug for TestAllTypes[src]

impl Default for TestAllTypes[src]

impl Message for TestAllTypes[src]

impl PartialEq<TestAllTypes> for TestAllTypes[src]

impl StructuralPartialEq for TestAllTypes[src]

Auto Trait Implementations

Blanket Implementations

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

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

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

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

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

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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.

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.