{-# 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.MediaLive.ListInputDeviceTransfers
-- 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)
--
-- List input devices that are currently being transferred. List input
-- devices that you are transferring from your AWS account or input devices
-- that another AWS account is transferring to you.
--
-- This operation returns paginated results.
module Amazonka.MediaLive.ListInputDeviceTransfers
  ( -- * Creating a Request
    ListInputDeviceTransfers (..),
    newListInputDeviceTransfers,

    -- * Request Lenses
    listInputDeviceTransfers_nextToken,
    listInputDeviceTransfers_maxResults,
    listInputDeviceTransfers_transferType,

    -- * Destructuring the Response
    ListInputDeviceTransfersResponse (..),
    newListInputDeviceTransfersResponse,

    -- * Response Lenses
    listInputDeviceTransfersResponse_nextToken,
    listInputDeviceTransfersResponse_inputDeviceTransfers,
    listInputDeviceTransfersResponse_httpStatus,
  )
where

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

-- | Placeholder documentation for ListInputDeviceTransfersRequest
--
-- /See:/ 'newListInputDeviceTransfers' smart constructor.
data ListInputDeviceTransfers = ListInputDeviceTransfers'
  { ListInputDeviceTransfers -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    ListInputDeviceTransfers -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural,
    ListInputDeviceTransfers -> Text
transferType :: Prelude.Text
  }
  deriving (ListInputDeviceTransfers -> ListInputDeviceTransfers -> Bool
(ListInputDeviceTransfers -> ListInputDeviceTransfers -> Bool)
-> (ListInputDeviceTransfers -> ListInputDeviceTransfers -> Bool)
-> Eq ListInputDeviceTransfers
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListInputDeviceTransfers -> ListInputDeviceTransfers -> Bool
$c/= :: ListInputDeviceTransfers -> ListInputDeviceTransfers -> Bool
== :: ListInputDeviceTransfers -> ListInputDeviceTransfers -> Bool
$c== :: ListInputDeviceTransfers -> ListInputDeviceTransfers -> Bool
Prelude.Eq, ReadPrec [ListInputDeviceTransfers]
ReadPrec ListInputDeviceTransfers
Int -> ReadS ListInputDeviceTransfers
ReadS [ListInputDeviceTransfers]
(Int -> ReadS ListInputDeviceTransfers)
-> ReadS [ListInputDeviceTransfers]
-> ReadPrec ListInputDeviceTransfers
-> ReadPrec [ListInputDeviceTransfers]
-> Read ListInputDeviceTransfers
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListInputDeviceTransfers]
$creadListPrec :: ReadPrec [ListInputDeviceTransfers]
readPrec :: ReadPrec ListInputDeviceTransfers
$creadPrec :: ReadPrec ListInputDeviceTransfers
readList :: ReadS [ListInputDeviceTransfers]
$creadList :: ReadS [ListInputDeviceTransfers]
readsPrec :: Int -> ReadS ListInputDeviceTransfers
$creadsPrec :: Int -> ReadS ListInputDeviceTransfers
Prelude.Read, Int -> ListInputDeviceTransfers -> ShowS
[ListInputDeviceTransfers] -> ShowS
ListInputDeviceTransfers -> String
(Int -> ListInputDeviceTransfers -> ShowS)
-> (ListInputDeviceTransfers -> String)
-> ([ListInputDeviceTransfers] -> ShowS)
-> Show ListInputDeviceTransfers
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListInputDeviceTransfers] -> ShowS
$cshowList :: [ListInputDeviceTransfers] -> ShowS
show :: ListInputDeviceTransfers -> String
$cshow :: ListInputDeviceTransfers -> String
showsPrec :: Int -> ListInputDeviceTransfers -> ShowS
$cshowsPrec :: Int -> ListInputDeviceTransfers -> ShowS
Prelude.Show, (forall x.
 ListInputDeviceTransfers -> Rep ListInputDeviceTransfers x)
-> (forall x.
    Rep ListInputDeviceTransfers x -> ListInputDeviceTransfers)
-> Generic ListInputDeviceTransfers
forall x.
Rep ListInputDeviceTransfers x -> ListInputDeviceTransfers
forall x.
ListInputDeviceTransfers -> Rep ListInputDeviceTransfers x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListInputDeviceTransfers x -> ListInputDeviceTransfers
$cfrom :: forall x.
ListInputDeviceTransfers -> Rep ListInputDeviceTransfers x
Prelude.Generic)

-- |
-- Create a value of 'ListInputDeviceTransfers' 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:
--
-- 'nextToken', 'listInputDeviceTransfers_nextToken' - Undocumented member.
--
-- 'maxResults', 'listInputDeviceTransfers_maxResults' - Undocumented member.
--
-- 'transferType', 'listInputDeviceTransfers_transferType' - Undocumented member.
newListInputDeviceTransfers ::
  -- | 'transferType'
  Prelude.Text ->
  ListInputDeviceTransfers
newListInputDeviceTransfers :: Text -> ListInputDeviceTransfers
newListInputDeviceTransfers Text
pTransferType_ =
  ListInputDeviceTransfers' :: Maybe Text -> Maybe Natural -> Text -> ListInputDeviceTransfers
ListInputDeviceTransfers'
    { $sel:nextToken:ListInputDeviceTransfers' :: Maybe Text
nextToken =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:maxResults:ListInputDeviceTransfers' :: Maybe Natural
maxResults = Maybe Natural
forall a. Maybe a
Prelude.Nothing,
      $sel:transferType:ListInputDeviceTransfers' :: Text
transferType = Text
pTransferType_
    }

-- | Undocumented member.
listInputDeviceTransfers_nextToken :: Lens.Lens' ListInputDeviceTransfers (Prelude.Maybe Prelude.Text)
listInputDeviceTransfers_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListInputDeviceTransfers -> f ListInputDeviceTransfers
listInputDeviceTransfers_nextToken = (ListInputDeviceTransfers -> Maybe Text)
-> (ListInputDeviceTransfers
    -> Maybe Text -> ListInputDeviceTransfers)
-> Lens
     ListInputDeviceTransfers
     ListInputDeviceTransfers
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListInputDeviceTransfers' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListInputDeviceTransfers' :: ListInputDeviceTransfers -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListInputDeviceTransfers
s@ListInputDeviceTransfers' {} Maybe Text
a -> ListInputDeviceTransfers
s {$sel:nextToken:ListInputDeviceTransfers' :: Maybe Text
nextToken = Maybe Text
a} :: ListInputDeviceTransfers)

-- | Undocumented member.
listInputDeviceTransfers_maxResults :: Lens.Lens' ListInputDeviceTransfers (Prelude.Maybe Prelude.Natural)
listInputDeviceTransfers_maxResults :: (Maybe Natural -> f (Maybe Natural))
-> ListInputDeviceTransfers -> f ListInputDeviceTransfers
listInputDeviceTransfers_maxResults = (ListInputDeviceTransfers -> Maybe Natural)
-> (ListInputDeviceTransfers
    -> Maybe Natural -> ListInputDeviceTransfers)
-> Lens
     ListInputDeviceTransfers
     ListInputDeviceTransfers
     (Maybe Natural)
     (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListInputDeviceTransfers' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListInputDeviceTransfers' :: ListInputDeviceTransfers -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListInputDeviceTransfers
s@ListInputDeviceTransfers' {} Maybe Natural
a -> ListInputDeviceTransfers
s {$sel:maxResults:ListInputDeviceTransfers' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListInputDeviceTransfers)

-- | Undocumented member.
listInputDeviceTransfers_transferType :: Lens.Lens' ListInputDeviceTransfers Prelude.Text
listInputDeviceTransfers_transferType :: (Text -> f Text)
-> ListInputDeviceTransfers -> f ListInputDeviceTransfers
listInputDeviceTransfers_transferType = (ListInputDeviceTransfers -> Text)
-> (ListInputDeviceTransfers -> Text -> ListInputDeviceTransfers)
-> Lens ListInputDeviceTransfers ListInputDeviceTransfers Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListInputDeviceTransfers' {Text
transferType :: Text
$sel:transferType:ListInputDeviceTransfers' :: ListInputDeviceTransfers -> Text
transferType} -> Text
transferType) (\s :: ListInputDeviceTransfers
s@ListInputDeviceTransfers' {} Text
a -> ListInputDeviceTransfers
s {$sel:transferType:ListInputDeviceTransfers' :: Text
transferType = Text
a} :: ListInputDeviceTransfers)

instance Core.AWSPager ListInputDeviceTransfers where
  page :: ListInputDeviceTransfers
-> AWSResponse ListInputDeviceTransfers
-> Maybe ListInputDeviceTransfers
page ListInputDeviceTransfers
rq AWSResponse ListInputDeviceTransfers
rs
    | Maybe Text -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse ListInputDeviceTransfers
ListInputDeviceTransfersResponse
rs
            ListInputDeviceTransfersResponse
-> Getting (First Text) ListInputDeviceTransfersResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> ListInputDeviceTransfersResponse
-> Const (First Text) ListInputDeviceTransfersResponse
Lens' ListInputDeviceTransfersResponse (Maybe Text)
listInputDeviceTransfersResponse_nextToken
              ((Maybe Text -> Const (First Text) (Maybe Text))
 -> ListInputDeviceTransfersResponse
 -> Const (First Text) ListInputDeviceTransfersResponse)
-> ((Text -> Const (First Text) Text)
    -> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) ListInputDeviceTransfersResponse Text
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text)
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
        ) =
      Maybe ListInputDeviceTransfers
forall a. Maybe a
Prelude.Nothing
    | Maybe [TransferringInputDeviceSummary] -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse ListInputDeviceTransfers
ListInputDeviceTransfersResponse
rs
            ListInputDeviceTransfersResponse
-> Getting
     (First [TransferringInputDeviceSummary])
     ListInputDeviceTransfersResponse
     [TransferringInputDeviceSummary]
-> Maybe [TransferringInputDeviceSummary]
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe [TransferringInputDeviceSummary]
 -> Const
      (First [TransferringInputDeviceSummary])
      (Maybe [TransferringInputDeviceSummary]))
-> ListInputDeviceTransfersResponse
-> Const
     (First [TransferringInputDeviceSummary])
     ListInputDeviceTransfersResponse
Lens'
  ListInputDeviceTransfersResponse
  (Maybe [TransferringInputDeviceSummary])
listInputDeviceTransfersResponse_inputDeviceTransfers
              ((Maybe [TransferringInputDeviceSummary]
  -> Const
       (First [TransferringInputDeviceSummary])
       (Maybe [TransferringInputDeviceSummary]))
 -> ListInputDeviceTransfersResponse
 -> Const
      (First [TransferringInputDeviceSummary])
      ListInputDeviceTransfersResponse)
-> (([TransferringInputDeviceSummary]
     -> Const
          (First [TransferringInputDeviceSummary])
          [TransferringInputDeviceSummary])
    -> Maybe [TransferringInputDeviceSummary]
    -> Const
         (First [TransferringInputDeviceSummary])
         (Maybe [TransferringInputDeviceSummary]))
-> Getting
     (First [TransferringInputDeviceSummary])
     ListInputDeviceTransfersResponse
     [TransferringInputDeviceSummary]
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([TransferringInputDeviceSummary]
 -> Const
      (First [TransferringInputDeviceSummary])
      [TransferringInputDeviceSummary])
-> Maybe [TransferringInputDeviceSummary]
-> Const
     (First [TransferringInputDeviceSummary])
     (Maybe [TransferringInputDeviceSummary])
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
        ) =
      Maybe ListInputDeviceTransfers
forall a. Maybe a
Prelude.Nothing
    | Bool
Prelude.otherwise =
      ListInputDeviceTransfers -> Maybe ListInputDeviceTransfers
forall a. a -> Maybe a
Prelude.Just (ListInputDeviceTransfers -> Maybe ListInputDeviceTransfers)
-> ListInputDeviceTransfers -> Maybe ListInputDeviceTransfers
forall a b. (a -> b) -> a -> b
Prelude.$
        ListInputDeviceTransfers
rq
          ListInputDeviceTransfers
-> (ListInputDeviceTransfers -> ListInputDeviceTransfers)
-> ListInputDeviceTransfers
forall a b. a -> (a -> b) -> b
Prelude.& (Maybe Text -> Identity (Maybe Text))
-> ListInputDeviceTransfers -> Identity ListInputDeviceTransfers
Lens
  ListInputDeviceTransfers
  ListInputDeviceTransfers
  (Maybe Text)
  (Maybe Text)
listInputDeviceTransfers_nextToken
          ((Maybe Text -> Identity (Maybe Text))
 -> ListInputDeviceTransfers -> Identity ListInputDeviceTransfers)
-> Maybe Text
-> ListInputDeviceTransfers
-> ListInputDeviceTransfers
forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListInputDeviceTransfers
ListInputDeviceTransfersResponse
rs
          ListInputDeviceTransfersResponse
-> Getting (First Text) ListInputDeviceTransfersResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> ListInputDeviceTransfersResponse
-> Const (First Text) ListInputDeviceTransfersResponse
Lens' ListInputDeviceTransfersResponse (Maybe Text)
listInputDeviceTransfersResponse_nextToken
            ((Maybe Text -> Const (First Text) (Maybe Text))
 -> ListInputDeviceTransfersResponse
 -> Const (First Text) ListInputDeviceTransfersResponse)
-> ((Text -> Const (First Text) Text)
    -> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) ListInputDeviceTransfersResponse Text
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text)
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just

instance Core.AWSRequest ListInputDeviceTransfers where
  type
    AWSResponse ListInputDeviceTransfers =
      ListInputDeviceTransfersResponse
  request :: ListInputDeviceTransfers -> Request ListInputDeviceTransfers
request = Service
-> ListInputDeviceTransfers -> Request ListInputDeviceTransfers
forall a. ToRequest a => Service -> a -> Request a
Request.get Service
defaultService
  response :: Logger
-> Service
-> Proxy ListInputDeviceTransfers
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse ListInputDeviceTransfers)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse ListInputDeviceTransfers))
-> Logger
-> Service
-> Proxy ListInputDeviceTransfers
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse ListInputDeviceTransfers)))
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 [TransferringInputDeviceSummary]
-> Int
-> ListInputDeviceTransfersResponse
ListInputDeviceTransfersResponse'
            (Maybe Text
 -> Maybe [TransferringInputDeviceSummary]
 -> Int
 -> ListInputDeviceTransfersResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [TransferringInputDeviceSummary]
      -> Int -> ListInputDeviceTransfersResponse)
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
"nextToken")
            Either
  String
  (Maybe [TransferringInputDeviceSummary]
   -> Int -> ListInputDeviceTransfersResponse)
-> Either String (Maybe [TransferringInputDeviceSummary])
-> Either String (Int -> ListInputDeviceTransfersResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object
-> Text
-> Either String (Maybe (Maybe [TransferringInputDeviceSummary]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"inputDeviceTransfers"
                            Either String (Maybe (Maybe [TransferringInputDeviceSummary]))
-> Maybe [TransferringInputDeviceSummary]
-> Either String (Maybe [TransferringInputDeviceSummary])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [TransferringInputDeviceSummary]
forall a. Monoid a => a
Prelude.mempty
                        )
            Either String (Int -> ListInputDeviceTransfersResponse)
-> Either String Int
-> Either String ListInputDeviceTransfersResponse
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 ListInputDeviceTransfers

instance Prelude.NFData ListInputDeviceTransfers

instance Core.ToHeaders ListInputDeviceTransfers where
  toHeaders :: ListInputDeviceTransfers -> ResponseHeaders
toHeaders =
    ResponseHeaders -> ListInputDeviceTransfers -> 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.ToPath ListInputDeviceTransfers where
  toPath :: ListInputDeviceTransfers -> ByteString
toPath = ByteString -> ListInputDeviceTransfers -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/prod/inputDeviceTransfers"

instance Core.ToQuery ListInputDeviceTransfers where
  toQuery :: ListInputDeviceTransfers -> QueryString
toQuery ListInputDeviceTransfers' {Maybe Natural
Maybe Text
Text
transferType :: Text
maxResults :: Maybe Natural
nextToken :: Maybe Text
$sel:transferType:ListInputDeviceTransfers' :: ListInputDeviceTransfers -> Text
$sel:maxResults:ListInputDeviceTransfers' :: ListInputDeviceTransfers -> Maybe Natural
$sel:nextToken:ListInputDeviceTransfers' :: ListInputDeviceTransfers -> Maybe Text
..} =
    [QueryString] -> QueryString
forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"nextToken" ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
nextToken,
        ByteString
"maxResults" ByteString -> Maybe Natural -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Natural
maxResults,
        ByteString
"transferType" ByteString -> Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Text
transferType
      ]

-- | Placeholder documentation for ListInputDeviceTransfersResponse
--
-- /See:/ 'newListInputDeviceTransfersResponse' smart constructor.
data ListInputDeviceTransfersResponse = ListInputDeviceTransfersResponse'
  { -- | A token to get additional list results.
    ListInputDeviceTransfersResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The list of devices that you are transferring or are being transferred
    -- to you.
    ListInputDeviceTransfersResponse
-> Maybe [TransferringInputDeviceSummary]
inputDeviceTransfers :: Prelude.Maybe [TransferringInputDeviceSummary],
    -- | The response's http status code.
    ListInputDeviceTransfersResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (ListInputDeviceTransfersResponse
-> ListInputDeviceTransfersResponse -> Bool
(ListInputDeviceTransfersResponse
 -> ListInputDeviceTransfersResponse -> Bool)
-> (ListInputDeviceTransfersResponse
    -> ListInputDeviceTransfersResponse -> Bool)
-> Eq ListInputDeviceTransfersResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListInputDeviceTransfersResponse
-> ListInputDeviceTransfersResponse -> Bool
$c/= :: ListInputDeviceTransfersResponse
-> ListInputDeviceTransfersResponse -> Bool
== :: ListInputDeviceTransfersResponse
-> ListInputDeviceTransfersResponse -> Bool
$c== :: ListInputDeviceTransfersResponse
-> ListInputDeviceTransfersResponse -> Bool
Prelude.Eq, ReadPrec [ListInputDeviceTransfersResponse]
ReadPrec ListInputDeviceTransfersResponse
Int -> ReadS ListInputDeviceTransfersResponse
ReadS [ListInputDeviceTransfersResponse]
(Int -> ReadS ListInputDeviceTransfersResponse)
-> ReadS [ListInputDeviceTransfersResponse]
-> ReadPrec ListInputDeviceTransfersResponse
-> ReadPrec [ListInputDeviceTransfersResponse]
-> Read ListInputDeviceTransfersResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListInputDeviceTransfersResponse]
$creadListPrec :: ReadPrec [ListInputDeviceTransfersResponse]
readPrec :: ReadPrec ListInputDeviceTransfersResponse
$creadPrec :: ReadPrec ListInputDeviceTransfersResponse
readList :: ReadS [ListInputDeviceTransfersResponse]
$creadList :: ReadS [ListInputDeviceTransfersResponse]
readsPrec :: Int -> ReadS ListInputDeviceTransfersResponse
$creadsPrec :: Int -> ReadS ListInputDeviceTransfersResponse
Prelude.Read, Int -> ListInputDeviceTransfersResponse -> ShowS
[ListInputDeviceTransfersResponse] -> ShowS
ListInputDeviceTransfersResponse -> String
(Int -> ListInputDeviceTransfersResponse -> ShowS)
-> (ListInputDeviceTransfersResponse -> String)
-> ([ListInputDeviceTransfersResponse] -> ShowS)
-> Show ListInputDeviceTransfersResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListInputDeviceTransfersResponse] -> ShowS
$cshowList :: [ListInputDeviceTransfersResponse] -> ShowS
show :: ListInputDeviceTransfersResponse -> String
$cshow :: ListInputDeviceTransfersResponse -> String
showsPrec :: Int -> ListInputDeviceTransfersResponse -> ShowS
$cshowsPrec :: Int -> ListInputDeviceTransfersResponse -> ShowS
Prelude.Show, (forall x.
 ListInputDeviceTransfersResponse
 -> Rep ListInputDeviceTransfersResponse x)
-> (forall x.
    Rep ListInputDeviceTransfersResponse x
    -> ListInputDeviceTransfersResponse)
-> Generic ListInputDeviceTransfersResponse
forall x.
Rep ListInputDeviceTransfersResponse x
-> ListInputDeviceTransfersResponse
forall x.
ListInputDeviceTransfersResponse
-> Rep ListInputDeviceTransfersResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListInputDeviceTransfersResponse x
-> ListInputDeviceTransfersResponse
$cfrom :: forall x.
ListInputDeviceTransfersResponse
-> Rep ListInputDeviceTransfersResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListInputDeviceTransfersResponse' 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:
--
-- 'nextToken', 'listInputDeviceTransfersResponse_nextToken' - A token to get additional list results.
--
-- 'inputDeviceTransfers', 'listInputDeviceTransfersResponse_inputDeviceTransfers' - The list of devices that you are transferring or are being transferred
-- to you.
--
-- 'httpStatus', 'listInputDeviceTransfersResponse_httpStatus' - The response's http status code.
newListInputDeviceTransfersResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ListInputDeviceTransfersResponse
newListInputDeviceTransfersResponse :: Int -> ListInputDeviceTransfersResponse
newListInputDeviceTransfersResponse Int
pHttpStatus_ =
  ListInputDeviceTransfersResponse' :: Maybe Text
-> Maybe [TransferringInputDeviceSummary]
-> Int
-> ListInputDeviceTransfersResponse
ListInputDeviceTransfersResponse'
    { $sel:nextToken:ListInputDeviceTransfersResponse' :: Maybe Text
nextToken =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:inputDeviceTransfers:ListInputDeviceTransfersResponse' :: Maybe [TransferringInputDeviceSummary]
inputDeviceTransfers = Maybe [TransferringInputDeviceSummary]
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:ListInputDeviceTransfersResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | A token to get additional list results.
listInputDeviceTransfersResponse_nextToken :: Lens.Lens' ListInputDeviceTransfersResponse (Prelude.Maybe Prelude.Text)
listInputDeviceTransfersResponse_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListInputDeviceTransfersResponse
-> f ListInputDeviceTransfersResponse
listInputDeviceTransfersResponse_nextToken = (ListInputDeviceTransfersResponse -> Maybe Text)
-> (ListInputDeviceTransfersResponse
    -> Maybe Text -> ListInputDeviceTransfersResponse)
-> Lens' ListInputDeviceTransfersResponse (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListInputDeviceTransfersResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListInputDeviceTransfersResponse' :: ListInputDeviceTransfersResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListInputDeviceTransfersResponse
s@ListInputDeviceTransfersResponse' {} Maybe Text
a -> ListInputDeviceTransfersResponse
s {$sel:nextToken:ListInputDeviceTransfersResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListInputDeviceTransfersResponse)

-- | The list of devices that you are transferring or are being transferred
-- to you.
listInputDeviceTransfersResponse_inputDeviceTransfers :: Lens.Lens' ListInputDeviceTransfersResponse (Prelude.Maybe [TransferringInputDeviceSummary])
listInputDeviceTransfersResponse_inputDeviceTransfers :: (Maybe [TransferringInputDeviceSummary]
 -> f (Maybe [TransferringInputDeviceSummary]))
-> ListInputDeviceTransfersResponse
-> f ListInputDeviceTransfersResponse
listInputDeviceTransfersResponse_inputDeviceTransfers = (ListInputDeviceTransfersResponse
 -> Maybe [TransferringInputDeviceSummary])
-> (ListInputDeviceTransfersResponse
    -> Maybe [TransferringInputDeviceSummary]
    -> ListInputDeviceTransfersResponse)
-> Lens'
     ListInputDeviceTransfersResponse
     (Maybe [TransferringInputDeviceSummary])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListInputDeviceTransfersResponse' {Maybe [TransferringInputDeviceSummary]
inputDeviceTransfers :: Maybe [TransferringInputDeviceSummary]
$sel:inputDeviceTransfers:ListInputDeviceTransfersResponse' :: ListInputDeviceTransfersResponse
-> Maybe [TransferringInputDeviceSummary]
inputDeviceTransfers} -> Maybe [TransferringInputDeviceSummary]
inputDeviceTransfers) (\s :: ListInputDeviceTransfersResponse
s@ListInputDeviceTransfersResponse' {} Maybe [TransferringInputDeviceSummary]
a -> ListInputDeviceTransfersResponse
s {$sel:inputDeviceTransfers:ListInputDeviceTransfersResponse' :: Maybe [TransferringInputDeviceSummary]
inputDeviceTransfers = Maybe [TransferringInputDeviceSummary]
a} :: ListInputDeviceTransfersResponse) ((Maybe [TransferringInputDeviceSummary]
  -> f (Maybe [TransferringInputDeviceSummary]))
 -> ListInputDeviceTransfersResponse
 -> f ListInputDeviceTransfersResponse)
-> ((Maybe [TransferringInputDeviceSummary]
     -> f (Maybe [TransferringInputDeviceSummary]))
    -> Maybe [TransferringInputDeviceSummary]
    -> f (Maybe [TransferringInputDeviceSummary]))
-> (Maybe [TransferringInputDeviceSummary]
    -> f (Maybe [TransferringInputDeviceSummary]))
-> ListInputDeviceTransfersResponse
-> f ListInputDeviceTransfersResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [TransferringInputDeviceSummary]
  [TransferringInputDeviceSummary]
  [TransferringInputDeviceSummary]
  [TransferringInputDeviceSummary]
-> Iso
     (Maybe [TransferringInputDeviceSummary])
     (Maybe [TransferringInputDeviceSummary])
     (Maybe [TransferringInputDeviceSummary])
     (Maybe [TransferringInputDeviceSummary])
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
  [TransferringInputDeviceSummary]
  [TransferringInputDeviceSummary]
  [TransferringInputDeviceSummary]
  [TransferringInputDeviceSummary]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

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

instance
  Prelude.NFData
    ListInputDeviceTransfersResponse