{-# 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.SSM.DeregisterTaskFromMaintenanceWindow
-- 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)
--
-- Removes a task from a maintenance window.
module Amazonka.SSM.DeregisterTaskFromMaintenanceWindow
  ( -- * Creating a Request
    DeregisterTaskFromMaintenanceWindow (..),
    newDeregisterTaskFromMaintenanceWindow,

    -- * Request Lenses
    deregisterTaskFromMaintenanceWindow_windowId,
    deregisterTaskFromMaintenanceWindow_windowTaskId,

    -- * Destructuring the Response
    DeregisterTaskFromMaintenanceWindowResponse (..),
    newDeregisterTaskFromMaintenanceWindowResponse,

    -- * Response Lenses
    deregisterTaskFromMaintenanceWindowResponse_windowTaskId,
    deregisterTaskFromMaintenanceWindowResponse_windowId,
    deregisterTaskFromMaintenanceWindowResponse_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.SSM.Types

-- | /See:/ 'newDeregisterTaskFromMaintenanceWindow' smart constructor.
data DeregisterTaskFromMaintenanceWindow = DeregisterTaskFromMaintenanceWindow'
  { -- | The ID of the maintenance window the task should be removed from.
    DeregisterTaskFromMaintenanceWindow -> Text
windowId :: Prelude.Text,
    -- | The ID of the task to remove from the maintenance window.
    DeregisterTaskFromMaintenanceWindow -> Text
windowTaskId :: Prelude.Text
  }
  deriving (DeregisterTaskFromMaintenanceWindow
-> DeregisterTaskFromMaintenanceWindow -> Bool
(DeregisterTaskFromMaintenanceWindow
 -> DeregisterTaskFromMaintenanceWindow -> Bool)
-> (DeregisterTaskFromMaintenanceWindow
    -> DeregisterTaskFromMaintenanceWindow -> Bool)
-> Eq DeregisterTaskFromMaintenanceWindow
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeregisterTaskFromMaintenanceWindow
-> DeregisterTaskFromMaintenanceWindow -> Bool
$c/= :: DeregisterTaskFromMaintenanceWindow
-> DeregisterTaskFromMaintenanceWindow -> Bool
== :: DeregisterTaskFromMaintenanceWindow
-> DeregisterTaskFromMaintenanceWindow -> Bool
$c== :: DeregisterTaskFromMaintenanceWindow
-> DeregisterTaskFromMaintenanceWindow -> Bool
Prelude.Eq, ReadPrec [DeregisterTaskFromMaintenanceWindow]
ReadPrec DeregisterTaskFromMaintenanceWindow
Int -> ReadS DeregisterTaskFromMaintenanceWindow
ReadS [DeregisterTaskFromMaintenanceWindow]
(Int -> ReadS DeregisterTaskFromMaintenanceWindow)
-> ReadS [DeregisterTaskFromMaintenanceWindow]
-> ReadPrec DeregisterTaskFromMaintenanceWindow
-> ReadPrec [DeregisterTaskFromMaintenanceWindow]
-> Read DeregisterTaskFromMaintenanceWindow
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeregisterTaskFromMaintenanceWindow]
$creadListPrec :: ReadPrec [DeregisterTaskFromMaintenanceWindow]
readPrec :: ReadPrec DeregisterTaskFromMaintenanceWindow
$creadPrec :: ReadPrec DeregisterTaskFromMaintenanceWindow
readList :: ReadS [DeregisterTaskFromMaintenanceWindow]
$creadList :: ReadS [DeregisterTaskFromMaintenanceWindow]
readsPrec :: Int -> ReadS DeregisterTaskFromMaintenanceWindow
$creadsPrec :: Int -> ReadS DeregisterTaskFromMaintenanceWindow
Prelude.Read, Int -> DeregisterTaskFromMaintenanceWindow -> ShowS
[DeregisterTaskFromMaintenanceWindow] -> ShowS
DeregisterTaskFromMaintenanceWindow -> String
(Int -> DeregisterTaskFromMaintenanceWindow -> ShowS)
-> (DeregisterTaskFromMaintenanceWindow -> String)
-> ([DeregisterTaskFromMaintenanceWindow] -> ShowS)
-> Show DeregisterTaskFromMaintenanceWindow
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeregisterTaskFromMaintenanceWindow] -> ShowS
$cshowList :: [DeregisterTaskFromMaintenanceWindow] -> ShowS
show :: DeregisterTaskFromMaintenanceWindow -> String
$cshow :: DeregisterTaskFromMaintenanceWindow -> String
showsPrec :: Int -> DeregisterTaskFromMaintenanceWindow -> ShowS
$cshowsPrec :: Int -> DeregisterTaskFromMaintenanceWindow -> ShowS
Prelude.Show, (forall x.
 DeregisterTaskFromMaintenanceWindow
 -> Rep DeregisterTaskFromMaintenanceWindow x)
-> (forall x.
    Rep DeregisterTaskFromMaintenanceWindow x
    -> DeregisterTaskFromMaintenanceWindow)
-> Generic DeregisterTaskFromMaintenanceWindow
forall x.
Rep DeregisterTaskFromMaintenanceWindow x
-> DeregisterTaskFromMaintenanceWindow
forall x.
DeregisterTaskFromMaintenanceWindow
-> Rep DeregisterTaskFromMaintenanceWindow x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeregisterTaskFromMaintenanceWindow x
-> DeregisterTaskFromMaintenanceWindow
$cfrom :: forall x.
DeregisterTaskFromMaintenanceWindow
-> Rep DeregisterTaskFromMaintenanceWindow x
Prelude.Generic)

-- |
-- Create a value of 'DeregisterTaskFromMaintenanceWindow' 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:
--
-- 'windowId', 'deregisterTaskFromMaintenanceWindow_windowId' - The ID of the maintenance window the task should be removed from.
--
-- 'windowTaskId', 'deregisterTaskFromMaintenanceWindow_windowTaskId' - The ID of the task to remove from the maintenance window.
newDeregisterTaskFromMaintenanceWindow ::
  -- | 'windowId'
  Prelude.Text ->
  -- | 'windowTaskId'
  Prelude.Text ->
  DeregisterTaskFromMaintenanceWindow
newDeregisterTaskFromMaintenanceWindow :: Text -> Text -> DeregisterTaskFromMaintenanceWindow
newDeregisterTaskFromMaintenanceWindow
  Text
pWindowId_
  Text
pWindowTaskId_ =
    DeregisterTaskFromMaintenanceWindow' :: Text -> Text -> DeregisterTaskFromMaintenanceWindow
DeregisterTaskFromMaintenanceWindow'
      { $sel:windowId:DeregisterTaskFromMaintenanceWindow' :: Text
windowId =
          Text
pWindowId_,
        $sel:windowTaskId:DeregisterTaskFromMaintenanceWindow' :: Text
windowTaskId = Text
pWindowTaskId_
      }

-- | The ID of the maintenance window the task should be removed from.
deregisterTaskFromMaintenanceWindow_windowId :: Lens.Lens' DeregisterTaskFromMaintenanceWindow Prelude.Text
deregisterTaskFromMaintenanceWindow_windowId :: (Text -> f Text)
-> DeregisterTaskFromMaintenanceWindow
-> f DeregisterTaskFromMaintenanceWindow
deregisterTaskFromMaintenanceWindow_windowId = (DeregisterTaskFromMaintenanceWindow -> Text)
-> (DeregisterTaskFromMaintenanceWindow
    -> Text -> DeregisterTaskFromMaintenanceWindow)
-> Lens
     DeregisterTaskFromMaintenanceWindow
     DeregisterTaskFromMaintenanceWindow
     Text
     Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeregisterTaskFromMaintenanceWindow' {Text
windowId :: Text
$sel:windowId:DeregisterTaskFromMaintenanceWindow' :: DeregisterTaskFromMaintenanceWindow -> Text
windowId} -> Text
windowId) (\s :: DeregisterTaskFromMaintenanceWindow
s@DeregisterTaskFromMaintenanceWindow' {} Text
a -> DeregisterTaskFromMaintenanceWindow
s {$sel:windowId:DeregisterTaskFromMaintenanceWindow' :: Text
windowId = Text
a} :: DeregisterTaskFromMaintenanceWindow)

-- | The ID of the task to remove from the maintenance window.
deregisterTaskFromMaintenanceWindow_windowTaskId :: Lens.Lens' DeregisterTaskFromMaintenanceWindow Prelude.Text
deregisterTaskFromMaintenanceWindow_windowTaskId :: (Text -> f Text)
-> DeregisterTaskFromMaintenanceWindow
-> f DeregisterTaskFromMaintenanceWindow
deregisterTaskFromMaintenanceWindow_windowTaskId = (DeregisterTaskFromMaintenanceWindow -> Text)
-> (DeregisterTaskFromMaintenanceWindow
    -> Text -> DeregisterTaskFromMaintenanceWindow)
-> Lens
     DeregisterTaskFromMaintenanceWindow
     DeregisterTaskFromMaintenanceWindow
     Text
     Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeregisterTaskFromMaintenanceWindow' {Text
windowTaskId :: Text
$sel:windowTaskId:DeregisterTaskFromMaintenanceWindow' :: DeregisterTaskFromMaintenanceWindow -> Text
windowTaskId} -> Text
windowTaskId) (\s :: DeregisterTaskFromMaintenanceWindow
s@DeregisterTaskFromMaintenanceWindow' {} Text
a -> DeregisterTaskFromMaintenanceWindow
s {$sel:windowTaskId:DeregisterTaskFromMaintenanceWindow' :: Text
windowTaskId = Text
a} :: DeregisterTaskFromMaintenanceWindow)

instance
  Core.AWSRequest
    DeregisterTaskFromMaintenanceWindow
  where
  type
    AWSResponse DeregisterTaskFromMaintenanceWindow =
      DeregisterTaskFromMaintenanceWindowResponse
  request :: DeregisterTaskFromMaintenanceWindow
-> Request DeregisterTaskFromMaintenanceWindow
request = Service
-> DeregisterTaskFromMaintenanceWindow
-> Request DeregisterTaskFromMaintenanceWindow
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy DeregisterTaskFromMaintenanceWindow
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse (AWSResponse DeregisterTaskFromMaintenanceWindow)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse DeregisterTaskFromMaintenanceWindow))
-> Logger
-> Service
-> Proxy DeregisterTaskFromMaintenanceWindow
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse (AWSResponse DeregisterTaskFromMaintenanceWindow)))
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 Text -> Int -> DeregisterTaskFromMaintenanceWindowResponse
DeregisterTaskFromMaintenanceWindowResponse'
            (Maybe Text
 -> Maybe Text
 -> Int
 -> DeregisterTaskFromMaintenanceWindowResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text -> Int -> DeregisterTaskFromMaintenanceWindowResponse)
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
"WindowTaskId")
              Either
  String
  (Maybe Text -> Int -> DeregisterTaskFromMaintenanceWindowResponse)
-> Either String (Maybe Text)
-> Either
     String (Int -> DeregisterTaskFromMaintenanceWindowResponse)
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
"WindowId")
              Either String (Int -> DeregisterTaskFromMaintenanceWindowResponse)
-> Either String Int
-> Either String DeregisterTaskFromMaintenanceWindowResponse
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
    DeregisterTaskFromMaintenanceWindow

instance
  Prelude.NFData
    DeregisterTaskFromMaintenanceWindow

instance
  Core.ToHeaders
    DeregisterTaskFromMaintenanceWindow
  where
  toHeaders :: DeregisterTaskFromMaintenanceWindow -> ResponseHeaders
toHeaders =
    ResponseHeaders
-> DeregisterTaskFromMaintenanceWindow -> 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
"AmazonSSM.DeregisterTaskFromMaintenanceWindow" ::
                          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
    DeregisterTaskFromMaintenanceWindow
  where
  toJSON :: DeregisterTaskFromMaintenanceWindow -> Value
toJSON DeregisterTaskFromMaintenanceWindow' {Text
windowTaskId :: Text
windowId :: Text
$sel:windowTaskId:DeregisterTaskFromMaintenanceWindow' :: DeregisterTaskFromMaintenanceWindow -> Text
$sel:windowId:DeregisterTaskFromMaintenanceWindow' :: DeregisterTaskFromMaintenanceWindow -> Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"WindowId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
windowId),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"WindowTaskId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
windowTaskId)
          ]
      )

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

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

-- | /See:/ 'newDeregisterTaskFromMaintenanceWindowResponse' smart constructor.
data DeregisterTaskFromMaintenanceWindowResponse = DeregisterTaskFromMaintenanceWindowResponse'
  { -- | The ID of the task removed from the maintenance window.
    DeregisterTaskFromMaintenanceWindowResponse -> Maybe Text
windowTaskId :: Prelude.Maybe Prelude.Text,
    -- | The ID of the maintenance window the task was removed from.
    DeregisterTaskFromMaintenanceWindowResponse -> Maybe Text
windowId :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    DeregisterTaskFromMaintenanceWindowResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (DeregisterTaskFromMaintenanceWindowResponse
-> DeregisterTaskFromMaintenanceWindowResponse -> Bool
(DeregisterTaskFromMaintenanceWindowResponse
 -> DeregisterTaskFromMaintenanceWindowResponse -> Bool)
-> (DeregisterTaskFromMaintenanceWindowResponse
    -> DeregisterTaskFromMaintenanceWindowResponse -> Bool)
-> Eq DeregisterTaskFromMaintenanceWindowResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeregisterTaskFromMaintenanceWindowResponse
-> DeregisterTaskFromMaintenanceWindowResponse -> Bool
$c/= :: DeregisterTaskFromMaintenanceWindowResponse
-> DeregisterTaskFromMaintenanceWindowResponse -> Bool
== :: DeregisterTaskFromMaintenanceWindowResponse
-> DeregisterTaskFromMaintenanceWindowResponse -> Bool
$c== :: DeregisterTaskFromMaintenanceWindowResponse
-> DeregisterTaskFromMaintenanceWindowResponse -> Bool
Prelude.Eq, ReadPrec [DeregisterTaskFromMaintenanceWindowResponse]
ReadPrec DeregisterTaskFromMaintenanceWindowResponse
Int -> ReadS DeregisterTaskFromMaintenanceWindowResponse
ReadS [DeregisterTaskFromMaintenanceWindowResponse]
(Int -> ReadS DeregisterTaskFromMaintenanceWindowResponse)
-> ReadS [DeregisterTaskFromMaintenanceWindowResponse]
-> ReadPrec DeregisterTaskFromMaintenanceWindowResponse
-> ReadPrec [DeregisterTaskFromMaintenanceWindowResponse]
-> Read DeregisterTaskFromMaintenanceWindowResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeregisterTaskFromMaintenanceWindowResponse]
$creadListPrec :: ReadPrec [DeregisterTaskFromMaintenanceWindowResponse]
readPrec :: ReadPrec DeregisterTaskFromMaintenanceWindowResponse
$creadPrec :: ReadPrec DeregisterTaskFromMaintenanceWindowResponse
readList :: ReadS [DeregisterTaskFromMaintenanceWindowResponse]
$creadList :: ReadS [DeregisterTaskFromMaintenanceWindowResponse]
readsPrec :: Int -> ReadS DeregisterTaskFromMaintenanceWindowResponse
$creadsPrec :: Int -> ReadS DeregisterTaskFromMaintenanceWindowResponse
Prelude.Read, Int -> DeregisterTaskFromMaintenanceWindowResponse -> ShowS
[DeregisterTaskFromMaintenanceWindowResponse] -> ShowS
DeregisterTaskFromMaintenanceWindowResponse -> String
(Int -> DeregisterTaskFromMaintenanceWindowResponse -> ShowS)
-> (DeregisterTaskFromMaintenanceWindowResponse -> String)
-> ([DeregisterTaskFromMaintenanceWindowResponse] -> ShowS)
-> Show DeregisterTaskFromMaintenanceWindowResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeregisterTaskFromMaintenanceWindowResponse] -> ShowS
$cshowList :: [DeregisterTaskFromMaintenanceWindowResponse] -> ShowS
show :: DeregisterTaskFromMaintenanceWindowResponse -> String
$cshow :: DeregisterTaskFromMaintenanceWindowResponse -> String
showsPrec :: Int -> DeregisterTaskFromMaintenanceWindowResponse -> ShowS
$cshowsPrec :: Int -> DeregisterTaskFromMaintenanceWindowResponse -> ShowS
Prelude.Show, (forall x.
 DeregisterTaskFromMaintenanceWindowResponse
 -> Rep DeregisterTaskFromMaintenanceWindowResponse x)
-> (forall x.
    Rep DeregisterTaskFromMaintenanceWindowResponse x
    -> DeregisterTaskFromMaintenanceWindowResponse)
-> Generic DeregisterTaskFromMaintenanceWindowResponse
forall x.
Rep DeregisterTaskFromMaintenanceWindowResponse x
-> DeregisterTaskFromMaintenanceWindowResponse
forall x.
DeregisterTaskFromMaintenanceWindowResponse
-> Rep DeregisterTaskFromMaintenanceWindowResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeregisterTaskFromMaintenanceWindowResponse x
-> DeregisterTaskFromMaintenanceWindowResponse
$cfrom :: forall x.
DeregisterTaskFromMaintenanceWindowResponse
-> Rep DeregisterTaskFromMaintenanceWindowResponse x
Prelude.Generic)

-- |
-- Create a value of 'DeregisterTaskFromMaintenanceWindowResponse' 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:
--
-- 'windowTaskId', 'deregisterTaskFromMaintenanceWindowResponse_windowTaskId' - The ID of the task removed from the maintenance window.
--
-- 'windowId', 'deregisterTaskFromMaintenanceWindowResponse_windowId' - The ID of the maintenance window the task was removed from.
--
-- 'httpStatus', 'deregisterTaskFromMaintenanceWindowResponse_httpStatus' - The response's http status code.
newDeregisterTaskFromMaintenanceWindowResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  DeregisterTaskFromMaintenanceWindowResponse
newDeregisterTaskFromMaintenanceWindowResponse :: Int -> DeregisterTaskFromMaintenanceWindowResponse
newDeregisterTaskFromMaintenanceWindowResponse
  Int
pHttpStatus_ =
    DeregisterTaskFromMaintenanceWindowResponse' :: Maybe Text
-> Maybe Text -> Int -> DeregisterTaskFromMaintenanceWindowResponse
DeregisterTaskFromMaintenanceWindowResponse'
      { $sel:windowTaskId:DeregisterTaskFromMaintenanceWindowResponse' :: Maybe Text
windowTaskId =
          Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:windowId:DeregisterTaskFromMaintenanceWindowResponse' :: Maybe Text
windowId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:httpStatus:DeregisterTaskFromMaintenanceWindowResponse' :: Int
httpStatus = Int
pHttpStatus_
      }

-- | The ID of the task removed from the maintenance window.
deregisterTaskFromMaintenanceWindowResponse_windowTaskId :: Lens.Lens' DeregisterTaskFromMaintenanceWindowResponse (Prelude.Maybe Prelude.Text)
deregisterTaskFromMaintenanceWindowResponse_windowTaskId :: (Maybe Text -> f (Maybe Text))
-> DeregisterTaskFromMaintenanceWindowResponse
-> f DeregisterTaskFromMaintenanceWindowResponse
deregisterTaskFromMaintenanceWindowResponse_windowTaskId = (DeregisterTaskFromMaintenanceWindowResponse -> Maybe Text)
-> (DeregisterTaskFromMaintenanceWindowResponse
    -> Maybe Text -> DeregisterTaskFromMaintenanceWindowResponse)
-> Lens
     DeregisterTaskFromMaintenanceWindowResponse
     DeregisterTaskFromMaintenanceWindowResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeregisterTaskFromMaintenanceWindowResponse' {Maybe Text
windowTaskId :: Maybe Text
$sel:windowTaskId:DeregisterTaskFromMaintenanceWindowResponse' :: DeregisterTaskFromMaintenanceWindowResponse -> Maybe Text
windowTaskId} -> Maybe Text
windowTaskId) (\s :: DeregisterTaskFromMaintenanceWindowResponse
s@DeregisterTaskFromMaintenanceWindowResponse' {} Maybe Text
a -> DeregisterTaskFromMaintenanceWindowResponse
s {$sel:windowTaskId:DeregisterTaskFromMaintenanceWindowResponse' :: Maybe Text
windowTaskId = Maybe Text
a} :: DeregisterTaskFromMaintenanceWindowResponse)

-- | The ID of the maintenance window the task was removed from.
deregisterTaskFromMaintenanceWindowResponse_windowId :: Lens.Lens' DeregisterTaskFromMaintenanceWindowResponse (Prelude.Maybe Prelude.Text)
deregisterTaskFromMaintenanceWindowResponse_windowId :: (Maybe Text -> f (Maybe Text))
-> DeregisterTaskFromMaintenanceWindowResponse
-> f DeregisterTaskFromMaintenanceWindowResponse
deregisterTaskFromMaintenanceWindowResponse_windowId = (DeregisterTaskFromMaintenanceWindowResponse -> Maybe Text)
-> (DeregisterTaskFromMaintenanceWindowResponse
    -> Maybe Text -> DeregisterTaskFromMaintenanceWindowResponse)
-> Lens
     DeregisterTaskFromMaintenanceWindowResponse
     DeregisterTaskFromMaintenanceWindowResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeregisterTaskFromMaintenanceWindowResponse' {Maybe Text
windowId :: Maybe Text
$sel:windowId:DeregisterTaskFromMaintenanceWindowResponse' :: DeregisterTaskFromMaintenanceWindowResponse -> Maybe Text
windowId} -> Maybe Text
windowId) (\s :: DeregisterTaskFromMaintenanceWindowResponse
s@DeregisterTaskFromMaintenanceWindowResponse' {} Maybe Text
a -> DeregisterTaskFromMaintenanceWindowResponse
s {$sel:windowId:DeregisterTaskFromMaintenanceWindowResponse' :: Maybe Text
windowId = Maybe Text
a} :: DeregisterTaskFromMaintenanceWindowResponse)

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

instance
  Prelude.NFData
    DeregisterTaskFromMaintenanceWindowResponse