{-# 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.ListNotebookInstanceLifecycleConfigs
-- 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 notebook instance lifestyle configurations created with the
-- CreateNotebookInstanceLifecycleConfig API.
--
-- This operation returns paginated results.
module Amazonka.SageMaker.ListNotebookInstanceLifecycleConfigs
  ( -- * Creating a Request
    ListNotebookInstanceLifecycleConfigs (..),
    newListNotebookInstanceLifecycleConfigs,

    -- * Request Lenses
    listNotebookInstanceLifecycleConfigs_nameContains,
    listNotebookInstanceLifecycleConfigs_lastModifiedTimeBefore,
    listNotebookInstanceLifecycleConfigs_creationTimeAfter,
    listNotebookInstanceLifecycleConfigs_nextToken,
    listNotebookInstanceLifecycleConfigs_sortOrder,
    listNotebookInstanceLifecycleConfigs_lastModifiedTimeAfter,
    listNotebookInstanceLifecycleConfigs_creationTimeBefore,
    listNotebookInstanceLifecycleConfigs_maxResults,
    listNotebookInstanceLifecycleConfigs_sortBy,

    -- * Destructuring the Response
    ListNotebookInstanceLifecycleConfigsResponse (..),
    newListNotebookInstanceLifecycleConfigsResponse,

    -- * Response Lenses
    listNotebookInstanceLifecycleConfigsResponse_nextToken,
    listNotebookInstanceLifecycleConfigsResponse_notebookInstanceLifecycleConfigs,
    listNotebookInstanceLifecycleConfigsResponse_httpStatus,
  )
where

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

-- | /See:/ 'newListNotebookInstanceLifecycleConfigs' smart constructor.
data ListNotebookInstanceLifecycleConfigs = ListNotebookInstanceLifecycleConfigs'
  { -- | A string in the lifecycle configuration name. This filter returns only
    -- lifecycle configurations whose name contains the specified string.
    ListNotebookInstanceLifecycleConfigs -> Maybe Text
nameContains :: Prelude.Maybe Prelude.Text,
    -- | A filter that returns only lifecycle configurations that were modified
    -- before the specified time (timestamp).
    ListNotebookInstanceLifecycleConfigs -> Maybe POSIX
lastModifiedTimeBefore :: Prelude.Maybe Core.POSIX,
    -- | A filter that returns only lifecycle configurations that were created
    -- after the specified time (timestamp).
    ListNotebookInstanceLifecycleConfigs -> Maybe POSIX
creationTimeAfter :: Prelude.Maybe Core.POSIX,
    -- | If the result of a @ListNotebookInstanceLifecycleConfigs@ request was
    -- truncated, the response includes a @NextToken@. To get the next set of
    -- lifecycle configurations, use the token in the next request.
    ListNotebookInstanceLifecycleConfigs -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The sort order for results.
    ListNotebookInstanceLifecycleConfigs
-> Maybe NotebookInstanceLifecycleConfigSortOrder
sortOrder :: Prelude.Maybe NotebookInstanceLifecycleConfigSortOrder,
    -- | A filter that returns only lifecycle configurations that were modified
    -- after the specified time (timestamp).
    ListNotebookInstanceLifecycleConfigs -> Maybe POSIX
lastModifiedTimeAfter :: Prelude.Maybe Core.POSIX,
    -- | A filter that returns only lifecycle configurations that were created
    -- before the specified time (timestamp).
    ListNotebookInstanceLifecycleConfigs -> Maybe POSIX
creationTimeBefore :: Prelude.Maybe Core.POSIX,
    -- | The maximum number of lifecycle configurations to return in the
    -- response.
    ListNotebookInstanceLifecycleConfigs -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural,
    -- | Sorts the list of results. The default is @CreationTime@.
    ListNotebookInstanceLifecycleConfigs
-> Maybe NotebookInstanceLifecycleConfigSortKey
sortBy :: Prelude.Maybe NotebookInstanceLifecycleConfigSortKey
  }
  deriving (ListNotebookInstanceLifecycleConfigs
-> ListNotebookInstanceLifecycleConfigs -> Bool
(ListNotebookInstanceLifecycleConfigs
 -> ListNotebookInstanceLifecycleConfigs -> Bool)
-> (ListNotebookInstanceLifecycleConfigs
    -> ListNotebookInstanceLifecycleConfigs -> Bool)
-> Eq ListNotebookInstanceLifecycleConfigs
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListNotebookInstanceLifecycleConfigs
-> ListNotebookInstanceLifecycleConfigs -> Bool
$c/= :: ListNotebookInstanceLifecycleConfigs
-> ListNotebookInstanceLifecycleConfigs -> Bool
== :: ListNotebookInstanceLifecycleConfigs
-> ListNotebookInstanceLifecycleConfigs -> Bool
$c== :: ListNotebookInstanceLifecycleConfigs
-> ListNotebookInstanceLifecycleConfigs -> Bool
Prelude.Eq, ReadPrec [ListNotebookInstanceLifecycleConfigs]
ReadPrec ListNotebookInstanceLifecycleConfigs
Int -> ReadS ListNotebookInstanceLifecycleConfigs
ReadS [ListNotebookInstanceLifecycleConfigs]
(Int -> ReadS ListNotebookInstanceLifecycleConfigs)
-> ReadS [ListNotebookInstanceLifecycleConfigs]
-> ReadPrec ListNotebookInstanceLifecycleConfigs
-> ReadPrec [ListNotebookInstanceLifecycleConfigs]
-> Read ListNotebookInstanceLifecycleConfigs
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListNotebookInstanceLifecycleConfigs]
$creadListPrec :: ReadPrec [ListNotebookInstanceLifecycleConfigs]
readPrec :: ReadPrec ListNotebookInstanceLifecycleConfigs
$creadPrec :: ReadPrec ListNotebookInstanceLifecycleConfigs
readList :: ReadS [ListNotebookInstanceLifecycleConfigs]
$creadList :: ReadS [ListNotebookInstanceLifecycleConfigs]
readsPrec :: Int -> ReadS ListNotebookInstanceLifecycleConfigs
$creadsPrec :: Int -> ReadS ListNotebookInstanceLifecycleConfigs
Prelude.Read, Int -> ListNotebookInstanceLifecycleConfigs -> ShowS
[ListNotebookInstanceLifecycleConfigs] -> ShowS
ListNotebookInstanceLifecycleConfigs -> String
(Int -> ListNotebookInstanceLifecycleConfigs -> ShowS)
-> (ListNotebookInstanceLifecycleConfigs -> String)
-> ([ListNotebookInstanceLifecycleConfigs] -> ShowS)
-> Show ListNotebookInstanceLifecycleConfigs
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListNotebookInstanceLifecycleConfigs] -> ShowS
$cshowList :: [ListNotebookInstanceLifecycleConfigs] -> ShowS
show :: ListNotebookInstanceLifecycleConfigs -> String
$cshow :: ListNotebookInstanceLifecycleConfigs -> String
showsPrec :: Int -> ListNotebookInstanceLifecycleConfigs -> ShowS
$cshowsPrec :: Int -> ListNotebookInstanceLifecycleConfigs -> ShowS
Prelude.Show, (forall x.
 ListNotebookInstanceLifecycleConfigs
 -> Rep ListNotebookInstanceLifecycleConfigs x)
-> (forall x.
    Rep ListNotebookInstanceLifecycleConfigs x
    -> ListNotebookInstanceLifecycleConfigs)
-> Generic ListNotebookInstanceLifecycleConfigs
forall x.
Rep ListNotebookInstanceLifecycleConfigs x
-> ListNotebookInstanceLifecycleConfigs
forall x.
ListNotebookInstanceLifecycleConfigs
-> Rep ListNotebookInstanceLifecycleConfigs x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListNotebookInstanceLifecycleConfigs x
-> ListNotebookInstanceLifecycleConfigs
$cfrom :: forall x.
ListNotebookInstanceLifecycleConfigs
-> Rep ListNotebookInstanceLifecycleConfigs x
Prelude.Generic)

-- |
-- Create a value of 'ListNotebookInstanceLifecycleConfigs' 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:
--
-- 'nameContains', 'listNotebookInstanceLifecycleConfigs_nameContains' - A string in the lifecycle configuration name. This filter returns only
-- lifecycle configurations whose name contains the specified string.
--
-- 'lastModifiedTimeBefore', 'listNotebookInstanceLifecycleConfigs_lastModifiedTimeBefore' - A filter that returns only lifecycle configurations that were modified
-- before the specified time (timestamp).
--
-- 'creationTimeAfter', 'listNotebookInstanceLifecycleConfigs_creationTimeAfter' - A filter that returns only lifecycle configurations that were created
-- after the specified time (timestamp).
--
-- 'nextToken', 'listNotebookInstanceLifecycleConfigs_nextToken' - If the result of a @ListNotebookInstanceLifecycleConfigs@ request was
-- truncated, the response includes a @NextToken@. To get the next set of
-- lifecycle configurations, use the token in the next request.
--
-- 'sortOrder', 'listNotebookInstanceLifecycleConfigs_sortOrder' - The sort order for results.
--
-- 'lastModifiedTimeAfter', 'listNotebookInstanceLifecycleConfigs_lastModifiedTimeAfter' - A filter that returns only lifecycle configurations that were modified
-- after the specified time (timestamp).
--
-- 'creationTimeBefore', 'listNotebookInstanceLifecycleConfigs_creationTimeBefore' - A filter that returns only lifecycle configurations that were created
-- before the specified time (timestamp).
--
-- 'maxResults', 'listNotebookInstanceLifecycleConfigs_maxResults' - The maximum number of lifecycle configurations to return in the
-- response.
--
-- 'sortBy', 'listNotebookInstanceLifecycleConfigs_sortBy' - Sorts the list of results. The default is @CreationTime@.
newListNotebookInstanceLifecycleConfigs ::
  ListNotebookInstanceLifecycleConfigs
newListNotebookInstanceLifecycleConfigs :: ListNotebookInstanceLifecycleConfigs
newListNotebookInstanceLifecycleConfigs =
  ListNotebookInstanceLifecycleConfigs' :: Maybe Text
-> Maybe POSIX
-> Maybe POSIX
-> Maybe Text
-> Maybe NotebookInstanceLifecycleConfigSortOrder
-> Maybe POSIX
-> Maybe POSIX
-> Maybe Natural
-> Maybe NotebookInstanceLifecycleConfigSortKey
-> ListNotebookInstanceLifecycleConfigs
ListNotebookInstanceLifecycleConfigs'
    { $sel:nameContains:ListNotebookInstanceLifecycleConfigs' :: Maybe Text
nameContains =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:lastModifiedTimeBefore:ListNotebookInstanceLifecycleConfigs' :: Maybe POSIX
lastModifiedTimeBefore =
        Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:creationTimeAfter:ListNotebookInstanceLifecycleConfigs' :: Maybe POSIX
creationTimeAfter = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:nextToken:ListNotebookInstanceLifecycleConfigs' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:sortOrder:ListNotebookInstanceLifecycleConfigs' :: Maybe NotebookInstanceLifecycleConfigSortOrder
sortOrder = Maybe NotebookInstanceLifecycleConfigSortOrder
forall a. Maybe a
Prelude.Nothing,
      $sel:lastModifiedTimeAfter:ListNotebookInstanceLifecycleConfigs' :: Maybe POSIX
lastModifiedTimeAfter =
        Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:creationTimeBefore:ListNotebookInstanceLifecycleConfigs' :: Maybe POSIX
creationTimeBefore = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:maxResults:ListNotebookInstanceLifecycleConfigs' :: Maybe Natural
maxResults = Maybe Natural
forall a. Maybe a
Prelude.Nothing,
      $sel:sortBy:ListNotebookInstanceLifecycleConfigs' :: Maybe NotebookInstanceLifecycleConfigSortKey
sortBy = Maybe NotebookInstanceLifecycleConfigSortKey
forall a. Maybe a
Prelude.Nothing
    }

-- | A string in the lifecycle configuration name. This filter returns only
-- lifecycle configurations whose name contains the specified string.
listNotebookInstanceLifecycleConfigs_nameContains :: Lens.Lens' ListNotebookInstanceLifecycleConfigs (Prelude.Maybe Prelude.Text)
listNotebookInstanceLifecycleConfigs_nameContains :: (Maybe Text -> f (Maybe Text))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
listNotebookInstanceLifecycleConfigs_nameContains = (ListNotebookInstanceLifecycleConfigs -> Maybe Text)
-> (ListNotebookInstanceLifecycleConfigs
    -> Maybe Text -> ListNotebookInstanceLifecycleConfigs)
-> Lens
     ListNotebookInstanceLifecycleConfigs
     ListNotebookInstanceLifecycleConfigs
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListNotebookInstanceLifecycleConfigs' {Maybe Text
nameContains :: Maybe Text
$sel:nameContains:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe Text
nameContains} -> Maybe Text
nameContains) (\s :: ListNotebookInstanceLifecycleConfigs
s@ListNotebookInstanceLifecycleConfigs' {} Maybe Text
a -> ListNotebookInstanceLifecycleConfigs
s {$sel:nameContains:ListNotebookInstanceLifecycleConfigs' :: Maybe Text
nameContains = Maybe Text
a} :: ListNotebookInstanceLifecycleConfigs)

-- | A filter that returns only lifecycle configurations that were modified
-- before the specified time (timestamp).
listNotebookInstanceLifecycleConfigs_lastModifiedTimeBefore :: Lens.Lens' ListNotebookInstanceLifecycleConfigs (Prelude.Maybe Prelude.UTCTime)
listNotebookInstanceLifecycleConfigs_lastModifiedTimeBefore :: (Maybe UTCTime -> f (Maybe UTCTime))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
listNotebookInstanceLifecycleConfigs_lastModifiedTimeBefore = (ListNotebookInstanceLifecycleConfigs -> Maybe POSIX)
-> (ListNotebookInstanceLifecycleConfigs
    -> Maybe POSIX -> ListNotebookInstanceLifecycleConfigs)
-> Lens
     ListNotebookInstanceLifecycleConfigs
     ListNotebookInstanceLifecycleConfigs
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListNotebookInstanceLifecycleConfigs' {Maybe POSIX
lastModifiedTimeBefore :: Maybe POSIX
$sel:lastModifiedTimeBefore:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe POSIX
lastModifiedTimeBefore} -> Maybe POSIX
lastModifiedTimeBefore) (\s :: ListNotebookInstanceLifecycleConfigs
s@ListNotebookInstanceLifecycleConfigs' {} Maybe POSIX
a -> ListNotebookInstanceLifecycleConfigs
s {$sel:lastModifiedTimeBefore:ListNotebookInstanceLifecycleConfigs' :: Maybe POSIX
lastModifiedTimeBefore = Maybe POSIX
a} :: ListNotebookInstanceLifecycleConfigs) ((Maybe POSIX -> f (Maybe POSIX))
 -> ListNotebookInstanceLifecycleConfigs
 -> f ListNotebookInstanceLifecycleConfigs)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

-- | A filter that returns only lifecycle configurations that were created
-- after the specified time (timestamp).
listNotebookInstanceLifecycleConfigs_creationTimeAfter :: Lens.Lens' ListNotebookInstanceLifecycleConfigs (Prelude.Maybe Prelude.UTCTime)
listNotebookInstanceLifecycleConfigs_creationTimeAfter :: (Maybe UTCTime -> f (Maybe UTCTime))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
listNotebookInstanceLifecycleConfigs_creationTimeAfter = (ListNotebookInstanceLifecycleConfigs -> Maybe POSIX)
-> (ListNotebookInstanceLifecycleConfigs
    -> Maybe POSIX -> ListNotebookInstanceLifecycleConfigs)
-> Lens
     ListNotebookInstanceLifecycleConfigs
     ListNotebookInstanceLifecycleConfigs
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListNotebookInstanceLifecycleConfigs' {Maybe POSIX
creationTimeAfter :: Maybe POSIX
$sel:creationTimeAfter:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe POSIX
creationTimeAfter} -> Maybe POSIX
creationTimeAfter) (\s :: ListNotebookInstanceLifecycleConfigs
s@ListNotebookInstanceLifecycleConfigs' {} Maybe POSIX
a -> ListNotebookInstanceLifecycleConfigs
s {$sel:creationTimeAfter:ListNotebookInstanceLifecycleConfigs' :: Maybe POSIX
creationTimeAfter = Maybe POSIX
a} :: ListNotebookInstanceLifecycleConfigs) ((Maybe POSIX -> f (Maybe POSIX))
 -> ListNotebookInstanceLifecycleConfigs
 -> f ListNotebookInstanceLifecycleConfigs)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

-- | If the result of a @ListNotebookInstanceLifecycleConfigs@ request was
-- truncated, the response includes a @NextToken@. To get the next set of
-- lifecycle configurations, use the token in the next request.
listNotebookInstanceLifecycleConfigs_nextToken :: Lens.Lens' ListNotebookInstanceLifecycleConfigs (Prelude.Maybe Prelude.Text)
listNotebookInstanceLifecycleConfigs_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
listNotebookInstanceLifecycleConfigs_nextToken = (ListNotebookInstanceLifecycleConfigs -> Maybe Text)
-> (ListNotebookInstanceLifecycleConfigs
    -> Maybe Text -> ListNotebookInstanceLifecycleConfigs)
-> Lens
     ListNotebookInstanceLifecycleConfigs
     ListNotebookInstanceLifecycleConfigs
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListNotebookInstanceLifecycleConfigs' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListNotebookInstanceLifecycleConfigs
s@ListNotebookInstanceLifecycleConfigs' {} Maybe Text
a -> ListNotebookInstanceLifecycleConfigs
s {$sel:nextToken:ListNotebookInstanceLifecycleConfigs' :: Maybe Text
nextToken = Maybe Text
a} :: ListNotebookInstanceLifecycleConfigs)

-- | The sort order for results.
listNotebookInstanceLifecycleConfigs_sortOrder :: Lens.Lens' ListNotebookInstanceLifecycleConfigs (Prelude.Maybe NotebookInstanceLifecycleConfigSortOrder)
listNotebookInstanceLifecycleConfigs_sortOrder :: (Maybe NotebookInstanceLifecycleConfigSortOrder
 -> f (Maybe NotebookInstanceLifecycleConfigSortOrder))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
listNotebookInstanceLifecycleConfigs_sortOrder = (ListNotebookInstanceLifecycleConfigs
 -> Maybe NotebookInstanceLifecycleConfigSortOrder)
-> (ListNotebookInstanceLifecycleConfigs
    -> Maybe NotebookInstanceLifecycleConfigSortOrder
    -> ListNotebookInstanceLifecycleConfigs)
-> Lens
     ListNotebookInstanceLifecycleConfigs
     ListNotebookInstanceLifecycleConfigs
     (Maybe NotebookInstanceLifecycleConfigSortOrder)
     (Maybe NotebookInstanceLifecycleConfigSortOrder)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListNotebookInstanceLifecycleConfigs' {Maybe NotebookInstanceLifecycleConfigSortOrder
sortOrder :: Maybe NotebookInstanceLifecycleConfigSortOrder
$sel:sortOrder:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs
-> Maybe NotebookInstanceLifecycleConfigSortOrder
sortOrder} -> Maybe NotebookInstanceLifecycleConfigSortOrder
sortOrder) (\s :: ListNotebookInstanceLifecycleConfigs
s@ListNotebookInstanceLifecycleConfigs' {} Maybe NotebookInstanceLifecycleConfigSortOrder
a -> ListNotebookInstanceLifecycleConfigs
s {$sel:sortOrder:ListNotebookInstanceLifecycleConfigs' :: Maybe NotebookInstanceLifecycleConfigSortOrder
sortOrder = Maybe NotebookInstanceLifecycleConfigSortOrder
a} :: ListNotebookInstanceLifecycleConfigs)

-- | A filter that returns only lifecycle configurations that were modified
-- after the specified time (timestamp).
listNotebookInstanceLifecycleConfigs_lastModifiedTimeAfter :: Lens.Lens' ListNotebookInstanceLifecycleConfigs (Prelude.Maybe Prelude.UTCTime)
listNotebookInstanceLifecycleConfigs_lastModifiedTimeAfter :: (Maybe UTCTime -> f (Maybe UTCTime))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
listNotebookInstanceLifecycleConfigs_lastModifiedTimeAfter = (ListNotebookInstanceLifecycleConfigs -> Maybe POSIX)
-> (ListNotebookInstanceLifecycleConfigs
    -> Maybe POSIX -> ListNotebookInstanceLifecycleConfigs)
-> Lens
     ListNotebookInstanceLifecycleConfigs
     ListNotebookInstanceLifecycleConfigs
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListNotebookInstanceLifecycleConfigs' {Maybe POSIX
lastModifiedTimeAfter :: Maybe POSIX
$sel:lastModifiedTimeAfter:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe POSIX
lastModifiedTimeAfter} -> Maybe POSIX
lastModifiedTimeAfter) (\s :: ListNotebookInstanceLifecycleConfigs
s@ListNotebookInstanceLifecycleConfigs' {} Maybe POSIX
a -> ListNotebookInstanceLifecycleConfigs
s {$sel:lastModifiedTimeAfter:ListNotebookInstanceLifecycleConfigs' :: Maybe POSIX
lastModifiedTimeAfter = Maybe POSIX
a} :: ListNotebookInstanceLifecycleConfigs) ((Maybe POSIX -> f (Maybe POSIX))
 -> ListNotebookInstanceLifecycleConfigs
 -> f ListNotebookInstanceLifecycleConfigs)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

-- | A filter that returns only lifecycle configurations that were created
-- before the specified time (timestamp).
listNotebookInstanceLifecycleConfigs_creationTimeBefore :: Lens.Lens' ListNotebookInstanceLifecycleConfigs (Prelude.Maybe Prelude.UTCTime)
listNotebookInstanceLifecycleConfigs_creationTimeBefore :: (Maybe UTCTime -> f (Maybe UTCTime))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
listNotebookInstanceLifecycleConfigs_creationTimeBefore = (ListNotebookInstanceLifecycleConfigs -> Maybe POSIX)
-> (ListNotebookInstanceLifecycleConfigs
    -> Maybe POSIX -> ListNotebookInstanceLifecycleConfigs)
-> Lens
     ListNotebookInstanceLifecycleConfigs
     ListNotebookInstanceLifecycleConfigs
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListNotebookInstanceLifecycleConfigs' {Maybe POSIX
creationTimeBefore :: Maybe POSIX
$sel:creationTimeBefore:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe POSIX
creationTimeBefore} -> Maybe POSIX
creationTimeBefore) (\s :: ListNotebookInstanceLifecycleConfigs
s@ListNotebookInstanceLifecycleConfigs' {} Maybe POSIX
a -> ListNotebookInstanceLifecycleConfigs
s {$sel:creationTimeBefore:ListNotebookInstanceLifecycleConfigs' :: Maybe POSIX
creationTimeBefore = Maybe POSIX
a} :: ListNotebookInstanceLifecycleConfigs) ((Maybe POSIX -> f (Maybe POSIX))
 -> ListNotebookInstanceLifecycleConfigs
 -> f ListNotebookInstanceLifecycleConfigs)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

-- | The maximum number of lifecycle configurations to return in the
-- response.
listNotebookInstanceLifecycleConfigs_maxResults :: Lens.Lens' ListNotebookInstanceLifecycleConfigs (Prelude.Maybe Prelude.Natural)
listNotebookInstanceLifecycleConfigs_maxResults :: (Maybe Natural -> f (Maybe Natural))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
listNotebookInstanceLifecycleConfigs_maxResults = (ListNotebookInstanceLifecycleConfigs -> Maybe Natural)
-> (ListNotebookInstanceLifecycleConfigs
    -> Maybe Natural -> ListNotebookInstanceLifecycleConfigs)
-> Lens
     ListNotebookInstanceLifecycleConfigs
     ListNotebookInstanceLifecycleConfigs
     (Maybe Natural)
     (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListNotebookInstanceLifecycleConfigs' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListNotebookInstanceLifecycleConfigs
s@ListNotebookInstanceLifecycleConfigs' {} Maybe Natural
a -> ListNotebookInstanceLifecycleConfigs
s {$sel:maxResults:ListNotebookInstanceLifecycleConfigs' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListNotebookInstanceLifecycleConfigs)

-- | Sorts the list of results. The default is @CreationTime@.
listNotebookInstanceLifecycleConfigs_sortBy :: Lens.Lens' ListNotebookInstanceLifecycleConfigs (Prelude.Maybe NotebookInstanceLifecycleConfigSortKey)
listNotebookInstanceLifecycleConfigs_sortBy :: (Maybe NotebookInstanceLifecycleConfigSortKey
 -> f (Maybe NotebookInstanceLifecycleConfigSortKey))
-> ListNotebookInstanceLifecycleConfigs
-> f ListNotebookInstanceLifecycleConfigs
listNotebookInstanceLifecycleConfigs_sortBy = (ListNotebookInstanceLifecycleConfigs
 -> Maybe NotebookInstanceLifecycleConfigSortKey)
-> (ListNotebookInstanceLifecycleConfigs
    -> Maybe NotebookInstanceLifecycleConfigSortKey
    -> ListNotebookInstanceLifecycleConfigs)
-> Lens
     ListNotebookInstanceLifecycleConfigs
     ListNotebookInstanceLifecycleConfigs
     (Maybe NotebookInstanceLifecycleConfigSortKey)
     (Maybe NotebookInstanceLifecycleConfigSortKey)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListNotebookInstanceLifecycleConfigs' {Maybe NotebookInstanceLifecycleConfigSortKey
sortBy :: Maybe NotebookInstanceLifecycleConfigSortKey
$sel:sortBy:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs
-> Maybe NotebookInstanceLifecycleConfigSortKey
sortBy} -> Maybe NotebookInstanceLifecycleConfigSortKey
sortBy) (\s :: ListNotebookInstanceLifecycleConfigs
s@ListNotebookInstanceLifecycleConfigs' {} Maybe NotebookInstanceLifecycleConfigSortKey
a -> ListNotebookInstanceLifecycleConfigs
s {$sel:sortBy:ListNotebookInstanceLifecycleConfigs' :: Maybe NotebookInstanceLifecycleConfigSortKey
sortBy = Maybe NotebookInstanceLifecycleConfigSortKey
a} :: ListNotebookInstanceLifecycleConfigs)

