{-# 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.NetworkManager.UpdateLink
-- 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 the details for an existing link. To remove information for any
-- of the parameters, specify an empty string.
module Amazonka.NetworkManager.UpdateLink
  ( -- * Creating a Request
    UpdateLink (..),
    newUpdateLink,

    -- * Request Lenses
    updateLink_bandwidth,
    updateLink_type,
    updateLink_description,
    updateLink_provider,
    updateLink_globalNetworkId,
    updateLink_linkId,

    -- * Destructuring the Response
    UpdateLinkResponse (..),
    newUpdateLinkResponse,

    -- * Response Lenses
    updateLinkResponse_link,
    updateLinkResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.NetworkManager.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newUpdateLink' smart constructor.
data UpdateLink = UpdateLink'
  { -- | The upload and download speed in Mbps.
    UpdateLink -> Maybe Bandwidth
bandwidth :: Prelude.Maybe Bandwidth,
    -- | The type of the link.
    --
    -- Length Constraints: Maximum length of 128 characters.
    UpdateLink -> Maybe Text
type' :: Prelude.Maybe Prelude.Text,
    -- | A description of the link.
    --
    -- Length Constraints: Maximum length of 256 characters.
    UpdateLink -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    -- | The provider of the link.
    --
    -- Length Constraints: Maximum length of 128 characters.
    UpdateLink -> Maybe Text
provider :: Prelude.Maybe Prelude.Text,
    -- | The ID of the global network.
    UpdateLink -> Text
globalNetworkId :: Prelude.Text,
    -- | The ID of the link.
    UpdateLink -> Text
linkId :: Prelude.Text
  }
  deriving (UpdateLink -> UpdateLink -> Bool
(UpdateLink -> UpdateLink -> Bool)
-> (UpdateLink -> UpdateLink -> Bool) -> Eq UpdateLink
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateLink -> UpdateLink -> Bool
$c/= :: UpdateLink -> UpdateLink -> Bool
== :: UpdateLink -> UpdateLink -> Bool
$c== :: UpdateLink -> UpdateLink -> Bool
Prelude.Eq, ReadPrec [UpdateLink]
ReadPrec UpdateLink
Int -> ReadS UpdateLink
ReadS [UpdateLink]
(Int -> ReadS UpdateLink)
-> ReadS [UpdateLink]
-> ReadPrec UpdateLink
-> ReadPrec [UpdateLink]
-> Read UpdateLink
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateLink]
$creadListPrec :: ReadPrec [UpdateLink]
readPrec :: ReadPrec UpdateLink
$creadPrec :: ReadPrec UpdateLink
readList :: ReadS [UpdateLink]
$creadList :: ReadS [UpdateLink]
readsPrec :: Int -> ReadS UpdateLink
$creadsPrec :: Int -> ReadS UpdateLink
Prelude.Read, Int -> UpdateLink -> ShowS
[UpdateLink] -> ShowS
UpdateLink -> String
(Int -> UpdateLink -> ShowS)
-> (UpdateLink -> String)
-> ([UpdateLink] -> ShowS)
-> Show UpdateLink
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateLink] -> ShowS
$cshowList :: [UpdateLink] -> ShowS
show :: UpdateLink -> String
$cshow :: UpdateLink -> String
showsPrec :: Int -> UpdateLink -> ShowS
$cshowsPrec :: Int -> UpdateLink -> ShowS
Prelude.Show, (forall x. UpdateLink -> Rep UpdateLink x)
-> (forall x. Rep UpdateLink x -> UpdateLink) -> Generic UpdateLink
forall x. Rep UpdateLink x -> UpdateLink
forall x. UpdateLink -> Rep UpdateLink x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateLink x -> UpdateLink
$cfrom :: forall x. UpdateLink -> Rep UpdateLink x
Prelude.Generic)

-- |
-- Create a value of 'UpdateLink' 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:
--
-- 'bandwidth', 'updateLink_bandwidth' - The upload and download speed in Mbps.
--
-- 'type'', 'updateLink_type' - The type of the link.
--
-- Length Constraints: Maximum length of 128 characters.
--
-- 'description', 'updateLink_description' - A description of the link.
--
-- Length Constraints: Maximum length of 256 characters.
--
-- 'provider', 'updateLink_provider' - The provider of the link.
--
-- Length Constraints: Maximum length of 128 characters.
--
-- 'globalNetworkId', 'updateLink_globalNetworkId' - The ID of the global network.
--
-- 'linkId', 'updateLink_linkId' - The ID of the link.
newUpdateLink ::
  -- | 'globalNetworkId'
  Prelude.Text ->
  -- | 'linkId'
  Prelude.Text ->
  UpdateLink
newUpdateLink :: Text -> Text -> UpdateLink
newUpdateLink Text
pGlobalNetworkId_ Text
pLinkId_ =
  UpdateLink' :: Maybe Bandwidth
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Text
-> Text
-> UpdateLink
UpdateLink'
    { $sel:bandwidth:UpdateLink' :: Maybe Bandwidth
bandwidth = Maybe Bandwidth
forall a. Maybe a
Prelude.Nothing,
      $sel:type':UpdateLink' :: Maybe Text
type' = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:description:UpdateLink' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:provider:UpdateLink' :: Maybe Text
provider = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:globalNetworkId:UpdateLink' :: Text
globalNetworkId = Text
pGlobalNetworkId_,
      $sel:linkId:UpdateLink' :: Text
linkId = Text
pLinkId_
    }

-- | The upload and download speed in Mbps.
updateLink_bandwidth :: Lens.Lens' UpdateLink (Prelude.Maybe Bandwidth)
updateLink_bandwidth :: (Maybe Bandwidth -> f (Maybe Bandwidth))
-> UpdateLink -> f UpdateLink
updateLink_bandwidth = (UpdateLink -> Maybe Bandwidth)
-> (UpdateLink -> Maybe Bandwidth -> UpdateLink)
-> Lens UpdateLink UpdateLink (Maybe Bandwidth) (Maybe Bandwidth)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateLink' {Maybe Bandwidth
bandwidth :: Maybe Bandwidth
$sel:bandwidth:UpdateLink' :: UpdateLink -> Maybe Bandwidth
bandwidth} -> Maybe Bandwidth
bandwidth) (\s :: UpdateLink
s@UpdateLink' {} Maybe Bandwidth
a -> UpdateLink
s {$sel:bandwidth:UpdateLink' :: Maybe Bandwidth
bandwidth = Maybe Bandwidth
a} :: UpdateLink)

-- | The type of the link.
--
-- Length Constraints: Maximum length of 128 characters.
updateLink_type :: Lens.Lens' UpdateLink (Prelude.Maybe Prelude.Text)
updateLink_type :: (Maybe Text -> f (Maybe Text)) -> UpdateLink -> f UpdateLink
updateLink_type = (UpdateLink -> Maybe Text)
-> (UpdateLink -> Maybe Text -> UpdateLink)
-> Lens UpdateLink UpdateLink (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateLink' {Maybe Text
type' :: Maybe Text
$sel:type':UpdateLink' :: UpdateLink -> Maybe Text
type'} -> Maybe Text
type') (\s :: UpdateLink
s@UpdateLink' {} Maybe Text
a -> UpdateLink
s {$sel:type':UpdateLink' :: Maybe Text
type' = Maybe Text
a} :: UpdateLink)

-- | A description of the link.
--
-- Length Constraints: Maximum length of 256 characters.
updateLink_description :: Lens.Lens' UpdateLink (Prelude.Maybe Prelude.Text)
updateLink_description :: (Maybe Text -> f (Maybe Text)) -> UpdateLink -> f UpdateLink
updateLink_description = (UpdateLink -> Maybe Text)
-> (UpdateLink -> Maybe Text -> UpdateLink)
-> Lens UpdateLink UpdateLink (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateLink' {Maybe Text
description :: Maybe Text
$sel:description:UpdateLink' :: UpdateLink -> Maybe Text
description} -> Maybe Text
description) (\s :: UpdateLink
s@UpdateLink' {} Maybe Text
a -> UpdateLink
s {$sel:description:UpdateLink' :: Maybe Text
description = Maybe Text
a} :: UpdateLink)

-- | The provider of the link.
--
-- Length Constraints: Maximum length of 128 characters.
updateLink_provider :: Lens.Lens' UpdateLink (Prelude.Maybe Prelude.Text)
updateLink_provider :: (Maybe Text -> f (Maybe Text)) -> UpdateLink -> f UpdateLink
updateLink_provider = (UpdateLink -> Maybe Text)
-> (UpdateLink -> Maybe Text -> UpdateLink)
-> Lens UpdateLink UpdateLink (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateLink' {Maybe Text
provider :: Maybe Text
$sel:provider:UpdateLink' :: UpdateLink -> Maybe Text
provider} -> Maybe Text
provider) (\s :: UpdateLink
s@UpdateLink' {} Maybe Text
a -> UpdateLink
s {$sel:provider:UpdateLink' :: Maybe Text
provider = Maybe Text
a} :: UpdateLink)

-- | The ID of the global network.
updateLink_globalNetworkId :: Lens.Lens' UpdateLink Prelude.Text
updateLink_globalNetworkId :: (Text -> f Text) -> UpdateLink -> f UpdateLink
updateLink_globalNetworkId = (UpdateLink -> Text)
-> (UpdateLink -> Text -> UpdateLink)
-> Lens UpdateLink UpdateLink Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateLink' {Text
globalNetworkId :: Text
$sel:globalNetworkId:UpdateLink' :: UpdateLink -> Text
globalNetworkId} -> Text
globalNetworkId) (\s :: UpdateLink
s@UpdateLink' {} Text
a -> UpdateLink
s {$sel:globalNetworkId:UpdateLink' :: Text
globalNetworkId = Text
a} :: UpdateLink)

-- | The ID of the link.
updateLink_linkId :: Lens.Lens' UpdateLink Prelude.Text
updateLink_linkId :: (Text -> f Text) -> UpdateLink -> f UpdateLink
updateLink_linkId = (UpdateLink -> Text)
-> (UpdateLink -> Text -> UpdateLink)
-> Lens UpdateLink UpdateLink Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateLink' {Text
linkId :: Text
$sel:linkId:UpdateLink' :: UpdateLink -> Text
linkId} -> Text
linkId) (\s :: UpdateLink
s@UpdateLink' {} Text
a -> UpdateLink
s {$sel:linkId:UpdateLink' :: Text
linkId = Text
a} :: UpdateLink)

instance Core.AWSRequest UpdateLink where
  type AWSResponse UpdateLink = UpdateLinkResponse
  request :: UpdateLink -> Request UpdateLink
request = Service -> UpdateLink -> Request UpdateLink
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.patchJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy UpdateLink
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse UpdateLink)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse UpdateLink))
-> Logger
-> Service
-> Proxy UpdateLink
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse UpdateLink)))
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 Link -> Int -> UpdateLinkResponse
UpdateLinkResponse'
            (Maybe Link -> Int -> UpdateLinkResponse)
-> Either String (Maybe Link)
-> Either String (Int -> UpdateLinkResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe Link)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Link")
            Either String (Int -> UpdateLinkResponse)
-> Either String Int -> Either String UpdateLinkResponse
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 UpdateLink

instance Prelude.NFData UpdateLink

instance Core.ToHeaders UpdateLink where
  toHeaders :: UpdateLink -> ResponseHeaders
toHeaders =
    ResponseHeaders -> UpdateLink -> 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 UpdateLink where
  toJSON :: UpdateLink -> Value
toJSON UpdateLink' {Maybe Text
Maybe Bandwidth
Text
linkId :: Text
globalNetworkId :: Text
provider :: Maybe Text
description :: Maybe Text
type' :: Maybe Text
bandwidth :: Maybe Bandwidth
$sel:linkId:UpdateLink' :: UpdateLink -> Text
$sel:globalNetworkId:UpdateLink' :: UpdateLink -> Text
$sel:provider:UpdateLink' :: UpdateLink -> Maybe Text
$sel:description:UpdateLink' :: UpdateLink -> Maybe Text
$sel:type':UpdateLink' :: UpdateLink -> Maybe Text
$sel:bandwidth:UpdateLink' :: UpdateLink -> Maybe Bandwidth
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"Bandwidth" Text -> Bandwidth -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Bandwidth -> Pair) -> Maybe Bandwidth -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bandwidth
bandwidth,
            (Text
"Type" 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
type',
            (Text
"Description" 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
description,
            (Text
"Provider" 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
provider
          ]
      )

instance Core.ToPath UpdateLink where
  toPath :: UpdateLink -> ByteString
toPath UpdateLink' {Maybe Text
Maybe Bandwidth
Text
linkId :: Text
globalNetworkId :: Text
provider :: Maybe Text
description :: Maybe Text
type' :: Maybe Text
bandwidth :: Maybe Bandwidth
$sel:linkId:UpdateLink' :: UpdateLink -> Text
$sel:globalNetworkId:UpdateLink' :: UpdateLink -> Text
$sel:provider:UpdateLink' :: UpdateLink -> Maybe Text
$sel:description:UpdateLink' :: UpdateLink -> Maybe Text
$sel:type':UpdateLink' :: UpdateLink -> Maybe Text
$sel:bandwidth:UpdateLink' :: UpdateLink -> Maybe Bandwidth
..} =
    [ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"/global-networks/",
        Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
globalNetworkId,
        ByteString
"/links/",
        Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
linkId
      ]

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

-- | /See:/ 'newUpdateLinkResponse' smart constructor.
data UpdateLinkResponse = UpdateLinkResponse'
  { -- | Information about the link.
    UpdateLinkResponse -> Maybe Link
link :: Prelude.Maybe Link,
    -- | The response's http status code.
    UpdateLinkResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (UpdateLinkResponse -> UpdateLinkResponse -> Bool
(UpdateLinkResponse -> UpdateLinkResponse -> Bool)
-> (UpdateLinkResponse -> UpdateLinkResponse -> Bool)
-> Eq UpdateLinkResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateLinkResponse -> UpdateLinkResponse -> Bool
$c/= :: UpdateLinkResponse -> UpdateLinkResponse -> Bool
== :: UpdateLinkResponse -> UpdateLinkResponse -> Bool
$c== :: UpdateLinkResponse -> UpdateLinkResponse -> Bool
Prelude.Eq, ReadPrec [UpdateLinkResponse]
ReadPrec UpdateLinkResponse
Int -> ReadS UpdateLinkResponse
ReadS [UpdateLinkResponse]
(Int -> ReadS UpdateLinkResponse)
-> ReadS [UpdateLinkResponse]
-> ReadPrec UpdateLinkResponse
-> ReadPrec [UpdateLinkResponse]
-> Read UpdateLinkResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateLinkResponse]
$creadListPrec :: ReadPrec [UpdateLinkResponse]
readPrec :: ReadPrec UpdateLinkResponse
$creadPrec :: ReadPrec UpdateLinkResponse
readList :: ReadS [UpdateLinkResponse]
$creadList :: ReadS [UpdateLinkResponse]
readsPrec :: Int -> ReadS UpdateLinkResponse
$creadsPrec :: Int -> ReadS UpdateLinkResponse
Prelude.Read, Int -> UpdateLinkResponse -> ShowS
[UpdateLinkResponse] -> ShowS
UpdateLinkResponse -> String
(Int -> UpdateLinkResponse -> ShowS)
-> (UpdateLinkResponse -> String)
-> ([UpdateLinkResponse] -> ShowS)
-> Show UpdateLinkResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateLinkResponse] -> ShowS
$cshowList :: [UpdateLinkResponse] -> ShowS
show :: UpdateLinkResponse -> String
$cshow :: UpdateLinkResponse -> String
showsPrec :: Int -> UpdateLinkResponse -> ShowS
$cshowsPrec :: Int -> UpdateLinkResponse -> ShowS
Prelude.Show, (forall x. UpdateLinkResponse -> Rep UpdateLinkResponse x)
-> (forall x. Rep UpdateLinkResponse x -> UpdateLinkResponse)
-> Generic UpdateLinkResponse
forall x. Rep UpdateLinkResponse x -> UpdateLinkResponse
forall x. UpdateLinkResponse -> Rep UpdateLinkResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateLinkResponse x -> UpdateLinkResponse
$cfrom :: forall x. UpdateLinkResponse -> Rep UpdateLinkResponse x
Prelude.Generic)

-- |
-- Create a value of 'UpdateLinkResponse' 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:
--
-- 'link', 'updateLinkResponse_link' - Information about the link.
--
-- 'httpStatus', 'updateLinkResponse_httpStatus' - The response's http status code.
newUpdateLinkResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  UpdateLinkResponse
newUpdateLinkResponse :: Int -> UpdateLinkResponse
newUpdateLinkResponse Int
pHttpStatus_ =
  UpdateLinkResponse' :: Maybe Link -> Int -> UpdateLinkResponse
UpdateLinkResponse'
    { $sel:link:UpdateLinkResponse' :: Maybe Link
link = Maybe Link
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:UpdateLinkResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | Information about the link.
updateLinkResponse_link :: Lens.Lens' UpdateLinkResponse (Prelude.Maybe Link)
updateLinkResponse_link :: (Maybe Link -> f (Maybe Link))
-> UpdateLinkResponse -> f UpdateLinkResponse
updateLinkResponse_link = (UpdateLinkResponse -> Maybe Link)
-> (UpdateLinkResponse -> Maybe Link -> UpdateLinkResponse)
-> Lens
     UpdateLinkResponse UpdateLinkResponse (Maybe Link) (Maybe Link)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateLinkResponse' {Maybe Link
link :: Maybe Link
$sel:link:UpdateLinkResponse' :: UpdateLinkResponse -> Maybe Link
link} -> Maybe Link
link) (\s :: UpdateLinkResponse
s@UpdateLinkResponse' {} Maybe Link
a -> UpdateLinkResponse
s {$sel:link:UpdateLinkResponse' :: Maybe Link
link = Maybe Link
a} :: UpdateLinkResponse)

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

instance Prelude.NFData UpdateLinkResponse