{-# 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 #-}
module Amazonka.ComprehendMedical.StartEntitiesDetectionV2Job
(
StartEntitiesDetectionV2Job (..),
newStartEntitiesDetectionV2Job,
startEntitiesDetectionV2Job_kmsKey,
startEntitiesDetectionV2Job_jobName,
startEntitiesDetectionV2Job_clientRequestToken,
startEntitiesDetectionV2Job_inputDataConfig,
startEntitiesDetectionV2Job_outputDataConfig,
startEntitiesDetectionV2Job_dataAccessRoleArn,
startEntitiesDetectionV2Job_languageCode,
StartEntitiesDetectionV2JobResponse (..),
newStartEntitiesDetectionV2JobResponse,
startEntitiesDetectionV2JobResponse_jobId,
startEntitiesDetectionV2JobResponse_httpStatus,
)
where
import Amazonka.ComprehendMedical.Types
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data StartEntitiesDetectionV2Job = StartEntitiesDetectionV2Job'
{
StartEntitiesDetectionV2Job -> Maybe Text
kmsKey :: Prelude.Maybe Prelude.Text,
StartEntitiesDetectionV2Job -> Maybe Text
jobName :: Prelude.Maybe Prelude.Text,
StartEntitiesDetectionV2Job -> Maybe Text
clientRequestToken :: Prelude.Maybe Prelude.Text,
StartEntitiesDetectionV2Job -> InputDataConfig
inputDataConfig :: InputDataConfig,
StartEntitiesDetectionV2Job -> OutputDataConfig
outputDataConfig :: OutputDataConfig,
StartEntitiesDetectionV2Job -> Text
dataAccessRoleArn :: Prelude.Text,
StartEntitiesDetectionV2Job -> LanguageCode
languageCode :: LanguageCode
}
deriving (StartEntitiesDetectionV2Job -> StartEntitiesDetectionV2Job -> Bool
(StartEntitiesDetectionV2Job
-> StartEntitiesDetectionV2Job -> Bool)
-> (StartEntitiesDetectionV2Job
-> StartEntitiesDetectionV2Job -> Bool)
-> Eq StartEntitiesDetectionV2Job
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: StartEntitiesDetectionV2Job -> StartEntitiesDetectionV2Job -> Bool
$c/= :: StartEntitiesDetectionV2Job -> StartEntitiesDetectionV2Job -> Bool
== :: StartEntitiesDetectionV2Job -> StartEntitiesDetectionV2Job -> Bool
$c== :: StartEntitiesDetectionV2Job -> StartEntitiesDetectionV2Job -> Bool
Prelude.Eq, ReadPrec [StartEntitiesDetectionV2Job]
ReadPrec StartEntitiesDetectionV2Job
Int -> ReadS StartEntitiesDetectionV2Job
ReadS [StartEntitiesDetectionV2Job]
(Int -> ReadS StartEntitiesDetectionV2Job)
-> ReadS [StartEntitiesDetectionV2Job]
-> ReadPrec StartEntitiesDetectionV2Job
-> ReadPrec [StartEntitiesDetectionV2Job]
-> Read StartEntitiesDetectionV2Job
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [StartEntitiesDetectionV2Job]
$creadListPrec :: ReadPrec [StartEntitiesDetectionV2Job]
readPrec :: ReadPrec StartEntitiesDetectionV2Job
$creadPrec :: ReadPrec StartEntitiesDetectionV2Job
readList :: ReadS [StartEntitiesDetectionV2Job]
$creadList :: ReadS [StartEntitiesDetectionV2Job]
readsPrec :: Int -> ReadS StartEntitiesDetectionV2Job
$creadsPrec :: Int -> ReadS StartEntitiesDetectionV2Job
Prelude.Read, Int -> StartEntitiesDetectionV2Job -> ShowS
[StartEntitiesDetectionV2Job] -> ShowS
StartEntitiesDetectionV2Job -> String
(Int -> StartEntitiesDetectionV2Job -> ShowS)
-> (StartEntitiesDetectionV2Job -> String)
-> ([StartEntitiesDetectionV2Job] -> ShowS)
-> Show StartEntitiesDetectionV2Job
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [StartEntitiesDetectionV2Job] -> ShowS
$cshowList :: [StartEntitiesDetectionV2Job] -> ShowS
show :: StartEntitiesDetectionV2Job -> String
$cshow :: StartEntitiesDetectionV2Job -> String
showsPrec :: Int -> StartEntitiesDetectionV2Job -> ShowS
$cshowsPrec :: Int -> StartEntitiesDetectionV2Job -> ShowS
Prelude.Show, (forall x.
StartEntitiesDetectionV2Job -> Rep StartEntitiesDetectionV2Job x)
-> (forall x.
Rep StartEntitiesDetectionV2Job x -> StartEntitiesDetectionV2Job)
-> Generic StartEntitiesDetectionV2Job
forall x.
Rep StartEntitiesDetectionV2Job x -> StartEntitiesDetectionV2Job
forall x.
StartEntitiesDetectionV2Job -> Rep StartEntitiesDetectionV2Job x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep StartEntitiesDetectionV2Job x -> StartEntitiesDetectionV2Job
$cfrom :: forall x.
StartEntitiesDetectionV2Job -> Rep StartEntitiesDetectionV2Job x
Prelude.Generic)
newStartEntitiesDetectionV2Job ::
InputDataConfig ->
OutputDataConfig ->
Prelude.Text ->
LanguageCode ->
StartEntitiesDetectionV2Job
newStartEntitiesDetectionV2Job :: InputDataConfig
-> OutputDataConfig
-> Text
-> LanguageCode
-> StartEntitiesDetectionV2Job
newStartEntitiesDetectionV2Job
InputDataConfig
pInputDataConfig_
OutputDataConfig
pOutputDataConfig_
Text
pDataAccessRoleArn_
LanguageCode
pLanguageCode_ =
StartEntitiesDetectionV2Job' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> InputDataConfig
-> OutputDataConfig
-> Text
-> LanguageCode
-> StartEntitiesDetectionV2Job
StartEntitiesDetectionV2Job'
{ $sel:kmsKey:StartEntitiesDetectionV2Job' :: Maybe Text
kmsKey =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:jobName:StartEntitiesDetectionV2Job' :: Maybe Text
jobName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:clientRequestToken:StartEntitiesDetectionV2Job' :: Maybe Text
clientRequestToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:inputDataConfig:StartEntitiesDetectionV2Job' :: InputDataConfig
inputDataConfig = InputDataConfig
pInputDataConfig_,
$sel:outputDataConfig:StartEntitiesDetectionV2Job' :: OutputDataConfig
outputDataConfig = OutputDataConfig
pOutputDataConfig_,
$sel:dataAccessRoleArn:StartEntitiesDetectionV2Job' :: Text
dataAccessRoleArn = Text
pDataAccessRoleArn_,
$sel:languageCode:StartEntitiesDetectionV2Job' :: LanguageCode
languageCode = LanguageCode
pLanguageCode_
}
startEntitiesDetectionV2Job_kmsKey :: Lens.Lens' StartEntitiesDetectionV2Job (Prelude.Maybe Prelude.Text)
startEntitiesDetectionV2Job_kmsKey :: (Maybe Text -> f (Maybe Text))
-> StartEntitiesDetectionV2Job -> f StartEntitiesDetectionV2Job
startEntitiesDetectionV2Job_kmsKey = (StartEntitiesDetectionV2Job -> Maybe Text)
-> (StartEntitiesDetectionV2Job
-> Maybe Text -> StartEntitiesDetectionV2Job)
-> Lens
StartEntitiesDetectionV2Job
StartEntitiesDetectionV2Job
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartEntitiesDetectionV2Job' {Maybe Text
kmsKey :: Maybe Text
$sel:kmsKey:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> Maybe Text
kmsKey} -> Maybe Text
kmsKey) (\s :: StartEntitiesDetectionV2Job
s@StartEntitiesDetectionV2Job' {} Maybe Text
a -> StartEntitiesDetectionV2Job
s {$sel:kmsKey:StartEntitiesDetectionV2Job' :: Maybe Text
kmsKey = Maybe Text
a} :: StartEntitiesDetectionV2Job)
startEntitiesDetectionV2Job_jobName :: Lens.Lens' StartEntitiesDetectionV2Job (Prelude.Maybe Prelude.Text)
startEntitiesDetectionV2Job_jobName :: (Maybe Text -> f (Maybe Text))
-> StartEntitiesDetectionV2Job -> f StartEntitiesDetectionV2Job
startEntitiesDetectionV2Job_jobName = (StartEntitiesDetectionV2Job -> Maybe Text)
-> (StartEntitiesDetectionV2Job
-> Maybe Text -> StartEntitiesDetectionV2Job)
-> Lens
StartEntitiesDetectionV2Job
StartEntitiesDetectionV2Job
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartEntitiesDetectionV2Job' {Maybe Text
jobName :: Maybe Text
$sel:jobName:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> Maybe Text
jobName} -> Maybe Text
jobName) (\s :: StartEntitiesDetectionV2Job
s@StartEntitiesDetectionV2Job' {} Maybe Text
a -> StartEntitiesDetectionV2Job
s {$sel:jobName:StartEntitiesDetectionV2Job' :: Maybe Text
jobName = Maybe Text
a} :: StartEntitiesDetectionV2Job)
startEntitiesDetectionV2Job_clientRequestToken :: Lens.Lens' StartEntitiesDetectionV2Job (Prelude.Maybe Prelude.Text)
startEntitiesDetectionV2Job_clientRequestToken :: (Maybe Text -> f (Maybe Text))
-> StartEntitiesDetectionV2Job -> f StartEntitiesDetectionV2Job
startEntitiesDetectionV2Job_clientRequestToken = (StartEntitiesDetectionV2Job -> Maybe Text)
-> (StartEntitiesDetectionV2Job
-> Maybe Text -> StartEntitiesDetectionV2Job)
-> Lens
StartEntitiesDetectionV2Job
StartEntitiesDetectionV2Job
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartEntitiesDetectionV2Job' {Maybe Text
clientRequestToken :: Maybe Text
$sel:clientRequestToken:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> Maybe Text
clientRequestToken} -> Maybe Text
clientRequestToken) (\s :: StartEntitiesDetectionV2Job
s@StartEntitiesDetectionV2Job' {} Maybe Text
a -> StartEntitiesDetectionV2Job
s {$sel:clientRequestToken:StartEntitiesDetectionV2Job' :: Maybe Text
clientRequestToken = Maybe Text
a} :: StartEntitiesDetectionV2Job)
startEntitiesDetectionV2Job_inputDataConfig :: Lens.Lens' StartEntitiesDetectionV2Job InputDataConfig
startEntitiesDetectionV2Job_inputDataConfig :: (InputDataConfig -> f InputDataConfig)
-> StartEntitiesDetectionV2Job -> f StartEntitiesDetectionV2Job
startEntitiesDetectionV2Job_inputDataConfig = (StartEntitiesDetectionV2Job -> InputDataConfig)
-> (StartEntitiesDetectionV2Job
-> InputDataConfig -> StartEntitiesDetectionV2Job)
-> Lens
StartEntitiesDetectionV2Job
StartEntitiesDetectionV2Job
InputDataConfig
InputDataConfig
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartEntitiesDetectionV2Job' {InputDataConfig
inputDataConfig :: InputDataConfig
$sel:inputDataConfig:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> InputDataConfig
inputDataConfig} -> InputDataConfig
inputDataConfig) (\s :: StartEntitiesDetectionV2Job
s@StartEntitiesDetectionV2Job' {} InputDataConfig
a -> StartEntitiesDetectionV2Job
s {$sel:inputDataConfig:StartEntitiesDetectionV2Job' :: InputDataConfig
inputDataConfig = InputDataConfig
a} :: StartEntitiesDetectionV2Job)
startEntitiesDetectionV2Job_outputDataConfig :: Lens.Lens' StartEntitiesDetectionV2Job OutputDataConfig
startEntitiesDetectionV2Job_outputDataConfig :: (OutputDataConfig -> f OutputDataConfig)
-> StartEntitiesDetectionV2Job -> f StartEntitiesDetectionV2Job
startEntitiesDetectionV2Job_outputDataConfig = (StartEntitiesDetectionV2Job -> OutputDataConfig)
-> (StartEntitiesDetectionV2Job
-> OutputDataConfig -> StartEntitiesDetectionV2Job)
-> Lens
StartEntitiesDetectionV2Job
StartEntitiesDetectionV2Job
OutputDataConfig
OutputDataConfig
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartEntitiesDetectionV2Job' {OutputDataConfig
outputDataConfig :: OutputDataConfig
$sel:outputDataConfig:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> OutputDataConfig
outputDataConfig} -> OutputDataConfig
outputDataConfig) (\s :: StartEntitiesDetectionV2Job
s@StartEntitiesDetectionV2Job' {} OutputDataConfig
a -> StartEntitiesDetectionV2Job
s {$sel:outputDataConfig:StartEntitiesDetectionV2Job' :: OutputDataConfig
outputDataConfig = OutputDataConfig
a} :: StartEntitiesDetectionV2Job)
startEntitiesDetectionV2Job_dataAccessRoleArn :: Lens.Lens' StartEntitiesDetectionV2Job Prelude.Text
startEntitiesDetectionV2Job_dataAccessRoleArn :: (Text -> f Text)
-> StartEntitiesDetectionV2Job -> f StartEntitiesDetectionV2Job
startEntitiesDetectionV2Job_dataAccessRoleArn = (StartEntitiesDetectionV2Job -> Text)
-> (StartEntitiesDetectionV2Job
-> Text -> StartEntitiesDetectionV2Job)
-> Lens
StartEntitiesDetectionV2Job StartEntitiesDetectionV2Job Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartEntitiesDetectionV2Job' {Text
dataAccessRoleArn :: Text
$sel:dataAccessRoleArn:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> Text
dataAccessRoleArn} -> Text
dataAccessRoleArn) (\s :: StartEntitiesDetectionV2Job
s@StartEntitiesDetectionV2Job' {} Text
a -> StartEntitiesDetectionV2Job
s {$sel:dataAccessRoleArn:StartEntitiesDetectionV2Job' :: Text
dataAccessRoleArn = Text
a} :: StartEntitiesDetectionV2Job)
startEntitiesDetectionV2Job_languageCode :: Lens.Lens' StartEntitiesDetectionV2Job LanguageCode
startEntitiesDetectionV2Job_languageCode :: (LanguageCode -> f LanguageCode)
-> StartEntitiesDetectionV2Job -> f StartEntitiesDetectionV2Job
startEntitiesDetectionV2Job_languageCode = (StartEntitiesDetectionV2Job -> LanguageCode)
-> (StartEntitiesDetectionV2Job
-> LanguageCode -> StartEntitiesDetectionV2Job)
-> Lens
StartEntitiesDetectionV2Job
StartEntitiesDetectionV2Job
LanguageCode
LanguageCode
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartEntitiesDetectionV2Job' {LanguageCode
languageCode :: LanguageCode
$sel:languageCode:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> LanguageCode
languageCode} -> LanguageCode
languageCode) (\s :: StartEntitiesDetectionV2Job
s@StartEntitiesDetectionV2Job' {} LanguageCode
a -> StartEntitiesDetectionV2Job
s {$sel:languageCode:StartEntitiesDetectionV2Job' :: LanguageCode
languageCode = LanguageCode
a} :: StartEntitiesDetectionV2Job)
instance Core.AWSRequest StartEntitiesDetectionV2Job where
type
AWSResponse StartEntitiesDetectionV2Job =
StartEntitiesDetectionV2JobResponse
request :: StartEntitiesDetectionV2Job -> Request StartEntitiesDetectionV2Job
request = Service
-> StartEntitiesDetectionV2Job
-> Request StartEntitiesDetectionV2Job
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy StartEntitiesDetectionV2Job
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse StartEntitiesDetectionV2Job)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse StartEntitiesDetectionV2Job))
-> Logger
-> Service
-> Proxy StartEntitiesDetectionV2Job
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse StartEntitiesDetectionV2Job)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe Text -> Int -> StartEntitiesDetectionV2JobResponse
StartEntitiesDetectionV2JobResponse'
(Maybe Text -> Int -> StartEntitiesDetectionV2JobResponse)
-> Either String (Maybe Text)
-> Either String (Int -> StartEntitiesDetectionV2JobResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"JobId")
Either String (Int -> StartEntitiesDetectionV2JobResponse)
-> Either String Int
-> Either String StartEntitiesDetectionV2JobResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable StartEntitiesDetectionV2Job
instance Prelude.NFData StartEntitiesDetectionV2Job
instance Core.ToHeaders StartEntitiesDetectionV2Job where
toHeaders :: StartEntitiesDetectionV2Job -> ResponseHeaders
toHeaders =
ResponseHeaders -> StartEntitiesDetectionV2Job -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"ComprehendMedical_20181030.StartEntitiesDetectionV2Job" ::
Prelude.ByteString
),
HeaderName
"Content-Type"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Core.ToJSON StartEntitiesDetectionV2Job where
toJSON :: StartEntitiesDetectionV2Job -> Value
toJSON StartEntitiesDetectionV2Job' {Maybe Text
Text
InputDataConfig
LanguageCode
OutputDataConfig
languageCode :: LanguageCode
dataAccessRoleArn :: Text
outputDataConfig :: OutputDataConfig
inputDataConfig :: InputDataConfig
clientRequestToken :: Maybe Text
jobName :: Maybe Text
kmsKey :: Maybe Text
$sel:languageCode:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> LanguageCode
$sel:dataAccessRoleArn:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> Text
$sel:outputDataConfig:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> OutputDataConfig
$sel:inputDataConfig:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> InputDataConfig
$sel:clientRequestToken:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> Maybe Text
$sel:jobName:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> Maybe Text
$sel:kmsKey:StartEntitiesDetectionV2Job' :: StartEntitiesDetectionV2Job -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"KMSKey" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
kmsKey,
(Text
"JobName" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
jobName,
(Text
"ClientRequestToken" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
clientRequestToken,
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
(Text
"InputDataConfig" Text -> InputDataConfig -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= InputDataConfig
inputDataConfig),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
(Text
"OutputDataConfig" Text -> OutputDataConfig -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= OutputDataConfig
outputDataConfig),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
(Text
"DataAccessRoleArn" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
dataAccessRoleArn),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"LanguageCode" Text -> LanguageCode -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= LanguageCode
languageCode)
]
)
instance Core.ToPath StartEntitiesDetectionV2Job where
toPath :: StartEntitiesDetectionV2Job -> ByteString
toPath = ByteString -> StartEntitiesDetectionV2Job -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery StartEntitiesDetectionV2Job where
toQuery :: StartEntitiesDetectionV2Job -> QueryString
toQuery = QueryString -> StartEntitiesDetectionV2Job -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data StartEntitiesDetectionV2JobResponse = StartEntitiesDetectionV2JobResponse'
{
StartEntitiesDetectionV2JobResponse -> Maybe Text
jobId :: Prelude.Maybe Prelude.Text,
StartEntitiesDetectionV2JobResponse -> Int
httpStatus :: Prelude.Int
}
deriving (StartEntitiesDetectionV2JobResponse
-> StartEntitiesDetectionV2JobResponse -> Bool
(StartEntitiesDetectionV2JobResponse
-> StartEntitiesDetectionV2JobResponse -> Bool)
-> (StartEntitiesDetectionV2JobResponse
-> StartEntitiesDetectionV2JobResponse -> Bool)
-> Eq StartEntitiesDetectionV2JobResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: StartEntitiesDetectionV2JobResponse
-> StartEntitiesDetectionV2JobResponse -> Bool
$c/= :: StartEntitiesDetectionV2JobResponse
-> StartEntitiesDetectionV2JobResponse -> Bool
== :: StartEntitiesDetectionV2JobResponse
-> StartEntitiesDetectionV2JobResponse -> Bool
$c== :: StartEntitiesDetectionV2JobResponse
-> StartEntitiesDetectionV2JobResponse -> Bool
Prelude.Eq, ReadPrec [StartEntitiesDetectionV2JobResponse]
ReadPrec StartEntitiesDetectionV2JobResponse
Int -> ReadS StartEntitiesDetectionV2JobResponse
ReadS [StartEntitiesDetectionV2JobResponse]
(Int -> ReadS StartEntitiesDetectionV2JobResponse)
-> ReadS [StartEntitiesDetectionV2JobResponse]
-> ReadPrec StartEntitiesDetectionV2JobResponse
-> ReadPrec [StartEntitiesDetectionV2JobResponse]
-> Read StartEntitiesDetectionV2JobResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [StartEntitiesDetectionV2JobResponse]
$creadListPrec :: ReadPrec [StartEntitiesDetectionV2JobResponse]
readPrec :: ReadPrec StartEntitiesDetectionV2JobResponse
$creadPrec :: ReadPrec StartEntitiesDetectionV2JobResponse
readList :: ReadS [StartEntitiesDetectionV2JobResponse]
$creadList :: ReadS [StartEntitiesDetectionV2JobResponse]
readsPrec :: Int -> ReadS StartEntitiesDetectionV2JobResponse
$creadsPrec :: Int -> ReadS StartEntitiesDetectionV2JobResponse
Prelude.Read, Int -> StartEntitiesDetectionV2JobResponse -> ShowS
[StartEntitiesDetectionV2JobResponse] -> ShowS
StartEntitiesDetectionV2JobResponse -> String
(Int -> StartEntitiesDetectionV2JobResponse -> ShowS)
-> (StartEntitiesDetectionV2JobResponse -> String)
-> ([StartEntitiesDetectionV2JobResponse] -> ShowS)
-> Show StartEntitiesDetectionV2JobResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [StartEntitiesDetectionV2JobResponse] -> ShowS
$cshowList :: [StartEntitiesDetectionV2JobResponse] -> ShowS
show :: StartEntitiesDetectionV2JobResponse -> String
$cshow :: StartEntitiesDetectionV2JobResponse -> String
showsPrec :: Int -> StartEntitiesDetectionV2JobResponse -> ShowS
$cshowsPrec :: Int -> StartEntitiesDetectionV2JobResponse -> ShowS
Prelude.Show, (forall x.
StartEntitiesDetectionV2JobResponse
-> Rep StartEntitiesDetectionV2JobResponse x)
-> (forall x.
Rep StartEntitiesDetectionV2JobResponse x
-> StartEntitiesDetectionV2JobResponse)
-> Generic StartEntitiesDetectionV2JobResponse
forall x.
Rep StartEntitiesDetectionV2JobResponse x
-> StartEntitiesDetectionV2JobResponse
forall x.
StartEntitiesDetectionV2JobResponse
-> Rep StartEntitiesDetectionV2JobResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep StartEntitiesDetectionV2JobResponse x
-> StartEntitiesDetectionV2JobResponse
$cfrom :: forall x.
StartEntitiesDetectionV2JobResponse
-> Rep StartEntitiesDetectionV2JobResponse x
Prelude.Generic)
newStartEntitiesDetectionV2JobResponse ::
Prelude.Int ->
StartEntitiesDetectionV2JobResponse
newStartEntitiesDetectionV2JobResponse :: Int -> StartEntitiesDetectionV2JobResponse
newStartEntitiesDetectionV2JobResponse Int
pHttpStatus_ =
StartEntitiesDetectionV2JobResponse' :: Maybe Text -> Int -> StartEntitiesDetectionV2JobResponse
StartEntitiesDetectionV2JobResponse'
{ $sel:jobId:StartEntitiesDetectionV2JobResponse' :: Maybe Text
jobId =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:StartEntitiesDetectionV2JobResponse' :: Int
httpStatus = Int
pHttpStatus_
}
startEntitiesDetectionV2JobResponse_jobId :: Lens.Lens' StartEntitiesDetectionV2JobResponse (Prelude.Maybe Prelude.Text)
startEntitiesDetectionV2JobResponse_jobId :: (Maybe Text -> f (Maybe Text))
-> StartEntitiesDetectionV2JobResponse
-> f StartEntitiesDetectionV2JobResponse
startEntitiesDetectionV2JobResponse_jobId = (StartEntitiesDetectionV2JobResponse -> Maybe Text)
-> (StartEntitiesDetectionV2JobResponse
-> Maybe Text -> StartEntitiesDetectionV2JobResponse)
-> Lens
StartEntitiesDetectionV2JobResponse
StartEntitiesDetectionV2JobResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartEntitiesDetectionV2JobResponse' {Maybe Text
jobId :: Maybe Text
$sel:jobId:StartEntitiesDetectionV2JobResponse' :: StartEntitiesDetectionV2JobResponse -> Maybe Text
jobId} -> Maybe Text
jobId) (\s :: StartEntitiesDetectionV2JobResponse
s@StartEntitiesDetectionV2JobResponse' {} Maybe Text
a -> StartEntitiesDetectionV2JobResponse
s {$sel:jobId:StartEntitiesDetectionV2JobResponse' :: Maybe Text
jobId = Maybe Text
a} :: StartEntitiesDetectionV2JobResponse)
startEntitiesDetectionV2JobResponse_httpStatus :: Lens.Lens' StartEntitiesDetectionV2JobResponse Prelude.Int
startEntitiesDetectionV2JobResponse_httpStatus :: (Int -> f Int)
-> StartEntitiesDetectionV2JobResponse
-> f StartEntitiesDetectionV2JobResponse
startEntitiesDetectionV2JobResponse_httpStatus = (StartEntitiesDetectionV2JobResponse -> Int)
-> (StartEntitiesDetectionV2JobResponse
-> Int -> StartEntitiesDetectionV2JobResponse)
-> Lens
StartEntitiesDetectionV2JobResponse
StartEntitiesDetectionV2JobResponse
Int
Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartEntitiesDetectionV2JobResponse' {Int
httpStatus :: Int
$sel:httpStatus:StartEntitiesDetectionV2JobResponse' :: StartEntitiesDetectionV2JobResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: StartEntitiesDetectionV2JobResponse
s@StartEntitiesDetectionV2JobResponse' {} Int
a -> StartEntitiesDetectionV2JobResponse
s {$sel:httpStatus:StartEntitiesDetectionV2JobResponse' :: Int
httpStatus = Int
a} :: StartEntitiesDetectionV2JobResponse)
instance
Prelude.NFData
StartEntitiesDetectionV2JobResponse