{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.CodeCommit.MergeBranchesByThreeWay
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Merges two specified branches using the three-way merge strategy.
module Amazonka.CodeCommit.MergeBranchesByThreeWay
  ( -- * Creating a Request
    MergeBranchesByThreeWay (..),
    newMergeBranchesByThreeWay,

    -- * Request Lenses
    mergeBranchesByThreeWay_authorName,
    mergeBranchesByThreeWay_commitMessage,
    mergeBranchesByThreeWay_conflictDetailLevel,
    mergeBranchesByThreeWay_conflictResolution,
    mergeBranchesByThreeWay_conflictResolutionStrategy,
    mergeBranchesByThreeWay_email,
    mergeBranchesByThreeWay_keepEmptyFolders,
    mergeBranchesByThreeWay_targetBranch,
    mergeBranchesByThreeWay_repositoryName,
    mergeBranchesByThreeWay_sourceCommitSpecifier,
    mergeBranchesByThreeWay_destinationCommitSpecifier,

    -- * Destructuring the Response
    MergeBranchesByThreeWayResponse (..),
    newMergeBranchesByThreeWayResponse,

    -- * Response Lenses
    mergeBranchesByThreeWayResponse_commitId,
    mergeBranchesByThreeWayResponse_treeId,
    mergeBranchesByThreeWayResponse_httpStatus,
  )
where

import Amazonka.CodeCommit.Types
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newMergeBranchesByThreeWay' smart constructor.
data MergeBranchesByThreeWay = MergeBranchesByThreeWay'
  { -- | The name of the author who created the commit. This information is used
    -- as both the author and committer for the commit.
    MergeBranchesByThreeWay -> Maybe Text
authorName :: Prelude.Maybe Prelude.Text,
    -- | The commit message to include in the commit information for the merge.
    MergeBranchesByThreeWay -> Maybe Text
commitMessage :: Prelude.Maybe Prelude.Text,
    -- | 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.
    MergeBranchesByThreeWay -> Maybe ConflictDetailLevelTypeEnum
conflictDetailLevel :: Prelude.Maybe ConflictDetailLevelTypeEnum,
    -- | If AUTOMERGE is the conflict resolution strategy, a list of inputs to
    -- use when resolving conflicts during a merge.
    MergeBranchesByThreeWay -> Maybe ConflictResolution
conflictResolution :: Prelude.Maybe ConflictResolution,
    -- | 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.
    MergeBranchesByThreeWay -> Maybe ConflictResolutionStrategyTypeEnum
conflictResolutionStrategy :: Prelude.Maybe ConflictResolutionStrategyTypeEnum,
    -- | The email address of the person merging the branches. This information
    -- is used in the commit information for the merge.
    MergeBranchesByThreeWay -> Maybe Text
email :: Prelude.Maybe Prelude.Text,
    -- | 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.
    MergeBranchesByThreeWay -> Maybe Bool
keepEmptyFolders :: Prelude.Maybe Prelude.Bool,
    -- | The branch where the merge is applied.
    MergeBranchesByThreeWay -> Maybe Text
targetBranch :: Prelude.Maybe Prelude.Text,
    -- | The name of the repository where you want to merge two branches.
    MergeBranchesByThreeWay -> Text
repositoryName :: Prelude.Text,
    -- | The branch, tag, HEAD, or other fully qualified reference used to
    -- identify a commit (for example, a branch name or a full commit ID).
    MergeBranchesByThreeWay -> Text
sourceCommitSpecifier :: Prelude.Text,
    -- | The branch, tag, HEAD, or other fully qualified reference used to
    -- identify a commit (for example, a branch name or a full commit ID).
    MergeBranchesByThreeWay -> Text
destinationCommitSpecifier :: Prelude.Text
  }
  deriving (MergeBranchesByThreeWay -> MergeBranchesByThreeWay -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: MergeBranchesByThreeWay -> MergeBranchesByThreeWay -> Bool
$c/= :: MergeBranchesByThreeWay -> MergeBranchesByThreeWay -> Bool
== :: MergeBranchesByThreeWay -> MergeBranchesByThreeWay -> Bool
$c== :: MergeBranchesByThreeWay -> MergeBranchesByThreeWay -> Bool
Prelude.Eq, ReadPrec [MergeBranchesByThreeWay]
ReadPrec MergeBranchesByThreeWay
Int -> ReadS MergeBranchesByThreeWay
ReadS [MergeBranchesByThreeWay]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [MergeBranchesByThreeWay]
$creadListPrec :: ReadPrec [MergeBranchesByThreeWay]
readPrec :: ReadPrec MergeBranchesByThreeWay
$creadPrec :: ReadPrec MergeBranchesByThreeWay
readList :: ReadS [MergeBranchesByThreeWay]
$creadList :: ReadS [MergeBranchesByThreeWay]
readsPrec :: Int -> ReadS MergeBranchesByThreeWay
$creadsPrec :: Int -> ReadS MergeBranchesByThreeWay
Prelude.Read, Int -> MergeBranchesByThreeWay -> ShowS
[MergeBranchesByThreeWay] -> ShowS
MergeBranchesByThreeWay -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [MergeBranchesByThreeWay] -> ShowS
$cshowList :: [MergeBranchesByThreeWay] -> ShowS
show :: MergeBranchesByThreeWay -> String
$cshow :: MergeBranchesByThreeWay -> String
showsPrec :: Int -> MergeBranchesByThreeWay -> ShowS
$cshowsPrec :: Int -> MergeBranchesByThreeWay -> ShowS
Prelude.Show, forall x. Rep MergeBranchesByThreeWay x -> MergeBranchesByThreeWay
forall x. MergeBranchesByThreeWay -> Rep MergeBranchesByThreeWay x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep MergeBranchesByThreeWay x -> MergeBranchesByThreeWay
$cfrom :: forall x. MergeBranchesByThreeWay -> Rep MergeBranchesByThreeWay x
Prelude.Generic)

-- |
-- Create a value of 'MergeBranchesByThreeWay' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'authorName', 'mergeBranchesByThreeWay_authorName' - The name of the author who created the commit. This information is used
-- as both the author and committer for the commit.
--
-- 'commitMessage', 'mergeBranchesByThreeWay_commitMessage' - The commit message to include in the commit information for the merge.
--
-- 'conflictDetailLevel', 'mergeBranchesByThreeWay_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.
--
-- 'conflictResolution', 'mergeBranchesByThreeWay_conflictResolution' - If AUTOMERGE is the conflict resolution strategy, a list of inputs to
-- use when resolving conflicts during a merge.
--
-- 'conflictResolutionStrategy', 'mergeBranchesByThreeWay_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.
--
-- 'email', 'mergeBranchesByThreeWay_email' - The email address of the person merging the branches. This information
-- is used in the commit information for the merge.
--
-- 'keepEmptyFolders', 'mergeBranchesByThreeWay_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.
--
-- 'targetBranch', 'mergeBranchesByThreeWay_targetBranch' - The branch where the merge is applied.
--
-- 'repositoryName', 'mergeBranchesByThreeWay_repositoryName' - The name of the repository where you want to merge two branches.
--
-- 'sourceCommitSpecifier', 'mergeBranchesByThreeWay_sourceCommitSpecifier' - The branch, tag, HEAD, or other fully qualified reference used to
-- identify a commit (for example, a branch name or a full commit ID).
--
-- 'destinationCommitSpecifier', 'mergeBranchesByThreeWay_destinationCommitSpecifier' - The branch, tag, HEAD, or other fully qualified reference used to
-- identify a commit (for example, a branch name or a full commit ID).
newMergeBranchesByThreeWay ::
  -- | 'repositoryName'
  Prelude.Text ->
  -- | 'sourceCommitSpecifier'
  Prelude.Text ->
  -- | 'destinationCommitSpecifier'
  Prelude.Text ->
  MergeBranchesByThreeWay
newMergeBranchesByThreeWay :: Text -> Text -> Text -> MergeBranchesByThreeWay
newMergeBranchesByThreeWay
  Text
pRepositoryName_
  Text
pSourceCommitSpecifier_
  Text
pDestinationCommitSpecifier_ =
    MergeBranchesByThreeWay'
      { $sel:authorName:MergeBranchesByThreeWay' :: Maybe Text
authorName =
          forall a. Maybe a
Prelude.Nothing,
        $sel:commitMessage:MergeBranchesByThreeWay' :: Maybe Text
commitMessage = forall a. Maybe a
Prelude.Nothing,
        $sel:conflictDetailLevel:MergeBranchesByThreeWay' :: Maybe ConflictDetailLevelTypeEnum
conflictDetailLevel = forall a. Maybe a
Prelude.Nothing,
        $sel:conflictResolution:MergeBranchesByThreeWay' :: Maybe ConflictResolution
conflictResolution = forall a. Maybe a
Prelude.Nothing,
        $sel:conflictResolutionStrategy:MergeBranchesByThreeWay' :: Maybe ConflictResolutionStrategyTypeEnum
conflictResolutionStrategy = forall a. Maybe a
Prelude.Nothing,
        $sel:email:MergeBranchesByThreeWay' :: Maybe Text
email = forall a. Maybe a
Prelude.Nothing,
        $sel:keepEmptyFolders:MergeBranchesByThreeWay' :: Maybe Bool
keepEmptyFolders = forall a. Maybe a
Prelude.Nothing,
        $sel:targetBranch:MergeBranchesByThreeWay' :: Maybe Text
targetBranch = forall a. Maybe a
Prelude.Nothing,
        $sel:repositoryName:MergeBranchesByThreeWay' :: Text
repositoryName = Text
pRepositoryName_,
        $sel:sourceCommitSpecifier:MergeBranchesByThreeWay' :: Text
sourceCommitSpecifier = Text
pSourceCommitSpecifier_,
        $sel:destinationCommitSpecifier:MergeBranchesByThreeWay' :: Text
destinationCommitSpecifier =
          Text
pDestinationCommitSpecifier_
      }

-- | The name of the author who created the commit. This information is used
-- as both the author and committer for the commit.
mergeBranchesByThreeWay_authorName :: Lens.Lens' MergeBranchesByThreeWay (Prelude.Maybe Prelude.Text)
mergeBranchesByThreeWay_authorName :: Lens' MergeBranchesByThreeWay (Maybe Text)
mergeBranchesByThreeWay_authorName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWay' {Maybe Text
authorName :: Maybe Text
$sel:authorName:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
authorName} -> Maybe Text
authorName) (\s :: MergeBranchesByThreeWay
s@MergeBranchesByThreeWay' {} Maybe Text
a -> MergeBranchesByThreeWay
s {$sel:authorName:MergeBranchesByThreeWay' :: Maybe Text
authorName = Maybe Text
a} :: MergeBranchesByThreeWay)

-- | The commit message to include in the commit information for the merge.
mergeBranchesByThreeWay_commitMessage :: Lens.Lens' MergeBranchesByThreeWay (Prelude.Maybe Prelude.Text)
mergeBranchesByThreeWay_commitMessage :: Lens' MergeBranchesByThreeWay (Maybe Text)
mergeBranchesByThreeWay_commitMessage = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWay' {Maybe Text
commitMessage :: Maybe Text
$sel:commitMessage:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
commitMessage} -> Maybe Text
commitMessage) (\s :: MergeBranchesByThreeWay
s@MergeBranchesByThreeWay' {} Maybe Text
a -> MergeBranchesByThreeWay
s {$sel:commitMessage:MergeBranchesByThreeWay' :: Maybe Text
commitMessage = Maybe Text
a} :: MergeBranchesByThreeWay)

-- | 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.
mergeBranchesByThreeWay_conflictDetailLevel :: Lens.Lens' MergeBranchesByThreeWay (Prelude.Maybe ConflictDetailLevelTypeEnum)
mergeBranchesByThreeWay_conflictDetailLevel :: Lens' MergeBranchesByThreeWay (Maybe ConflictDetailLevelTypeEnum)
mergeBranchesByThreeWay_conflictDetailLevel = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWay' {Maybe ConflictDetailLevelTypeEnum
conflictDetailLevel :: Maybe ConflictDetailLevelTypeEnum
$sel:conflictDetailLevel:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe ConflictDetailLevelTypeEnum
conflictDetailLevel} -> Maybe ConflictDetailLevelTypeEnum
conflictDetailLevel) (\s :: MergeBranchesByThreeWay
s@MergeBranchesByThreeWay' {} Maybe ConflictDetailLevelTypeEnum
a -> MergeBranchesByThreeWay
s {$sel:conflictDetailLevel:MergeBranchesByThreeWay' :: Maybe ConflictDetailLevelTypeEnum
conflictDetailLevel = Maybe ConflictDetailLevelTypeEnum
a} :: MergeBranchesByThreeWay)

-- | If AUTOMERGE is the conflict resolution strategy, a list of inputs to
-- use when resolving conflicts during a merge.
mergeBranchesByThreeWay_conflictResolution :: Lens.Lens' MergeBranchesByThreeWay (Prelude.Maybe ConflictResolution)
mergeBranchesByThreeWay_conflictResolution :: Lens' MergeBranchesByThreeWay (Maybe ConflictResolution)
mergeBranchesByThreeWay_conflictResolution = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWay' {Maybe ConflictResolution
conflictResolution :: Maybe ConflictResolution
$sel:conflictResolution:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe ConflictResolution
conflictResolution} -> Maybe ConflictResolution
conflictResolution) (\s :: MergeBranchesByThreeWay
s@MergeBranchesByThreeWay' {} Maybe ConflictResolution
a -> MergeBranchesByThreeWay
s {$sel:conflictResolution:MergeBranchesByThreeWay' :: Maybe ConflictResolution
conflictResolution = Maybe ConflictResolution
a} :: MergeBranchesByThreeWay)

-- | 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.
mergeBranchesByThreeWay_conflictResolutionStrategy :: Lens.Lens' MergeBranchesByThreeWay (Prelude.Maybe ConflictResolutionStrategyTypeEnum)
mergeBranchesByThreeWay_conflictResolutionStrategy :: Lens'
  MergeBranchesByThreeWay (Maybe ConflictResolutionStrategyTypeEnum)
mergeBranchesByThreeWay_conflictResolutionStrategy = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWay' {Maybe ConflictResolutionStrategyTypeEnum
conflictResolutionStrategy :: Maybe ConflictResolutionStrategyTypeEnum
$sel:conflictResolutionStrategy:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe ConflictResolutionStrategyTypeEnum
conflictResolutionStrategy} -> Maybe ConflictResolutionStrategyTypeEnum
conflictResolutionStrategy) (\s :: MergeBranchesByThreeWay
s@MergeBranchesByThreeWay' {} Maybe ConflictResolutionStrategyTypeEnum
a -> MergeBranchesByThreeWay
s {$sel:conflictResolutionStrategy:MergeBranchesByThreeWay' :: Maybe ConflictResolutionStrategyTypeEnum
conflictResolutionStrategy = Maybe ConflictResolutionStrategyTypeEnum
a} :: MergeBranchesByThreeWay)

-- | The email address of the person merging the branches. This information
-- is used in the commit information for the merge.
mergeBranchesByThreeWay_email :: Lens.Lens' MergeBranchesByThreeWay (Prelude.Maybe Prelude.Text)
mergeBranchesByThreeWay_email :: Lens' MergeBranchesByThreeWay (Maybe Text)
mergeBranchesByThreeWay_email = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWay' {Maybe Text
email :: Maybe Text
$sel:email:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
email} -> Maybe Text
email) (\s :: MergeBranchesByThreeWay
s@MergeBranchesByThreeWay' {} Maybe Text
a -> MergeBranchesByThreeWay
s {$sel:email:MergeBranchesByThreeWay' :: Maybe Text
email = Maybe Text
a} :: MergeBranchesByThreeWay)

-- | 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.
mergeBranchesByThreeWay_keepEmptyFolders :: Lens.Lens' MergeBranchesByThreeWay (Prelude.Maybe Prelude.Bool)
mergeBranchesByThreeWay_keepEmptyFolders :: Lens' MergeBranchesByThreeWay (Maybe Bool)
mergeBranchesByThreeWay_keepEmptyFolders = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWay' {Maybe Bool
keepEmptyFolders :: Maybe Bool
$sel:keepEmptyFolders:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Bool
keepEmptyFolders} -> Maybe Bool
keepEmptyFolders) (\s :: MergeBranchesByThreeWay
s@MergeBranchesByThreeWay' {} Maybe Bool
a -> MergeBranchesByThreeWay
s {$sel:keepEmptyFolders:MergeBranchesByThreeWay' :: Maybe Bool
keepEmptyFolders = Maybe Bool
a} :: MergeBranchesByThreeWay)

-- | The branch where the merge is applied.
mergeBranchesByThreeWay_targetBranch :: Lens.Lens' MergeBranchesByThreeWay (Prelude.Maybe Prelude.Text)
mergeBranchesByThreeWay_targetBranch :: Lens' MergeBranchesByThreeWay (Maybe Text)
mergeBranchesByThreeWay_targetBranch = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWay' {Maybe Text
targetBranch :: Maybe Text
$sel:targetBranch:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
targetBranch} -> Maybe Text
targetBranch) (\s :: MergeBranchesByThreeWay
s@MergeBranchesByThreeWay' {} Maybe Text
a -> MergeBranchesByThreeWay
s {$sel:targetBranch:MergeBranchesByThreeWay' :: Maybe Text
targetBranch = Maybe Text
a} :: MergeBranchesByThreeWay)

-- | The name of the repository where you want to merge two branches.
mergeBranchesByThreeWay_repositoryName :: Lens.Lens' MergeBranchesByThreeWay Prelude.Text
mergeBranchesByThreeWay_repositoryName :: Lens' MergeBranchesByThreeWay Text
mergeBranchesByThreeWay_repositoryName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWay' {Text
repositoryName :: Text
$sel:repositoryName:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Text
repositoryName} -> Text
repositoryName) (\s :: MergeBranchesByThreeWay
s@MergeBranchesByThreeWay' {} Text
a -> MergeBranchesByThreeWay
s {$sel:repositoryName:MergeBranchesByThreeWay' :: Text
repositoryName = Text
a} :: MergeBranchesByThreeWay)

-- | The branch, tag, HEAD, or other fully qualified reference used to
-- identify a commit (for example, a branch name or a full commit ID).
mergeBranchesByThreeWay_sourceCommitSpecifier :: Lens.Lens' MergeBranchesByThreeWay Prelude.Text
mergeBranchesByThreeWay_sourceCommitSpecifier :: Lens' MergeBranchesByThreeWay Text
mergeBranchesByThreeWay_sourceCommitSpecifier = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWay' {Text
sourceCommitSpecifier :: Text
$sel:sourceCommitSpecifier:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Text
sourceCommitSpecifier} -> Text
sourceCommitSpecifier) (\s :: MergeBranchesByThreeWay
s@MergeBranchesByThreeWay' {} Text
a -> MergeBranchesByThreeWay
s {$sel:sourceCommitSpecifier:MergeBranchesByThreeWay' :: Text
sourceCommitSpecifier = Text
a} :: MergeBranchesByThreeWay)

-- | The branch, tag, HEAD, or other fully qualified reference used to
-- identify a commit (for example, a branch name or a full commit ID).
mergeBranchesByThreeWay_destinationCommitSpecifier :: Lens.Lens' MergeBranchesByThreeWay Prelude.Text
mergeBranchesByThreeWay_destinationCommitSpecifier :: Lens' MergeBranchesByThreeWay Text
mergeBranchesByThreeWay_destinationCommitSpecifier = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWay' {Text
destinationCommitSpecifier :: Text
$sel:destinationCommitSpecifier:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Text
destinationCommitSpecifier} -> Text
destinationCommitSpecifier) (\s :: MergeBranchesByThreeWay
s@MergeBranchesByThreeWay' {} Text
a -> MergeBranchesByThreeWay
s {$sel:destinationCommitSpecifier:MergeBranchesByThreeWay' :: Text
destinationCommitSpecifier = Text
a} :: MergeBranchesByThreeWay)

instance Core.AWSRequest MergeBranchesByThreeWay where
  type
    AWSResponse MergeBranchesByThreeWay =
      MergeBranchesByThreeWayResponse
  request :: (Service -> Service)
-> MergeBranchesByThreeWay -> Request MergeBranchesByThreeWay
request Service -> Service
overrides =
    forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON (Service -> Service
overrides Service
defaultService)
  response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy MergeBranchesByThreeWay
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse MergeBranchesByThreeWay)))
response =
    forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
      ( \Int
s ResponseHeaders
h Object
x ->
          Maybe Text -> Maybe Text -> Int -> MergeBranchesByThreeWayResponse
MergeBranchesByThreeWayResponse'
            forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"commitId")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"treeId")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance Prelude.Hashable MergeBranchesByThreeWay where
  hashWithSalt :: Int -> MergeBranchesByThreeWay -> Int
hashWithSalt Int
_salt MergeBranchesByThreeWay' {Maybe Bool
Maybe Text
Maybe ConflictDetailLevelTypeEnum
Maybe ConflictResolutionStrategyTypeEnum
Maybe ConflictResolution
Text
destinationCommitSpecifier :: Text
sourceCommitSpecifier :: Text
repositoryName :: Text
targetBranch :: Maybe Text
keepEmptyFolders :: Maybe Bool
email :: Maybe Text
conflictResolutionStrategy :: Maybe ConflictResolutionStrategyTypeEnum
conflictResolution :: Maybe ConflictResolution
conflictDetailLevel :: Maybe ConflictDetailLevelTypeEnum
commitMessage :: Maybe Text
authorName :: Maybe Text
$sel:destinationCommitSpecifier:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Text
$sel:sourceCommitSpecifier:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Text
$sel:repositoryName:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Text
$sel:targetBranch:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
$sel:keepEmptyFolders:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Bool
$sel:email:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
$sel:conflictResolutionStrategy:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe ConflictResolutionStrategyTypeEnum
$sel:conflictResolution:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe ConflictResolution
$sel:conflictDetailLevel:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe ConflictDetailLevelTypeEnum
$sel:commitMessage:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
$sel:authorName:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
authorName
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
commitMessage
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ConflictDetailLevelTypeEnum
conflictDetailLevel
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ConflictResolution
conflictResolution
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ConflictResolutionStrategyTypeEnum
conflictResolutionStrategy
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
email
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
keepEmptyFolders
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
targetBranch
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
repositoryName
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
sourceCommitSpecifier
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
destinationCommitSpecifier

instance Prelude.NFData MergeBranchesByThreeWay where
  rnf :: MergeBranchesByThreeWay -> ()
rnf MergeBranchesByThreeWay' {Maybe Bool
Maybe Text
Maybe ConflictDetailLevelTypeEnum
Maybe ConflictResolutionStrategyTypeEnum
Maybe ConflictResolution
Text
destinationCommitSpecifier :: Text
sourceCommitSpecifier :: Text
repositoryName :: Text
targetBranch :: Maybe Text
keepEmptyFolders :: Maybe Bool
email :: Maybe Text
conflictResolutionStrategy :: Maybe ConflictResolutionStrategyTypeEnum
conflictResolution :: Maybe ConflictResolution
conflictDetailLevel :: Maybe ConflictDetailLevelTypeEnum
commitMessage :: Maybe Text
authorName :: Maybe Text
$sel:destinationCommitSpecifier:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Text
$sel:sourceCommitSpecifier:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Text
$sel:repositoryName:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Text
$sel:targetBranch:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
$sel:keepEmptyFolders:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Bool
$sel:email:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
$sel:conflictResolutionStrategy:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe ConflictResolutionStrategyTypeEnum
$sel:conflictResolution:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe ConflictResolution
$sel:conflictDetailLevel:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe ConflictDetailLevelTypeEnum
$sel:commitMessage:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
$sel:authorName:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
authorName
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
commitMessage
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ConflictDetailLevelTypeEnum
conflictDetailLevel
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ConflictResolution
conflictResolution
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ConflictResolutionStrategyTypeEnum
conflictResolutionStrategy
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
email
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
keepEmptyFolders
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
targetBranch
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
repositoryName
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
sourceCommitSpecifier
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
destinationCommitSpecifier

instance Data.ToHeaders MergeBranchesByThreeWay where
  toHeaders :: MergeBranchesByThreeWay -> ResponseHeaders
toHeaders =
    forall a b. a -> b -> a
Prelude.const
      ( forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"X-Amz-Target"
              forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"CodeCommit_20150413.MergeBranchesByThreeWay" ::
                          Prelude.ByteString
                      ),
            HeaderName
"Content-Type"
              forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

instance Data.ToJSON MergeBranchesByThreeWay where
  toJSON :: MergeBranchesByThreeWay -> Value
toJSON MergeBranchesByThreeWay' {Maybe Bool
Maybe Text
Maybe ConflictDetailLevelTypeEnum
Maybe ConflictResolutionStrategyTypeEnum
Maybe ConflictResolution
Text
destinationCommitSpecifier :: Text
sourceCommitSpecifier :: Text
repositoryName :: Text
targetBranch :: Maybe Text
keepEmptyFolders :: Maybe Bool
email :: Maybe Text
conflictResolutionStrategy :: Maybe ConflictResolutionStrategyTypeEnum
conflictResolution :: Maybe ConflictResolution
conflictDetailLevel :: Maybe ConflictDetailLevelTypeEnum
commitMessage :: Maybe Text
authorName :: Maybe Text
$sel:destinationCommitSpecifier:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Text
$sel:sourceCommitSpecifier:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Text
$sel:repositoryName:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Text
$sel:targetBranch:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
$sel:keepEmptyFolders:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Bool
$sel:email:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
$sel:conflictResolutionStrategy:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe ConflictResolutionStrategyTypeEnum
$sel:conflictResolution:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe ConflictResolution
$sel:conflictDetailLevel:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe ConflictDetailLevelTypeEnum
$sel:commitMessage:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
$sel:authorName:MergeBranchesByThreeWay' :: MergeBranchesByThreeWay -> Maybe Text
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Key
"authorName" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
authorName,
            (Key
"commitMessage" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
commitMessage,
            (Key
"conflictDetailLevel" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ConflictDetailLevelTypeEnum
conflictDetailLevel,
            (Key
"conflictResolution" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ConflictResolution
conflictResolution,
            (Key
"conflictResolutionStrategy" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ConflictResolutionStrategyTypeEnum
conflictResolutionStrategy,
            (Key
"email" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
email,
            (Key
"keepEmptyFolders" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
keepEmptyFolders,
            (Key
"targetBranch" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
targetBranch,
            forall a. a -> Maybe a
Prelude.Just
              (Key
"repositoryName" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
repositoryName),
            forall a. a -> Maybe a
Prelude.Just
              ( Key
"sourceCommitSpecifier"
                  forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
sourceCommitSpecifier
              ),
            forall a. a -> Maybe a
Prelude.Just
              ( Key
"destinationCommitSpecifier"
                  forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
destinationCommitSpecifier
              )
          ]
      )

instance Data.ToPath MergeBranchesByThreeWay where
  toPath :: MergeBranchesByThreeWay -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"

instance Data.ToQuery MergeBranchesByThreeWay where
  toQuery :: MergeBranchesByThreeWay -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty

-- | /See:/ 'newMergeBranchesByThreeWayResponse' smart constructor.
data MergeBranchesByThreeWayResponse = MergeBranchesByThreeWayResponse'
  { -- | The commit ID of the merge in the destination or target branch.
    MergeBranchesByThreeWayResponse -> Maybe Text
commitId :: Prelude.Maybe Prelude.Text,
    -- | The tree ID of the merge in the destination or target branch.
    MergeBranchesByThreeWayResponse -> Maybe Text
treeId :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    MergeBranchesByThreeWayResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (MergeBranchesByThreeWayResponse
-> MergeBranchesByThreeWayResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: MergeBranchesByThreeWayResponse
-> MergeBranchesByThreeWayResponse -> Bool
$c/= :: MergeBranchesByThreeWayResponse
-> MergeBranchesByThreeWayResponse -> Bool
== :: MergeBranchesByThreeWayResponse
-> MergeBranchesByThreeWayResponse -> Bool
$c== :: MergeBranchesByThreeWayResponse
-> MergeBranchesByThreeWayResponse -> Bool
Prelude.Eq, ReadPrec [MergeBranchesByThreeWayResponse]
ReadPrec MergeBranchesByThreeWayResponse
Int -> ReadS MergeBranchesByThreeWayResponse
ReadS [MergeBranchesByThreeWayResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [MergeBranchesByThreeWayResponse]
$creadListPrec :: ReadPrec [MergeBranchesByThreeWayResponse]
readPrec :: ReadPrec MergeBranchesByThreeWayResponse
$creadPrec :: ReadPrec MergeBranchesByThreeWayResponse
readList :: ReadS [MergeBranchesByThreeWayResponse]
$creadList :: ReadS [MergeBranchesByThreeWayResponse]
readsPrec :: Int -> ReadS MergeBranchesByThreeWayResponse
$creadsPrec :: Int -> ReadS MergeBranchesByThreeWayResponse
Prelude.Read, Int -> MergeBranchesByThreeWayResponse -> ShowS
[MergeBranchesByThreeWayResponse] -> ShowS
MergeBranchesByThreeWayResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [MergeBranchesByThreeWayResponse] -> ShowS
$cshowList :: [MergeBranchesByThreeWayResponse] -> ShowS
show :: MergeBranchesByThreeWayResponse -> String
$cshow :: MergeBranchesByThreeWayResponse -> String
showsPrec :: Int -> MergeBranchesByThreeWayResponse -> ShowS
$cshowsPrec :: Int -> MergeBranchesByThreeWayResponse -> ShowS
Prelude.Show, forall x.
Rep MergeBranchesByThreeWayResponse x
-> MergeBranchesByThreeWayResponse
forall x.
MergeBranchesByThreeWayResponse
-> Rep MergeBranchesByThreeWayResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep MergeBranchesByThreeWayResponse x
-> MergeBranchesByThreeWayResponse
$cfrom :: forall x.
MergeBranchesByThreeWayResponse
-> Rep MergeBranchesByThreeWayResponse x
Prelude.Generic)

-- |
-- Create a value of 'MergeBranchesByThreeWayResponse' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'commitId', 'mergeBranchesByThreeWayResponse_commitId' - The commit ID of the merge in the destination or target branch.
--
-- 'treeId', 'mergeBranchesByThreeWayResponse_treeId' - The tree ID of the merge in the destination or target branch.
--
-- 'httpStatus', 'mergeBranchesByThreeWayResponse_httpStatus' - The response's http status code.
newMergeBranchesByThreeWayResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  MergeBranchesByThreeWayResponse
newMergeBranchesByThreeWayResponse :: Int -> MergeBranchesByThreeWayResponse
newMergeBranchesByThreeWayResponse Int
pHttpStatus_ =
  MergeBranchesByThreeWayResponse'
    { $sel:commitId:MergeBranchesByThreeWayResponse' :: Maybe Text
commitId =
        forall a. Maybe a
Prelude.Nothing,
      $sel:treeId:MergeBranchesByThreeWayResponse' :: Maybe Text
treeId = forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:MergeBranchesByThreeWayResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The commit ID of the merge in the destination or target branch.
mergeBranchesByThreeWayResponse_commitId :: Lens.Lens' MergeBranchesByThreeWayResponse (Prelude.Maybe Prelude.Text)
mergeBranchesByThreeWayResponse_commitId :: Lens' MergeBranchesByThreeWayResponse (Maybe Text)
mergeBranchesByThreeWayResponse_commitId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWayResponse' {Maybe Text
commitId :: Maybe Text
$sel:commitId:MergeBranchesByThreeWayResponse' :: MergeBranchesByThreeWayResponse -> Maybe Text
commitId} -> Maybe Text
commitId) (\s :: MergeBranchesByThreeWayResponse
s@MergeBranchesByThreeWayResponse' {} Maybe Text
a -> MergeBranchesByThreeWayResponse
s {$sel:commitId:MergeBranchesByThreeWayResponse' :: Maybe Text
commitId = Maybe Text
a} :: MergeBranchesByThreeWayResponse)

-- | The tree ID of the merge in the destination or target branch.
mergeBranchesByThreeWayResponse_treeId :: Lens.Lens' MergeBranchesByThreeWayResponse (Prelude.Maybe Prelude.Text)
mergeBranchesByThreeWayResponse_treeId :: Lens' MergeBranchesByThreeWayResponse (Maybe Text)
mergeBranchesByThreeWayResponse_treeId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWayResponse' {Maybe Text
treeId :: Maybe Text
$sel:treeId:MergeBranchesByThreeWayResponse' :: MergeBranchesByThreeWayResponse -> Maybe Text
treeId} -> Maybe Text
treeId) (\s :: MergeBranchesByThreeWayResponse
s@MergeBranchesByThreeWayResponse' {} Maybe Text
a -> MergeBranchesByThreeWayResponse
s {$sel:treeId:MergeBranchesByThreeWayResponse' :: Maybe Text
treeId = Maybe Text
a} :: MergeBranchesByThreeWayResponse)

-- | The response's http status code.
mergeBranchesByThreeWayResponse_httpStatus :: Lens.Lens' MergeBranchesByThreeWayResponse Prelude.Int
mergeBranchesByThreeWayResponse_httpStatus :: Lens' MergeBranchesByThreeWayResponse Int
mergeBranchesByThreeWayResponse_httpStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MergeBranchesByThreeWayResponse' {Int
httpStatus :: Int
$sel:httpStatus:MergeBranchesByThreeWayResponse' :: MergeBranchesByThreeWayResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: MergeBranchesByThreeWayResponse
s@MergeBranchesByThreeWayResponse' {} Int
a -> MergeBranchesByThreeWayResponse
s {$sel:httpStatus:MergeBranchesByThreeWayResponse' :: Int
httpStatus = Int
a} :: MergeBranchesByThreeWayResponse)

instance
  Prelude.NFData
    MergeBranchesByThreeWayResponse
  where
  rnf :: MergeBranchesByThreeWayResponse -> ()
rnf MergeBranchesByThreeWayResponse' {Int
Maybe Text
httpStatus :: Int
treeId :: Maybe Text
commitId :: Maybe Text
$sel:httpStatus:MergeBranchesByThreeWayResponse' :: MergeBranchesByThreeWayResponse -> Int
$sel:treeId:MergeBranchesByThreeWayResponse' :: MergeBranchesByThreeWayResponse -> Maybe Text
$sel:commitId:MergeBranchesByThreeWayResponse' :: MergeBranchesByThreeWayResponse -> Maybe Text
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
commitId
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
treeId
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus