{-# 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.SageMaker.ListAliases
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Lists the aliases of a specified image or image version.
--
-- This operation returns paginated results.
module Amazonka.SageMaker.ListAliases
  ( -- * Creating a Request
    ListAliases (..),
    newListAliases,

    -- * Request Lenses
    listAliases_alias,
    listAliases_maxResults,
    listAliases_nextToken,
    listAliases_version,
    listAliases_imageName,

    -- * Destructuring the Response
    ListAliasesResponse (..),
    newListAliasesResponse,

    -- * Response Lenses
    listAliasesResponse_nextToken,
    listAliasesResponse_sageMakerImageVersionAliases,
    listAliasesResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
import Amazonka.SageMaker.Types

-- | /See:/ 'newListAliases' smart constructor.
data ListAliases = ListAliases'
  { -- | The alias of the image version.
    ListAliases -> Maybe Text
alias :: Prelude.Maybe Prelude.Text,
    -- | The maximum number of aliases to return.
    ListAliases -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural,
    -- | If the previous call to @ListAliases@ didn\'t return the full set of
    -- aliases, the call returns a token for retrieving the next set of
    -- aliases.
    ListAliases -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The version of the image. If image version is not specified, the aliases
    -- of all versions of the image are listed.
    ListAliases -> Maybe Natural
version :: Prelude.Maybe Prelude.Natural,
    -- | The name of the image.
    ListAliases -> Text
imageName :: Prelude.Text
  }
  deriving (ListAliases -> ListAliases -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListAliases -> ListAliases -> Bool
$c/= :: ListAliases -> ListAliases -> Bool
== :: ListAliases -> ListAliases -> Bool
$c== :: ListAliases -> ListAliases -> Bool
Prelude.Eq, ReadPrec [ListAliases]
ReadPrec ListAliases
Int -> ReadS ListAliases
ReadS [ListAliases]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListAliases]
$creadListPrec :: ReadPrec [ListAliases]
readPrec :: ReadPrec ListAliases
$creadPrec :: ReadPrec ListAliases
readList :: ReadS [ListAliases]
$creadList :: ReadS [ListAliases]
readsPrec :: Int -> ReadS ListAliases
$creadsPrec :: Int -> ReadS ListAliases
Prelude.Read, Int -> ListAliases -> ShowS
[ListAliases] -> ShowS
ListAliases -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListAliases] -> ShowS
$cshowList :: [ListAliases] -> ShowS
show :: ListAliases -> String
$cshow :: ListAliases -> String
showsPrec :: Int -> ListAliases -> ShowS
$cshowsPrec :: Int -> ListAliases -> ShowS
Prelude.Show, forall x. Rep ListAliases x -> ListAliases
forall x. ListAliases -> Rep ListAliases x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListAliases x -> ListAliases
$cfrom :: forall x. ListAliases -> Rep ListAliases x
Prelude.Generic)

-- |
-- Create a value of 'ListAliases' 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:
--
-- 'alias', 'listAliases_alias' - The alias of the image version.
--
-- 'maxResults', 'listAliases_maxResults' - The maximum number of aliases to return.
--
-- 'nextToken', 'listAliases_nextToken' - If the previous call to @ListAliases@ didn\'t return the full set of
-- aliases, the call returns a token for retrieving the next set of
-- aliases.
--
-- 'version', 'listAliases_version' - The version of the image. If image version is not specified, the aliases
-- of all versions of the image are listed.
--
-- 'imageName', 'listAliases_imageName' - The name of the image.
newListAliases ::
  -- | 'imageName'
  Prelude.Text ->
  ListAliases
newListAliases :: Text -> ListAliases
newListAliases Text
pImageName_ =
  ListAliases'
    { $sel:alias:ListAliases' :: Maybe Text
alias = forall a. Maybe a
Prelude.Nothing,
      $sel:maxResults:ListAliases' :: Maybe Natural
maxResults = forall a. Maybe a
Prelude.Nothing,
      $sel:nextToken:ListAliases' :: Maybe Text
nextToken = forall a. Maybe a
Prelude.Nothing,
      $sel:version:ListAliases' :: Maybe Natural
version = forall a. Maybe a
Prelude.Nothing,
      $sel:imageName:ListAliases' :: Text
imageName = Text
pImageName_
    }

-- | The alias of the image version.
listAliases_alias :: Lens.Lens' ListAliases (Prelude.Maybe Prelude.Text)
listAliases_alias :: Lens' ListAliases (Maybe Text)
listAliases_alias = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAliases' {Maybe Text
alias :: Maybe Text
$sel:alias:ListAliases' :: ListAliases -> Maybe Text
alias} -> Maybe Text
alias) (\s :: ListAliases
s@ListAliases' {} Maybe Text
a -> ListAliases
s {$sel:alias:ListAliases' :: Maybe Text
alias = Maybe Text
a} :: ListAliases)

-- | The maximum number of aliases to return.
listAliases_maxResults :: Lens.Lens' ListAliases (Prelude.Maybe Prelude.Natural)
listAliases_maxResults :: Lens' ListAliases (Maybe Natural)
listAliases_maxResults = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAliases' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListAliases' :: ListAliases -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListAliases
s@ListAliases' {} Maybe Natural
a -> ListAliases
s {$sel:maxResults:ListAliases' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListAliases)

-- | If the previous call to @ListAliases@ didn\'t return the full set of
-- aliases, the call returns a token for retrieving the next set of
-- aliases.
listAliases_nextToken :: Lens.Lens' ListAliases (Prelude.Maybe Prelude.Text)
listAliases_nextToken :: Lens' ListAliases (Maybe Text)
listAliases_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAliases' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListAliases' :: ListAliases -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListAliases
s@ListAliases' {} Maybe Text
a -> ListAliases
s {$sel:nextToken:ListAliases' :: Maybe Text
nextToken = Maybe Text
a} :: ListAliases)

-- | The version of the image. If image version is not specified, the aliases
-- of all versions of the image are listed.
listAliases_version :: Lens.Lens' ListAliases (Prelude.Maybe Prelude.Natural)
listAliases_version :: Lens' ListAliases (Maybe Natural)
listAliases_version = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAliases' {Maybe Natural
version :: Maybe Natural
$sel:version:ListAliases' :: ListAliases -> Maybe Natural
version} -> Maybe Natural
version) (\s :: ListAliases
s@ListAliases' {} Maybe Natural
a -> ListAliases
s {$sel:version:ListAliases' :: Maybe Natural
version = Maybe Natural
a} :: ListAliases)

-- | The name of the image.
listAliases_imageName :: Lens.Lens' ListAliases Prelude.Text
listAliases_imageName :: Lens' ListAliases Text
listAliases_imageName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAliases' {Text
imageName :: Text
$sel:imageName:ListAliases' :: ListAliases -> Text
imageName} -> Text
imageName) (\s :: ListAliases
s@ListAliases' {} Text
a -> ListAliases
s {$sel:imageName:ListAliases' :: Text
imageName = Text
a} :: ListAliases)

instance Core.AWSPager ListAliases where
  page :: ListAliases -> AWSResponse ListAliases -> Maybe ListAliases
page ListAliases
rq AWSResponse ListAliases
rs
    | forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse ListAliases
rs
            forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListAliasesResponse (Maybe Text)
listAliasesResponse_nextToken
            forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
        ) =
        forall a. Maybe a
Prelude.Nothing
    | forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse ListAliases
rs
            forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListAliasesResponse (Maybe [Text])
listAliasesResponse_sageMakerImageVersionAliases
            forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
        ) =
        forall a. Maybe a
Prelude.Nothing
    | Bool
Prelude.otherwise =
        forall a. a -> Maybe a
Prelude.Just
          forall a b. (a -> b) -> a -> b
Prelude.$ ListAliases
rq
          forall a b. a -> (a -> b) -> b
Prelude.& Lens' ListAliases (Maybe Text)
listAliases_nextToken
          forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListAliases
rs
          forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListAliasesResponse (Maybe Text)
listAliasesResponse_nextToken
          forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just

instance Core.AWSRequest ListAliases where
  type AWSResponse ListAliases = ListAliasesResponse
  request :: (Service -> Service) -> ListAliases -> Request ListAliases
request Service -> Service
overrides =
    forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON (Service -> Service
overrides Service
defaultService)
  response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy ListAliases
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse ListAliases)))
response =
    forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
      ( \Int
s ResponseHeaders
h Object
x ->
          Maybe Text -> Maybe [Text] -> Int -> ListAliasesResponse
ListAliasesResponse'
            forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"NextToken")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"SageMakerImageVersionAliases"
                            forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ forall a. Monoid a => a
Prelude.mempty
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance Prelude.Hashable ListAliases where
  hashWithSalt :: Int -> ListAliases -> Int
hashWithSalt Int
_salt ListAliases' {Maybe Natural
Maybe Text
Text
imageName :: Text
version :: Maybe Natural
nextToken :: Maybe Text
maxResults :: Maybe Natural
alias :: Maybe Text
$sel:imageName:ListAliases' :: ListAliases -> Text
$sel:version:ListAliases' :: ListAliases -> Maybe Natural
$sel:nextToken:ListAliases' :: ListAliases -> Maybe Text
$sel:maxResults:ListAliases' :: ListAliases -> Maybe Natural
$sel:alias:ListAliases' :: ListAliases -> Maybe Text
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
alias
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
maxResults
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
nextToken
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
version
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
imageName

instance Prelude.NFData ListAliases where
  rnf :: ListAliases -> ()
rnf ListAliases' {Maybe Natural
Maybe Text
Text
imageName :: Text
version :: Maybe Natural
nextToken :: Maybe Text
maxResults :: Maybe Natural
alias :: Maybe Text
$sel:imageName:ListAliases' :: ListAliases -> Text
$sel:version:ListAliases' :: ListAliases -> Maybe Natural
$sel:nextToken:ListAliases' :: ListAliases -> Maybe Text
$sel:maxResults:ListAliases' :: ListAliases -> Maybe Natural
$sel:alias:ListAliases' :: ListAliases -> Maybe Text
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
alias
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
maxResults
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
nextToken
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
version
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
imageName

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

instance Data.ToJSON ListAliases where
  toJSON :: ListAliases -> Value
toJSON ListAliases' {Maybe Natural
Maybe Text
Text
imageName :: Text
version :: Maybe Natural
nextToken :: Maybe Text
maxResults :: Maybe Natural
alias :: Maybe Text
$sel:imageName:ListAliases' :: ListAliases -> Text
$sel:version:ListAliases' :: ListAliases -> Maybe Natural
$sel:nextToken:ListAliases' :: ListAliases -> Maybe Text
$sel:maxResults:ListAliases' :: ListAliases -> Maybe Natural
$sel:alias:ListAliases' :: ListAliases -> Maybe Text
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Key
"Alias" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
alias,
            (Key
"MaxResults" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Natural
maxResults,
            (Key
"NextToken" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
nextToken,
            (Key
"Version" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Natural
version,
            forall a. a -> Maybe a
Prelude.Just (Key
"ImageName" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
imageName)
          ]
      )

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

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

-- | /See:/ 'newListAliasesResponse' smart constructor.
data ListAliasesResponse = ListAliasesResponse'
  { -- | A token for getting the next set of aliases, if more aliases exist.
    ListAliasesResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | A list of SageMaker image version aliases.
    ListAliasesResponse -> Maybe [Text]
sageMakerImageVersionAliases :: Prelude.Maybe [Prelude.Text],
    -- | The response's http status code.
    ListAliasesResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (ListAliasesResponse -> ListAliasesResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListAliasesResponse -> ListAliasesResponse -> Bool
$c/= :: ListAliasesResponse -> ListAliasesResponse -> Bool
== :: ListAliasesResponse -> ListAliasesResponse -> Bool
$c== :: ListAliasesResponse -> ListAliasesResponse -> Bool
Prelude.Eq, ReadPrec [ListAliasesResponse]
ReadPrec ListAliasesResponse
Int -> ReadS ListAliasesResponse
ReadS [ListAliasesResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListAliasesResponse]
$creadListPrec :: ReadPrec [ListAliasesResponse]
readPrec :: ReadPrec ListAliasesResponse
$creadPrec :: ReadPrec ListAliasesResponse
readList :: ReadS [ListAliasesResponse]
$creadList :: ReadS [ListAliasesResponse]
readsPrec :: Int -> ReadS ListAliasesResponse
$creadsPrec :: Int -> ReadS ListAliasesResponse
Prelude.Read, Int -> ListAliasesResponse -> ShowS
[ListAliasesResponse] -> ShowS
ListAliasesResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListAliasesResponse] -> ShowS
$cshowList :: [ListAliasesResponse] -> ShowS
show :: ListAliasesResponse -> String
$cshow :: ListAliasesResponse -> String
showsPrec :: Int -> ListAliasesResponse -> ShowS
$cshowsPrec :: Int -> ListAliasesResponse -> ShowS
Prelude.Show, forall x. Rep ListAliasesResponse x -> ListAliasesResponse
forall x. ListAliasesResponse -> Rep ListAliasesResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListAliasesResponse x -> ListAliasesResponse
$cfrom :: forall x. ListAliasesResponse -> Rep ListAliasesResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListAliasesResponse' 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', 'listAliasesResponse_nextToken' - A token for getting the next set of aliases, if more aliases exist.
--
-- 'sageMakerImageVersionAliases', 'listAliasesResponse_sageMakerImageVersionAliases' - A list of SageMaker image version aliases.
--
-- 'httpStatus', 'listAliasesResponse_httpStatus' - The response's http status code.
newListAliasesResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ListAliasesResponse
newListAliasesResponse :: Int -> ListAliasesResponse
newListAliasesResponse Int
pHttpStatus_ =
  ListAliasesResponse'
    { $sel:nextToken:ListAliasesResponse' :: Maybe Text
nextToken = forall a. Maybe a
Prelude.Nothing,
      $sel:sageMakerImageVersionAliases:ListAliasesResponse' :: Maybe [Text]
sageMakerImageVersionAliases = forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:ListAliasesResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | A token for getting the next set of aliases, if more aliases exist.
listAliasesResponse_nextToken :: Lens.Lens' ListAliasesResponse (Prelude.Maybe Prelude.Text)
listAliasesResponse_nextToken :: Lens' ListAliasesResponse (Maybe Text)
listAliasesResponse_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAliasesResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListAliasesResponse' :: ListAliasesResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListAliasesResponse
s@ListAliasesResponse' {} Maybe Text
a -> ListAliasesResponse
s {$sel:nextToken:ListAliasesResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListAliasesResponse)

-- | A list of SageMaker image version aliases.
listAliasesResponse_sageMakerImageVersionAliases :: Lens.Lens' ListAliasesResponse (Prelude.Maybe [Prelude.Text])
listAliasesResponse_sageMakerImageVersionAliases :: Lens' ListAliasesResponse (Maybe [Text])
listAliasesResponse_sageMakerImageVersionAliases = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAliasesResponse' {Maybe [Text]
sageMakerImageVersionAliases :: Maybe [Text]
$sel:sageMakerImageVersionAliases:ListAliasesResponse' :: ListAliasesResponse -> Maybe [Text]
sageMakerImageVersionAliases} -> Maybe [Text]
sageMakerImageVersionAliases) (\s :: ListAliasesResponse
s@ListAliasesResponse' {} Maybe [Text]
a -> ListAliasesResponse
s {$sel:sageMakerImageVersionAliases:ListAliasesResponse' :: Maybe [Text]
sageMakerImageVersionAliases = Maybe [Text]
a} :: ListAliasesResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

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

instance Prelude.NFData ListAliasesResponse where
  rnf :: ListAliasesResponse -> ()
rnf ListAliasesResponse' {Int
Maybe [Text]
Maybe Text
httpStatus :: Int
sageMakerImageVersionAliases :: Maybe [Text]
nextToken :: Maybe Text
$sel:httpStatus:ListAliasesResponse' :: ListAliasesResponse -> Int
$sel:sageMakerImageVersionAliases:ListAliasesResponse' :: ListAliasesResponse -> Maybe [Text]
$sel:nextToken:ListAliasesResponse' :: ListAliasesResponse -> Maybe Text
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
nextToken
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
sageMakerImageVersionAliases
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus