{-# 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.KinesisAnalyticsV2.ListApplicationVersions
-- 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)
--
-- Lists all the versions for the specified application, including versions
-- that were rolled back. The response also includes a summary of the
-- configuration associated with each version.
--
-- To get the complete description of a specific application version,
-- invoke the DescribeApplicationVersion operation.
--
-- This operation is supported only for Amazon Kinesis Data Analytics for
-- Apache Flink.
module Amazonka.KinesisAnalyticsV2.ListApplicationVersions
  ( -- * Creating a Request
    ListApplicationVersions (..),
    newListApplicationVersions,

    -- * Request Lenses
    listApplicationVersions_nextToken,
    listApplicationVersions_limit,
    listApplicationVersions_applicationName,

    -- * Destructuring the Response
    ListApplicationVersionsResponse (..),
    newListApplicationVersionsResponse,

    -- * Response Lenses
    listApplicationVersionsResponse_applicationVersionSummaries,
    listApplicationVersionsResponse_nextToken,
    listApplicationVersionsResponse_httpStatus,
  )
where

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

-- | /See:/ 'newListApplicationVersions' smart constructor.
data ListApplicationVersions = ListApplicationVersions'
  { -- | If a previous invocation of this operation returned a pagination token,
    -- pass it into this value to retrieve the next set of results. For more
    -- information about pagination, see
    -- <https://docs.aws.amazon.com/cli/latest/userguide/pagination.html Using the Amazon Command Line Interface\'s Pagination Options>.
    ListApplicationVersions -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The maximum number of versions to list in this invocation of the
    -- operation.
    ListApplicationVersions -> Maybe Natural
limit :: Prelude.Maybe Prelude.Natural,
    -- | The name of the application for which you want to list all versions.
    ListApplicationVersions -> Text
applicationName :: Prelude.Text
  }
  deriving (ListApplicationVersions -> ListApplicationVersions -> Bool
(ListApplicationVersions -> ListApplicationVersions -> Bool)
-> (ListApplicationVersions -> ListApplicationVersions -> Bool)
-> Eq ListApplicationVersions
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListApplicationVersions -> ListApplicationVersions -> Bool
$c/= :: ListApplicationVersions -> ListApplicationVersions -> Bool
== :: ListApplicationVersions -> ListApplicationVersions -> Bool
$c== :: ListApplicationVersions -> ListApplicationVersions -> Bool
Prelude.Eq, ReadPrec [ListApplicationVersions]
ReadPrec ListApplicationVersions
Int -> ReadS ListApplicationVersions
ReadS [ListApplicationVersions]
(Int -> ReadS ListApplicationVersions)
-> ReadS [ListApplicationVersions]
-> ReadPrec ListApplicationVersions
-> ReadPrec [ListApplicationVersions]
-> Read ListApplicationVersions
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListApplicationVersions]
$creadListPrec :: ReadPrec [ListApplicationVersions]
readPrec :: ReadPrec ListApplicationVersions
$creadPrec :: ReadPrec ListApplicationVersions
readList :: ReadS [ListApplicationVersions]
$creadList :: ReadS [ListApplicationVersions]
readsPrec :: Int -> ReadS ListApplicationVersions
$creadsPrec :: Int -> ReadS ListApplicationVersions
Prelude.Read, Int -> ListApplicationVersions -> ShowS
[ListApplicationVersions] -> ShowS
ListApplicationVersions -> String
(Int -> ListApplicationVersions -> ShowS)
-> (ListApplicationVersions -> String)
-> ([ListApplicationVersions] -> ShowS)
-> Show ListApplicationVersions
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListApplicationVersions] -> ShowS
$cshowList :: [ListApplicationVersions] -> ShowS
show :: ListApplicationVersions -> String
$cshow :: ListApplicationVersions -> String
showsPrec :: Int -> ListApplicationVersions -> ShowS
$cshowsPrec :: Int -> ListApplicationVersions -> ShowS
Prelude.Show, (forall x.
 ListApplicationVersions -> Rep ListApplicationVersions x)
-> (forall x.
    Rep ListApplicationVersions x -> ListApplicationVersions)
-> Generic ListApplicationVersions
forall x. Rep ListApplicationVersions x -> ListApplicationVersions
forall x. ListApplicationVersions -> Rep ListApplicationVersions x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListApplicationVersions x -> ListApplicationVersions
$cfrom :: forall x. ListApplicationVersions -> Rep ListApplicationVersions x
Prelude.Generic)

-- |
-- Create a value of 'ListApplicationVersions' 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', 'listApplicationVersions_nextToken' - If a previous invocation of this operation returned a pagination token,
-- pass it into this value to retrieve the next set of results. For more
-- information about pagination, see
-- <https://docs.aws.amazon.com/cli/latest/userguide/pagination.html Using the Amazon Command Line Interface\'s Pagination Options>.
--
-- 'limit', 'listApplicationVersions_limit' - The maximum number of versions to list in this invocation of the
-- operation.
--
-- 'applicationName', 'listApplicationVersions_applicationName' - The name of the application for which you want to list all versions.
newListApplicationVersions ::
  -- | 'applicationName'
  Prelude.Text ->
  ListApplicationVersions
newListApplicationVersions :: Text -> ListApplicationVersions
newListApplicationVersions Text
pApplicationName_ =
  ListApplicationVersions' :: Maybe Text -> Maybe Natural -> Text -> ListApplicationVersions
ListApplicationVersions'
    { $sel:nextToken:ListApplicationVersions' :: Maybe Text
nextToken =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:limit:ListApplicationVersions' :: Maybe Natural
limit = Maybe Natural
forall a. Maybe a
Prelude.Nothing,
      $sel:applicationName:ListApplicationVersions' :: Text
applicationName = Text
pApplicationName_
    }

-- | If a previous invocation of this operation returned a pagination token,
-- pass it into this value to retrieve the next set of results. For more
-- information about pagination, see
-- <https://docs.aws.amazon.com/cli/latest/userguide/pagination.html Using the Amazon Command Line Interface\'s Pagination Options>.
listApplicationVersions_nextToken :: Lens.Lens' ListApplicationVersions (Prelude.Maybe Prelude.Text)
listApplicationVersions_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListApplicationVersions -> f ListApplicationVersions
listApplicationVersions_nextToken = (ListApplicationVersions -> Maybe Text)
-> (ListApplicationVersions
    -> Maybe Text -> ListApplicationVersions)
-> Lens
     ListApplicationVersions
     ListApplicationVersions
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListApplicationVersions' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListApplicationVersions' :: ListApplicationVersions -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListApplicationVersions
s@ListApplicationVersions' {} Maybe Text
a -> ListApplicationVersions
s {$sel:nextToken:ListApplicationVersions' :: Maybe Text
nextToken = Maybe Text
a} :: ListApplicationVersions)

-- | The maximum number of versions to list in this invocation of the
-- operation.
listApplicationVersions_limit :: Lens.Lens' ListApplicationVersions (Prelude.Maybe Prelude.Natural)
listApplicationVersions_limit :: (Maybe Natural -> f (Maybe Natural))
-> ListApplicationVersions -> f ListApplicationVersions
listApplicationVersions_limit = (ListApplicationVersions -> Maybe Natural)
-> (ListApplicationVersions
    -> Maybe Natural -> ListApplicationVersions)
-> Lens
     ListApplicationVersions
     ListApplicationVersions
     (Maybe Natural)
     (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListApplicationVersions' {Maybe Natural
limit :: Maybe Natural
$sel:limit:ListApplicationVersions' :: ListApplicationVersions -> Maybe Natural
limit} -> Maybe Natural
limit) (\s :: ListApplicationVersions
s@ListApplicationVersions' {} Maybe Natural
a -> ListApplicationVersions
s {$sel:limit:ListApplicationVersions' :: Maybe Natural
limit = Maybe Natural
a} :: ListApplicationVersions)

-- | The name of the application for which you want to list all versions.
listApplicationVersions_applicationName :: Lens.Lens' ListApplicationVersions Prelude.Text
listApplicationVersions_applicationName :: (Text -> f Text)
-> ListApplicationVersions -> f ListApplicationVersions
listApplicationVersions_applicationName = (ListApplicationVersions -> Text)
-> (ListApplicationVersions -> Text -> ListApplicationVersions)
-> Lens ListApplicationVersions ListApplicationVersions Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListApplicationVersions' {Text
applicationName :: Text
$sel:applicationName:ListApplicationVersions' :: ListApplicationVersions -> Text
applicationName} -> Text
applicationName) (\s :: ListApplicationVersions
s@ListApplicationVersions' {} Text
a -> ListApplicationVersions
s {$sel:applicationName:ListApplicationVersions' :: Text
applicationName = Text
a} :: ListApplicationVersions)

instance Core.AWSRequest ListApplicationVersions where
  type
    AWSResponse ListApplicationVersions =
      ListApplicationVersionsResponse
  request :: ListApplicationVersions -> Request ListApplicationVersions
request = Service
-> ListApplicationVersions -> Request ListApplicationVersions
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy ListApplicationVersions
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse ListApplicationVersions)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse ListApplicationVersions))
-> Logger
-> Service
-> Proxy ListApplicationVersions
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse ListApplicationVersions)))
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 [ApplicationVersionSummary]
-> Maybe Text -> Int -> ListApplicationVersionsResponse
ListApplicationVersionsResponse'
            (Maybe [ApplicationVersionSummary]
 -> Maybe Text -> Int -> ListApplicationVersionsResponse)
-> Either String (Maybe [ApplicationVersionSummary])
-> Either
     String (Maybe Text -> Int -> ListApplicationVersionsResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ( Object
x Object
-> Text
-> Either String (Maybe (Maybe [ApplicationVersionSummary]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"ApplicationVersionSummaries"
                            Either String (Maybe (Maybe [ApplicationVersionSummary]))
-> Maybe [ApplicationVersionSummary]
-> Either String (Maybe [ApplicationVersionSummary])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [ApplicationVersionSummary]
forall a. Monoid a => a
Prelude.mempty
                        )
            Either
  String (Maybe Text -> Int -> ListApplicationVersionsResponse)
-> Either String (Maybe Text)
-> Either String (Int -> ListApplicationVersionsResponse)
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
"NextToken")
            Either String (Int -> ListApplicationVersionsResponse)
-> Either String Int
-> Either String ListApplicationVersionsResponse
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 ListApplicationVersions

instance Prelude.NFData ListApplicationVersions

instance Core.ToHeaders ListApplicationVersions where
  toHeaders :: ListApplicationVersions -> ResponseHeaders
toHeaders =
    ResponseHeaders -> ListApplicationVersions -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
      ( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"X-Amz-Target"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"KinesisAnalytics_20180523.ListApplicationVersions" ::
                          Prelude.ByteString
                      ),
            HeaderName
"Content-Type"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

instance Core.ToJSON ListApplicationVersions where
  toJSON :: ListApplicationVersions -> Value
toJSON ListApplicationVersions' {Maybe Natural
Maybe Text
Text
applicationName :: Text
limit :: Maybe Natural
nextToken :: Maybe Text
$sel:applicationName:ListApplicationVersions' :: ListApplicationVersions -> Text
$sel:limit:ListApplicationVersions' :: ListApplicationVersions -> Maybe Natural
$sel:nextToken:ListApplicationVersions' :: ListApplicationVersions -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"NextToken" 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
nextToken,
            (Text
"Limit" Text -> Natural -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Natural -> Pair) -> Maybe Natural -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Natural
limit,
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
              (Text
"ApplicationName" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
applicationName)
          ]
      )

instance Core.ToPath ListApplicationVersions where
  toPath :: ListApplicationVersions -> ByteString
toPath = ByteString -> ListApplicationVersions -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"

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

-- | /See:/ 'newListApplicationVersionsResponse' smart constructor.
data ListApplicationVersionsResponse = ListApplicationVersionsResponse'
  { -- | A list of the application versions and the associated configuration
    -- summaries. The list includes application versions that were rolled back.
    --
    -- To get the complete description of a specific application version,
    -- invoke the DescribeApplicationVersion operation.
    ListApplicationVersionsResponse
-> Maybe [ApplicationVersionSummary]
applicationVersionSummaries :: Prelude.Maybe [ApplicationVersionSummary],
    -- | The pagination token for the next set of results, or @null@ if there are
    -- no additional results. To retrieve the next set of items, pass this
    -- token into a subsequent invocation of this operation. For more
    -- information about pagination, see
    -- <https://docs.aws.amazon.com/cli/latest/userguide/pagination.html Using the Amazon Command Line Interface\'s Pagination Options>.
    ListApplicationVersionsResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    ListApplicationVersionsResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (ListApplicationVersionsResponse
-> ListApplicationVersionsResponse -> Bool
(ListApplicationVersionsResponse
 -> ListApplicationVersionsResponse -> Bool)
-> (ListApplicationVersionsResponse
    -> ListApplicationVersionsResponse -> Bool)
-> Eq ListApplicationVersionsResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListApplicationVersionsResponse
-> ListApplicationVersionsResponse -> Bool
$c/= :: ListApplicationVersionsResponse
-> ListApplicationVersionsResponse -> Bool
== :: ListApplicationVersionsResponse
-> ListApplicationVersionsResponse -> Bool
$c== :: ListApplicationVersionsResponse
-> ListApplicationVersionsResponse -> Bool
Prelude.Eq, ReadPrec [ListApplicationVersionsResponse]
ReadPrec ListApplicationVersionsResponse
Int -> ReadS ListApplicationVersionsResponse
ReadS [ListApplicationVersionsResponse]
(Int -> ReadS ListApplicationVersionsResponse)
-> ReadS [ListApplicationVersionsResponse]
-> ReadPrec ListApplicationVersionsResponse
-> ReadPrec [ListApplicationVersionsResponse]
-> Read ListApplicationVersionsResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListApplicationVersionsResponse]
$creadListPrec :: ReadPrec [ListApplicationVersionsResponse]
readPrec :: ReadPrec ListApplicationVersionsResponse
$creadPrec :: ReadPrec ListApplicationVersionsResponse
readList :: ReadS [ListApplicationVersionsResponse]
$creadList :: ReadS [ListApplicationVersionsResponse]
readsPrec :: Int -> ReadS ListApplicationVersionsResponse
$creadsPrec :: Int -> ReadS ListApplicationVersionsResponse
Prelude.Read, Int -> ListApplicationVersionsResponse -> ShowS
[ListApplicationVersionsResponse] -> ShowS
ListApplicationVersionsResponse -> String
(Int -> ListApplicationVersionsResponse -> ShowS)
-> (ListApplicationVersionsResponse -> String)
-> ([ListApplicationVersionsResponse] -> ShowS)
-> Show ListApplicationVersionsResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListApplicationVersionsResponse] -> ShowS
$cshowList :: [ListApplicationVersionsResponse] -> ShowS
show :: ListApplicationVersionsResponse -> String
$cshow :: ListApplicationVersionsResponse -> String
showsPrec :: Int -> ListApplicationVersionsResponse -> ShowS
$cshowsPrec :: Int -> ListApplicationVersionsResponse -> ShowS
Prelude.Show, (forall x.
 ListApplicationVersionsResponse
 -> Rep ListApplicationVersionsResponse x)
-> (forall x.
    Rep ListApplicationVersionsResponse x
    -> ListApplicationVersionsResponse)
-> Generic ListApplicationVersionsResponse
forall x.
Rep ListApplicationVersionsResponse x
-> ListApplicationVersionsResponse
forall x.
ListApplicationVersionsResponse
-> Rep ListApplicationVersionsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListApplicationVersionsResponse x
-> ListApplicationVersionsResponse
$cfrom :: forall x.
ListApplicationVersionsResponse
-> Rep ListApplicationVersionsResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListApplicationVersionsResponse' 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:
--
-- 'applicationVersionSummaries', 'listApplicationVersionsResponse_applicationVersionSummaries' - A list of the application versions and the associated configuration
-- summaries. The list includes application versions that were rolled back.
--
-- To get the complete description of a specific application version,
-- invoke the DescribeApplicationVersion operation.
--
-- 'nextToken', 'listApplicationVersionsResponse_nextToken' - The pagination token for the next set of results, or @null@ if there are
-- no additional results. To retrieve the next set of items, pass this
-- token into a subsequent invocation of this operation. For more
-- information about pagination, see
-- <https://docs.aws.amazon.com/cli/latest/userguide/pagination.html Using the Amazon Command Line Interface\'s Pagination Options>.
--
-- 'httpStatus', 'listApplicationVersionsResponse_httpStatus' - The response's http status code.
newListApplicationVersionsResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ListApplicationVersionsResponse
newListApplicationVersionsResponse :: Int -> ListApplicationVersionsResponse
newListApplicationVersionsResponse Int
pHttpStatus_ =
  ListApplicationVersionsResponse' :: Maybe [ApplicationVersionSummary]
-> Maybe Text -> Int -> ListApplicationVersionsResponse
ListApplicationVersionsResponse'
    { $sel:applicationVersionSummaries:ListApplicationVersionsResponse' :: Maybe [ApplicationVersionSummary]
applicationVersionSummaries =
        Maybe [ApplicationVersionSummary]
forall a. Maybe a
Prelude.Nothing,
      $sel:nextToken:ListApplicationVersionsResponse' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:ListApplicationVersionsResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | A list of the application versions and the associated configuration
-- summaries. The list includes application versions that were rolled back.
--
-- To get the complete description of a specific application version,
-- invoke the DescribeApplicationVersion operation.
listApplicationVersionsResponse_applicationVersionSummaries :: Lens.Lens' ListApplicationVersionsResponse (Prelude.Maybe [ApplicationVersionSummary])
listApplicationVersionsResponse_applicationVersionSummaries :: (Maybe [ApplicationVersionSummary]
 -> f (Maybe [ApplicationVersionSummary]))
-> ListApplicationVersionsResponse
-> f ListApplicationVersionsResponse
listApplicationVersionsResponse_applicationVersionSummaries = (ListApplicationVersionsResponse
 -> Maybe [ApplicationVersionSummary])
-> (ListApplicationVersionsResponse
    -> Maybe [ApplicationVersionSummary]
    -> ListApplicationVersionsResponse)
-> Lens
     ListApplicationVersionsResponse
     ListApplicationVersionsResponse
     (Maybe [ApplicationVersionSummary])
     (Maybe [ApplicationVersionSummary])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListApplicationVersionsResponse' {Maybe [ApplicationVersionSummary]
applicationVersionSummaries :: Maybe [ApplicationVersionSummary]
$sel:applicationVersionSummaries:ListApplicationVersionsResponse' :: ListApplicationVersionsResponse
-> Maybe [ApplicationVersionSummary]
applicationVersionSummaries} -> Maybe [ApplicationVersionSummary]
applicationVersionSummaries) (\s :: ListApplicationVersionsResponse
s@ListApplicationVersionsResponse' {} Maybe [ApplicationVersionSummary]
a -> ListApplicationVersionsResponse
s {$sel:applicationVersionSummaries:ListApplicationVersionsResponse' :: Maybe [ApplicationVersionSummary]
applicationVersionSummaries = Maybe [ApplicationVersionSummary]
a} :: ListApplicationVersionsResponse) ((Maybe [ApplicationVersionSummary]
  -> f (Maybe [ApplicationVersionSummary]))
 -> ListApplicationVersionsResponse
 -> f ListApplicationVersionsResponse)
-> ((Maybe [ApplicationVersionSummary]
     -> f (Maybe [ApplicationVersionSummary]))
    -> Maybe [ApplicationVersionSummary]
    -> f (Maybe [ApplicationVersionSummary]))
-> (Maybe [ApplicationVersionSummary]
    -> f (Maybe [ApplicationVersionSummary]))
-> ListApplicationVersionsResponse
-> f ListApplicationVersionsResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [ApplicationVersionSummary]
  [ApplicationVersionSummary]
  [ApplicationVersionSummary]
  [ApplicationVersionSummary]
-> Iso
     (Maybe [ApplicationVersionSummary])
     (Maybe [ApplicationVersionSummary])
     (Maybe [ApplicationVersionSummary])
     (Maybe [ApplicationVersionSummary])
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
  [ApplicationVersionSummary]
  [ApplicationVersionSummary]
  [ApplicationVersionSummary]
  [ApplicationVersionSummary]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The pagination token for the next set of results, or @null@ if there are
-- no additional results. To retrieve the next set of items, pass this
-- token into a subsequent invocation of this operation. For more
-- information about pagination, see
-- <https://docs.aws.amazon.com/cli/latest/userguide/pagination.html Using the Amazon Command Line Interface\'s Pagination Options>.
listApplicationVersionsResponse_nextToken :: Lens.Lens' ListApplicationVersionsResponse (Prelude.Maybe Prelude.Text)
listApplicationVersionsResponse_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListApplicationVersionsResponse
-> f ListApplicationVersionsResponse
listApplicationVersionsResponse_nextToken = (ListApplicationVersionsResponse -> Maybe Text)
-> (ListApplicationVersionsResponse
    -> Maybe Text -> ListApplicationVersionsResponse)
-> Lens
     ListApplicationVersionsResponse
     ListApplicationVersionsResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListApplicationVersionsResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListApplicationVersionsResponse' :: ListApplicationVersionsResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListApplicationVersionsResponse
s@ListApplicationVersionsResponse' {} Maybe Text
a -> ListApplicationVersionsResponse
s {$sel:nextToken:ListApplicationVersionsResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListApplicationVersionsResponse)

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

instance
  Prelude.NFData
    ListApplicationVersionsResponse