{-# 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.ApiGatewayV2.UpdateRouteResponse
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Updates a RouteResponse.
module Amazonka.ApiGatewayV2.UpdateRouteResponse
  ( -- * Creating a Request
    UpdateRouteResponse (..),
    newUpdateRouteResponse,

    -- * Request Lenses
    updateRouteResponse_modelSelectionExpression,
    updateRouteResponse_responseModels,
    updateRouteResponse_routeResponseKey,
    updateRouteResponse_responseParameters,
    updateRouteResponse_routeResponseId,
    updateRouteResponse_apiId,
    updateRouteResponse_routeId,

    -- * Destructuring the Response
    UpdateRouteResponseResponse (..),
    newUpdateRouteResponseResponse,

    -- * Response Lenses
    updateRouteResponseResponse_modelSelectionExpression,
    updateRouteResponseResponse_responseModels,
    updateRouteResponseResponse_routeResponseId,
    updateRouteResponseResponse_routeResponseKey,
    updateRouteResponseResponse_responseParameters,
    updateRouteResponseResponse_httpStatus,
  )
where

import Amazonka.ApiGatewayV2.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

-- | Updates a RouteResponse.
--
-- /See:/ 'newUpdateRouteResponse' smart constructor.
data UpdateRouteResponse = UpdateRouteResponse'
  { -- | The model selection expression for the route response. Supported only
    -- for WebSocket APIs.
    UpdateRouteResponse -> Maybe Text
modelSelectionExpression :: Prelude.Maybe Prelude.Text,
    -- | The response models for the route response.
    UpdateRouteResponse -> Maybe (HashMap Text Text)
responseModels :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
    -- | The route response key.
    UpdateRouteResponse -> Maybe Text
routeResponseKey :: Prelude.Maybe Prelude.Text,
    -- | The route response parameters.
    UpdateRouteResponse -> Maybe (HashMap Text ParameterConstraints)
responseParameters :: Prelude.Maybe (Prelude.HashMap Prelude.Text ParameterConstraints),
    -- | The route response ID.
    UpdateRouteResponse -> Text
routeResponseId :: Prelude.Text,
    -- | The API identifier.
    UpdateRouteResponse -> Text
apiId :: Prelude.Text,
    -- | The route ID.
    UpdateRouteResponse -> Text
routeId :: Prelude.Text
  }
  deriving (UpdateRouteResponse -> UpdateRouteResponse -> Bool
(UpdateRouteResponse -> UpdateRouteResponse -> Bool)
-> (UpdateRouteResponse -> UpdateRouteResponse -> Bool)
-> Eq UpdateRouteResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateRouteResponse -> UpdateRouteResponse -> Bool
$c/= :: UpdateRouteResponse -> UpdateRouteResponse -> Bool
== :: UpdateRouteResponse -> UpdateRouteResponse -> Bool
$c== :: UpdateRouteResponse -> UpdateRouteResponse -> Bool
Prelude.Eq, ReadPrec [UpdateRouteResponse]
ReadPrec UpdateRouteResponse
Int -> ReadS UpdateRouteResponse
ReadS [UpdateRouteResponse]
(Int -> ReadS UpdateRouteResponse)
-> ReadS [UpdateRouteResponse]
-> ReadPrec UpdateRouteResponse
-> ReadPrec [UpdateRouteResponse]
-> Read UpdateRouteResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateRouteResponse]
$creadListPrec :: ReadPrec [UpdateRouteResponse]
readPrec :: ReadPrec UpdateRouteResponse
$creadPrec :: ReadPrec UpdateRouteResponse
readList :: ReadS [UpdateRouteResponse]
$creadList :: ReadS [UpdateRouteResponse]
readsPrec :: Int -> ReadS UpdateRouteResponse
$creadsPrec :: Int -> ReadS UpdateRouteResponse
Prelude.Read, Int -> UpdateRouteResponse -> ShowS
[UpdateRouteResponse] -> ShowS
UpdateRouteResponse -> String
(Int -> UpdateRouteResponse -> ShowS)
-> (UpdateRouteResponse -> String)
-> ([UpdateRouteResponse] -> ShowS)
-> Show UpdateRouteResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateRouteResponse] -> ShowS
$cshowList :: [UpdateRouteResponse] -> ShowS
show :: UpdateRouteResponse -> String
$cshow :: UpdateRouteResponse -> String
showsPrec :: Int -> UpdateRouteResponse -> ShowS
$cshowsPrec :: Int -> UpdateRouteResponse -> ShowS
Prelude.Show, (forall x. UpdateRouteResponse -> Rep UpdateRouteResponse x)
-> (forall x. Rep UpdateRouteResponse x -> UpdateRouteResponse)
-> Generic UpdateRouteResponse
forall x. Rep UpdateRouteResponse x -> UpdateRouteResponse
forall x. UpdateRouteResponse -> Rep UpdateRouteResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateRouteResponse x -> UpdateRouteResponse
$cfrom :: forall x. UpdateRouteResponse -> Rep UpdateRouteResponse x
Prelude.Generic)

-- |
-- Create a value of 'UpdateRouteResponse' 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:
--
-- 'modelSelectionExpression', 'updateRouteResponse_modelSelectionExpression' - The model selection expression for the route response. Supported only
-- for WebSocket APIs.
--
-- 'responseModels', 'updateRouteResponse_responseModels' - The response models for the route response.
--
-- 'routeResponseKey', 'updateRouteResponse_routeResponseKey' - The route response key.
--
-- 'responseParameters', 'updateRouteResponse_responseParameters' - The route response parameters.
--
-- 'routeResponseId', 'updateRouteResponse_routeResponseId' - The route response ID.
--
-- 'apiId', 'updateRouteResponse_apiId' - The API identifier.
--
-- 'routeId', 'updateRouteResponse_routeId' - The route ID.
newUpdateRouteResponse ::
  -- | 'routeResponseId'
  Prelude.Text ->
  -- | 'apiId'
  Prelude.Text ->
  -- | 'routeId'
  Prelude.Text ->
  UpdateRouteResponse
newUpdateRouteResponse :: Text -> Text -> Text -> UpdateRouteResponse
newUpdateRouteResponse
  Text
pRouteResponseId_
  Text
pApiId_
  Text
pRouteId_ =
    UpdateRouteResponse' :: Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe (HashMap Text ParameterConstraints)
-> Text
-> Text
-> Text
-> UpdateRouteResponse
UpdateRouteResponse'
      { $sel:modelSelectionExpression:UpdateRouteResponse' :: Maybe Text
modelSelectionExpression =
          Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:responseModels:UpdateRouteResponse' :: Maybe (HashMap Text Text)
responseModels = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
        $sel:routeResponseKey:UpdateRouteResponse' :: Maybe Text
routeResponseKey = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:responseParameters:UpdateRouteResponse' :: Maybe (HashMap Text ParameterConstraints)
responseParameters = Maybe (HashMap Text ParameterConstraints)
forall a. Maybe a
Prelude.Nothing,
        $sel:routeResponseId:UpdateRouteResponse' :: Text
routeResponseId = Text
pRouteResponseId_,
        $sel:apiId:UpdateRouteResponse' :: Text
apiId = Text
pApiId_,
        $sel:routeId:UpdateRouteResponse' :: Text
routeId = Text
pRouteId_
      }

-- | The model selection expression for the route response. Supported only
-- for WebSocket APIs.
updateRouteResponse_modelSelectionExpression :: Lens.Lens' UpdateRouteResponse (Prelude.Maybe Prelude.Text)
updateRouteResponse_modelSelectionExpression :: (Maybe Text -> f (Maybe Text))
-> UpdateRouteResponse -> f UpdateRouteResponse
updateRouteResponse_modelSelectionExpression = (UpdateRouteResponse -> Maybe Text)
-> (UpdateRouteResponse -> Maybe Text -> UpdateRouteResponse)
-> Lens
     UpdateRouteResponse UpdateRouteResponse (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRouteResponse' {Maybe Text
modelSelectionExpression :: Maybe Text
$sel:modelSelectionExpression:UpdateRouteResponse' :: UpdateRouteResponse -> Maybe Text
modelSelectionExpression} -> Maybe Text
modelSelectionExpression) (\s :: UpdateRouteResponse
s@UpdateRouteResponse' {} Maybe Text
a -> UpdateRouteResponse
s {$sel:modelSelectionExpression:UpdateRouteResponse' :: Maybe Text
modelSelectionExpression = Maybe Text
a} :: UpdateRouteResponse)

-- | The response models for the route response.
updateRouteResponse_responseModels :: Lens.Lens' UpdateRouteResponse (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
updateRouteResponse_responseModels :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> UpdateRouteResponse -> f UpdateRouteResponse
updateRouteResponse_responseModels = (UpdateRouteResponse -> Maybe (HashMap Text Text))
-> (UpdateRouteResponse
    -> Maybe (HashMap Text Text) -> UpdateRouteResponse)
-> Lens
     UpdateRouteResponse
     UpdateRouteResponse
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRouteResponse' {Maybe (HashMap Text Text)
responseModels :: Maybe (HashMap Text Text)
$sel:responseModels:UpdateRouteResponse' :: UpdateRouteResponse -> Maybe (HashMap Text Text)
responseModels} -> Maybe (HashMap Text Text)
responseModels) (\s :: UpdateRouteResponse
s@UpdateRouteResponse' {} Maybe (HashMap Text Text)
a -> UpdateRouteResponse
s {$sel:responseModels:UpdateRouteResponse' :: Maybe (HashMap Text Text)
responseModels = Maybe (HashMap Text Text)
a} :: UpdateRouteResponse) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
 -> UpdateRouteResponse -> f UpdateRouteResponse)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
    -> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> UpdateRouteResponse
-> f UpdateRouteResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
-> Iso
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
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 AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The route response key.
updateRouteResponse_routeResponseKey :: Lens.Lens' UpdateRouteResponse (Prelude.Maybe Prelude.Text)
updateRouteResponse_routeResponseKey :: (Maybe Text -> f (Maybe Text))
-> UpdateRouteResponse -> f UpdateRouteResponse
updateRouteResponse_routeResponseKey = (UpdateRouteResponse -> Maybe Text)
-> (UpdateRouteResponse -> Maybe Text -> UpdateRouteResponse)
-> Lens
     UpdateRouteResponse UpdateRouteResponse (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRouteResponse' {Maybe Text
routeResponseKey :: Maybe Text
$sel:routeResponseKey:UpdateRouteResponse' :: UpdateRouteResponse -> Maybe Text
routeResponseKey} -> Maybe Text
routeResponseKey) (\s :: UpdateRouteResponse
s@UpdateRouteResponse' {} Maybe Text
a -> UpdateRouteResponse
s {$sel:routeResponseKey:UpdateRouteResponse' :: Maybe Text
routeResponseKey = Maybe Text
a} :: UpdateRouteResponse)

-- | The route response parameters.
updateRouteResponse_responseParameters :: Lens.Lens' UpdateRouteResponse (Prelude.Maybe (Prelude.HashMap Prelude.Text ParameterConstraints))
updateRouteResponse_responseParameters :: (Maybe (HashMap Text ParameterConstraints)
 -> f (Maybe (HashMap Text ParameterConstraints)))
-> UpdateRouteResponse -> f UpdateRouteResponse
updateRouteResponse_responseParameters = (UpdateRouteResponse -> Maybe (HashMap Text ParameterConstraints))
-> (UpdateRouteResponse
    -> Maybe (HashMap Text ParameterConstraints)
    -> UpdateRouteResponse)
-> Lens
     UpdateRouteResponse
     UpdateRouteResponse
     (Maybe (HashMap Text ParameterConstraints))
     (Maybe (HashMap Text ParameterConstraints))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRouteResponse' {Maybe (HashMap Text ParameterConstraints)
responseParameters :: Maybe (HashMap Text ParameterConstraints)
$sel:responseParameters:UpdateRouteResponse' :: UpdateRouteResponse -> Maybe (HashMap Text ParameterConstraints)
responseParameters} -> Maybe (HashMap Text ParameterConstraints)
responseParameters) (\s :: UpdateRouteResponse
s@UpdateRouteResponse' {} Maybe (HashMap Text ParameterConstraints)
a -> UpdateRouteResponse
s {$sel:responseParameters:UpdateRouteResponse' :: Maybe (HashMap Text ParameterConstraints)
responseParameters = Maybe (HashMap Text ParameterConstraints)
a} :: UpdateRouteResponse) ((Maybe (HashMap Text ParameterConstraints)
  -> f (Maybe (HashMap Text ParameterConstraints)))
 -> UpdateRouteResponse -> f UpdateRouteResponse)
-> ((Maybe (HashMap Text ParameterConstraints)
     -> f (Maybe (HashMap Text ParameterConstraints)))
    -> Maybe (HashMap Text ParameterConstraints)
    -> f (Maybe (HashMap Text ParameterConstraints)))
-> (Maybe (HashMap Text ParameterConstraints)
    -> f (Maybe (HashMap Text ParameterConstraints)))
-> UpdateRouteResponse
-> f UpdateRouteResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (HashMap Text ParameterConstraints)
  (HashMap Text ParameterConstraints)
  (HashMap Text ParameterConstraints)
  (HashMap Text ParameterConstraints)
-> Iso
     (Maybe (HashMap Text ParameterConstraints))
     (Maybe (HashMap Text ParameterConstraints))
     (Maybe (HashMap Text ParameterConstraints))
     (Maybe (HashMap Text ParameterConstraints))
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 AnIso
  (HashMap Text ParameterConstraints)
  (HashMap Text ParameterConstraints)
  (HashMap Text ParameterConstraints)
  (HashMap Text ParameterConstraints)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The route response ID.
