{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.CodePipeline.Types.ThirdPartyJobDetails where
import Amazonka.CodePipeline.Types.ThirdPartyJobData
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data ThirdPartyJobDetails = ThirdPartyJobDetails'
{
ThirdPartyJobDetails -> Maybe ThirdPartyJobData
data' :: Prelude.Maybe ThirdPartyJobData,
ThirdPartyJobDetails -> Maybe Text
id :: Prelude.Maybe Prelude.Text,
ThirdPartyJobDetails -> Maybe Text
nonce :: Prelude.Maybe Prelude.Text
}
deriving (ThirdPartyJobDetails -> ThirdPartyJobDetails -> Bool
(ThirdPartyJobDetails -> ThirdPartyJobDetails -> Bool)
-> (ThirdPartyJobDetails -> ThirdPartyJobDetails -> Bool)
-> Eq ThirdPartyJobDetails
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ThirdPartyJobDetails -> ThirdPartyJobDetails -> Bool
$c/= :: ThirdPartyJobDetails -> ThirdPartyJobDetails -> Bool
== :: ThirdPartyJobDetails -> ThirdPartyJobDetails -> Bool
$c== :: ThirdPartyJobDetails -> ThirdPartyJobDetails -> Bool
Prelude.Eq, Int -> ThirdPartyJobDetails -> ShowS
[ThirdPartyJobDetails] -> ShowS
ThirdPartyJobDetails -> String
(Int -> ThirdPartyJobDetails -> ShowS)
-> (ThirdPartyJobDetails -> String)
-> ([ThirdPartyJobDetails] -> ShowS)
-> Show ThirdPartyJobDetails
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ThirdPartyJobDetails] -> ShowS
$cshowList :: [ThirdPartyJobDetails] -> ShowS
show :: ThirdPartyJobDetails -> String
$cshow :: ThirdPartyJobDetails -> String
showsPrec :: Int -> ThirdPartyJobDetails -> ShowS
$cshowsPrec :: Int -> ThirdPartyJobDetails -> ShowS
Prelude.Show, (forall x. ThirdPartyJobDetails -> Rep ThirdPartyJobDetails x)
-> (forall x. Rep ThirdPartyJobDetails x -> ThirdPartyJobDetails)
-> Generic ThirdPartyJobDetails
forall x. Rep ThirdPartyJobDetails x -> ThirdPartyJobDetails
forall x. ThirdPartyJobDetails -> Rep ThirdPartyJobDetails x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ThirdPartyJobDetails x -> ThirdPartyJobDetails
$cfrom :: forall x. ThirdPartyJobDetails -> Rep ThirdPartyJobDetails x
Prelude.Generic)
newThirdPartyJobDetails ::
ThirdPartyJobDetails
newThirdPartyJobDetails :: ThirdPartyJobDetails
newThirdPartyJobDetails =
ThirdPartyJobDetails' :: Maybe ThirdPartyJobData
-> Maybe Text -> Maybe Text -> ThirdPartyJobDetails
ThirdPartyJobDetails'
{ $sel:data':ThirdPartyJobDetails' :: Maybe ThirdPartyJobData
data' = Maybe ThirdPartyJobData
forall a. Maybe a
Prelude.Nothing,
$sel:id:ThirdPartyJobDetails' :: Maybe Text
id = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:nonce:ThirdPartyJobDetails' :: Maybe Text
nonce = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
thirdPartyJobDetails_data :: Lens.Lens' ThirdPartyJobDetails (Prelude.Maybe ThirdPartyJobData)
thirdPartyJobDetails_data :: (Maybe ThirdPartyJobData -> f (Maybe ThirdPartyJobData))
-> ThirdPartyJobDetails -> f ThirdPartyJobDetails
thirdPartyJobDetails_data = (ThirdPartyJobDetails -> Maybe ThirdPartyJobData)
-> (ThirdPartyJobDetails
-> Maybe ThirdPartyJobData -> ThirdPartyJobDetails)
-> Lens
ThirdPartyJobDetails
ThirdPartyJobDetails
(Maybe ThirdPartyJobData)
(Maybe ThirdPartyJobData)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ThirdPartyJobDetails' {Maybe ThirdPartyJobData
data' :: Maybe ThirdPartyJobData
$sel:data':ThirdPartyJobDetails' :: ThirdPartyJobDetails -> Maybe ThirdPartyJobData
data'} -> Maybe ThirdPartyJobData
data') (\s :: ThirdPartyJobDetails
s@ThirdPartyJobDetails' {} Maybe ThirdPartyJobData
a -> ThirdPartyJobDetails
s {$sel:data':ThirdPartyJobDetails' :: Maybe ThirdPartyJobData
data' = Maybe ThirdPartyJobData
a} :: ThirdPartyJobDetails)
thirdPartyJobDetails_id :: Lens.Lens' ThirdPartyJobDetails (Prelude.Maybe Prelude.Text)
thirdPartyJobDetails_id :: (Maybe Text -> f (Maybe Text))
-> ThirdPartyJobDetails -> f ThirdPartyJobDetails
thirdPartyJobDetails_id = (ThirdPartyJobDetails -> Maybe Text)
-> (ThirdPartyJobDetails -> Maybe Text -> ThirdPartyJobDetails)
-> Lens
ThirdPartyJobDetails ThirdPartyJobDetails (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ThirdPartyJobDetails' {Maybe Text
id :: Maybe Text
$sel:id:ThirdPartyJobDetails' :: ThirdPartyJobDetails -> Maybe Text
id} -> Maybe Text
id) (\s :: ThirdPartyJobDetails
s@ThirdPartyJobDetails' {} Maybe Text
a -> ThirdPartyJobDetails
s {$sel:id:ThirdPartyJobDetails' :: Maybe Text
id = Maybe Text
a} :: ThirdPartyJobDetails)
thirdPartyJobDetails_nonce :: Lens.Lens' ThirdPartyJobDetails (Prelude.Maybe Prelude.Text)
thirdPartyJobDetails_nonce :: (Maybe Text -> f (Maybe Text))
-> ThirdPartyJobDetails -> f ThirdPartyJobDetails
thirdPartyJobDetails_nonce = (ThirdPartyJobDetails -> Maybe Text)
-> (ThirdPartyJobDetails -> Maybe Text -> ThirdPartyJobDetails)
-> Lens
ThirdPartyJobDetails ThirdPartyJobDetails (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ThirdPartyJobDetails' {Maybe Text
nonce :: Maybe Text
$sel:nonce:ThirdPartyJobDetails' :: ThirdPartyJobDetails -> Maybe Text
nonce} -> Maybe Text
nonce) (\s :: ThirdPartyJobDetails
s@ThirdPartyJobDetails' {} Maybe Text
a -> ThirdPartyJobDetails
s {$sel:nonce:ThirdPartyJobDetails' :: Maybe Text
nonce = Maybe Text
a} :: ThirdPartyJobDetails)
instance Core.FromJSON ThirdPartyJobDetails where
parseJSON :: Value -> Parser ThirdPartyJobDetails
parseJSON =
String
-> (Object -> Parser ThirdPartyJobDetails)
-> Value
-> Parser ThirdPartyJobDetails
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"ThirdPartyJobDetails"
( \Object
x ->
Maybe ThirdPartyJobData
-> Maybe Text -> Maybe Text -> ThirdPartyJobDetails
ThirdPartyJobDetails'
(Maybe ThirdPartyJobData
-> Maybe Text -> Maybe Text -> ThirdPartyJobDetails)
-> Parser (Maybe ThirdPartyJobData)
-> Parser (Maybe Text -> Maybe Text -> ThirdPartyJobDetails)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe ThirdPartyJobData)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"data")
Parser (Maybe Text -> Maybe Text -> ThirdPartyJobDetails)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> ThirdPartyJobDetails)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"id")
Parser (Maybe Text -> ThirdPartyJobDetails)
-> Parser (Maybe Text) -> Parser ThirdPartyJobDetails
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"nonce")
)
instance Prelude.Hashable ThirdPartyJobDetails
instance Prelude.NFData ThirdPartyJobDetails