AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
CreatePullRequestRequest.h
1
6#pragma once
7#include <aws/codecommit/CodeCommit_EXPORTS.h>
8#include <aws/codecommit/CodeCommitRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/codecommit/model/Target.h>
12#include <utility>
13#include <aws/core/utils/UUID.h>
14
15namespace Aws
16{
17namespace CodeCommit
18{
19namespace Model
20{
21
25 {
26 public:
27 AWS_CODECOMMIT_API CreatePullRequestRequest() = default;
28
29 // Service request name is the Operation name which will send this request out,
30 // each operation should has unique request name, so that we can get operation's name from this request.
31 // Note: this is not true for response, multiple operations may have the same response name,
32 // so we can not get operation's name from response.
33 inline virtual const char* GetServiceRequestName() const override { return "CreatePullRequest"; }
34
35 AWS_CODECOMMIT_API Aws::String SerializePayload() const override;
36
38
39
41
45 inline const Aws::String& GetTitle() const { return m_title; }
46 inline bool TitleHasBeenSet() const { return m_titleHasBeenSet; }
47 template<typename TitleT = Aws::String>
48 void SetTitle(TitleT&& value) { m_titleHasBeenSet = true; m_title = std::forward<TitleT>(value); }
49 template<typename TitleT = Aws::String>
50 CreatePullRequestRequest& WithTitle(TitleT&& value) { SetTitle(std::forward<TitleT>(value)); return *this;}
52
54
57 inline const Aws::String& GetDescription() const { return m_description; }
58 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
59 template<typename DescriptionT = Aws::String>
60 void SetDescription(DescriptionT&& value) { m_descriptionHasBeenSet = true; m_description = std::forward<DescriptionT>(value); }
61 template<typename DescriptionT = Aws::String>
62 CreatePullRequestRequest& WithDescription(DescriptionT&& value) { SetDescription(std::forward<DescriptionT>(value)); return *this;}
64
66
72 inline const Aws::Vector<Target>& GetTargets() const { return m_targets; }
73 inline bool TargetsHasBeenSet() const { return m_targetsHasBeenSet; }
74 template<typename TargetsT = Aws::Vector<Target>>
75 void SetTargets(TargetsT&& value) { m_targetsHasBeenSet = true; m_targets = std::forward<TargetsT>(value); }
76 template<typename TargetsT = Aws::Vector<Target>>
77 CreatePullRequestRequest& WithTargets(TargetsT&& value) { SetTargets(std::forward<TargetsT>(value)); return *this;}
78 template<typename TargetsT = Target>
79 CreatePullRequestRequest& AddTargets(TargetsT&& value) { m_targetsHasBeenSet = true; m_targets.emplace_back(std::forward<TargetsT>(value)); return *this; }
81
83
92 inline const Aws::String& GetClientRequestToken() const { return m_clientRequestToken; }
93 inline bool ClientRequestTokenHasBeenSet() const { return m_clientRequestTokenHasBeenSet; }
94 template<typename ClientRequestTokenT = Aws::String>
95 void SetClientRequestToken(ClientRequestTokenT&& value) { m_clientRequestTokenHasBeenSet = true; m_clientRequestToken = std::forward<ClientRequestTokenT>(value); }
96 template<typename ClientRequestTokenT = Aws::String>
97 CreatePullRequestRequest& WithClientRequestToken(ClientRequestTokenT&& value) { SetClientRequestToken(std::forward<ClientRequestTokenT>(value)); return *this;}
99 private:
100
101 Aws::String m_title;
102 bool m_titleHasBeenSet = false;
103
104 Aws::String m_description;
105 bool m_descriptionHasBeenSet = false;
106
107 Aws::Vector<Target> m_targets;
108 bool m_targetsHasBeenSet = false;
109
110 Aws::String m_clientRequestToken{Aws::Utils::UUID::PseudoRandomUUID()};
111 bool m_clientRequestTokenHasBeenSet = true;
112 };
113
114} // namespace Model
115} // namespace CodeCommit
116} // namespace Aws
AWS_CODECOMMIT_API CreatePullRequestRequest()=default
CreatePullRequestRequest & WithDescription(DescriptionT &&value)
CreatePullRequestRequest & WithClientRequestToken(ClientRequestTokenT &&value)
CreatePullRequestRequest & AddTargets(TargetsT &&value)
virtual const char * GetServiceRequestName() const override
CreatePullRequestRequest & WithTitle(TitleT &&value)
AWS_CODECOMMIT_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
CreatePullRequestRequest & WithTargets(TargetsT &&value)
AWS_CODECOMMIT_API Aws::String SerializePayload() const override
static Aws::Utils::UUID PseudoRandomUUID()
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector