aws-sdk-ecr 1.107.0

AWS SDK for Amazon Elastic Container Registry
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct CompleteLayerUploadOutput {
    /// <p>The registry ID associated with the request.</p>
    pub registry_id: ::std::option::Option<::std::string::String>,
    /// <p>The repository name associated with the request.</p>
    pub repository_name: ::std::option::Option<::std::string::String>,
    /// <p>The upload ID associated with the layer.</p>
    pub upload_id: ::std::option::Option<::std::string::String>,
    /// <p>The <code>sha256</code> digest of the image layer.</p>
    pub layer_digest: ::std::option::Option<::std::string::String>,
    _request_id: Option<String>,
}
impl CompleteLayerUploadOutput {
    /// <p>The registry ID associated with the request.</p>
    pub fn registry_id(&self) -> ::std::option::Option<&str> {
        self.registry_id.as_deref()
    }
    /// <p>The repository name associated with the request.</p>
    pub fn repository_name(&self) -> ::std::option::Option<&str> {
        self.repository_name.as_deref()
    }
    /// <p>The upload ID associated with the layer.</p>
    pub fn upload_id(&self) -> ::std::option::Option<&str> {
        self.upload_id.as_deref()
    }
    /// <p>The <code>sha256</code> digest of the image layer.</p>
    pub fn layer_digest(&self) -> ::std::option::Option<&str> {
        self.layer_digest.as_deref()
    }
}
impl ::aws_types::request_id::RequestId for CompleteLayerUploadOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl CompleteLayerUploadOutput {
    /// Creates a new builder-style object to manufacture [`CompleteLayerUploadOutput`](crate::operation::complete_layer_upload::CompleteLayerUploadOutput).
    pub fn builder() -> crate::operation::complete_layer_upload::builders::CompleteLayerUploadOutputBuilder {
        crate::operation::complete_layer_upload::builders::CompleteLayerUploadOutputBuilder::default()
    }
}

/// A builder for [`CompleteLayerUploadOutput`](crate::operation::complete_layer_upload::CompleteLayerUploadOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct CompleteLayerUploadOutputBuilder {
    pub(crate) registry_id: ::std::option::Option<::std::string::String>,
    pub(crate) repository_name: ::std::option::Option<::std::string::String>,
    pub(crate) upload_id: ::std::option::Option<::std::string::String>,
    pub(crate) layer_digest: ::std::option::Option<::std::string::String>,
    _request_id: Option<String>,
}
impl CompleteLayerUploadOutputBuilder {
    /// <p>The registry ID associated with the request.</p>
    pub fn registry_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.registry_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The registry ID associated with the request.</p>
    pub fn set_registry_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.registry_id = input;
        self
    }
    /// <p>The registry ID associated with the request.</p>
    pub fn get_registry_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.registry_id
    }
    /// <p>The repository name associated with the request.</p>
    pub fn repository_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.repository_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The repository name associated with the request.</p>
    pub fn set_repository_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.repository_name = input;
        self
    }
    /// <p>The repository name associated with the request.</p>
    pub fn get_repository_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.repository_name
    }
    /// <p>The upload ID associated with the layer.</p>
    pub fn upload_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.upload_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The upload ID associated with the layer.</p>
    pub fn set_upload_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.upload_id = input;
        self
    }
    /// <p>The upload ID associated with the layer.</p>
    pub fn get_upload_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.upload_id
    }
    /// <p>The <code>sha256</code> digest of the image layer.</p>
    pub fn layer_digest(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.layer_digest = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The <code>sha256</code> digest of the image layer.</p>
    pub fn set_layer_digest(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.layer_digest = input;
        self
    }
    /// <p>The <code>sha256</code> digest of the image layer.</p>
    pub fn get_layer_digest(&self) -> &::std::option::Option<::std::string::String> {
        &self.layer_digest
    }
    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
        self._request_id = Some(request_id.into());
        self
    }

    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
        self._request_id = request_id;
        self
    }
    /// Consumes the builder and constructs a [`CompleteLayerUploadOutput`](crate::operation::complete_layer_upload::CompleteLayerUploadOutput).
    pub fn build(self) -> crate::operation::complete_layer_upload::CompleteLayerUploadOutput {
        crate::operation::complete_layer_upload::CompleteLayerUploadOutput {
            registry_id: self.registry_id,
            repository_name: self.repository_name,
            upload_id: self.upload_id,
            layer_digest: self.layer_digest,
            _request_id: self._request_id,
        }
    }
}