aws_sdk_glue/types/
_s3_direct_source_additional_options.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2
3/// <p>Specifies additional connection options for the Amazon S3 data store.</p>
4#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct S3DirectSourceAdditionalOptions {
7    /// <p>Sets the upper limit for the target size of the dataset in bytes that will be processed.</p>
8    pub bounded_size: ::std::option::Option<i64>,
9    /// <p>Sets the upper limit for the target number of files that will be processed.</p>
10    pub bounded_files: ::std::option::Option<i64>,
11    /// <p>Sets option to enable a sample path.</p>
12    pub enable_sample_path: ::std::option::Option<bool>,
13    /// <p>If enabled, specifies the sample path.</p>
14    pub sample_path: ::std::option::Option<::std::string::String>,
15}
16impl S3DirectSourceAdditionalOptions {
17    /// <p>Sets the upper limit for the target size of the dataset in bytes that will be processed.</p>
18    pub fn bounded_size(&self) -> ::std::option::Option<i64> {
19        self.bounded_size
20    }
21    /// <p>Sets the upper limit for the target number of files that will be processed.</p>
22    pub fn bounded_files(&self) -> ::std::option::Option<i64> {
23        self.bounded_files
24    }
25    /// <p>Sets option to enable a sample path.</p>
26    pub fn enable_sample_path(&self) -> ::std::option::Option<bool> {
27        self.enable_sample_path
28    }
29    /// <p>If enabled, specifies the sample path.</p>
30    pub fn sample_path(&self) -> ::std::option::Option<&str> {
31        self.sample_path.as_deref()
32    }
33}
34impl S3DirectSourceAdditionalOptions {
35    /// Creates a new builder-style object to manufacture [`S3DirectSourceAdditionalOptions`](crate::types::S3DirectSourceAdditionalOptions).
36    pub fn builder() -> crate::types::builders::S3DirectSourceAdditionalOptionsBuilder {
37        crate::types::builders::S3DirectSourceAdditionalOptionsBuilder::default()
38    }
39}
40
41/// A builder for [`S3DirectSourceAdditionalOptions`](crate::types::S3DirectSourceAdditionalOptions).
42#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
43#[non_exhaustive]
44pub struct S3DirectSourceAdditionalOptionsBuilder {
45    pub(crate) bounded_size: ::std::option::Option<i64>,
46    pub(crate) bounded_files: ::std::option::Option<i64>,
47    pub(crate) enable_sample_path: ::std::option::Option<bool>,
48    pub(crate) sample_path: ::std::option::Option<::std::string::String>,
49}
50impl S3DirectSourceAdditionalOptionsBuilder {
51    /// <p>Sets the upper limit for the target size of the dataset in bytes that will be processed.</p>
52    pub fn bounded_size(mut self, input: i64) -> Self {
53        self.bounded_size = ::std::option::Option::Some(input);
54        self
55    }
56    /// <p>Sets the upper limit for the target size of the dataset in bytes that will be processed.</p>
57    pub fn set_bounded_size(mut self, input: ::std::option::Option<i64>) -> Self {
58        self.bounded_size = input;
59        self
60    }
61    /// <p>Sets the upper limit for the target size of the dataset in bytes that will be processed.</p>
62    pub fn get_bounded_size(&self) -> &::std::option::Option<i64> {
63        &self.bounded_size
64    }
65    /// <p>Sets the upper limit for the target number of files that will be processed.</p>
66    pub fn bounded_files(mut self, input: i64) -> Self {
67        self.bounded_files = ::std::option::Option::Some(input);
68        self
69    }
70    /// <p>Sets the upper limit for the target number of files that will be processed.</p>
71    pub fn set_bounded_files(mut self, input: ::std::option::Option<i64>) -> Self {
72        self.bounded_files = input;
73        self
74    }
75    /// <p>Sets the upper limit for the target number of files that will be processed.</p>
76    pub fn get_bounded_files(&self) -> &::std::option::Option<i64> {
77        &self.bounded_files
78    }
79    /// <p>Sets option to enable a sample path.</p>
80    pub fn enable_sample_path(mut self, input: bool) -> Self {
81        self.enable_sample_path = ::std::option::Option::Some(input);
82        self
83    }
84    /// <p>Sets option to enable a sample path.</p>
85    pub fn set_enable_sample_path(mut self, input: ::std::option::Option<bool>) -> Self {
86        self.enable_sample_path = input;
87        self
88    }
89    /// <p>Sets option to enable a sample path.</p>
90    pub fn get_enable_sample_path(&self) -> &::std::option::Option<bool> {
91        &self.enable_sample_path
92    }
93    /// <p>If enabled, specifies the sample path.</p>
94    pub fn sample_path(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
95        self.sample_path = ::std::option::Option::Some(input.into());
96        self
97    }
98    /// <p>If enabled, specifies the sample path.</p>
99    pub fn set_sample_path(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
100        self.sample_path = input;
101        self
102    }
103    /// <p>If enabled, specifies the sample path.</p>
104    pub fn get_sample_path(&self) -> &::std::option::Option<::std::string::String> {
105        &self.sample_path
106    }
107    /// Consumes the builder and constructs a [`S3DirectSourceAdditionalOptions`](crate::types::S3DirectSourceAdditionalOptions).
108    pub fn build(self) -> crate::types::S3DirectSourceAdditionalOptions {
109        crate::types::S3DirectSourceAdditionalOptions {
110            bounded_size: self.bounded_size,
111            bounded_files: self.bounded_files,
112            enable_sample_path: self.enable_sample_path,
113            sample_path: self.sample_path,
114        }
115    }
116}