updateRouteResponse_routeResponseId :: Lens.Lens' UpdateRouteResponse Prelude.Text
updateRouteResponse_routeResponseId :: (Text -> f Text) -> UpdateRouteResponse -> f UpdateRouteResponse
updateRouteResponse_routeResponseId = (UpdateRouteResponse -> Text)
-> (UpdateRouteResponse -> Text -> UpdateRouteResponse)
-> Lens UpdateRouteResponse UpdateRouteResponse Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRouteResponse' {Text
routeResponseId :: Text
$sel:routeResponseId:UpdateRouteResponse' :: UpdateRouteResponse -> Text
routeResponseId} -> Text
routeResponseId) (\s :: UpdateRouteResponse
s@UpdateRouteResponse' {} Text
a -> UpdateRouteResponse
s {$sel:routeResponseId:UpdateRouteResponse' :: Text
routeResponseId = Text
a} :: UpdateRouteResponse)

-- | The API identifier.
updateRouteResponse_apiId :: Lens.Lens' UpdateRouteResponse Prelude.Text
updateRouteResponse_apiId :: (Text -> f Text) -> UpdateRouteResponse -> f UpdateRouteResponse
updateRouteResponse_apiId = (UpdateRouteResponse -> Text)
-> (UpdateRouteResponse -> Text -> UpdateRouteResponse)
-> Lens UpdateRouteResponse UpdateRouteResponse Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRouteResponse' {Text
apiId :: Text
$sel:apiId:UpdateRouteResponse' :: UpdateRouteResponse -> Text
apiId} -> Text
apiId) (\s :: UpdateRouteResponse
s@UpdateRouteResponse' {} Text
a -> UpdateRouteResponse
s {$sel:apiId:UpdateRouteResponse' :: Text
apiId = Text
a} :: UpdateRouteResponse)

-- | The route ID.
updateRouteResponse_routeId :: Lens.Lens' UpdateRouteResponse Prelude.Text
updateRouteResponse_routeId :: (Text -> f Text) -> UpdateRouteResponse -> f UpdateRouteResponse
updateRouteResponse_routeId = (UpdateRouteResponse -> Text)
-> (UpdateRouteResponse -> Text -> UpdateRouteResponse)
-> Lens UpdateRouteResponse UpdateRouteResponse Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRouteResponse' {Text
routeId :: Text
$sel:routeId:UpdateRouteResponse' :: UpdateRouteResponse -> Text
routeId} -> Text
routeId) (\s :: UpdateRouteResponse
s@UpdateRouteResponse' {} Text
a -> UpdateRouteResponse
s {$sel:routeId:UpdateRouteResponse' :: Text
routeId = Text
a} :: UpdateRouteResponse)

instance Core.AWSRequest UpdateRouteResponse where
  type
    AWSResponse UpdateRouteResponse =
      UpdateRouteResponseResponse
  request :: UpdateRouteResponse -> Request UpdateRouteResponse
request = Service -> UpdateRouteResponse -> Request UpdateRouteResponse
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.patchJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy UpdateRouteResponse
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse UpdateRouteResponse)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse UpdateRouteResponse))
-> Logger
-> Service
-> Proxy UpdateRouteResponse
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse UpdateRouteResponse)))
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
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text ParameterConstraints)
-> Int
-> UpdateRouteResponseResponse
UpdateRouteResponseResponse'
            (Maybe Text
 -> Maybe (HashMap Text Text)
 -> Maybe Text
 -> Maybe Text
 -> Maybe (HashMap Text ParameterConstraints)
 -> Int
 -> UpdateRouteResponseResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text ParameterConstraints)
      -> Int
      -> UpdateRouteResponseResponse)
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
"modelSelectionExpression")
            Either
  String
  (Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text ParameterConstraints)
   -> Int
   -> UpdateRouteResponseResponse)
-> Either String (Maybe (HashMap Text Text))
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text ParameterConstraints)
      -> Int
      -> UpdateRouteResponseResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe (Maybe (HashMap Text Text)))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"responseModels" Either String (Maybe (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text)
-> Either String (Maybe (HashMap Text Text))
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe (HashMap Text Text)
forall a. Monoid a => a
Prelude.mempty)
            Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text ParameterConstraints)
   -> Int
   -> UpdateRouteResponseResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe (HashMap Text ParameterConstraints)
      -> Int
      -> UpdateRouteResponseResponse)
forall (f :: * -> *) a b. Applicative f => 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
"routeResponseId")
            Either
  String
  (Maybe Text
   -> Maybe (HashMap Text ParameterConstraints)
   -> Int
   -> UpdateRouteResponseResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe (HashMap Text ParameterConstraints)
      -> Int -> UpdateRouteResponseResponse)
forall (f :: * -> *) a b. Applicative f => 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
"routeResponseKey")
            Either
  String
  (Maybe (HashMap Text ParameterConstraints)
   -> Int -> UpdateRouteResponseResponse)
-> Either String (Maybe (HashMap Text ParameterConstraints))
-> Either String (Int -> UpdateRouteResponseResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object
-> Text
-> Either
     String (Maybe (Maybe (HashMap Text ParameterConstraints)))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"responseParameters"
                            Either String (Maybe (Maybe (HashMap Text ParameterConstraints)))
-> Maybe (HashMap Text ParameterConstraints)
-> Either String (Maybe (HashMap Text ParameterConstraints))
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe (HashMap Text ParameterConstraints)
forall a. Monoid a => a
Prelude.mempty
                        )
            Either String (Int -> UpdateRouteResponseResponse)
-> Either String Int -> Either String UpdateRouteResponseResponse
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 UpdateRouteResponse

instance Prelude.NFData UpdateRouteResponse

instance Core.ToHeaders UpdateRouteResponse where
  toHeaders :: UpdateRouteResponse -> ResponseHeaders
toHeaders =
    ResponseHeaders -> UpdateRouteResponse -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
      ( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ 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 UpdateRouteResponse where
  toJSON :: UpdateRouteResponse -> Value
toJSON UpdateRouteResponse' {Maybe Text
Maybe (HashMap Text Text)
Maybe (HashMap Text ParameterConstraints)
Text
routeId :: Text
apiId :: Text
routeResponseId :: Text
responseParameters :: Maybe (HashMap Text ParameterConstraints)
routeResponseKey :: Maybe Text
responseModels :: Maybe (HashMap Text Text)
modelSelectionExpression :: Maybe Text
$sel:routeId:UpdateRouteResponse' :: UpdateRouteResponse -> Text
$sel:apiId:UpdateRouteResponse' :: UpdateRouteResponse -> Text
$sel:routeResponseId:UpdateRouteResponse' :: UpdateRouteResponse -> Text
$sel:responseParameters:UpdateRouteResponse' :: UpdateRouteResponse -> Maybe (HashMap Text ParameterConstraints)
$sel:routeResponseKey:UpdateRouteResponse' :: UpdateRouteResponse -> Maybe Text
$sel:responseModels:UpdateRouteResponse' :: UpdateRouteResponse -> Maybe (HashMap Text Text)
$sel:modelSelectionExpression:UpdateRouteResponse' :: UpdateRouteResponse -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"modelSelectionExpression" 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
modelSelectionExpression,
            (Text
"responseModels" Text -> HashMap Text Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (HashMap Text Text -> Pair)
-> Maybe (HashMap Text Text) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (HashMap Text Text)
responseModels,
            (Text
"routeResponseKey" 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
routeResponseKey,
            (Text
"responseParameters" Text -> HashMap Text ParameterConstraints -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (HashMap Text ParameterConstraints -> Pair)
-> Maybe (HashMap Text ParameterConstraints) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (HashMap Text ParameterConstraints)
responseParameters
          ]
      )

instance Core.ToPath UpdateRouteResponse where
  toPath :: UpdateRouteResponse -> ByteString
toPath UpdateRouteResponse' {Maybe Text
Maybe (HashMap Text Text)
Maybe (HashMap Text ParameterConstraints)
Text
routeId :: Text
apiId :: Text
routeResponseId :: Text
responseParameters :: Maybe (HashMap Text ParameterConstraints)
routeResponseKey :: Maybe Text
responseModels :: Maybe (HashMap Text Text)
modelSelectionExpression :: Maybe Text
$sel:routeId:UpdateRouteResponse' :: UpdateRouteResponse -> Text
$sel:apiId:UpdateRouteResponse' :: UpdateRouteResponse -> Text
$sel:routeResponseId:UpdateRouteResponse' :: UpdateRouteResponse -> Text
$sel:responseParameters:UpdateRouteResponse' :: UpdateRouteResponse -> Maybe (HashMap Text ParameterConstraints)
$sel:routeResponseKey:UpdateRouteResponse' :: UpdateRouteResponse -> Maybe Text
$sel:responseModels:UpdateRouteResponse' :: UpdateRouteResponse -> Maybe (HashMap Text Text)
$sel:modelSelectionExpression:UpdateRouteResponse' :: UpdateRouteResponse -> Maybe Text
..} =
    [ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"/v2/apis/",
        Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
apiId,
        ByteString
"/routes/",
        Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
routeId,
        ByteString
"/routeresponses/",
        Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
routeResponseId
      ]

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

-- | /See:/ 'newUpdateRouteResponseResponse' smart constructor.
data UpdateRouteResponseResponse = UpdateRouteResponseResponse'
  { -- | Represents the model selection expression of a route response. Supported
    -- only for WebSocket APIs.
    UpdateRouteResponseResponse -> Maybe Text
modelSelectionExpression :: Prelude.Maybe Prelude.Text,
    -- | Represents the response models of a route response.
    UpdateRouteResponseResponse -> Maybe (HashMap Text Text)
responseModels :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
    -- | Represents the identifier of a route response.
    UpdateRouteResponseResponse -> Maybe Text
routeResponseId :: Prelude.Maybe Prelude.Text,
    -- | Represents the route response key of a route response.
    UpdateRouteResponseResponse -> Maybe Text
routeResponseKey :: Prelude.Maybe Prelude.Text,
    -- | Represents the response parameters of a route response.
    UpdateRouteResponseResponse
-> Maybe (HashMap Text ParameterConstraints)
responseParameters :: Prelude.Maybe (Prelude.HashMap Prelude.Text ParameterConstraints),
    -- | The response's http status code.
    UpdateRouteResponseResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (UpdateRouteResponseResponse -> UpdateRouteResponseResponse -> Bool
(UpdateRouteResponseResponse
 -> UpdateRouteResponseResponse -> Bool)
-> (UpdateRouteResponseResponse
    -> UpdateRouteResponseResponse -> Bool)
-> Eq UpdateRouteResponseResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateRouteResponseResponse -> UpdateRouteResponseResponse -> Bool
$c/= :: UpdateRouteResponseResponse -> UpdateRouteResponseResponse -> Bool
== :: UpdateRouteResponseResponse -> UpdateRouteResponseResponse -> Bool
$c== :: UpdateRouteResponseResponse -> UpdateRouteResponseResponse -> Bool
Prelude.Eq, ReadPrec [UpdateRouteResponseResponse]
ReadPrec UpdateRouteResponseResponse
Int -> ReadS UpdateRouteResponseResponse
ReadS [UpdateRouteResponseResponse]
(Int -> ReadS UpdateRouteResponseResponse)
-> ReadS [UpdateRouteResponseResponse]
-> ReadPrec UpdateRouteResponseResponse
-> ReadPrec [UpdateRouteResponseResponse]
-> Read UpdateRouteResponseResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateRouteResponseResponse]
$creadListPrec :: ReadPrec [UpdateRouteResponseResponse]
readPrec :: ReadPrec UpdateRouteResponseResponse
$creadPrec :: ReadPrec UpdateRouteResponseResponse
readList :: ReadS [UpdateRouteResponseResponse]
$creadList :: ReadS [UpdateRouteResponseResponse]
readsPrec :: Int -> ReadS UpdateRouteResponseResponse
$creadsPrec :: Int -> ReadS UpdateRouteResponseResponse
Prelude.Read, Int -> UpdateRouteResponseResponse -> ShowS
[UpdateRouteResponseResponse] -> ShowS
UpdateRouteResponseResponse -> String
(Int -> UpdateRouteResponseResponse -> ShowS)
-> (UpdateRouteResponseResponse -> String)
-> ([UpdateRouteResponseResponse] -> ShowS)
-> Show UpdateRouteResponseResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateRouteResponseResponse] -> ShowS
$cshowList :: [UpdateRouteResponseResponse] -> ShowS
show :: UpdateRouteResponseResponse -> String
$cshow :: UpdateRouteResponseResponse -> String
showsPrec :: Int -> UpdateRouteResponseResponse -> ShowS
$cshowsPrec :: Int -> UpdateRouteResponseResponse -> ShowS
Prelude.Show, (forall x.
 UpdateRouteResponseResponse -> Rep UpdateRouteResponseResponse x)
-> (forall x.
    Rep UpdateRouteResponseResponse x -> UpdateRouteResponseResponse)
-> Generic UpdateRouteResponseResponse
forall x.
Rep UpdateRouteResponseResponse x -> UpdateRouteResponseResponse
forall x.
UpdateRouteResponseResponse -> Rep UpdateRouteResponseResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep UpdateRouteResponseResponse x -> UpdateRouteResponseResponse
$cfrom :: forall x.
UpdateRouteResponseResponse -> Rep UpdateRouteResponseResponse x
Prelude.Generic)

-- |
-- Create a value of 'UpdateRouteResponseResponse' 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:
--
-- 'modelSelectionExpression', 'updateRouteResponseResponse_modelSelectionExpression' - Represents the model selection expression of a route response. Supported
-- only for WebSocket APIs.
--
-- 'responseModels', 'updateRouteResponseResponse_responseModels' - Represents the response models of a route response.
--
-- 'routeResponseId', 'updateRouteResponseResponse_routeResponseId' - Represents the identifier of a route response.
--
-- 'routeResponseKey', 'updateRouteResponseResponse_routeResponseKey' - Represents the route response key of a route response.
--
-- 'responseParameters', 'updateRouteResponseResponse_responseParameters' - Represents the response parameters of a route response.
--
-- 'httpStatus', 'updateRouteResponseResponse_httpStatus' - The response's http status code.
newUpdateRouteResponseResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  UpdateRouteResponseResponse
newUpdateRouteResponseResponse :: Int -> UpdateRouteResponseResponse
newUpdateRouteResponseResponse Int
pHttpStatus_ =
  UpdateRouteResponseResponse' :: Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text ParameterConstraints)
-> Int
-> UpdateRouteResponseResponse
UpdateRouteResponseResponse'
    { $sel:modelSelectionExpression:UpdateRouteResponseResponse' :: Maybe Text
modelSelectionExpression =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:responseModels:UpdateRouteResponseResponse' :: Maybe (HashMap Text Text)
responseModels = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
      $sel:routeResponseId:UpdateRouteResponseResponse' :: Maybe Text
routeResponseId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:routeResponseKey:UpdateRouteResponseResponse' :: Maybe Text
routeResponseKey = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:responseParameters:UpdateRouteResponseResponse' :: Maybe (HashMap Text ParameterConstraints)
responseParameters = Maybe (HashMap Text ParameterConstraints)
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:UpdateRouteResponseResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | Represents the model selection expression of a route response. Supported
-- only for WebSocket APIs.
updateRouteResponseResponse_modelSelectionExpression :: Lens.Lens' UpdateRouteResponseResponse (Prelude.Maybe Prelude.Text)
updateRouteResponseResponse_modelSelectionExpression :: (Maybe Text -> f (Maybe Text))
-> UpdateRouteResponseResponse -> f UpdateRouteResponseResponse
updateRouteResponseResponse_modelSelectionExpression = (UpdateRouteResponseResponse -> Maybe Text)
-> (UpdateRouteResponseResponse
    -> Maybe Text -> UpdateRouteResponseResponse)
-> Lens
     UpdateRouteResponseResponse
     UpdateRouteResponseResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRouteResponseResponse' {Maybe Text
modelSelectionExpression :: Maybe Text
$sel:modelSelectionExpression:UpdateRouteResponseResponse' :: UpdateRouteResponseResponse -> Maybe Text
modelSelectionExpression} -> Maybe Text
modelSelectionExpression) (\s :: UpdateRouteResponseResponse
s@UpdateRouteResponseResponse' {} Maybe Text
a -> UpdateRouteResponseResponse
s {$sel:modelSelectionExpression:UpdateRouteResponseResponse' :: Maybe Text
modelSelectionExpression = Maybe Text
a} :: UpdateRouteResponseResponse)

