{-# 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.ThirdPartyJob where
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
data ThirdPartyJob = ThirdPartyJob'
{
ThirdPartyJob -> Maybe Text
clientId :: Prelude.Maybe Prelude.Text,
ThirdPartyJob -> Maybe Text
jobId :: Prelude.Maybe Prelude.Text
}
deriving (ThirdPartyJob -> ThirdPartyJob -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ThirdPartyJob -> ThirdPartyJob -> Bool
$c/= :: ThirdPartyJob -> ThirdPartyJob -> Bool
== :: ThirdPartyJob -> ThirdPartyJob -> Bool
$c== :: ThirdPartyJob -> ThirdPartyJob -> Bool
Prelude.Eq, ReadPrec [ThirdPartyJob]
ReadPrec ThirdPartyJob
Int -> ReadS ThirdPartyJob
ReadS [ThirdPartyJob]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ThirdPartyJob]
$creadListPrec :: ReadPrec [ThirdPartyJob]
readPrec :: ReadPrec ThirdPartyJob
$creadPrec :: ReadPrec ThirdPartyJob
readList :: ReadS [ThirdPartyJob]
$creadList :: ReadS [ThirdPartyJob]
readsPrec :: Int -> ReadS ThirdPartyJob
$creadsPrec :: Int -> ReadS ThirdPartyJob
Prelude.Read, Int -> ThirdPartyJob -> ShowS
[ThirdPartyJob] -> ShowS
ThirdPartyJob -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ThirdPartyJob] -> ShowS
$cshowList :: [ThirdPartyJob] -> ShowS
show :: ThirdPartyJob -> String
$cshow :: ThirdPartyJob -> String
showsPrec :: Int -> ThirdPartyJob -> ShowS
$cshowsPrec :: Int -> ThirdPartyJob -> ShowS
Prelude.Show, forall x. Rep ThirdPartyJob x -> ThirdPartyJob
forall x. ThirdPartyJob -> Rep ThirdPartyJob x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ThirdPartyJob x -> ThirdPartyJob
$cfrom :: forall x. ThirdPartyJob -> Rep ThirdPartyJob x
Prelude.Generic)
newThirdPartyJob ::
ThirdPartyJob
newThirdPartyJob :: ThirdPartyJob
newThirdPartyJob =
ThirdPartyJob'
{ $sel:clientId:ThirdPartyJob' :: Maybe Text
clientId = forall a. Maybe a
Prelude.Nothing,
$sel:jobId:ThirdPartyJob' :: Maybe Text
jobId = forall a. Maybe a
Prelude.Nothing
}
thirdPartyJob_clientId :: Lens.Lens' ThirdPartyJob (Prelude.Maybe Prelude.Text)
thirdPartyJob_clientId :: Lens' ThirdPartyJob (Maybe Text)
thirdPartyJob_clientId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ThirdPartyJob' {Maybe Text
clientId :: Maybe Text
$sel:clientId:ThirdPartyJob' :: ThirdPartyJob -> Maybe Text
clientId} -> Maybe Text
clientId) (\s :: ThirdPartyJob
s@ThirdPartyJob' {} Maybe Text
a -> ThirdPartyJob
s {$sel:clientId:ThirdPartyJob' :: Maybe Text
clientId = Maybe Text
a} :: ThirdPartyJob)
thirdPartyJob_jobId :: Lens.Lens' ThirdPartyJob (Prelude.Maybe Prelude.Text)
thirdPartyJob_jobId :: Lens' ThirdPartyJob (Maybe Text)
thirdPartyJob_jobId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ThirdPartyJob' {Maybe Text
jobId :: Maybe Text
$sel:jobId:ThirdPartyJob' :: ThirdPartyJob -> Maybe Text
jobId} -> Maybe Text
jobId) (\s :: ThirdPartyJob
s@ThirdPartyJob' {} Maybe Text
a -> ThirdPartyJob
s {$sel:jobId:ThirdPartyJob' :: Maybe Text
jobId = Maybe Text
a} :: ThirdPartyJob)
instance Data.FromJSON ThirdPartyJob where
parseJSON :: Value -> Parser ThirdPartyJob
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"ThirdPartyJob"
( \Object
x ->
Maybe Text -> Maybe Text -> ThirdPartyJob
ThirdPartyJob'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"clientId")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"jobId")
)
instance Prelude.Hashable ThirdPartyJob where
hashWithSalt :: Int -> ThirdPartyJob -> Int
hashWithSalt Int
_salt ThirdPartyJob' {Maybe Text
jobId :: Maybe Text
clientId :: Maybe Text
$sel:jobId:ThirdPartyJob' :: ThirdPartyJob -> Maybe Text
$sel:clientId:ThirdPartyJob' :: ThirdPartyJob -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
clientId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
jobId
instance Prelude.NFData ThirdPartyJob where
rnf :: ThirdPartyJob -> ()
rnf ThirdPartyJob' {Maybe Text
jobId :: Maybe Text
clientId :: Maybe Text
$sel:jobId:ThirdPartyJob' :: ThirdPartyJob -> Maybe Text
$sel:clientId:ThirdPartyJob' :: ThirdPartyJob -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
clientId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
jobId