{-# 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.GameLift.CreateGameSessionQueue
(
CreateGameSessionQueue (..),
newCreateGameSessionQueue,
createGameSessionQueue_customEventData,
createGameSessionQueue_destinations,
createGameSessionQueue_filterConfiguration,
createGameSessionQueue_notificationTarget,
createGameSessionQueue_playerLatencyPolicies,
createGameSessionQueue_priorityConfiguration,
createGameSessionQueue_tags,
createGameSessionQueue_timeoutInSeconds,
createGameSessionQueue_name,
CreateGameSessionQueueResponse (..),
newCreateGameSessionQueueResponse,
createGameSessionQueueResponse_gameSessionQueue,
createGameSessionQueueResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.GameLift.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data CreateGameSessionQueue = CreateGameSessionQueue'
{
CreateGameSessionQueue -> Maybe Text
customEventData :: Prelude.Maybe Prelude.Text,
CreateGameSessionQueue -> Maybe [GameSessionQueueDestination]
destinations :: Prelude.Maybe [GameSessionQueueDestination],
CreateGameSessionQueue -> Maybe FilterConfiguration
filterConfiguration :: Prelude.Maybe FilterConfiguration,
CreateGameSessionQueue -> Maybe Text
notificationTarget :: Prelude.Maybe Prelude.Text,
CreateGameSessionQueue -> Maybe [PlayerLatencyPolicy]
playerLatencyPolicies :: Prelude.Maybe [PlayerLatencyPolicy],
CreateGameSessionQueue -> Maybe PriorityConfiguration
priorityConfiguration :: Prelude.Maybe PriorityConfiguration,
CreateGameSessionQueue -> Maybe [Tag]
tags :: Prelude.Maybe [Tag],
CreateGameSessionQueue -> Maybe Natural
timeoutInSeconds :: Prelude.Maybe Prelude.Natural,
CreateGameSessionQueue -> Text
name :: Prelude.Text
}
deriving (CreateGameSessionQueue -> CreateGameSessionQueue -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateGameSessionQueue -> CreateGameSessionQueue -> Bool
$c/= :: CreateGameSessionQueue -> CreateGameSessionQueue -> Bool
== :: CreateGameSessionQueue -> CreateGameSessionQueue -> Bool
$c== :: CreateGameSessionQueue -> CreateGameSessionQueue -> Bool
Prelude.Eq, ReadPrec [CreateGameSessionQueue]
ReadPrec CreateGameSessionQueue
Int -> ReadS CreateGameSessionQueue
ReadS [CreateGameSessionQueue]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateGameSessionQueue]
$creadListPrec :: ReadPrec [CreateGameSessionQueue]
readPrec :: ReadPrec CreateGameSessionQueue
$creadPrec :: ReadPrec CreateGameSessionQueue
readList :: ReadS [CreateGameSessionQueue]
$creadList :: ReadS [CreateGameSessionQueue]
readsPrec :: Int -> ReadS CreateGameSessionQueue
$creadsPrec :: Int -> ReadS CreateGameSessionQueue
Prelude.Read, Int -> CreateGameSessionQueue -> ShowS
[CreateGameSessionQueue] -> ShowS
CreateGameSessionQueue -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateGameSessionQueue] -> ShowS
$cshowList :: [CreateGameSessionQueue] -> ShowS
show :: CreateGameSessionQueue -> String
$cshow :: CreateGameSessionQueue -> String
showsPrec :: Int -> CreateGameSessionQueue -> ShowS
$cshowsPrec :: Int -> CreateGameSessionQueue -> ShowS
Prelude.Show, forall x. Rep CreateGameSessionQueue x -> CreateGameSessionQueue
forall x. CreateGameSessionQueue -> Rep CreateGameSessionQueue x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateGameSessionQueue x -> CreateGameSessionQueue
$cfrom :: forall x. CreateGameSessionQueue -> Rep CreateGameSessionQueue x
Prelude.Generic)
newCreateGameSessionQueue ::
Prelude.Text ->
CreateGameSessionQueue
newCreateGameSessionQueue :: Text -> CreateGameSessionQueue
newCreateGameSessionQueue Text
pName_ =
CreateGameSessionQueue'
{ $sel:customEventData:CreateGameSessionQueue' :: Maybe Text
customEventData =
forall a. Maybe a
Prelude.Nothing,
$sel:destinations:CreateGameSessionQueue' :: Maybe [GameSessionQueueDestination]
destinations = forall a. Maybe a
Prelude.Nothing,
$sel:filterConfiguration:CreateGameSessionQueue' :: Maybe FilterConfiguration
filterConfiguration = forall a. Maybe a
Prelude.Nothing,
$sel:notificationTarget:CreateGameSessionQueue' :: Maybe Text
notificationTarget = forall a. Maybe a
Prelude.Nothing,
$sel:playerLatencyPolicies:CreateGameSessionQueue' :: Maybe [PlayerLatencyPolicy]
playerLatencyPolicies = forall a. Maybe a
Prelude.Nothing,
$sel:priorityConfiguration:CreateGameSessionQueue' :: Maybe PriorityConfiguration
priorityConfiguration = forall a. Maybe a
Prelude.Nothing,
$sel:tags:CreateGameSessionQueue' :: Maybe [Tag]
tags = forall a. Maybe a
Prelude.Nothing,
$sel:timeoutInSeconds:CreateGameSessionQueue' :: Maybe Natural
timeoutInSeconds = forall a. Maybe a
Prelude.Nothing,
$sel:name:CreateGameSessionQueue' :: Text
name = Text
pName_
}
createGameSessionQueue_customEventData :: Lens.Lens' CreateGameSessionQueue (Prelude.Maybe Prelude.Text)
createGameSessionQueue_customEventData :: Lens' CreateGameSessionQueue (Maybe Text)
createGameSessionQueue_customEventData = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGameSessionQueue' {Maybe Text
customEventData :: Maybe Text
$sel:customEventData:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe Text
customEventData} -> Maybe Text
customEventData) (\s :: CreateGameSessionQueue
s@CreateGameSessionQueue' {} Maybe Text
a -> CreateGameSessionQueue
s {$sel:customEventData:CreateGameSessionQueue' :: Maybe Text
customEventData = Maybe Text
a} :: CreateGameSessionQueue)
createGameSessionQueue_destinations :: Lens.Lens' CreateGameSessionQueue (Prelude.Maybe [GameSessionQueueDestination])
createGameSessionQueue_destinations :: Lens' CreateGameSessionQueue (Maybe [GameSessionQueueDestination])
createGameSessionQueue_destinations = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGameSessionQueue' {Maybe [GameSessionQueueDestination]
destinations :: Maybe [GameSessionQueueDestination]
$sel:destinations:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe [GameSessionQueueDestination]
destinations} -> Maybe [GameSessionQueueDestination]
destinations) (\s :: CreateGameSessionQueue
s@CreateGameSessionQueue' {} Maybe [GameSessionQueueDestination]
a -> CreateGameSessionQueue
s {$sel:destinations:CreateGameSessionQueue' :: Maybe [GameSessionQueueDestination]
destinations = Maybe [GameSessionQueueDestination]
a} :: CreateGameSessionQueue) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
createGameSessionQueue_filterConfiguration :: Lens.Lens' CreateGameSessionQueue (Prelude.Maybe FilterConfiguration)
createGameSessionQueue_filterConfiguration :: Lens' CreateGameSessionQueue (Maybe FilterConfiguration)
createGameSessionQueue_filterConfiguration = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGameSessionQueue' {Maybe FilterConfiguration
filterConfiguration :: Maybe FilterConfiguration
$sel:filterConfiguration:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe FilterConfiguration
filterConfiguration} -> Maybe FilterConfiguration
filterConfiguration) (\s :: CreateGameSessionQueue
s@CreateGameSessionQueue' {} Maybe FilterConfiguration
a -> CreateGameSessionQueue
s {$sel:filterConfiguration:CreateGameSessionQueue' :: Maybe FilterConfiguration
filterConfiguration = Maybe FilterConfiguration
a} :: CreateGameSessionQueue)
createGameSessionQueue_notificationTarget :: Lens.Lens' CreateGameSessionQueue (Prelude.Maybe Prelude.Text)
createGameSessionQueue_notificationTarget :: Lens' CreateGameSessionQueue (Maybe Text)
createGameSessionQueue_notificationTarget = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGameSessionQueue' {Maybe Text
notificationTarget :: Maybe Text
$sel:notificationTarget:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe Text
notificationTarget} -> Maybe Text
notificationTarget) (\s :: CreateGameSessionQueue
s@CreateGameSessionQueue' {} Maybe Text
a -> CreateGameSessionQueue
s {$sel:notificationTarget:CreateGameSessionQueue' :: Maybe Text
notificationTarget = Maybe Text
a} :: CreateGameSessionQueue)
createGameSessionQueue_playerLatencyPolicies :: Lens.Lens' CreateGameSessionQueue (Prelude.Maybe [PlayerLatencyPolicy])
createGameSessionQueue_playerLatencyPolicies :: Lens' CreateGameSessionQueue (Maybe [PlayerLatencyPolicy])
createGameSessionQueue_playerLatencyPolicies = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGameSessionQueue' {Maybe [PlayerLatencyPolicy]
playerLatencyPolicies :: Maybe [PlayerLatencyPolicy]
$sel:playerLatencyPolicies:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe [PlayerLatencyPolicy]
playerLatencyPolicies} -> Maybe [PlayerLatencyPolicy]
playerLatencyPolicies) (\s :: CreateGameSessionQueue
s@CreateGameSessionQueue' {} Maybe [PlayerLatencyPolicy]
a -> CreateGameSessionQueue
s {$sel:playerLatencyPolicies:CreateGameSessionQueue' :: Maybe [PlayerLatencyPolicy]
playerLatencyPolicies = Maybe [PlayerLatencyPolicy]
a} :: CreateGameSessionQueue) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
createGameSessionQueue_priorityConfiguration :: Lens.Lens' CreateGameSessionQueue (Prelude.Maybe PriorityConfiguration)
createGameSessionQueue_priorityConfiguration :: Lens' CreateGameSessionQueue (Maybe PriorityConfiguration)
createGameSessionQueue_priorityConfiguration = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGameSessionQueue' {Maybe PriorityConfiguration
priorityConfiguration :: Maybe PriorityConfiguration
$sel:priorityConfiguration:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe PriorityConfiguration
priorityConfiguration} -> Maybe PriorityConfiguration
priorityConfiguration) (\s :: CreateGameSessionQueue
s@CreateGameSessionQueue' {} Maybe PriorityConfiguration
a -> CreateGameSessionQueue
s {$sel:priorityConfiguration:CreateGameSessionQueue' :: Maybe PriorityConfiguration
priorityConfiguration = Maybe PriorityConfiguration
a} :: CreateGameSessionQueue)
createGameSessionQueue_tags :: Lens.Lens' CreateGameSessionQueue (Prelude.Maybe [Tag])
createGameSessionQueue_tags :: Lens' CreateGameSessionQueue (Maybe [Tag])
createGameSessionQueue_tags = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGameSessionQueue' {Maybe [Tag]
tags :: Maybe [Tag]
$sel:tags:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe [Tag]
tags} -> Maybe [Tag]
tags) (\s :: CreateGameSessionQueue
s@CreateGameSessionQueue' {} Maybe [Tag]
a -> CreateGameSessionQueue
s {$sel:tags:CreateGameSessionQueue' :: Maybe [Tag]
tags = Maybe [Tag]
a} :: CreateGameSessionQueue) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
createGameSessionQueue_timeoutInSeconds :: Lens.Lens' CreateGameSessionQueue (Prelude.Maybe Prelude.Natural)
createGameSessionQueue_timeoutInSeconds :: Lens' CreateGameSessionQueue (Maybe Natural)
createGameSessionQueue_timeoutInSeconds = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGameSessionQueue' {Maybe Natural
timeoutInSeconds :: Maybe Natural
$sel:timeoutInSeconds:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe Natural
timeoutInSeconds} -> Maybe Natural
timeoutInSeconds) (\s :: CreateGameSessionQueue
s@CreateGameSessionQueue' {} Maybe Natural
a -> CreateGameSessionQueue
s {$sel:timeoutInSeconds:CreateGameSessionQueue' :: Maybe Natural
timeoutInSeconds = Maybe Natural
a} :: CreateGameSessionQueue)
createGameSessionQueue_name :: Lens.Lens' CreateGameSessionQueue Prelude.Text
createGameSessionQueue_name :: Lens' CreateGameSessionQueue Text
createGameSessionQueue_name = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGameSessionQueue' {Text
name :: Text
$sel:name:CreateGameSessionQueue' :: CreateGameSessionQueue -> Text
name} -> Text
name) (\s :: CreateGameSessionQueue
s@CreateGameSessionQueue' {} Text
a -> CreateGameSessionQueue
s {$sel:name:CreateGameSessionQueue' :: Text
name = Text
a} :: CreateGameSessionQueue)
instance Core.AWSRequest CreateGameSessionQueue where
type
AWSResponse CreateGameSessionQueue =
CreateGameSessionQueueResponse
request :: (Service -> Service)
-> CreateGameSessionQueue -> Request CreateGameSessionQueue
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 CreateGameSessionQueue
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse CreateGameSessionQueue)))
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 GameSessionQueue -> Int -> CreateGameSessionQueueResponse
CreateGameSessionQueueResponse'
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
"GameSessionQueue")
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 CreateGameSessionQueue where
hashWithSalt :: Int -> CreateGameSessionQueue -> Int
hashWithSalt Int
_salt CreateGameSessionQueue' {Maybe Natural
Maybe [GameSessionQueueDestination]
Maybe [PlayerLatencyPolicy]
Maybe [Tag]
Maybe Text
Maybe FilterConfiguration
Maybe PriorityConfiguration
Text
name :: Text
timeoutInSeconds :: Maybe Natural
tags :: Maybe [Tag]
priorityConfiguration :: Maybe PriorityConfiguration
playerLatencyPolicies :: Maybe [PlayerLatencyPolicy]
notificationTarget :: Maybe Text
filterConfiguration :: Maybe FilterConfiguration
destinations :: Maybe [GameSessionQueueDestination]
customEventData :: Maybe Text
$sel:name:CreateGameSessionQueue' :: CreateGameSessionQueue -> Text
$sel:timeoutInSeconds:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe Natural
$sel:tags:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe [Tag]
$sel:priorityConfiguration:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe PriorityConfiguration
$sel:playerLatencyPolicies:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe [PlayerLatencyPolicy]
$sel:notificationTarget:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe Text
$sel:filterConfiguration:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe FilterConfiguration
$sel:destinations:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe [GameSessionQueueDestination]
$sel:customEventData:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
customEventData
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [GameSessionQueueDestination]
destinations
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe FilterConfiguration
filterConfiguration
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
notificationTarget
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [PlayerLatencyPolicy]
playerLatencyPolicies
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe PriorityConfiguration
priorityConfiguration
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Tag]
tags
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
timeoutInSeconds
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
name
instance Prelude.NFData CreateGameSessionQueue where
rnf :: CreateGameSessionQueue -> ()
rnf CreateGameSessionQueue' {Maybe Natural
Maybe [GameSessionQueueDestination]
Maybe [PlayerLatencyPolicy]
Maybe [Tag]
Maybe Text
Maybe FilterConfiguration
Maybe PriorityConfiguration
Text
name :: Text
timeoutInSeconds :: Maybe Natural
tags :: Maybe [Tag]
priorityConfiguration :: Maybe PriorityConfiguration
playerLatencyPolicies :: Maybe [PlayerLatencyPolicy]
notificationTarget :: Maybe Text
filterConfiguration :: Maybe FilterConfiguration
destinations :: Maybe [GameSessionQueueDestination]
customEventData :: Maybe Text
$sel:name:CreateGameSessionQueue' :: CreateGameSessionQueue -> Text
$sel:timeoutInSeconds:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe Natural
$sel:tags:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe [Tag]
$sel:priorityConfiguration:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe PriorityConfiguration
$sel:playerLatencyPolicies:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe [PlayerLatencyPolicy]
$sel:notificationTarget:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe Text
$sel:filterConfiguration:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe FilterConfiguration
$sel:destinations:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe [GameSessionQueueDestination]
$sel:customEventData:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
customEventData
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [GameSessionQueueDestination]
destinations
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe FilterConfiguration
filterConfiguration
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
notificationTarget
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [PlayerLatencyPolicy]
playerLatencyPolicies
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe PriorityConfiguration
priorityConfiguration
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [Tag]
tags
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
timeoutInSeconds
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
name
instance Data.ToHeaders CreateGameSessionQueue where
toHeaders :: CreateGameSessionQueue -> 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
"GameLift.CreateGameSessionQueue" ::
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 CreateGameSessionQueue where
toJSON :: CreateGameSessionQueue -> Value
toJSON CreateGameSessionQueue' {Maybe Natural
Maybe [GameSessionQueueDestination]
Maybe [PlayerLatencyPolicy]
Maybe [Tag]
Maybe Text
Maybe FilterConfiguration
Maybe PriorityConfiguration
Text
name :: Text
timeoutInSeconds :: Maybe Natural
tags :: Maybe [Tag]
priorityConfiguration :: Maybe PriorityConfiguration
playerLatencyPolicies :: Maybe [PlayerLatencyPolicy]
notificationTarget :: Maybe Text
filterConfiguration :: Maybe FilterConfiguration
destinations :: Maybe [GameSessionQueueDestination]
customEventData :: Maybe Text
$sel:name:CreateGameSessionQueue' :: CreateGameSessionQueue -> Text
$sel:timeoutInSeconds:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe Natural
$sel:tags:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe [Tag]
$sel:priorityConfiguration:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe PriorityConfiguration
$sel:playerLatencyPolicies:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe [PlayerLatencyPolicy]
$sel:notificationTarget:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe Text
$sel:filterConfiguration:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe FilterConfiguration
$sel:destinations:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe [GameSessionQueueDestination]
$sel:customEventData:CreateGameSessionQueue' :: CreateGameSessionQueue -> Maybe Text
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Key
"CustomEventData" 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
customEventData,
(Key
"Destinations" 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 [GameSessionQueueDestination]
destinations,
(Key
"FilterConfiguration" 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 FilterConfiguration
filterConfiguration,
(Key
"NotificationTarget" 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
notificationTarget,
(Key
"PlayerLatencyPolicies" 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 [PlayerLatencyPolicy]
playerLatencyPolicies,
(Key
"PriorityConfiguration" 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 PriorityConfiguration
priorityConfiguration,
(Key
"Tags" 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 [Tag]
tags,
(Key
"TimeoutInSeconds" 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 Natural
timeoutInSeconds,
forall a. a -> Maybe a
Prelude.Just (Key
"Name" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
name)
]
)
instance Data.ToPath CreateGameSessionQueue where
toPath :: CreateGameSessionQueue -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Data.ToQuery CreateGameSessionQueue where
toQuery :: CreateGameSessionQueue -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data CreateGameSessionQueueResponse = CreateGameSessionQueueResponse'
{
CreateGameSessionQueueResponse -> Maybe GameSessionQueue
gameSessionQueue :: Prelude.Maybe GameSessionQueue,
CreateGameSessionQueueResponse -> Int
httpStatus :: Prelude.Int
}
deriving (CreateGameSessionQueueResponse
-> CreateGameSessionQueueResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateGameSessionQueueResponse
-> CreateGameSessionQueueResponse -> Bool
$c/= :: CreateGameSessionQueueResponse
-> CreateGameSessionQueueResponse -> Bool
== :: CreateGameSessionQueueResponse
-> CreateGameSessionQueueResponse -> Bool
$c== :: CreateGameSessionQueueResponse
-> CreateGameSessionQueueResponse -> Bool
Prelude.Eq, ReadPrec [CreateGameSessionQueueResponse]
ReadPrec CreateGameSessionQueueResponse
Int -> ReadS CreateGameSessionQueueResponse
ReadS [CreateGameSessionQueueResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateGameSessionQueueResponse]
$creadListPrec :: ReadPrec [CreateGameSessionQueueResponse]
readPrec :: ReadPrec CreateGameSessionQueueResponse
$creadPrec :: ReadPrec CreateGameSessionQueueResponse
readList :: ReadS [CreateGameSessionQueueResponse]
$creadList :: ReadS [CreateGameSessionQueueResponse]
readsPrec :: Int -> ReadS CreateGameSessionQueueResponse
$creadsPrec :: Int -> ReadS CreateGameSessionQueueResponse
Prelude.Read, Int -> CreateGameSessionQueueResponse -> ShowS
[CreateGameSessionQueueResponse] -> ShowS
CreateGameSessionQueueResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateGameSessionQueueResponse] -> ShowS
$cshowList :: [CreateGameSessionQueueResponse] -> ShowS
show :: CreateGameSessionQueueResponse -> String
$cshow :: CreateGameSessionQueueResponse -> String
showsPrec :: Int -> CreateGameSessionQueueResponse -> ShowS
$cshowsPrec :: Int -> CreateGameSessionQueueResponse -> ShowS
Prelude.Show, forall x.
Rep CreateGameSessionQueueResponse x
-> CreateGameSessionQueueResponse
forall x.
CreateGameSessionQueueResponse
-> Rep CreateGameSessionQueueResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateGameSessionQueueResponse x
-> CreateGameSessionQueueResponse
$cfrom :: forall x.
CreateGameSessionQueueResponse
-> Rep CreateGameSessionQueueResponse x
Prelude.Generic)
newCreateGameSessionQueueResponse ::
Prelude.Int ->
CreateGameSessionQueueResponse
newCreateGameSessionQueueResponse :: Int -> CreateGameSessionQueueResponse
newCreateGameSessionQueueResponse Int
pHttpStatus_ =
CreateGameSessionQueueResponse'
{ $sel:gameSessionQueue:CreateGameSessionQueueResponse' :: Maybe GameSessionQueue
gameSessionQueue =
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:CreateGameSessionQueueResponse' :: Int
httpStatus = Int
pHttpStatus_
}
createGameSessionQueueResponse_gameSessionQueue :: Lens.Lens' CreateGameSessionQueueResponse (Prelude.Maybe GameSessionQueue)
createGameSessionQueueResponse_gameSessionQueue :: Lens' CreateGameSessionQueueResponse (Maybe GameSessionQueue)
createGameSessionQueueResponse_gameSessionQueue = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGameSessionQueueResponse' {Maybe GameSessionQueue
gameSessionQueue :: Maybe GameSessionQueue
$sel:gameSessionQueue:CreateGameSessionQueueResponse' :: CreateGameSessionQueueResponse -> Maybe GameSessionQueue
gameSessionQueue} -> Maybe GameSessionQueue
gameSessionQueue) (\s :: CreateGameSessionQueueResponse
s@CreateGameSessionQueueResponse' {} Maybe GameSessionQueue
a -> CreateGameSessionQueueResponse
s {$sel:gameSessionQueue:CreateGameSessionQueueResponse' :: Maybe GameSessionQueue
gameSessionQueue = Maybe GameSessionQueue
a} :: CreateGameSessionQueueResponse)
createGameSessionQueueResponse_httpStatus :: Lens.Lens' CreateGameSessionQueueResponse Prelude.Int
createGameSessionQueueResponse_httpStatus :: Lens' CreateGameSessionQueueResponse Int
createGameSessionQueueResponse_httpStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGameSessionQueueResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateGameSessionQueueResponse' :: CreateGameSessionQueueResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateGameSessionQueueResponse
s@CreateGameSessionQueueResponse' {} Int
a -> CreateGameSessionQueueResponse
s {$sel:httpStatus:CreateGameSessionQueueResponse' :: Int
httpStatus = Int
a} :: CreateGameSessionQueueResponse)
instance
Prelude.NFData
CreateGameSessionQueueResponse
where
rnf :: CreateGameSessionQueueResponse -> ()
rnf CreateGameSessionQueueResponse' {Int
Maybe GameSessionQueue
httpStatus :: Int
gameSessionQueue :: Maybe GameSessionQueue
$sel:httpStatus:CreateGameSessionQueueResponse' :: CreateGameSessionQueueResponse -> Int
$sel:gameSessionQueue:CreateGameSessionQueueResponse' :: CreateGameSessionQueueResponse -> Maybe GameSessionQueue
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe GameSessionQueue
gameSessionQueue
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus