// This file is generated by rust-protobuf 3.7.2. Do not edit
// .proto file is parsed by protoc 24.4
// @generated

// https://github.com/rust-lang/rust-clippy/issues/702
#![allow(unknown_lints)]
#![allow(clippy::all)]

#![allow(unused_attributes)]
#![cfg_attr(rustfmt, rustfmt::skip)]

#![allow(dead_code)]
#![allow(missing_docs)]
#![allow(non_camel_case_types)]
#![allow(non_snake_case)]
#![allow(non_upper_case_globals)]
#![allow(trivial_casts)]
#![allow(unused_results)]
#![allow(unused_mut)]

//! Generated file from `in_toto_attestation/predicates/provenance/v0.1/provenance.proto`

/// Generated files are compatible only with the same version
/// of protobuf runtime.
const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_7_2;

// @@protoc_insertion_point(message:in_toto_attestation.predicates.provenance.v01.Provenance)
#[derive(PartialEq,Clone,Default,Debug)]
pub struct Provenance {
    // message fields
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Provenance.builder)
    pub builder: ::protobuf::MessageField<Builder>,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Provenance.recipe)
    pub recipe: ::protobuf::MessageField<Recipe>,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Provenance.metadata)
    pub metadata: ::protobuf::MessageField<Metadata>,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Provenance.materials)
    pub materials: ::std::vec::Vec<Material>,
    // special fields
    // @@protoc_insertion_point(special_field:in_toto_attestation.predicates.provenance.v01.Provenance.special_fields)
    pub special_fields: ::protobuf::SpecialFields,
}

impl<'a> ::std::default::Default for &'a Provenance {
    fn default() -> &'a Provenance {
        <Provenance as ::protobuf::Message>::default_instance()
    }
}

impl Provenance {
    pub fn new() -> Provenance {
        ::std::default::Default::default()
    }

    fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
        let mut fields = ::std::vec::Vec::with_capacity(4);
        let mut oneofs = ::std::vec::Vec::with_capacity(0);
        fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, Builder>(
            "builder",
            |m: &Provenance| { &m.builder },
            |m: &mut Provenance| { &mut m.builder },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, Recipe>(
            "recipe",
            |m: &Provenance| { &m.recipe },
            |m: &mut Provenance| { &mut m.recipe },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, Metadata>(
            "metadata",
            |m: &Provenance| { &m.metadata },
            |m: &mut Provenance| { &mut m.metadata },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_vec_simpler_accessor::<_, _>(
            "materials",
            |m: &Provenance| { &m.materials },
            |m: &mut Provenance| { &mut m.materials },
        ));
        ::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<Provenance>(
            "Provenance",
            fields,
            oneofs,
        )
    }
}

impl ::protobuf::Message for Provenance {
    const NAME: &'static str = "Provenance";

    fn is_initialized(&self) -> bool {
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
        while let Some(tag) = is.read_raw_tag_or_eof()? {
            match tag {
                10 => {
                    ::protobuf::rt::read_singular_message_into_field(is, &mut self.builder)?;
                },
                18 => {
                    ::protobuf::rt::read_singular_message_into_field(is, &mut self.recipe)?;
                },
                26 => {
                    ::protobuf::rt::read_singular_message_into_field(is, &mut self.metadata)?;
                },
                34 => {
                    self.materials.push(is.read_message()?);
                },
                tag => {
                    ::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u64 {
        let mut my_size = 0;
        if let Some(v) = self.builder.as_ref() {
            let len = v.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
        }
        if let Some(v) = self.recipe.as_ref() {
            let len = v.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
        }
        if let Some(v) = self.metadata.as_ref() {
            let len = v.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
        }
        for value in &self.materials {
            let len = value.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
        };
        my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
        self.special_fields.cached_size().set(my_size as u32);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
        if let Some(v) = self.builder.as_ref() {
            ::protobuf::rt::write_message_field_with_cached_size(1, v, os)?;
        }
        if let Some(v) = self.recipe.as_ref() {
            ::protobuf::rt::write_message_field_with_cached_size(2, v, os)?;
        }
        if let Some(v) = self.metadata.as_ref() {
            ::protobuf::rt::write_message_field_with_cached_size(3, v, os)?;
        }
        for v in &self.materials {
            ::protobuf::rt::write_message_field_with_cached_size(4, v, os)?;
        };
        os.write_unknown_fields(self.special_fields.unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn special_fields(&self) -> &::protobuf::SpecialFields {
        &self.special_fields
    }

    fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
        &mut self.special_fields
    }

    fn new() -> Provenance {
        Provenance::new()
    }

    fn clear(&mut self) {
        self.builder.clear();
        self.recipe.clear();
        self.metadata.clear();
        self.materials.clear();
        self.special_fields.clear();
    }

    fn default_instance() -> &'static Provenance {
        static instance: Provenance = Provenance {
            builder: ::protobuf::MessageField::none(),
            recipe: ::protobuf::MessageField::none(),
            metadata: ::protobuf::MessageField::none(),
            materials: ::std::vec::Vec::new(),
            special_fields: ::protobuf::SpecialFields::new(),
        };
        &instance
    }
}

impl ::protobuf::MessageFull for Provenance {
    fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
        descriptor.get(|| file_descriptor().message_by_package_relative_name("Provenance").unwrap()).clone()
    }
}

impl ::std::fmt::Display for Provenance {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for Provenance {
    type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
}

// @@protoc_insertion_point(message:in_toto_attestation.predicates.provenance.v01.Builder)
#[derive(PartialEq,Clone,Default,Debug)]
pub struct Builder {
    // message fields
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Builder.id)
    pub id: ::std::string::String,
    // special fields
    // @@protoc_insertion_point(special_field:in_toto_attestation.predicates.provenance.v01.Builder.special_fields)
    pub special_fields: ::protobuf::SpecialFields,
}

impl<'a> ::std::default::Default for &'a Builder {
    fn default() -> &'a Builder {
        <Builder as ::protobuf::Message>::default_instance()
    }
}

impl Builder {
    pub fn new() -> Builder {
        ::std::default::Default::default()
    }

    fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
        let mut fields = ::std::vec::Vec::with_capacity(1);
        let mut oneofs = ::std::vec::Vec::with_capacity(0);
        fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
            "id",
            |m: &Builder| { &m.id },
            |m: &mut Builder| { &mut m.id },
        ));
        ::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<Builder>(
            "Builder",
            fields,
            oneofs,
        )
    }
}

impl ::protobuf::Message for Builder {
    const NAME: &'static str = "Builder";

    fn is_initialized(&self) -> bool {
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
        while let Some(tag) = is.read_raw_tag_or_eof()? {
            match tag {
                10 => {
                    self.id = is.read_string()?;
                },
                tag => {
                    ::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u64 {
        let mut my_size = 0;
        if !self.id.is_empty() {
            my_size += ::protobuf::rt::string_size(1, &self.id);
        }
        my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
        self.special_fields.cached_size().set(my_size as u32);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
        if !self.id.is_empty() {
            os.write_string(1, &self.id)?;
        }
        os.write_unknown_fields(self.special_fields.unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn special_fields(&self) -> &::protobuf::SpecialFields {
        &self.special_fields
    }

    fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
        &mut self.special_fields
    }

    fn new() -> Builder {
        Builder::new()
    }

    fn clear(&mut self) {
        self.id.clear();
        self.special_fields.clear();
    }

    fn default_instance() -> &'static Builder {
        static instance: Builder = Builder {
            id: ::std::string::String::new(),
            special_fields: ::protobuf::SpecialFields::new(),
        };
        &instance
    }
}

impl ::protobuf::MessageFull for Builder {
    fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
        descriptor.get(|| file_descriptor().message_by_package_relative_name("Builder").unwrap()).clone()
    }
}

impl ::std::fmt::Display for Builder {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for Builder {
    type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
}

// @@protoc_insertion_point(message:in_toto_attestation.predicates.provenance.v01.Recipe)
#[derive(PartialEq,Clone,Default,Debug)]
pub struct Recipe {
    // message fields
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Recipe.type)
    pub type_: ::std::string::String,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Recipe.defined_in_material)
    pub defined_in_material: i32,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Recipe.entry_point)
    pub entry_point: ::std::string::String,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Recipe.arguments)
    pub arguments: ::protobuf::MessageField<::protobuf::well_known_types::struct_::Struct>,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Recipe.environment)
    pub environment: ::protobuf::MessageField<::protobuf::well_known_types::struct_::Struct>,
    // special fields
    // @@protoc_insertion_point(special_field:in_toto_attestation.predicates.provenance.v01.Recipe.special_fields)
    pub special_fields: ::protobuf::SpecialFields,
}

impl<'a> ::std::default::Default for &'a Recipe {
    fn default() -> &'a Recipe {
        <Recipe as ::protobuf::Message>::default_instance()
    }
}

impl Recipe {
    pub fn new() -> Recipe {
        ::std::default::Default::default()
    }

    fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
        let mut fields = ::std::vec::Vec::with_capacity(5);
        let mut oneofs = ::std::vec::Vec::with_capacity(0);
        fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
            "type",
            |m: &Recipe| { &m.type_ },
            |m: &mut Recipe| { &mut m.type_ },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
            "defined_in_material",
            |m: &Recipe| { &m.defined_in_material },
            |m: &mut Recipe| { &mut m.defined_in_material },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
            "entry_point",
            |m: &Recipe| { &m.entry_point },
            |m: &mut Recipe| { &mut m.entry_point },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, ::protobuf::well_known_types::struct_::Struct>(
            "arguments",
            |m: &Recipe| { &m.arguments },
            |m: &mut Recipe| { &mut m.arguments },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, ::protobuf::well_known_types::struct_::Struct>(
            "environment",
            |m: &Recipe| { &m.environment },
            |m: &mut Recipe| { &mut m.environment },
        ));
        ::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<Recipe>(
            "Recipe",
            fields,
            oneofs,
        )
    }
}

impl ::protobuf::Message for Recipe {
    const NAME: &'static str = "Recipe";

    fn is_initialized(&self) -> bool {
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
        while let Some(tag) = is.read_raw_tag_or_eof()? {
            match tag {
                10 => {
                    self.type_ = is.read_string()?;
                },
                16 => {
                    self.defined_in_material = is.read_int32()?;
                },
                26 => {
                    self.entry_point = is.read_string()?;
                },
                34 => {
                    ::protobuf::rt::read_singular_message_into_field(is, &mut self.arguments)?;
                },
                42 => {
                    ::protobuf::rt::read_singular_message_into_field(is, &mut self.environment)?;
                },
                tag => {
                    ::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u64 {
        let mut my_size = 0;
        if !self.type_.is_empty() {
            my_size += ::protobuf::rt::string_size(1, &self.type_);
        }
        if self.defined_in_material != 0 {
            my_size += ::protobuf::rt::int32_size(2, self.defined_in_material);
        }
        if !self.entry_point.is_empty() {
            my_size += ::protobuf::rt::string_size(3, &self.entry_point);
        }
        if let Some(v) = self.arguments.as_ref() {
            let len = v.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
        }
        if let Some(v) = self.environment.as_ref() {
            let len = v.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
        }
        my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
        self.special_fields.cached_size().set(my_size as u32);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
        if !self.type_.is_empty() {
            os.write_string(1, &self.type_)?;
        }
        if self.defined_in_material != 0 {
            os.write_int32(2, self.defined_in_material)?;
        }
        if !self.entry_point.is_empty() {
            os.write_string(3, &self.entry_point)?;
        }
        if let Some(v) = self.arguments.as_ref() {
            ::protobuf::rt::write_message_field_with_cached_size(4, v, os)?;
        }
        if let Some(v) = self.environment.as_ref() {
            ::protobuf::rt::write_message_field_with_cached_size(5, v, os)?;
        }
        os.write_unknown_fields(self.special_fields.unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn special_fields(&self) -> &::protobuf::SpecialFields {
        &self.special_fields
    }

    fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
        &mut self.special_fields
    }

    fn new() -> Recipe {
        Recipe::new()
    }

    fn clear(&mut self) {
        self.type_.clear();
        self.defined_in_material = 0;
        self.entry_point.clear();
        self.arguments.clear();
        self.environment.clear();
        self.special_fields.clear();
    }

    fn default_instance() -> &'static Recipe {
        static instance: Recipe = Recipe {
            type_: ::std::string::String::new(),
            defined_in_material: 0,
            entry_point: ::std::string::String::new(),
            arguments: ::protobuf::MessageField::none(),
            environment: ::protobuf::MessageField::none(),
            special_fields: ::protobuf::SpecialFields::new(),
        };
        &instance
    }
}

impl ::protobuf::MessageFull for Recipe {
    fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
        descriptor.get(|| file_descriptor().message_by_package_relative_name("Recipe").unwrap()).clone()
    }
}

impl ::std::fmt::Display for Recipe {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for Recipe {
    type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
}

// @@protoc_insertion_point(message:in_toto_attestation.predicates.provenance.v01.Metadata)
#[derive(PartialEq,Clone,Default,Debug)]
pub struct Metadata {
    // message fields
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Metadata.build_invocation_id)
    pub build_invocation_id: ::std::string::String,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Metadata.build_started_on)
    pub build_started_on: ::protobuf::MessageField<::protobuf::well_known_types::timestamp::Timestamp>,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Metadata.build_finished_on)
    pub build_finished_on: ::protobuf::MessageField<::protobuf::well_known_types::timestamp::Timestamp>,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Metadata.completeness)
    pub completeness: ::protobuf::MessageField<Completeness>,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Metadata.reproducible)
    pub reproducible: bool,
    // special fields
    // @@protoc_insertion_point(special_field:in_toto_attestation.predicates.provenance.v01.Metadata.special_fields)
    pub special_fields: ::protobuf::SpecialFields,
}

impl<'a> ::std::default::Default for &'a Metadata {
    fn default() -> &'a Metadata {
        <Metadata as ::protobuf::Message>::default_instance()
    }
}

impl Metadata {
    pub fn new() -> Metadata {
        ::std::default::Default::default()
    }

    fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
        let mut fields = ::std::vec::Vec::with_capacity(5);
        let mut oneofs = ::std::vec::Vec::with_capacity(0);
        fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
            "build_invocation_id",
            |m: &Metadata| { &m.build_invocation_id },
            |m: &mut Metadata| { &mut m.build_invocation_id },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, ::protobuf::well_known_types::timestamp::Timestamp>(
            "build_started_on",
            |m: &Metadata| { &m.build_started_on },
            |m: &mut Metadata| { &mut m.build_started_on },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, ::protobuf::well_known_types::timestamp::Timestamp>(
            "build_finished_on",
            |m: &Metadata| { &m.build_finished_on },
            |m: &mut Metadata| { &mut m.build_finished_on },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_message_field_accessor::<_, Completeness>(
            "completeness",
            |m: &Metadata| { &m.completeness },
            |m: &mut Metadata| { &mut m.completeness },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
            "reproducible",
            |m: &Metadata| { &m.reproducible },
            |m: &mut Metadata| { &mut m.reproducible },
        ));
        ::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<Metadata>(
            "Metadata",
            fields,
            oneofs,
        )
    }
}

impl ::protobuf::Message for Metadata {
    const NAME: &'static str = "Metadata";

