/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include namespace Aws { namespace CodeCommit { namespace Model { /** */ class MergePullRequestBySquashRequest : public CodeCommitRequest { public: AWS_CODECOMMIT_API MergePullRequestBySquashRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "MergePullRequestBySquash"; } AWS_CODECOMMIT_API Aws::String SerializePayload() const override; AWS_CODECOMMIT_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; /** *

The system-generated ID of the pull request. To get this ID, use * ListPullRequests.

*/ inline const Aws::String& GetPullRequestId() const{ return m_pullRequestId; } /** *

The system-generated ID of the pull request. To get this ID, use * ListPullRequests.

*/ inline bool PullRequestIdHasBeenSet() const { return m_pullRequestIdHasBeenSet; } /** *

The system-generated ID of the pull request. To get this ID, use * ListPullRequests.

*/ inline void SetPullRequestId(const Aws::String& value) { m_pullRequestIdHasBeenSet = true; m_pullRequestId = value; } /** *

The system-generated ID of the pull request. To get this ID, use * ListPullRequests.

*/ inline void SetPullRequestId(Aws::String&& value) { m_pullRequestIdHasBeenSet = true; m_pullRequestId = std::move(value); } /** *

The system-generated ID of the pull request. To get this ID, use * ListPullRequests.

*/ inline void SetPullRequestId(const char* value) { m_pullRequestIdHasBeenSet = true; m_pullRequestId.assign(value); } /** *

The system-generated ID of the pull request. To get this ID, use * ListPullRequests.

*/ inline MergePullRequestBySquashRequest& WithPullRequestId(const Aws::String& value) { SetPullRequestId(value); return *this;} /** *

The system-generated ID of the pull request. To get this ID, use * ListPullRequests.

*/ inline MergePullRequestBySquashRequest& WithPullRequestId(Aws::String&& value) { SetPullRequestId(std::move(value)); return *this;} /** *

The system-generated ID of the pull request. To get this ID, use * ListPullRequests.

*/ inline MergePullRequestBySquashRequest& WithPullRequestId(const char* value) { SetPullRequestId(value); return *this;} /** *

The name of the repository where the pull request was created.

*/ inline const Aws::String& GetRepositoryName() const{ return m_repositoryName; } /** *

The name of the repository where the pull request was created.

*/ inline bool RepositoryNameHasBeenSet() const { return m_repositoryNameHasBeenSet; } /** *

The name of the repository where the pull request was created.

*/ inline void SetRepositoryName(const Aws::String& value) { m_repositoryNameHasBeenSet = true; m_repositoryName = value; } /** *

The name of the repository where the pull request was created.

*/ inline void SetRepositoryName(Aws::String&& value) { m_repositoryNameHasBeenSet = true; m_repositoryName = std::move(value); } /** *

The name of the repository where the pull request was created.

*/ inline void SetRepositoryName(const char* value) { m_repositoryNameHasBeenSet = true; m_repositoryName.assign(value); } /** *

The name of the repository where the pull request was created.

*/ inline MergePullRequestBySquashRequest& WithRepositoryName(const Aws::String& value) { SetRepositoryName(value); return *this;} /** *

The name of the repository where the pull request was created.

*/ inline MergePullRequestBySquashRequest& WithRepositoryName(Aws::String&& value) { SetRepositoryName(std::move(value)); return *this;} /** *

The name of the repository where the pull request was created.

*/ inline MergePullRequestBySquashRequest& WithRepositoryName(const char* value) { SetRepositoryName(value); return *this;} /** *

The full commit ID of the original or updated commit in the pull request * source branch. Pass this value if you want an exception thrown if the current * commit ID of the tip of the source branch does not match this commit ID.

*/ inline const Aws::String& GetSourceCommitId() const{ return m_sourceCommitId; } /** *

The full commit ID of the original or updated commit in the pull request * source branch. Pass this value if you want an exception thrown if the current * commit ID of the tip of the source branch does not match this commit ID.

*/ inline bool SourceCommitIdHasBeenSet() const { return m_sourceCommitIdHasBeenSet; } /** *

The full commit ID of the original or updated commit in the pull request * source branch. Pass this value if you want an exception thrown if the current * commit ID of the tip of the source branch does not match this commit ID.

*/ inline void SetSourceCommitId(const Aws::String& value) { m_sourceCommitIdHasBeenSet = true; m_sourceCommitId = value; } /** *

The full commit ID of the original or updated commit in the pull request * source branch. Pass this value if you want an exception thrown if the current * commit ID of the tip of the source branch does not match this commit ID.

*/ inline void SetSourceCommitId(Aws::String&& value) { m_sourceCommitIdHasBeenSet = true; m_sourceCommitId = std::move(value); } /** *

The full commit ID of the original or updated commit in the pull request * source branch. Pass this value if you want an exception thrown if the current * commit ID of the tip of the source branch does not match this commit ID.

*/ inline void SetSourceCommitId(const char* value) { m_sourceCommitIdHasBeenSet = true; m_sourceCommitId.assign(value); } /** *

The full commit ID of the original or updated commit in the pull request * source branch. Pass this value if you want an exception thrown if the current * commit ID of the tip of the source branch does not match this commit ID.

*/ inline MergePullRequestBySquashRequest& WithSourceCommitId(const Aws::String& value) { SetSourceCommitId(value); return *this;} /** *

The full commit ID of the original or updated commit in the pull request * source branch. Pass this value if you want an exception thrown if the current * commit ID of the tip of the source branch does not match this commit ID.

*/ inline MergePullRequestBySquashRequest& WithSourceCommitId(Aws::String&& value) { SetSourceCommitId(std::move(value)); return *this;} /** *

The full commit ID of the original or updated commit in the pull request * source branch. Pass this value if you want an exception thrown if the current * commit ID of the tip of the source branch does not match this commit ID.

*/ inline MergePullRequestBySquashRequest& WithSourceCommitId(const char* value) { SetSourceCommitId(value); return *this;} /** *

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.

*/ inline const ConflictDetailLevelTypeEnum& GetConflictDetailLevel() const{ return m_conflictDetailLevel; } /** *

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.

*/ inline bool ConflictDetailLevelHasBeenSet() const { return m_conflictDetailLevelHasBeenSet; } /** *

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.

*/ inline void SetConflictDetailLevel(const ConflictDetailLevelTypeEnum& value) { m_conflictDetailLevelHasBeenSet = true; m_conflictDetailLevel = value; } /** *

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.

*/ inline void SetConflictDetailLevel(ConflictDetailLevelTypeEnum&& value) { m_conflictDetailLevelHasBeenSet = true; m_conflictDetailLevel = std::move(value); } /** *

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.

*/ inline MergePullRequestBySquashRequest& WithConflictDetailLevel(const ConflictDetailLevelTypeEnum& value) { SetConflictDetailLevel(value); return *this;} /** *

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.

*/ inline MergePullRequestBySquashRequest& WithConflictDetailLevel(ConflictDetailLevelTypeEnum&& value) { SetConflictDetailLevel(std::move(value)); return *this;} /** *

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.

*/ inline const ConflictResolutionStrategyTypeEnum& GetConflictResolutionStrategy() const{ return m_conflictResolutionStrategy; } /** *

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.

*/ inline bool ConflictResolutionStrategyHasBeenSet() const { return m_conflictResolutionStrategyHasBeenSet; } /** *

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.

*/ inline void SetConflictResolutionStrategy(const ConflictResolutionStrategyTypeEnum& value) { m_conflictResolutionStrategyHasBeenSet = true; m_conflictResolutionStrategy = value; } /** *

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.

*/ inline void SetConflictResolutionStrategy(ConflictResolutionStrategyTypeEnum&& value) { m_conflictResolutionStrategyHasBeenSet = true; m_conflictResolutionStrategy = std::move(value); } /** *

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.

*/ inline MergePullRequestBySquashRequest& WithConflictResolutionStrategy(const ConflictResolutionStrategyTypeEnum& value) { SetConflictResolutionStrategy(value); return *this;} /** *

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.

*/ inline MergePullRequestBySquashRequest& WithConflictResolutionStrategy(ConflictResolutionStrategyTypeEnum&& value) { SetConflictResolutionStrategy(std::move(value)); return *this;} /** *

The commit message to include in the commit information for the merge.

*/ inline const Aws::String& GetCommitMessage() const{ return m_commitMessage; } /** *

The commit message to include in the commit information for the merge.

*/ inline bool CommitMessageHasBeenSet() const { return m_commitMessageHasBeenSet; } /** *

The commit message to include in the commit information for the merge.

*/ inline void SetCommitMessage(const Aws::String& value) { m_commitMessageHasBeenSet = true; m_commitMessage = value; } /** *

The commit message to include in the commit information for the merge.

*/ inline void SetCommitMessage(Aws::String&& value) { m_commitMessageHasBeenSet = true; m_commitMessage = std::move(value); } /** *

The commit message to include in the commit information for the merge.

*/ inline void SetCommitMessage(const char* value) { m_commitMessageHasBeenSet = true; m_commitMessage.assign(value); } /** *

The commit message to include in the commit information for the merge.

*/ inline MergePullRequestBySquashRequest& WithCommitMessage(const Aws::String& value) { SetCommitMessage(value); return *this;} /** *

The commit message to include in the commit information for the merge.

*/ inline MergePullRequestBySquashRequest& WithCommitMessage(Aws::String&& value) { SetCommitMessage(std::move(value)); return *this;} /** *

The commit message to include in the commit information for the merge.

*/ inline MergePullRequestBySquashRequest& WithCommitMessage(const char* value) { SetCommitMessage(value); return *this;} /** *

The name of the author who created the commit. This information is used as * both the author and committer for the commit.

*/ inline const Aws::String& GetAuthorName() const{ return m_authorName; } /** *

The name of the author who created the commit. This information is used as * both the author and committer for the commit.

*/ inline bool AuthorNameHasBeenSet() const { return m_authorNameHasBeenSet; } /** *

The name of the author who created the commit. This information is used as * both the author and committer for the commit.

*/ inline void SetAuthorName(const Aws::String& value) { m_authorNameHasBeenSet = true; m_authorName = value; } /** *

The name of the author who created the commit. This information is used as * both the author and committer for the commit.

*/ inline void SetAuthorName(Aws::String&& value) { m_authorNameHasBeenSet = true; m_authorName = std::move(value); } /** *

The name of the author who created the commit. This information is used as * both the author and committer for the commit.

*/ inline void SetAuthorName(const char* value) { m_authorNameHasBeenSet = true; m_authorName.assign(value); } /** *

The name of the author who created the commit. This information is used as * both the author and committer for the commit.

*/ inline MergePullRequestBySquashRequest& WithAuthorName(const Aws::String& value) { SetAuthorName(value); return *this;} /** *

The name of the author who created the commit. This information is used as * both the author and committer for the commit.

*/ inline MergePullRequestBySquashRequest& WithAuthorName(Aws::String&& value) { SetAuthorName(std::move(value)); return *this;} /** *

The name of the author who created the commit. This information is used as * both the author and committer for the commit.

*/ inline MergePullRequestBySquashRequest& WithAuthorName(const char* value) { SetAuthorName(value); return *this;} /** *

The email address of the person merging the branches. This information is * used in the commit information for the merge.

*/ inline const Aws::String& GetEmail() const{ return m_email; } /** *

The email address of the person merging the branches. This information is * used in the commit information for the merge.

*/ inline bool EmailHasBeenSet() const { return m_emailHasBeenSet; } /** *

The email address of the person merging the branches. This information is * used in the commit information for the merge.

*/ inline void SetEmail(const Aws::String& value) { m_emailHasBeenSet = true; m_email = value; } /** *

The email address of the person merging the branches. This information is * used in the commit information for the merge.

*/ inline void SetEmail(Aws::String&& value) { m_emailHasBeenSet = true; m_email = std::move(value); } /** *

The email address of the person merging the branches. This information is * used in the commit information for the merge.

*/ inline void SetEmail(const char* value) { m_emailHasBeenSet = true; m_email.assign(value); } /** *

The email address of the person merging the branches. This information is * used in the commit information for the merge.

*/ inline MergePullRequestBySquashRequest& WithEmail(const Aws::String& value) { SetEmail(value); return *this;} /** *

The email address of the person merging the branches. This information is * used in the commit information for the merge.

*/ inline MergePullRequestBySquashRequest& WithEmail(Aws::String&& value) { SetEmail(std::move(value)); return *this;} /** *

The email address of the person merging the branches. This information is * used in the commit information for the merge.

*/ inline MergePullRequestBySquashRequest& WithEmail(const char* value) { SetEmail(value); return *this;} /** *

If the commit contains deletions, whether to keep a folder or folder * structure if the changes leave the folders empty. If true, a .gitkeep file is * created for empty folders. The default is false.

*/ inline bool GetKeepEmptyFolders() const{ return m_keepEmptyFolders; } /** *

If the commit contains deletions, whether to keep a folder or folder * structure if the changes leave the folders empty. If true, a .gitkeep file is * created for empty folders. The default is false.

*/ inline bool KeepEmptyFoldersHasBeenSet() const { return m_keepEmptyFoldersHasBeenSet; } /** *

If the commit contains deletions, whether to keep a folder or folder * structure if the changes leave the folders empty. If true, a .gitkeep file is * created for empty folders. The default is false.

*/ inline void SetKeepEmptyFolders(bool value) { m_keepEmptyFoldersHasBeenSet = true; m_keepEmptyFolders = value; } /** *

If the commit contains deletions, whether to keep a folder or folder * structure if the changes leave the folders empty. If true, a .gitkeep file is * created for empty folders. The default is false.

*/ inline MergePullRequestBySquashRequest& WithKeepEmptyFolders(bool value) { SetKeepEmptyFolders(value); return *this;} /** *

If AUTOMERGE is the conflict resolution strategy, a list of inputs to use * when resolving conflicts during a merge.

*/ inline const ConflictResolution& GetConflictResolution() const{ return m_conflictResolution; } /** *

If AUTOMERGE is the conflict resolution strategy, a list of inputs to use * when resolving conflicts during a merge.

*/ inline bool ConflictResolutionHasBeenSet() const { return m_conflictResolutionHasBeenSet; } /** *

If AUTOMERGE is the conflict resolution strategy, a list of inputs to use * when resolving conflicts during a merge.

*/ inline void SetConflictResolution(const ConflictResolution& value) { m_conflictResolutionHasBeenSet = true; m_conflictResolution = value; } /** *

If AUTOMERGE is the conflict resolution strategy, a list of inputs to use * when resolving conflicts during a merge.

*/ inline void SetConflictResolution(ConflictResolution&& value) { m_conflictResolutionHasBeenSet = true; m_conflictResolution = std::move(value); } /** *

If AUTOMERGE is the conflict resolution strategy, a list of inputs to use * when resolving conflicts during a merge.

*/ inline MergePullRequestBySquashRequest& WithConflictResolution(const ConflictResolution& value) { SetConflictResolution(value); return *this;} /** *

If AUTOMERGE is the conflict resolution strategy, a list of inputs to use * when resolving conflicts during a merge.

*/ inline MergePullRequestBySquashRequest& WithConflictResolution(ConflictResolution&& value) { SetConflictResolution(std::move(value)); return *this;} private: Aws::String m_pullRequestId; bool m_pullRequestIdHasBeenSet = false; Aws::String m_repositoryName; bool m_repositoryNameHasBeenSet = false; Aws::String m_sourceCommitId; bool m_sourceCommitIdHasBeenSet = false; ConflictDetailLevelTypeEnum m_conflictDetailLevel; bool m_conflictDetailLevelHasBeenSet = false; ConflictResolutionStrategyTypeEnum m_conflictResolutionStrategy; bool m_conflictResolutionStrategyHasBeenSet = false; Aws::String m_commitMessage; bool m_commitMessageHasBeenSet = false; Aws::String m_authorName; bool m_authorNameHasBeenSet = false; Aws::String m_email; bool m_emailHasBeenSet = false; bool m_keepEmptyFolders; bool m_keepEmptyFoldersHasBeenSet = false; ConflictResolution m_conflictResolution; bool m_conflictResolutionHasBeenSet = false; }; } // namespace Model } // namespace CodeCommit } // namespace Aws