1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
// 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 UpdateCrawlerScheduleInput {
/// <p>The name of the crawler whose schedule to update.</p>
pub crawler_name: ::std::option::Option<::std::string::String>,
/// <p>The updated <code>cron</code> expression used to specify the schedule (see <a href="https://docs.aws.amazon.com/glue/latest/dg/monitor-data-warehouse-schedule.html">Time-Based Schedules for Jobs and Crawlers</a>. For example, to run something every day at 12:15 UTC, you would specify: <code>cron(15 12 * * ? *)</code>.</p>
pub schedule: ::std::option::Option<::std::string::String>,
}
impl UpdateCrawlerScheduleInput {
/// <p>The name of the crawler whose schedule to update.</p>
pub fn crawler_name(&self) -> ::std::option::Option<&str> {
self.crawler_name.as_deref()
}
/// <p>The updated <code>cron</code> expression used to specify the schedule (see <a href="https://docs.aws.amazon.com/glue/latest/dg/monitor-data-warehouse-schedule.html">Time-Based Schedules for Jobs and Crawlers</a>. For example, to run something every day at 12:15 UTC, you would specify: <code>cron(15 12 * * ? *)</code>.</p>
pub fn schedule(&self) -> ::std::option::Option<&str> {
self.schedule.as_deref()
}
}
impl UpdateCrawlerScheduleInput {
/// Creates a new builder-style object to manufacture [`UpdateCrawlerScheduleInput`](crate::operation::update_crawler_schedule::UpdateCrawlerScheduleInput).
pub fn builder() -> crate::operation::update_crawler_schedule::builders::UpdateCrawlerScheduleInputBuilder {
crate::operation::update_crawler_schedule::builders::UpdateCrawlerScheduleInputBuilder::default()
}
}
/// A builder for [`UpdateCrawlerScheduleInput`](crate::operation::update_crawler_schedule::UpdateCrawlerScheduleInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct UpdateCrawlerScheduleInputBuilder {
pub(crate) crawler_name: ::std::option::Option<::std::string::String>,
pub(crate) schedule: ::std::option::Option<::std::string::String>,
}
impl UpdateCrawlerScheduleInputBuilder {
/// <p>The name of the crawler whose schedule to update.</p>
/// This field is required.
pub fn crawler_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.crawler_name = ::std::option::Option::Some(input.into());
self
}
/// <p>The name of the crawler whose schedule to update.</p>
pub fn set_crawler_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.crawler_name = input;
self
}
/// <p>The name of the crawler whose schedule to update.</p>
pub fn get_crawler_name(&self) -> &::std::option::Option<::std::string::String> {
&self.crawler_name
}
/// <p>The updated <code>cron</code> expression used to specify the schedule (see <a href="https://docs.aws.amazon.com/glue/latest/dg/monitor-data-warehouse-schedule.html">Time-Based Schedules for Jobs and Crawlers</a>. For example, to run something every day at 12:15 UTC, you would specify: <code>cron(15 12 * * ? *)</code>.</p>
pub fn schedule(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.schedule = ::std::option::Option::Some(input.into());
self
}
/// <p>The updated <code>cron</code> expression used to specify the schedule (see <a href="https://docs.aws.amazon.com/glue/latest/dg/monitor-data-warehouse-schedule.html">Time-Based Schedules for Jobs and Crawlers</a>. For example, to run something every day at 12:15 UTC, you would specify: <code>cron(15 12 * * ? *)</code>.</p>
pub fn set_schedule(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.schedule = input;
self
}
/// <p>The updated <code>cron</code> expression used to specify the schedule (see <a href="https://docs.aws.amazon.com/glue/latest/dg/monitor-data-warehouse-schedule.html">Time-Based Schedules for Jobs and Crawlers</a>. For example, to run something every day at 12:15 UTC, you would specify: <code>cron(15 12 * * ? *)</code>.</p>
pub fn get_schedule(&self) -> &::std::option::Option<::std::string::String> {
&self.schedule
}
/// Consumes the builder and constructs a [`UpdateCrawlerScheduleInput`](crate::operation::update_crawler_schedule::UpdateCrawlerScheduleInput).
pub fn build(
self,
) -> ::std::result::Result<crate::operation::update_crawler_schedule::UpdateCrawlerScheduleInput, ::aws_smithy_types::error::operation::BuildError>
{
::std::result::Result::Ok(crate::operation::update_crawler_schedule::UpdateCrawlerScheduleInput {
crawler_name: self.crawler_name,
schedule: self.schedule,
})
}
}