    fn is_initialized(&self) -> bool {
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
        while let Some(tag) = is.read_raw_tag_or_eof()? {
            match tag {
                10 => {
                    self.build_invocation_id = is.read_string()?;
                },
                18 => {
                    ::protobuf::rt::read_singular_message_into_field(is, &mut self.build_started_on)?;
                },
                26 => {
                    ::protobuf::rt::read_singular_message_into_field(is, &mut self.build_finished_on)?;
                },
                34 => {
                    ::protobuf::rt::read_singular_message_into_field(is, &mut self.completeness)?;
                },
                40 => {
                    self.reproducible = is.read_bool()?;
                },
                tag => {
                    ::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u64 {
        let mut my_size = 0;
        if !self.build_invocation_id.is_empty() {
            my_size += ::protobuf::rt::string_size(1, &self.build_invocation_id);
        }
        if let Some(v) = self.build_started_on.as_ref() {
            let len = v.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
        }
        if let Some(v) = self.build_finished_on.as_ref() {
            let len = v.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
        }
        if let Some(v) = self.completeness.as_ref() {
            let len = v.compute_size();
            my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(len) + len;
        }
        if self.reproducible != false {
            my_size += 1 + 1;
        }
        my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
        self.special_fields.cached_size().set(my_size as u32);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
        if !self.build_invocation_id.is_empty() {
            os.write_string(1, &self.build_invocation_id)?;
        }
        if let Some(v) = self.build_started_on.as_ref() {
            ::protobuf::rt::write_message_field_with_cached_size(2, v, os)?;
        }
        if let Some(v) = self.build_finished_on.as_ref() {
            ::protobuf::rt::write_message_field_with_cached_size(3, v, os)?;
        }
        if let Some(v) = self.completeness.as_ref() {
            ::protobuf::rt::write_message_field_with_cached_size(4, v, os)?;
        }
        if self.reproducible != false {
            os.write_bool(5, self.reproducible)?;
        }
        os.write_unknown_fields(self.special_fields.unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn special_fields(&self) -> &::protobuf::SpecialFields {
        &self.special_fields
    }

    fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
        &mut self.special_fields
    }

    fn new() -> Metadata {
        Metadata::new()
    }

    fn clear(&mut self) {
        self.build_invocation_id.clear();
        self.build_started_on.clear();
        self.build_finished_on.clear();
        self.completeness.clear();
        self.reproducible = false;
        self.special_fields.clear();
    }

    fn default_instance() -> &'static Metadata {
        static instance: Metadata = Metadata {
            build_invocation_id: ::std::string::String::new(),
            build_started_on: ::protobuf::MessageField::none(),
            build_finished_on: ::protobuf::MessageField::none(),
            completeness: ::protobuf::MessageField::none(),
            reproducible: false,
            special_fields: ::protobuf::SpecialFields::new(),
        };
        &instance
    }
}

impl ::protobuf::MessageFull for Metadata {
    fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
        descriptor.get(|| file_descriptor().message_by_package_relative_name("Metadata").unwrap()).clone()
    }
}

impl ::std::fmt::Display for Metadata {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for Metadata {
    type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
}

// @@protoc_insertion_point(message:in_toto_attestation.predicates.provenance.v01.Completeness)
#[derive(PartialEq,Clone,Default,Debug)]
pub struct Completeness {
    // message fields
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Completeness.arguments)
    pub arguments: bool,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Completeness.environment)
    pub environment: bool,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Completeness.materials)
    pub materials: bool,
    // special fields
    // @@protoc_insertion_point(special_field:in_toto_attestation.predicates.provenance.v01.Completeness.special_fields)
    pub special_fields: ::protobuf::SpecialFields,
}

impl<'a> ::std::default::Default for &'a Completeness {
    fn default() -> &'a Completeness {
        <Completeness as ::protobuf::Message>::default_instance()
    }
}

impl Completeness {
    pub fn new() -> Completeness {
        ::std::default::Default::default()
    }

    fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
        let mut fields = ::std::vec::Vec::with_capacity(3);
        let mut oneofs = ::std::vec::Vec::with_capacity(0);
        fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
            "arguments",
            |m: &Completeness| { &m.arguments },
            |m: &mut Completeness| { &mut m.arguments },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
            "environment",
            |m: &Completeness| { &m.environment },
            |m: &mut Completeness| { &mut m.environment },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
            "materials",
            |m: &Completeness| { &m.materials },
            |m: &mut Completeness| { &mut m.materials },
        ));
        ::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<Completeness>(
            "Completeness",
            fields,
            oneofs,
        )
    }
}

impl ::protobuf::Message for Completeness {
    const NAME: &'static str = "Completeness";

    fn is_initialized(&self) -> bool {
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
        while let Some(tag) = is.read_raw_tag_or_eof()? {
            match tag {
                8 => {
                    self.arguments = is.read_bool()?;
                },
                16 => {
                    self.environment = is.read_bool()?;
                },
                24 => {
                    self.materials = is.read_bool()?;
                },
                tag => {
                    ::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u64 {
        let mut my_size = 0;
        if self.arguments != false {
            my_size += 1 + 1;
        }
        if self.environment != false {
            my_size += 1 + 1;
        }
        if self.materials != false {
            my_size += 1 + 1;
        }
        my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
        self.special_fields.cached_size().set(my_size as u32);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
        if self.arguments != false {
            os.write_bool(1, self.arguments)?;
        }
        if self.environment != false {
            os.write_bool(2, self.environment)?;
        }
        if self.materials != false {
            os.write_bool(3, self.materials)?;
        }
        os.write_unknown_fields(self.special_fields.unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn special_fields(&self) -> &::protobuf::SpecialFields {
        &self.special_fields
    }

    fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
        &mut self.special_fields
    }

    fn new() -> Completeness {
        Completeness::new()
    }

    fn clear(&mut self) {
        self.arguments = false;
        self.environment = false;
        self.materials = false;
        self.special_fields.clear();
    }

    fn default_instance() -> &'static Completeness {
        static instance: Completeness = Completeness {
            arguments: false,
            environment: false,
            materials: false,
            special_fields: ::protobuf::SpecialFields::new(),
        };
        &instance
    }
}

impl ::protobuf::MessageFull for Completeness {
    fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
        descriptor.get(|| file_descriptor().message_by_package_relative_name("Completeness").unwrap()).clone()
    }
}

impl ::std::fmt::Display for Completeness {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for Completeness {
    type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
}

// @@protoc_insertion_point(message:in_toto_attestation.predicates.provenance.v01.Material)
#[derive(PartialEq,Clone,Default,Debug)]
pub struct Material {
    // message fields
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Material.uri)
    pub uri: ::std::string::String,
    // @@protoc_insertion_point(field:in_toto_attestation.predicates.provenance.v01.Material.digest)
    pub digest: ::std::collections::HashMap<::std::string::String, ::std::string::String>,
    // special fields
    // @@protoc_insertion_point(special_field:in_toto_attestation.predicates.provenance.v01.Material.special_fields)
    pub special_fields: ::protobuf::SpecialFields,
}

impl<'a> ::std::default::Default for &'a Material {
    fn default() -> &'a Material {
        <Material as ::protobuf::Message>::default_instance()
    }
}

impl Material {
    pub fn new() -> Material {
        ::std::default::Default::default()
    }

    fn generated_message_descriptor_data() -> ::protobuf::reflect::GeneratedMessageDescriptorData {
        let mut fields = ::std::vec::Vec::with_capacity(2);
        let mut oneofs = ::std::vec::Vec::with_capacity(0);
        fields.push(::protobuf::reflect::rt::v2::make_simpler_field_accessor::<_, _>(
            "uri",
            |m: &Material| { &m.uri },
            |m: &mut Material| { &mut m.uri },
        ));
        fields.push(::protobuf::reflect::rt::v2::make_map_simpler_accessor_new::<_, _>(
            "digest",
            |m: &Material| { &m.digest },
            |m: &mut Material| { &mut m.digest },
        ));
        ::protobuf::reflect::GeneratedMessageDescriptorData::new_2::<Material>(
            "Material",
            fields,
            oneofs,
        )
    }
}

impl ::protobuf::Message for Material {
    const NAME: &'static str = "Material";

    fn is_initialized(&self) -> bool {
        true
    }

    fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream<'_>) -> ::protobuf::Result<()> {
        while let Some(tag) = is.read_raw_tag_or_eof()? {
            match tag {
                10 => {
                    self.uri = is.read_string()?;
                },
                18 => {
                    let len = is.read_raw_varint32()?;
                    let old_limit = is.push_limit(len as u64)?;
                    let mut key = ::std::default::Default::default();
                    let mut value = ::std::default::Default::default();
                    while let Some(tag) = is.read_raw_tag_or_eof()? {
                        match tag {
                            10 => key = is.read_string()?,
                            18 => value = is.read_string()?,
                            _ => ::protobuf::rt::skip_field_for_tag(tag, is)?,
                        };
                    }
                    is.pop_limit(old_limit);
                    self.digest.insert(key, value);
                },
                tag => {
                    ::protobuf::rt::read_unknown_or_skip_group(tag, is, self.special_fields.mut_unknown_fields())?;
                },
            };
        }
        ::std::result::Result::Ok(())
    }

    // Compute sizes of nested messages
    #[allow(unused_variables)]
    fn compute_size(&self) -> u64 {
        let mut my_size = 0;
        if !self.uri.is_empty() {
            my_size += ::protobuf::rt::string_size(1, &self.uri);
        }
        for (k, v) in &self.digest {
            let mut entry_size = 0;
            entry_size += ::protobuf::rt::string_size(1, &k);
            entry_size += ::protobuf::rt::string_size(2, &v);
            my_size += 1 + ::protobuf::rt::compute_raw_varint64_size(entry_size) + entry_size
        };
        my_size += ::protobuf::rt::unknown_fields_size(self.special_fields.unknown_fields());
        self.special_fields.cached_size().set(my_size as u32);
        my_size
    }

    fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream<'_>) -> ::protobuf::Result<()> {
        if !self.uri.is_empty() {
            os.write_string(1, &self.uri)?;
        }
        for (k, v) in &self.digest {
            let mut entry_size = 0;
            entry_size += ::protobuf::rt::string_size(1, &k);
            entry_size += ::protobuf::rt::string_size(2, &v);
            os.write_raw_varint32(18)?; // Tag.
            os.write_raw_varint32(entry_size as u32)?;
            os.write_string(1, &k)?;
            os.write_string(2, &v)?;
        };
        os.write_unknown_fields(self.special_fields.unknown_fields())?;
        ::std::result::Result::Ok(())
    }

    fn special_fields(&self) -> &::protobuf::SpecialFields {
        &self.special_fields
    }

    fn mut_special_fields(&mut self) -> &mut ::protobuf::SpecialFields {
        &mut self.special_fields
    }

    fn new() -> Material {
        Material::new()
    }

    fn clear(&mut self) {
        self.uri.clear();
        self.digest.clear();
        self.special_fields.clear();
    }

    fn default_instance() -> &'static Material {
        static instance: ::protobuf::rt::Lazy<Material> = ::protobuf::rt::Lazy::new();
        instance.get(Material::new)
    }
}

impl ::protobuf::MessageFull for Material {
    fn descriptor() -> ::protobuf::reflect::MessageDescriptor {
        static descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::rt::Lazy::new();
        descriptor.get(|| file_descriptor().message_by_package_relative_name("Material").unwrap()).clone()
    }
}

impl ::std::fmt::Display for Material {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        ::protobuf::text_format::fmt(self, f)
    }
}

impl ::protobuf::reflect::ProtobufValue for Material {
    type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage<Self>;
}

static file_descriptor_proto_data: &'static [u8] = b"\
    \n?in_toto_attestation/predicates/provenance/v0.1/provenance.proto\x12-i\
    n_toto_attestation.predicates.provenance.v01\x1a\x1cgoogle/protobuf/stru\
    ct.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xd9\x02\n\nProvenance\
    \x12P\n\x07builder\x18\x01\x20\x01(\x0b26.in_toto_attestation.predicates\
    .provenance.v01.BuilderR\x07builder\x12M\n\x06recipe\x18\x02\x20\x01(\
    \x0b25.in_toto_attestation.predicates.provenance.v01.RecipeR\x06recipe\
    \x12S\n\x08metadata\x18\x03\x20\x01(\x0b27.in_toto_attestation.predicate\
    s.provenance.v01.MetadataR\x08metadata\x12U\n\tmaterials\x18\x04\x20\x03\
    (\x0b27.in_toto_attestation.predicates.provenance.v01.MaterialR\tmateria\
    ls\"\x19\n\x07Builder\x12\x0e\n\x02id\x18\x01\x20\x01(\tR\x02id\"\xdf\
    \x01\n\x06Recipe\x12\x12\n\x04type\x18\x01\x20\x01(\tR\x04type\x12.\n\
    \x13defined_in_material\x18\x02\x20\x01(\x05R\x11definedInMaterial\x12\
    \x1f\n\x0bentry_point\x18\x03\x20\x01(\tR\nentryPoint\x125\n\targuments\
    \x18\x04\x20\x01(\x0b2\x17.google.protobuf.StructR\targuments\x129\n\x0b\
    environment\x18\x05\x20\x01(\x0b2\x17.google.protobuf.StructR\x0benviron\
    ment\"\xcd\x02\n\x08Metadata\x12.\n\x13build_invocation_id\x18\x01\x20\
    \x01(\tR\x11buildInvocationId\x12D\n\x10build_started_on\x18\x02\x20\x01\
    (\x0b2\x1a.google.protobuf.TimestampR\x0ebuildStartedOn\x12F\n\x11build_\
    finished_on\x18\x03\x20\x01(\x0b2\x1a.google.protobuf.TimestampR\x0fbuil\
    dFinishedOn\x12_\n\x0ccompleteness\x18\x04\x20\x01(\x0b2;.in_toto_attest\
    ation.predicates.provenance.v01.CompletenessR\x0ccompleteness\x12\"\n\
    \x0creproducible\x18\x05\x20\x01(\x08R\x0creproducible\"l\n\x0cCompleten\
    ess\x12\x1c\n\targuments\x18\x01\x20\x01(\x08R\targuments\x12\x20\n\x0be\
    nvironment\x18\x02\x20\x01(\x08R\x0benvironment\x12\x1c\n\tmaterials\x18\
    \x03\x20\x01(\x08R\tmaterials\"\xb4\x01\n\x08Material\x12\x10\n\x03uri\
    \x18\x01\x20\x01(\tR\x03uri\x12[\n\x06digest\x18\x02\x20\x03(\x0b2C.in_t\
    oto_attestation.predicates.provenance.v01.Material.DigestEntryR\x06diges\
    t\x1a9\n\x0bDigestEntry\x12\x10\n\x03key\x18\x01\x20\x01(\tR\x03key\x12\
    \x14\n\x05value\x18\x02\x20\x01(\tR\x05value:\x028\x01Bu\n6io.github.int\
    oto.attestation.predicates.provenance.v01Z;github.com/in-toto/attestatio\
    n/go/predicates/provenance/v01b\x06proto3\
";

/// `FileDescriptorProto` object which was a source for this generated file
fn file_descriptor_proto() -> &'static ::protobuf::descriptor::FileDescriptorProto {
    static file_descriptor_proto_lazy: ::protobuf::rt::Lazy<::protobuf::descriptor::FileDescriptorProto> = ::protobuf::rt::Lazy::new();
    file_descriptor_proto_lazy.get(|| {
        ::protobuf::Message::parse_from_bytes(file_descriptor_proto_data).unwrap()
    })
}

/// `FileDescriptor` object which allows dynamic access to files
pub fn file_descriptor() -> &'static ::protobuf::reflect::FileDescriptor {
    static generated_file_descriptor_lazy: ::protobuf::rt::Lazy<::protobuf::reflect::GeneratedFileDescriptor> = ::protobuf::rt::Lazy::new();
    static file_descriptor: ::protobuf::rt::Lazy<::protobuf::reflect::FileDescriptor> = ::protobuf::rt::Lazy::new();
    file_descriptor.get(|| {
        let generated_file_descriptor = generated_file_descriptor_lazy.get(|| {
            let mut deps = ::std::vec::Vec::with_capacity(2);
            deps.push(::protobuf::well_known_types::struct_::file_descriptor().clone());
            deps.push(::protobuf::well_known_types::timestamp::file_descriptor().clone());
            let mut messages = ::std::vec::Vec::with_capacity(6);
            messages.push(Provenance::generated_message_descriptor_data());
            messages.push(Builder::generated_message_descriptor_data());
            messages.push(Recipe::generated_message_descriptor_data());
            messages.push(Metadata::generated_message_descriptor_data());
            messages.push(Completeness::generated_message_descriptor_data());
            messages.push(Material::generated_message_descriptor_data());
            let mut enums = ::std::vec::Vec::with_capacity(0);
            ::protobuf::reflect::GeneratedFileDescriptor::new_generated(
                file_descriptor_proto(),
                deps,
                messages,
                enums,
            )
        });
        ::protobuf::reflect::FileDescriptor::new_generated_2(generated_file_descriptor)
    })
}
