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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
// 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 GetMergeOptionsInput {
/// <p>The name of the repository that contains the commits about which you want to get merge options.</p>
pub repository_name: ::std::option::Option<::std::string::String>,
/// <p>The branch, tag, HEAD, or other fully qualified reference used to identify a commit (for example, a branch name or a full commit ID).</p>
pub source_commit_specifier: ::std::option::Option<::std::string::String>,
/// <p>The branch, tag, HEAD, or other fully qualified reference used to identify a commit (for example, a branch name or a full commit ID).</p>
pub destination_commit_specifier: ::std::option::Option<::std::string::String>,
/// <p>The level of conflict detail to use. If unspecified, the default FILE_LEVEL is used, which returns a not-mergeable result if the same file has differences in both branches. If LINE_LEVEL is specified, a conflict is considered not mergeable if the same file in both branches has differences on the same line.</p>
pub conflict_detail_level: ::std::option::Option<crate::types::ConflictDetailLevelTypeEnum>,
/// <p>Specifies which branch to use when resolving conflicts, or whether to attempt automatically merging two versions of a file. The default is NONE, which requires any conflicts to be resolved manually before the merge operation is successful.</p>
pub conflict_resolution_strategy: ::std::option::Option<crate::types::ConflictResolutionStrategyTypeEnum>,
}
impl GetMergeOptionsInput {
/// <p>The name of the repository that contains the commits about which you want to get merge options.</p>
pub fn repository_name(&self) -> ::std::option::Option<&str> {
self.repository_name.as_deref()
}
/// <p>The branch, tag, HEAD, or other fully qualified reference used to identify a commit (for example, a branch name or a full commit ID).</p>
pub fn source_commit_specifier(&self) -> ::std::option::Option<&str> {
self.source_commit_specifier.as_deref()
}
/// <p>The branch, tag, HEAD, or other fully qualified reference used to identify a commit (for example, a branch name or a full commit ID).</p>
pub fn destination_commit_specifier(&self) -> ::std::option::Option<&str> {
self.destination_commit_specifier.as_deref()
}
/// <p>The level of conflict detail to use. If unspecified, the default FILE_LEVEL is used, which returns a not-mergeable result if the same file has differences in both branches. If LINE_LEVEL is specified, a conflict is considered not mergeable if the same file in both branches has differences on the same line.</p>
pub fn conflict_detail_level(&self) -> ::std::option::Option<&crate::types::ConflictDetailLevelTypeEnum> {
self.conflict_detail_level.as_ref()
}
/// <p>Specifies which branch to use when resolving conflicts, or whether to attempt automatically merging two versions of a file. The default is NONE, which requires any conflicts to be resolved manually before the merge operation is successful.</p>
pub fn conflict_resolution_strategy(&self) -> ::std::option::Option<&crate::types::ConflictResolutionStrategyTypeEnum> {
self.conflict_resolution_strategy.as_ref()
}
}
impl GetMergeOptionsInput {
/// Creates a new builder-style object to manufacture [`GetMergeOptionsInput`](crate::operation::get_merge_options::GetMergeOptionsInput).
pub fn builder() -> crate::operation::get_merge_options::builders::GetMergeOptionsInputBuilder {
crate::operation::get_merge_options::builders::GetMergeOptionsInputBuilder::default()
}
}
/// A builder for [`GetMergeOptionsInput`](crate::operation::get_merge_options::GetMergeOptionsInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetMergeOptionsInputBuilder {
pub(crate) repository_name: ::std::option::Option<::std::string::String>,
pub(crate) source_commit_specifier: ::std::option::Option<::std::string::String>,
pub(crate) destination_commit_specifier: ::std::option::Option<::std::string::String>,
pub(crate) conflict_detail_level: ::std::option::Option<crate::types::ConflictDetailLevelTypeEnum>,
pub(crate) conflict_resolution_strategy: ::std::option::Option<crate::types::ConflictResolutionStrategyTypeEnum>,
}
impl GetMergeOptionsInputBuilder {
/// <p>The name of the repository that contains the commits about which you want to get merge options.</p>
/// This field is required.
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 name of the repository that contains the commits about which you want to get merge options.</p>
pub fn set_repository_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.repository_name = input;
self
}
/// <p>The name of the repository that contains the commits about which you want to get merge options.</p>
pub fn get_repository_name(&self) -> &::std::option::Option<::std::string::String> {
&self.repository_name
}
/// <p>The branch, tag, HEAD, or other fully qualified reference used to identify a commit (for example, a branch name or a full commit ID).</p>
/// This field is required.
pub fn source_commit_specifier(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.source_commit_specifier = ::std::option::Option::Some(input.into());
self
}
/// <p>The branch, tag, HEAD, or other fully qualified reference used to identify a commit (for example, a branch name or a full commit ID).</p>
pub fn set_source_commit_specifier(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.source_commit_specifier = input;
self
}
/// <p>The branch, tag, HEAD, or other fully qualified reference used to identify a commit (for example, a branch name or a full commit ID).</p>
pub fn get_source_commit_specifier(&self) -> &::std::option::Option<::std::string::String> {
&self.source_commit_specifier
}
/// <p>The branch, tag, HEAD, or other fully qualified reference used to identify a commit (for example, a branch name or a full commit ID).</p>
/// This field is required.
pub fn destination_commit_specifier(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.destination_commit_specifier = ::std::option::Option::Some(input.into());
self
}
/// <p>The branch, tag, HEAD, or other fully qualified reference used to identify a commit (for example, a branch name or a full commit ID).</p>
pub fn set_destination_commit_specifier(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.destination_commit_specifier = input;
self
}
/// <p>The branch, tag, HEAD, or other fully qualified reference used to identify a commit (for example, a branch name or a full commit ID).</p>
pub fn get_destination_commit_specifier(&self) -> &::std::option::Option<::std::string::String> {
&self.destination_commit_specifier
}
/// <p>The level of conflict detail to use. If unspecified, the default FILE_LEVEL is used, which returns a not-mergeable result if the same file has differences in both branches. If LINE_LEVEL is specified, a conflict is considered not mergeable if the same file in both branches has differences on the same line.</p>
pub fn conflict_detail_level(mut self, input: crate::types::ConflictDetailLevelTypeEnum) -> Self {
self.conflict_detail_level = ::std::option::Option::Some(input);
self
}
/// <p>The level of conflict detail to use. If unspecified, the default FILE_LEVEL is used, which returns a not-mergeable result if the same file has differences in both branches. If LINE_LEVEL is specified, a conflict is considered not mergeable if the same file in both branches has differences on the same line.</p>
pub fn set_conflict_detail_level(mut self, input: ::std::option::Option<crate::types::ConflictDetailLevelTypeEnum>) -> Self {
self.conflict_detail_level = input;
self
}
/// <p>The level of conflict detail to use. If unspecified, the default FILE_LEVEL is used, which returns a not-mergeable result if the same file has differences in both branches. If LINE_LEVEL is specified, a conflict is considered not mergeable if the same file in both branches has differences on the same line.</p>
pub fn get_conflict_detail_level(&self) -> &::std::option::Option<crate::types::ConflictDetailLevelTypeEnum> {
&self.conflict_detail_level
}
/// <p>Specifies which branch to use when resolving conflicts, or whether to attempt automatically merging two versions of a file. The default is NONE, which requires any conflicts to be resolved manually before the merge operation is successful.</p>
pub fn conflict_resolution_strategy(mut self, input: crate::types::ConflictResolutionStrategyTypeEnum) -> Self {
self.conflict_resolution_strategy = ::std::option::Option::Some(input);
self
}
/// <p>Specifies which branch to use when resolving conflicts, or whether to attempt automatically merging two versions of a file. The default is NONE, which requires any conflicts to be resolved manually before the merge operation is successful.</p>
pub fn set_conflict_resolution_strategy(mut self, input: ::std::option::Option<crate::types::ConflictResolutionStrategyTypeEnum>) -> Self {
self.conflict_resolution_strategy = input;
self
}
/// <p>Specifies which branch to use when resolving conflicts, or whether to attempt automatically merging two versions of a file. The default is NONE, which requires any conflicts to be resolved manually before the merge operation is successful.</p>
pub fn get_conflict_resolution_strategy(&self) -> &::std::option::Option<crate::types::ConflictResolutionStrategyTypeEnum> {
&self.conflict_resolution_strategy
}
/// Consumes the builder and constructs a [`GetMergeOptionsInput`](crate::operation::get_merge_options::GetMergeOptionsInput).
pub fn build(
self,
) -> ::std::result::Result<crate::operation::get_merge_options::GetMergeOptionsInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::get_merge_options::GetMergeOptionsInput {
repository_name: self.repository_name,
source_commit_specifier: self.source_commit_specifier,
destination_commit_specifier: self.destination_commit_specifier,
conflict_detail_level: self.conflict_detail_level,
conflict_resolution_strategy: self.conflict_resolution_strategy,
})
}
}