-- | Represents the response models of a route response.
updateRouteResponseResponse_responseModels :: Lens.Lens' UpdateRouteResponseResponse (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
updateRouteResponseResponse_responseModels :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> UpdateRouteResponseResponse -> f UpdateRouteResponseResponse
updateRouteResponseResponse_responseModels = (UpdateRouteResponseResponse -> Maybe (HashMap Text Text))
-> (UpdateRouteResponseResponse
    -> Maybe (HashMap Text Text) -> UpdateRouteResponseResponse)
-> Lens
     UpdateRouteResponseResponse
     UpdateRouteResponseResponse
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRouteResponseResponse' {Maybe (HashMap Text Text)
responseModels :: Maybe (HashMap Text Text)
$sel:responseModels:UpdateRouteResponseResponse' :: UpdateRouteResponseResponse -> Maybe (HashMap Text Text)
responseModels} -> Maybe (HashMap Text Text)
responseModels) (\s :: UpdateRouteResponseResponse
s@UpdateRouteResponseResponse' {} Maybe (HashMap Text Text)
a -> UpdateRouteResponseResponse
s {$sel:responseModels:UpdateRouteResponseResponse' :: Maybe (HashMap Text Text)
responseModels = Maybe (HashMap Text Text)
a} :: UpdateRouteResponseResponse) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
 -> UpdateRouteResponseResponse -> f UpdateRouteResponseResponse)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
    -> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> UpdateRouteResponseResponse
-> f UpdateRouteResponseResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
-> Iso
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
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 AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Represents the identifier of a route response.
updateRouteResponseResponse_routeResponseId :: Lens.Lens' UpdateRouteResponseResponse (Prelude.Maybe Prelude.Text)
updateRouteResponseResponse_routeResponseId :: (Maybe Text -> f (Maybe Text))
-> UpdateRouteResponseResponse -> f UpdateRouteResponseResponse
updateRouteResponseResponse_routeResponseId = (UpdateRouteResponseResponse -> Maybe Text)
-> (UpdateRouteResponseResponse
    -> Maybe Text -> UpdateRouteResponseResponse)
-> Lens
     UpdateRouteResponseResponse
     UpdateRouteResponseResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRouteResponseResponse' {Maybe Text
routeResponseId :: Maybe Text
$sel:routeResponseId:UpdateRouteResponseResponse' :: UpdateRouteResponseResponse -> Maybe Text
routeResponseId} -> Maybe Text
routeResponseId) (\s :: UpdateRouteResponseResponse
s@UpdateRouteResponseResponse' {} Maybe Text
a -> UpdateRouteResponseResponse
s {$sel:routeResponseId:UpdateRouteResponseResponse' :: Maybe Text
routeResponseId = Maybe Text
a} :: UpdateRouteResponseResponse)

-- | Represents the route response key of a route response.
updateRouteResponseResponse_routeResponseKey :: Lens.Lens' UpdateRouteResponseResponse (Prelude.Maybe Prelude.Text)
updateRouteResponseResponse_routeResponseKey :: (Maybe Text -> f (Maybe Text))
-> UpdateRouteResponseResponse -> f UpdateRouteResponseResponse
updateRouteResponseResponse_routeResponseKey = (UpdateRouteResponseResponse -> Maybe Text)
-> (UpdateRouteResponseResponse
    -> Maybe Text -> UpdateRouteResponseResponse)
-> Lens
     UpdateRouteResponseResponse
     UpdateRouteResponseResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRouteResponseResponse' {Maybe Text
routeResponseKey :: Maybe Text
$sel:routeResponseKey:UpdateRouteResponseResponse' :: UpdateRouteResponseResponse -> Maybe Text
routeResponseKey} -> Maybe Text
routeResponseKey) (\s :: UpdateRouteResponseResponse
s@UpdateRouteResponseResponse' {} Maybe Text
a -> UpdateRouteResponseResponse
s {$sel:routeResponseKey:UpdateRouteResponseResponse' :: Maybe Text
routeResponseKey = Maybe Text
a} :: UpdateRouteResponseResponse)

-- | Represents the response parameters of a route response.
updateRouteResponseResponse_responseParameters :: Lens.Lens' UpdateRouteResponseResponse (Prelude.Maybe (Prelude.HashMap Prelude.Text ParameterConstraints))
updateRouteResponseResponse_responseParameters :: (Maybe (HashMap Text ParameterConstraints)
 -> f (Maybe (HashMap Text ParameterConstraints)))
-> UpdateRouteResponseResponse -> f UpdateRouteResponseResponse
updateRouteResponseResponse_responseParameters = (UpdateRouteResponseResponse
 -> Maybe (HashMap Text ParameterConstraints))
-> (UpdateRouteResponseResponse
    -> Maybe (HashMap Text ParameterConstraints)
    -> UpdateRouteResponseResponse)
-> Lens
     UpdateRouteResponseResponse
     UpdateRouteResponseResponse
     (Maybe (HashMap Text ParameterConstraints))
     (Maybe (HashMap Text ParameterConstraints))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRouteResponseResponse' {Maybe (HashMap Text ParameterConstraints)
responseParameters :: Maybe (HashMap Text ParameterConstraints)
$sel:responseParameters:UpdateRouteResponseResponse' :: UpdateRouteResponseResponse
-> Maybe (HashMap Text ParameterConstraints)
responseParameters} -> Maybe (HashMap Text ParameterConstraints)
responseParameters) (\s :: UpdateRouteResponseResponse
s@UpdateRouteResponseResponse' {} Maybe (HashMap Text ParameterConstraints)
a -> UpdateRouteResponseResponse
s {$sel:responseParameters:UpdateRouteResponseResponse' :: Maybe (HashMap Text ParameterConstraints)
responseParameters = Maybe (HashMap Text ParameterConstraints)
a} :: UpdateRouteResponseResponse) ((Maybe (HashMap Text ParameterConstraints)
  -> f (Maybe (HashMap Text ParameterConstraints)))
 -> UpdateRouteResponseResponse -> f UpdateRouteResponseResponse)
-> ((Maybe (HashMap Text ParameterConstraints)
     -> f (Maybe (HashMap Text ParameterConstraints)))
    -> Maybe (HashMap Text ParameterConstraints)
    -> f (Maybe (HashMap Text ParameterConstraints)))
-> (Maybe (HashMap Text ParameterConstraints)
    -> f (Maybe (HashMap Text ParameterConstraints)))
-> UpdateRouteResponseResponse
-> f UpdateRouteResponseResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (HashMap Text ParameterConstraints)
  (HashMap Text ParameterConstraints)
  (HashMap Text ParameterConstraints)
  (HashMap Text ParameterConstraints)
-> Iso
     (Maybe (HashMap Text ParameterConstraints))
     (Maybe (HashMap Text ParameterConstraints))
     (Maybe (HashMap Text ParameterConstraints))
     (Maybe (HashMap Text ParameterConstraints))
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 AnIso
  (HashMap Text ParameterConstraints)
  (HashMap Text ParameterConstraints)
  (HashMap Text ParameterConstraints)
  (HashMap Text ParameterConstraints)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

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

instance Prelude.NFData UpdateRouteResponseResponse