instance
  Core.AWSPager
    ListNotebookInstanceLifecycleConfigs
  where
  page :: ListNotebookInstanceLifecycleConfigs
-> AWSResponse ListNotebookInstanceLifecycleConfigs
-> Maybe ListNotebookInstanceLifecycleConfigs
page ListNotebookInstanceLifecycleConfigs
rq AWSResponse ListNotebookInstanceLifecycleConfigs
rs
    | Maybe Text -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse ListNotebookInstanceLifecycleConfigs
ListNotebookInstanceLifecycleConfigsResponse
rs
            ListNotebookInstanceLifecycleConfigsResponse
-> Getting
     (First Text) ListNotebookInstanceLifecycleConfigsResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> ListNotebookInstanceLifecycleConfigsResponse
-> Const (First Text) ListNotebookInstanceLifecycleConfigsResponse
Lens' ListNotebookInstanceLifecycleConfigsResponse (Maybe Text)
listNotebookInstanceLifecycleConfigsResponse_nextToken
              ((Maybe Text -> Const (First Text) (Maybe Text))
 -> ListNotebookInstanceLifecycleConfigsResponse
 -> Const (First Text) ListNotebookInstanceLifecycleConfigsResponse)
-> ((Text -> Const (First Text) Text)
    -> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting
     (First Text) ListNotebookInstanceLifecycleConfigsResponse 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 ListNotebookInstanceLifecycleConfigs
forall a. Maybe a
Prelude.Nothing
    | Maybe [NotebookInstanceLifecycleConfigSummary] -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse ListNotebookInstanceLifecycleConfigs
ListNotebookInstanceLifecycleConfigsResponse
rs
            ListNotebookInstanceLifecycleConfigsResponse
-> Getting
     (First [NotebookInstanceLifecycleConfigSummary])
     ListNotebookInstanceLifecycleConfigsResponse
     [NotebookInstanceLifecycleConfigSummary]
-> Maybe [NotebookInstanceLifecycleConfigSummary]
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe [NotebookInstanceLifecycleConfigSummary]
 -> Const
      (First [NotebookInstanceLifecycleConfigSummary])
      (Maybe [NotebookInstanceLifecycleConfigSummary]))
-> ListNotebookInstanceLifecycleConfigsResponse
-> Const
     (First [NotebookInstanceLifecycleConfigSummary])
     ListNotebookInstanceLifecycleConfigsResponse
Lens'
  ListNotebookInstanceLifecycleConfigsResponse
  (Maybe [NotebookInstanceLifecycleConfigSummary])
listNotebookInstanceLifecycleConfigsResponse_notebookInstanceLifecycleConfigs
              ((Maybe [NotebookInstanceLifecycleConfigSummary]
  -> Const
       (First [NotebookInstanceLifecycleConfigSummary])
       (Maybe [NotebookInstanceLifecycleConfigSummary]))
 -> ListNotebookInstanceLifecycleConfigsResponse
 -> Const
      (First [NotebookInstanceLifecycleConfigSummary])
      ListNotebookInstanceLifecycleConfigsResponse)
-> (([NotebookInstanceLifecycleConfigSummary]
     -> Const
          (First [NotebookInstanceLifecycleConfigSummary])
          [NotebookInstanceLifecycleConfigSummary])
    -> Maybe [NotebookInstanceLifecycleConfigSummary]
    -> Const
         (First [NotebookInstanceLifecycleConfigSummary])
         (Maybe [NotebookInstanceLifecycleConfigSummary]))
-> Getting
     (First [NotebookInstanceLifecycleConfigSummary])
     ListNotebookInstanceLifecycleConfigsResponse
     [NotebookInstanceLifecycleConfigSummary]
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([NotebookInstanceLifecycleConfigSummary]
 -> Const
      (First [NotebookInstanceLifecycleConfigSummary])
      [NotebookInstanceLifecycleConfigSummary])
-> Maybe [NotebookInstanceLifecycleConfigSummary]
-> Const
     (First [NotebookInstanceLifecycleConfigSummary])
     (Maybe [NotebookInstanceLifecycleConfigSummary])
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
        ) =
      Maybe ListNotebookInstanceLifecycleConfigs
forall a. Maybe a
Prelude.Nothing
    | Bool
Prelude.otherwise =
      ListNotebookInstanceLifecycleConfigs
-> Maybe ListNotebookInstanceLifecycleConfigs
forall a. a -> Maybe a
Prelude.Just (ListNotebookInstanceLifecycleConfigs
 -> Maybe ListNotebookInstanceLifecycleConfigs)
-> ListNotebookInstanceLifecycleConfigs
-> Maybe ListNotebookInstanceLifecycleConfigs
forall a b. (a -> b) -> a -> b
Prelude.$
        ListNotebookInstanceLifecycleConfigs
rq
          ListNotebookInstanceLifecycleConfigs
-> (ListNotebookInstanceLifecycleConfigs
    -> ListNotebookInstanceLifecycleConfigs)
-> ListNotebookInstanceLifecycleConfigs
forall a b. a -> (a -> b) -> b
Prelude.& (Maybe Text -> Identity (Maybe Text))
-> ListNotebookInstanceLifecycleConfigs
-> Identity ListNotebookInstanceLifecycleConfigs
Lens
  ListNotebookInstanceLifecycleConfigs
  ListNotebookInstanceLifecycleConfigs
  (Maybe Text)
  (Maybe Text)
listNotebookInstanceLifecycleConfigs_nextToken
          ((Maybe Text -> Identity (Maybe Text))
 -> ListNotebookInstanceLifecycleConfigs
 -> Identity ListNotebookInstanceLifecycleConfigs)
-> Maybe Text
-> ListNotebookInstanceLifecycleConfigs
-> ListNotebookInstanceLifecycleConfigs
forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListNotebookInstanceLifecycleConfigs
ListNotebookInstanceLifecycleConfigsResponse
rs
            ListNotebookInstanceLifecycleConfigsResponse
-> Getting
     (First Text) ListNotebookInstanceLifecycleConfigsResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> ListNotebookInstanceLifecycleConfigsResponse
-> Const (First Text) ListNotebookInstanceLifecycleConfigsResponse
Lens' ListNotebookInstanceLifecycleConfigsResponse (Maybe Text)
listNotebookInstanceLifecycleConfigsResponse_nextToken
              ((Maybe Text -> Const (First Text) (Maybe Text))
 -> ListNotebookInstanceLifecycleConfigsResponse
 -> Const (First Text) ListNotebookInstanceLifecycleConfigsResponse)
-> ((Text -> Const (First Text) Text)
    -> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting
     (First Text) ListNotebookInstanceLifecycleConfigsResponse 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
    ListNotebookInstanceLifecycleConfigs
  where
  type
    AWSResponse ListNotebookInstanceLifecycleConfigs =
      ListNotebookInstanceLifecycleConfigsResponse
  request :: ListNotebookInstanceLifecycleConfigs
-> Request ListNotebookInstanceLifecycleConfigs
request = Service
-> ListNotebookInstanceLifecycleConfigs
-> Request ListNotebookInstanceLifecycleConfigs
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy ListNotebookInstanceLifecycleConfigs
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse
           (AWSResponse ListNotebookInstanceLifecycleConfigs)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either
      String (AWSResponse ListNotebookInstanceLifecycleConfigs))
-> Logger
-> Service
-> Proxy ListNotebookInstanceLifecycleConfigs
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse
           (AWSResponse ListNotebookInstanceLifecycleConfigs)))
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 [NotebookInstanceLifecycleConfigSummary]
-> Int
-> ListNotebookInstanceLifecycleConfigsResponse
ListNotebookInstanceLifecycleConfigsResponse'
            (Maybe Text
 -> Maybe [NotebookInstanceLifecycleConfigSummary]
 -> Int
 -> ListNotebookInstanceLifecycleConfigsResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [NotebookInstanceLifecycleConfigSummary]
      -> Int -> ListNotebookInstanceLifecycleConfigsResponse)
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 [NotebookInstanceLifecycleConfigSummary]
   -> Int -> ListNotebookInstanceLifecycleConfigsResponse)
-> Either String (Maybe [NotebookInstanceLifecycleConfigSummary])
-> Either
     String (Int -> ListNotebookInstanceLifecycleConfigsResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object
-> Text
-> Either
     String (Maybe (Maybe [NotebookInstanceLifecycleConfigSummary]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"NotebookInstanceLifecycleConfigs"
                              Either
  String (Maybe (Maybe [NotebookInstanceLifecycleConfigSummary]))
-> Maybe [NotebookInstanceLifecycleConfigSummary]
-> Either String (Maybe [NotebookInstanceLifecycleConfigSummary])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [NotebookInstanceLifecycleConfigSummary]
forall a. Monoid a => a
Prelude.mempty
                          )
              Either String (Int -> ListNotebookInstanceLifecycleConfigsResponse)
-> Either String Int
-> Either String ListNotebookInstanceLifecycleConfigsResponse
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
    ListNotebookInstanceLifecycleConfigs

instance
  Prelude.NFData
    ListNotebookInstanceLifecycleConfigs

instance
  Core.ToHeaders
    ListNotebookInstanceLifecycleConfigs
  where
  toHeaders :: ListNotebookInstanceLifecycleConfigs -> ResponseHeaders
toHeaders =
    ResponseHeaders
-> ListNotebookInstanceLifecycleConfigs -> 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
"SageMaker.ListNotebookInstanceLifecycleConfigs" ::
                          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
    ListNotebookInstanceLifecycleConfigs
  where
  toJSON :: ListNotebookInstanceLifecycleConfigs -> Value
toJSON ListNotebookInstanceLifecycleConfigs' {Maybe Natural
Maybe Text
Maybe POSIX
Maybe NotebookInstanceLifecycleConfigSortKey
Maybe NotebookInstanceLifecycleConfigSortOrder
sortBy :: Maybe NotebookInstanceLifecycleConfigSortKey
maxResults :: Maybe Natural
creationTimeBefore :: Maybe POSIX
lastModifiedTimeAfter :: Maybe POSIX
sortOrder :: Maybe NotebookInstanceLifecycleConfigSortOrder
nextToken :: Maybe Text
creationTimeAfter :: Maybe POSIX
lastModifiedTimeBefore :: Maybe POSIX
nameContains :: Maybe Text
$sel:sortBy:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs
-> Maybe NotebookInstanceLifecycleConfigSortKey
$sel:maxResults:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe Natural
$sel:creationTimeBefore:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe POSIX
$sel:lastModifiedTimeAfter:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe POSIX
$sel:sortOrder:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs
-> Maybe NotebookInstanceLifecycleConfigSortOrder
$sel:nextToken:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe Text
$sel:creationTimeAfter:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe POSIX
$sel:lastModifiedTimeBefore:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe POSIX
$sel:nameContains:ListNotebookInstanceLifecycleConfigs' :: ListNotebookInstanceLifecycleConfigs -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"NameContains" 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
nameContains,
            (Text
"LastModifiedTimeBefore" Text -> POSIX -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (POSIX -> Pair) -> Maybe POSIX -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
lastModifiedTimeBefore,
            (Text
"CreationTimeAfter" Text -> POSIX -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (POSIX -> Pair) -> Maybe POSIX -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
creationTimeAfter,
            (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
"SortOrder" Text -> NotebookInstanceLifecycleConfigSortOrder -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (NotebookInstanceLifecycleConfigSortOrder -> Pair)
-> Maybe NotebookInstanceLifecycleConfigSortOrder -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe NotebookInstanceLifecycleConfigSortOrder
sortOrder,
            (Text
"LastModifiedTimeAfter" Text -> POSIX -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (POSIX -> Pair) -> Maybe POSIX -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
lastModifiedTimeAfter,
            (Text
"CreationTimeBefore" Text -> POSIX -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (POSIX -> Pair) -> Maybe POSIX -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
creationTimeBefore,
            (Text
"MaxResults" 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
maxResults,
            (Text
"SortBy" Text -> NotebookInstanceLifecycleConfigSortKey -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (NotebookInstanceLifecycleConfigSortKey -> Pair)
-> Maybe NotebookInstanceLifecycleConfigSortKey -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe NotebookInstanceLifecycleConfigSortKey
sortBy
          ]
      )

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

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

-- | /See:/ 'newListNotebookInstanceLifecycleConfigsResponse' smart constructor.
data ListNotebookInstanceLifecycleConfigsResponse = ListNotebookInstanceLifecycleConfigsResponse'
  { -- | If the response is truncated, Amazon SageMaker returns this token. To
    -- get the next set of lifecycle configurations, use it in the next
    -- request.
    ListNotebookInstanceLifecycleConfigsResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | An array of @NotebookInstanceLifecycleConfiguration@ objects, each
    -- listing a lifecycle configuration.
    ListNotebookInstanceLifecycleConfigsResponse
-> Maybe [NotebookInstanceLifecycleConfigSummary]
notebookInstanceLifecycleConfigs :: Prelude.Maybe [NotebookInstanceLifecycleConfigSummary],
    -- | The response's http status code.
    ListNotebookInstanceLifecycleConfigsResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (ListNotebookInstanceLifecycleConfigsResponse
-> ListNotebookInstanceLifecycleConfigsResponse -> Bool
(ListNotebookInstanceLifecycleConfigsResponse
 -> ListNotebookInstanceLifecycleConfigsResponse -> Bool)
-> (ListNotebookInstanceLifecycleConfigsResponse
    -> ListNotebookInstanceLifecycleConfigsResponse -> Bool)
-> Eq ListNotebookInstanceLifecycleConfigsResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListNotebookInstanceLifecycleConfigsResponse
-> ListNotebookInstanceLifecycleConfigsResponse -> Bool
$c/= :: ListNotebookInstanceLifecycleConfigsResponse
-> ListNotebookInstanceLifecycleConfigsResponse -> Bool
== :: ListNotebookInstanceLifecycleConfigsResponse
-> ListNotebookInstanceLifecycleConfigsResponse -> Bool
$c== :: ListNotebookInstanceLifecycleConfigsResponse
-> ListNotebookInstanceLifecycleConfigsResponse -> Bool
Prelude.Eq, ReadPrec [ListNotebookInstanceLifecycleConfigsResponse]
ReadPrec ListNotebookInstanceLifecycleConfigsResponse
Int -> ReadS ListNotebookInstanceLifecycleConfigsResponse
ReadS [ListNotebookInstanceLifecycleConfigsResponse]
(Int -> ReadS ListNotebookInstanceLifecycleConfigsResponse)
-> ReadS [ListNotebookInstanceLifecycleConfigsResponse]
-> ReadPrec ListNotebookInstanceLifecycleConfigsResponse
-> ReadPrec [ListNotebookInstanceLifecycleConfigsResponse]
-> Read ListNotebookInstanceLifecycleConfigsResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListNotebookInstanceLifecycleConfigsResponse]
$creadListPrec :: ReadPrec [ListNotebookInstanceLifecycleConfigsResponse]
readPrec :: ReadPrec ListNotebookInstanceLifecycleConfigsResponse
$creadPrec :: ReadPrec ListNotebookInstanceLifecycleConfigsResponse
readList :: ReadS [ListNotebookInstanceLifecycleConfigsResponse]
$creadList :: ReadS [ListNotebookInstanceLifecycleConfigsResponse]
readsPrec :: Int -> ReadS ListNotebookInstanceLifecycleConfigsResponse
$creadsPrec :: Int -> ReadS ListNotebookInstanceLifecycleConfigsResponse
Prelude.Read, Int -> ListNotebookInstanceLifecycleConfigsResponse -> ShowS
[ListNotebookInstanceLifecycleConfigsResponse] -> ShowS
ListNotebookInstanceLifecycleConfigsResponse -> String
(Int -> ListNotebookInstanceLifecycleConfigsResponse -> ShowS)
-> (ListNotebookInstanceLifecycleConfigsResponse -> String)
-> ([ListNotebookInstanceLifecycleConfigsResponse] -> ShowS)
-> Show ListNotebookInstanceLifecycleConfigsResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListNotebookInstanceLifecycleConfigsResponse] -> ShowS
$cshowList :: [ListNotebookInstanceLifecycleConfigsResponse] -> ShowS
show :: ListNotebookInstanceLifecycleConfigsResponse -> String
$cshow :: ListNotebookInstanceLifecycleConfigsResponse -> String
showsPrec :: Int -> ListNotebookInstanceLifecycleConfigsResponse -> ShowS
$cshowsPrec :: Int -> ListNotebookInstanceLifecycleConfigsResponse -> ShowS
Prelude.Show, (forall x.
 ListNotebookInstanceLifecycleConfigsResponse
 -> Rep ListNotebookInstanceLifecycleConfigsResponse x)
-> (forall x.
    Rep ListNotebookInstanceLifecycleConfigsResponse x
    -> ListNotebookInstanceLifecycleConfigsResponse)
-> Generic ListNotebookInstanceLifecycleConfigsResponse
forall x.
Rep ListNotebookInstanceLifecycleConfigsResponse x
-> ListNotebookInstanceLifecycleConfigsResponse
forall x.
ListNotebookInstanceLifecycleConfigsResponse
-> Rep ListNotebookInstanceLifecycleConfigsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListNotebookInstanceLifecycleConfigsResponse x
-> ListNotebookInstanceLifecycleConfigsResponse
$cfrom :: forall x.
ListNotebookInstanceLifecycleConfigsResponse
-> Rep ListNotebookInstanceLifecycleConfigsResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListNotebookInstanceLifecycleConfigsResponse' 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', 'listNotebookInstanceLifecycleConfigsResponse_nextToken' - If the response is truncated, Amazon SageMaker returns this token. To
-- get the next set of lifecycle configurations, use it in the next
-- request.
--
-- 'notebookInstanceLifecycleConfigs', 'listNotebookInstanceLifecycleConfigsResponse_notebookInstanceLifecycleConfigs' - An array of @NotebookInstanceLifecycleConfiguration@ objects, each
-- listing a lifecycle configuration.
--
-- 'httpStatus', 'listNotebookInstanceLifecycleConfigsResponse_httpStatus' - The response's http status code.
newListNotebookInstanceLifecycleConfigsResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ListNotebookInstanceLifecycleConfigsResponse
newListNotebookInstanceLifecycleConfigsResponse :: Int -> ListNotebookInstanceLifecycleConfigsResponse
newListNotebookInstanceLifecycleConfigsResponse
  Int
pHttpStatus_ =
    ListNotebookInstanceLifecycleConfigsResponse' :: Maybe Text
-> Maybe [NotebookInstanceLifecycleConfigSummary]
-> Int
-> ListNotebookInstanceLifecycleConfigsResponse
ListNotebookInstanceLifecycleConfigsResponse'
      { $sel:nextToken:ListNotebookInstanceLifecycleConfigsResponse' :: Maybe Text
nextToken =
          Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:notebookInstanceLifecycleConfigs:ListNotebookInstanceLifecycleConfigsResponse' :: Maybe [NotebookInstanceLifecycleConfigSummary]
notebookInstanceLifecycleConfigs =
          Maybe [NotebookInstanceLifecycleConfigSummary]
forall a. Maybe a
Prelude.Nothing,
        $sel:httpStatus:ListNotebookInstanceLifecycleConfigsResponse' :: Int
httpStatus = Int
pHttpStatus_
      }

-- | If the response is truncated, Amazon SageMaker returns this token. To
-- get the next set of lifecycle configurations, use it in the next
-- request.
listNotebookInstanceLifecycleConfigsResponse_nextToken :: Lens.Lens' ListNotebookInstanceLifecycleConfigsResponse (Prelude.Maybe Prelude.Text)
listNotebookInstanceLifecycleConfigsResponse_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListNotebookInstanceLifecycleConfigsResponse
-> f ListNotebookInstanceLifecycleConfigsResponse
listNotebookInstanceLifecycleConfigsResponse_nextToken = (ListNotebookInstanceLifecycleConfigsResponse -> Maybe Text)
-> (ListNotebookInstanceLifecycleConfigsResponse
    -> Maybe Text -> ListNotebookInstanceLifecycleConfigsResponse)
-> Lens' ListNotebookInstanceLifecycleConfigsResponse (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListNotebookInstanceLifecycleConfigsResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListNotebookInstanceLifecycleConfigsResponse' :: ListNotebookInstanceLifecycleConfigsResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListNotebookInstanceLifecycleConfigsResponse
s@ListNotebookInstanceLifecycleConfigsResponse' {} Maybe Text
a -> ListNotebookInstanceLifecycleConfigsResponse
s {$sel:nextToken:ListNotebookInstanceLifecycleConfigsResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListNotebookInstanceLifecycleConfigsResponse)

-- | An array of @NotebookInstanceLifecycleConfiguration@ objects, each
-- listing a lifecycle configuration.
listNotebookInstanceLifecycleConfigsResponse_notebookInstanceLifecycleConfigs :: Lens.Lens' ListNotebookInstanceLifecycleConfigsResponse (Prelude.Maybe [NotebookInstanceLifecycleConfigSummary])
listNotebookInstanceLifecycleConfigsResponse_notebookInstanceLifecycleConfigs :: (Maybe [NotebookInstanceLifecycleConfigSummary]
 -> f (Maybe [NotebookInstanceLifecycleConfigSummary]))
-> ListNotebookInstanceLifecycleConfigsResponse
-> f ListNotebookInstanceLifecycleConfigsResponse
listNotebookInstanceLifecycleConfigsResponse_notebookInstanceLifecycleConfigs = (ListNotebookInstanceLifecycleConfigsResponse
 -> Maybe [NotebookInstanceLifecycleConfigSummary])
-> (ListNotebookInstanceLifecycleConfigsResponse
    -> Maybe [NotebookInstanceLifecycleConfigSummary]
    -> ListNotebookInstanceLifecycleConfigsResponse)
-> Lens'
     ListNotebookInstanceLifecycleConfigsResponse
     (Maybe [NotebookInstanceLifecycleConfigSummary])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListNotebookInstanceLifecycleConfigsResponse' {Maybe [NotebookInstanceLifecycleConfigSummary]
notebookInstanceLifecycleConfigs :: Maybe [NotebookInstanceLifecycleConfigSummary]
$sel:notebookInstanceLifecycleConfigs:ListNotebookInstanceLifecycleConfigsResponse' :: ListNotebookInstanceLifecycleConfigsResponse
-> Maybe [NotebookInstanceLifecycleConfigSummary]
notebookInstanceLifecycleConfigs} -> Maybe [NotebookInstanceLifecycleConfigSummary]
notebookInstanceLifecycleConfigs) (\s :: ListNotebookInstanceLifecycleConfigsResponse
s@ListNotebookInstanceLifecycleConfigsResponse' {} Maybe [NotebookInstanceLifecycleConfigSummary]
a -> ListNotebookInstanceLifecycleConfigsResponse
s {$sel:notebookInstanceLifecycleConfigs:ListNotebookInstanceLifecycleConfigsResponse' :: Maybe [NotebookInstanceLifecycleConfigSummary]
notebookInstanceLifecycleConfigs = Maybe [NotebookInstanceLifecycleConfigSummary]
a} :: ListNotebookInstanceLifecycleConfigsResponse) ((Maybe [NotebookInstanceLifecycleConfigSummary]
  -> f (Maybe [NotebookInstanceLifecycleConfigSummary]))
 -> ListNotebookInstanceLifecycleConfigsResponse
 -> f ListNotebookInstanceLifecycleConfigsResponse)
-> ((Maybe [NotebookInstanceLifecycleConfigSummary]
     -> f (Maybe [NotebookInstanceLifecycleConfigSummary]))
    -> Maybe [NotebookInstanceLifecycleConfigSummary]
    -> f (Maybe [NotebookInstanceLifecycleConfigSummary]))
-> (Maybe [NotebookInstanceLifecycleConfigSummary]
    -> f (Maybe [NotebookInstanceLifecycleConfigSummary]))
-> ListNotebookInstanceLifecycleConfigsResponse
-> f ListNotebookInstanceLifecycleConfigsResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [NotebookInstanceLifecycleConfigSummary]
  [NotebookInstanceLifecycleConfigSummary]
  [NotebookInstanceLifecycleConfigSummary]
  [NotebookInstanceLifecycleConfigSummary]
-> Iso
     (Maybe [NotebookInstanceLifecycleConfigSummary])
     (Maybe [NotebookInstanceLifecycleConfigSummary])
     (Maybe [NotebookInstanceLifecycleConfigSummary])
     (Maybe [NotebookInstanceLifecycleConfigSummary])
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
  [NotebookInstanceLifecycleConfigSummary]
  [NotebookInstanceLifecycleConfigSummary]
  [NotebookInstanceLifecycleConfigSummary]
  [NotebookInstanceLifecycleConfigSummary]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

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

instance
  Prelude.NFData
    ListNotebookInstanceLifecycleConfigsResponse