{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.RDS.Types.OptionGroupOption
-- 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)
module Amazonka.RDS.Types.OptionGroupOption where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.RDS.Types.OptionGroupOptionSetting
import Amazonka.RDS.Types.OptionVersion

-- | Available option.
--
-- /See:/ 'newOptionGroupOption' smart constructor.
data OptionGroupOption = OptionGroupOption'
  { -- | The minimum required engine version for the option to be applied.
    OptionGroupOption -> Maybe Text
minimumRequiredMinorEngineVersion :: Prelude.Maybe Prelude.Text,
    -- | The options that conflict with this option.
    OptionGroupOption -> Maybe [Text]
optionsConflictsWith :: Prelude.Maybe [Prelude.Text],
    -- | Permanent options can never be removed from an option group. An option
    -- group containing a permanent option can\'t be removed from a DB
    -- instance.
    OptionGroupOption -> Maybe Bool
permanent :: Prelude.Maybe Prelude.Bool,
    -- | Persistent options can\'t be removed from an option group while DB
    -- instances are associated with the option group. If you disassociate all
    -- DB instances from the option group, your can remove the persistent
    -- option from the option group.
    OptionGroupOption -> Maybe Bool
persistent :: Prelude.Maybe Prelude.Bool,
    -- | The versions that are available for the option.
    OptionGroupOption -> Maybe [OptionVersion]
optionGroupOptionVersions :: Prelude.Maybe [OptionVersion],
    -- | The name of the engine that this option can be applied to.
    OptionGroupOption -> Maybe Text
engineName :: Prelude.Maybe Prelude.Text,
    -- | Indicates the major engine version that the option is available for.
    OptionGroupOption -> Maybe Text
majorEngineVersion :: Prelude.Maybe Prelude.Text,
    -- | The name of the option.
    OptionGroupOption -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
    -- | If true, you can change the option to an earlier version of the option.
    -- This only applies to options that have different versions available.
    OptionGroupOption -> Maybe Bool
supportsOptionVersionDowngrade :: Prelude.Maybe Prelude.Bool,
    -- | If the option requires a port, specifies the default port for the
    -- option.
    OptionGroupOption -> Maybe Int
defaultPort :: Prelude.Maybe Prelude.Int,
    -- | The option settings that are available (and the default value) for each
    -- option in an option group.
    OptionGroupOption -> Maybe [OptionGroupOptionSetting]
optionGroupOptionSettings :: Prelude.Maybe [OptionGroupOptionSetting],
    -- | If true, you must enable the Auto Minor Version Upgrade setting for your
    -- DB instance before you can use this option. You can enable Auto Minor
    -- Version Upgrade when you first create your DB instance, or by modifying
    -- your DB instance later.
    OptionGroupOption -> Maybe Bool
requiresAutoMinorEngineVersionUpgrade :: Prelude.Maybe Prelude.Bool,
    -- | Specifies whether the option requires a port.
    OptionGroupOption -> Maybe Bool
portRequired :: Prelude.Maybe Prelude.Bool,
    -- | The description of the option.
    OptionGroupOption -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    -- | The options that are prerequisites for this option.
    OptionGroupOption -> Maybe [Text]
optionsDependedOn :: Prelude.Maybe [Prelude.Text],
    -- | If true, you can only use this option with a DB instance that is in a
    -- VPC.
    OptionGroupOption -> Maybe Bool
vpcOnly :: Prelude.Maybe Prelude.Bool
  }
  deriving (OptionGroupOption -> OptionGroupOption -> Bool
(OptionGroupOption -> OptionGroupOption -> Bool)
-> (OptionGroupOption -> OptionGroupOption -> Bool)
-> Eq OptionGroupOption
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: OptionGroupOption -> OptionGroupOption -> Bool
$c/= :: OptionGroupOption -> OptionGroupOption -> Bool
== :: OptionGroupOption -> OptionGroupOption -> Bool
$c== :: OptionGroupOption -> OptionGroupOption -> Bool
Prelude.Eq, ReadPrec [OptionGroupOption]
ReadPrec OptionGroupOption
Int -> ReadS OptionGroupOption
ReadS [OptionGroupOption]
(Int -> ReadS OptionGroupOption)
-> ReadS [OptionGroupOption]
-> ReadPrec OptionGroupOption
-> ReadPrec [OptionGroupOption]
-> Read OptionGroupOption
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [OptionGroupOption]
$creadListPrec :: ReadPrec [OptionGroupOption]
readPrec :: ReadPrec OptionGroupOption
$creadPrec :: ReadPrec OptionGroupOption
readList :: ReadS [OptionGroupOption]
$creadList :: ReadS [OptionGroupOption]
readsPrec :: Int -> ReadS OptionGroupOption
$creadsPrec :: Int -> ReadS OptionGroupOption
Prelude.Read, Int -> OptionGroupOption -> ShowS
[OptionGroupOption] -> ShowS
OptionGroupOption -> String
(Int -> OptionGroupOption -> ShowS)
-> (OptionGroupOption -> String)
-> ([OptionGroupOption] -> ShowS)
-> Show OptionGroupOption
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [OptionGroupOption] -> ShowS
$cshowList :: [OptionGroupOption] -> ShowS
show :: OptionGroupOption -> String
$cshow :: OptionGroupOption -> String
showsPrec :: Int -> OptionGroupOption -> ShowS
$cshowsPrec :: Int -> OptionGroupOption -> ShowS
Prelude.Show, (forall x. OptionGroupOption -> Rep OptionGroupOption x)
-> (forall x. Rep OptionGroupOption x -> OptionGroupOption)
-> Generic OptionGroupOption
forall x. Rep OptionGroupOption x -> OptionGroupOption
forall x. OptionGroupOption -> Rep OptionGroupOption x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep OptionGroupOption x -> OptionGroupOption
$cfrom :: forall x. OptionGroupOption -> Rep OptionGroupOption x
Prelude.Generic)

-- |
-- Create a value of 'OptionGroupOption' 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:
--
-- 'minimumRequiredMinorEngineVersion', 'optionGroupOption_minimumRequiredMinorEngineVersion' - The minimum required engine version for the option to be applied.
--
-- 'optionsConflictsWith', 'optionGroupOption_optionsConflictsWith' - The options that conflict with this option.
--
-- 'permanent', 'optionGroupOption_permanent' - Permanent options can never be removed from an option group. An option
-- group containing a permanent option can\'t be removed from a DB
-- instance.
--
-- 'persistent', 'optionGroupOption_persistent' - Persistent options can\'t be removed from an option group while DB
-- instances are associated with the option group. If you disassociate all
-- DB instances from the option group, your can remove the persistent
-- option from the option group.
--
-- 'optionGroupOptionVersions', 'optionGroupOption_optionGroupOptionVersions' - The versions that are available for the option.
--
-- 'engineName', 'optionGroupOption_engineName' - The name of the engine that this option can be applied to.
--
-- 'majorEngineVersion', 'optionGroupOption_majorEngineVersion' - Indicates the major engine version that the option is available for.
--
-- 'name', 'optionGroupOption_name' - The name of the option.
--
-- 'supportsOptionVersionDowngrade', 'optionGroupOption_supportsOptionVersionDowngrade' - If true, you can change the option to an earlier version of the option.
-- This only applies to options that have different versions available.
--
-- 'defaultPort', 'optionGroupOption_defaultPort' - If the option requires a port, specifies the default port for the
-- option.
--
-- 'optionGroupOptionSettings', 'optionGroupOption_optionGroupOptionSettings' - The option settings that are available (and the default value) for each
-- option in an option group.
--
-- 'requiresAutoMinorEngineVersionUpgrade', 'optionGroupOption_requiresAutoMinorEngineVersionUpgrade' - If true, you must enable the Auto Minor Version Upgrade setting for your
-- DB instance before you can use this option. You can enable Auto Minor
-- Version Upgrade when you first create your DB instance, or by modifying
-- your DB instance later.
--
-- 'portRequired', 'optionGroupOption_portRequired' - Specifies whether the option requires a port.
--
-- 'description', 'optionGroupOption_description' - The description of the option.
--
-- 'optionsDependedOn', 'optionGroupOption_optionsDependedOn' - The options that are prerequisites for this option.
--
-- 'vpcOnly', 'optionGroupOption_vpcOnly' - If true, you can only use this option with a DB instance that is in a
-- VPC.
newOptionGroupOption ::
  OptionGroupOption
newOptionGroupOption :: OptionGroupOption
newOptionGroupOption =
  OptionGroupOption' :: Maybe Text
-> Maybe [Text]
-> Maybe Bool
-> Maybe Bool
-> Maybe [OptionVersion]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Int
-> Maybe [OptionGroupOptionSetting]
-> Maybe Bool
-> Maybe Bool
-> Maybe Text
-> Maybe [Text]
-> Maybe Bool
-> OptionGroupOption
OptionGroupOption'
    { $sel:minimumRequiredMinorEngineVersion:OptionGroupOption' :: Maybe Text
minimumRequiredMinorEngineVersion =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:optionsConflictsWith:OptionGroupOption' :: Maybe [Text]
optionsConflictsWith = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:permanent:OptionGroupOption' :: Maybe Bool
permanent = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:persistent:OptionGroupOption' :: Maybe Bool
persistent = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:optionGroupOptionVersions:OptionGroupOption' :: Maybe [OptionVersion]
optionGroupOptionVersions = Maybe [OptionVersion]
forall a. Maybe a
Prelude.Nothing,
      $sel:engineName:OptionGroupOption' :: Maybe Text
engineName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:majorEngineVersion:OptionGroupOption' :: Maybe Text
majorEngineVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:name:OptionGroupOption' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:supportsOptionVersionDowngrade:OptionGroupOption' :: Maybe Bool
supportsOptionVersionDowngrade = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:defaultPort:OptionGroupOption' :: Maybe Int
defaultPort = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:optionGroupOptionSettings:OptionGroupOption' :: Maybe [OptionGroupOptionSetting]
optionGroupOptionSettings = Maybe [OptionGroupOptionSetting]
forall a. Maybe a
Prelude.Nothing,
      $sel:requiresAutoMinorEngineVersionUpgrade:OptionGroupOption' :: Maybe Bool
requiresAutoMinorEngineVersionUpgrade =
        Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:portRequired:OptionGroupOption' :: Maybe Bool
portRequired = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:description:OptionGroupOption' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:optionsDependedOn:OptionGroupOption' :: Maybe [Text]
optionsDependedOn = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:vpcOnly:OptionGroupOption' :: Maybe Bool
vpcOnly = Maybe Bool
forall a. Maybe a
Prelude.Nothing
    }

-- | The minimum required engine version for the option to be applied.
optionGroupOption_minimumRequiredMinorEngineVersion :: Lens.Lens' OptionGroupOption (Prelude.Maybe Prelude.Text)
optionGroupOption_minimumRequiredMinorEngineVersion :: (Maybe Text -> f (Maybe Text))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_minimumRequiredMinorEngineVersion = (OptionGroupOption -> Maybe Text)
-> (OptionGroupOption -> Maybe Text -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe Text
minimumRequiredMinorEngineVersion :: Maybe Text
$sel:minimumRequiredMinorEngineVersion:OptionGroupOption' :: OptionGroupOption -> Maybe Text
minimumRequiredMinorEngineVersion} -> Maybe Text
minimumRequiredMinorEngineVersion) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe Text
a -> OptionGroupOption
s {$sel:minimumRequiredMinorEngineVersion:OptionGroupOption' :: Maybe Text
minimumRequiredMinorEngineVersion = Maybe Text
a} :: OptionGroupOption)

-- | The options that conflict with this option.
optionGroupOption_optionsConflictsWith :: Lens.Lens' OptionGroupOption (Prelude.Maybe [Prelude.Text])
optionGroupOption_optionsConflictsWith :: (Maybe [Text] -> f (Maybe [Text]))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_optionsConflictsWith = (OptionGroupOption -> Maybe [Text])
-> (OptionGroupOption -> Maybe [Text] -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe [Text]
optionsConflictsWith :: Maybe [Text]
$sel:optionsConflictsWith:OptionGroupOption' :: OptionGroupOption -> Maybe [Text]
optionsConflictsWith} -> Maybe [Text]
optionsConflictsWith) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe [Text]
a -> OptionGroupOption
s {$sel:optionsConflictsWith:OptionGroupOption' :: Maybe [Text]
optionsConflictsWith = Maybe [Text]
a} :: OptionGroupOption) ((Maybe [Text] -> f (Maybe [Text]))
 -> OptionGroupOption -> f OptionGroupOption)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> OptionGroupOption
-> f OptionGroupOption
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Permanent options can never be removed from an option group. An option
-- group containing a permanent option can\'t be removed from a DB
-- instance.
optionGroupOption_permanent :: Lens.Lens' OptionGroupOption (Prelude.Maybe Prelude.Bool)
optionGroupOption_permanent :: (Maybe Bool -> f (Maybe Bool))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_permanent = (OptionGroupOption -> Maybe Bool)
-> (OptionGroupOption -> Maybe Bool -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe Bool
permanent :: Maybe Bool
$sel:permanent:OptionGroupOption' :: OptionGroupOption -> Maybe Bool
permanent} -> Maybe Bool
permanent) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe Bool
a -> OptionGroupOption
s {$sel:permanent:OptionGroupOption' :: Maybe Bool
permanent = Maybe Bool
a} :: OptionGroupOption)

-- | Persistent options can\'t be removed from an option group while DB
-- instances are associated with the option group. If you disassociate all
-- DB instances from the option group, your can remove the persistent
-- option from the option group.
optionGroupOption_persistent :: Lens.Lens' OptionGroupOption (Prelude.Maybe Prelude.Bool)
optionGroupOption_persistent :: (Maybe Bool -> f (Maybe Bool))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_persistent = (OptionGroupOption -> Maybe Bool)
-> (OptionGroupOption -> Maybe Bool -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe Bool
persistent :: Maybe Bool
$sel:persistent:OptionGroupOption' :: OptionGroupOption -> Maybe Bool
persistent} -> Maybe Bool
persistent) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe Bool
a -> OptionGroupOption
s {$sel:persistent:OptionGroupOption' :: Maybe Bool
persistent = Maybe Bool
a} :: OptionGroupOption)

-- | The versions that are available for the option.
optionGroupOption_optionGroupOptionVersions :: Lens.Lens' OptionGroupOption (Prelude.Maybe [OptionVersion])
optionGroupOption_optionGroupOptionVersions :: (Maybe [OptionVersion] -> f (Maybe [OptionVersion]))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_optionGroupOptionVersions = (OptionGroupOption -> Maybe [OptionVersion])
-> (OptionGroupOption
    -> Maybe [OptionVersion] -> OptionGroupOption)
-> Lens
     OptionGroupOption
     OptionGroupOption
     (Maybe [OptionVersion])
     (Maybe [OptionVersion])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe [OptionVersion]
optionGroupOptionVersions :: Maybe [OptionVersion]
$sel:optionGroupOptionVersions:OptionGroupOption' :: OptionGroupOption -> Maybe [OptionVersion]
optionGroupOptionVersions} -> Maybe [OptionVersion]
optionGroupOptionVersions) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe [OptionVersion]
a -> OptionGroupOption
s {$sel:optionGroupOptionVersions:OptionGroupOption' :: Maybe [OptionVersion]
optionGroupOptionVersions = Maybe [OptionVersion]
a} :: OptionGroupOption) ((Maybe [OptionVersion] -> f (Maybe [OptionVersion]))
 -> OptionGroupOption -> f OptionGroupOption)
-> ((Maybe [OptionVersion] -> f (Maybe [OptionVersion]))
    -> Maybe [OptionVersion] -> f (Maybe [OptionVersion]))
-> (Maybe [OptionVersion] -> f (Maybe [OptionVersion]))
-> OptionGroupOption
-> f OptionGroupOption
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [OptionVersion] [OptionVersion] [OptionVersion] [OptionVersion]
-> Iso
     (Maybe [OptionVersion])
     (Maybe [OptionVersion])
     (Maybe [OptionVersion])
     (Maybe [OptionVersion])
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
  [OptionVersion] [OptionVersion] [OptionVersion] [OptionVersion]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The name of the engine that this option can be applied to.
optionGroupOption_engineName :: Lens.Lens' OptionGroupOption (Prelude.Maybe Prelude.Text)
optionGroupOption_engineName :: (Maybe Text -> f (Maybe Text))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_engineName = (OptionGroupOption -> Maybe Text)
-> (OptionGroupOption -> Maybe Text -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe Text
engineName :: Maybe Text
$sel:engineName:OptionGroupOption' :: OptionGroupOption -> Maybe Text
engineName} -> Maybe Text
engineName) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe Text
a -> OptionGroupOption
s {$sel:engineName:OptionGroupOption' :: Maybe Text
engineName = Maybe Text
a} :: OptionGroupOption)

-- | Indicates the major engine version that the option is available for.
optionGroupOption_majorEngineVersion :: Lens.Lens' OptionGroupOption (Prelude.Maybe Prelude.Text)
optionGroupOption_majorEngineVersion :: (Maybe Text -> f (Maybe Text))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_majorEngineVersion = (OptionGroupOption -> Maybe Text)
-> (OptionGroupOption -> Maybe Text -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe Text
majorEngineVersion :: Maybe Text
$sel:majorEngineVersion:OptionGroupOption' :: OptionGroupOption -> Maybe Text
majorEngineVersion} -> Maybe Text
majorEngineVersion) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe Text
a -> OptionGroupOption
s {$sel:majorEngineVersion:OptionGroupOption' :: Maybe Text
majorEngineVersion = Maybe Text
a} :: OptionGroupOption)

-- | The name of the option.
optionGroupOption_name :: Lens.Lens' OptionGroupOption (Prelude.Maybe Prelude.Text)
optionGroupOption_name :: (Maybe Text -> f (Maybe Text))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_name = (OptionGroupOption -> Maybe Text)
-> (OptionGroupOption -> Maybe Text -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe Text
name :: Maybe Text
$sel:name:OptionGroupOption' :: OptionGroupOption -> Maybe Text
name} -> Maybe Text
name) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe Text
a -> OptionGroupOption
s {$sel:name:OptionGroupOption' :: Maybe Text
name = Maybe Text
a} :: OptionGroupOption)

-- | If true, you can change the option to an earlier version of the option.
-- This only applies to options that have different versions available.
optionGroupOption_supportsOptionVersionDowngrade :: Lens.Lens' OptionGroupOption (Prelude.Maybe Prelude.Bool)
optionGroupOption_supportsOptionVersionDowngrade :: (Maybe Bool -> f (Maybe Bool))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_supportsOptionVersionDowngrade = (OptionGroupOption -> Maybe Bool)
-> (OptionGroupOption -> Maybe Bool -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe Bool
supportsOptionVersionDowngrade :: Maybe Bool
$sel:supportsOptionVersionDowngrade:OptionGroupOption' :: OptionGroupOption -> Maybe Bool
supportsOptionVersionDowngrade} -> Maybe Bool
supportsOptionVersionDowngrade) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe Bool
a -> OptionGroupOption
s {$sel:supportsOptionVersionDowngrade:OptionGroupOption' :: Maybe Bool
supportsOptionVersionDowngrade = Maybe Bool
a} :: OptionGroupOption)

-- | If the option requires a port, specifies the default port for the
-- option.
optionGroupOption_defaultPort :: Lens.Lens' OptionGroupOption (Prelude.Maybe Prelude.Int)
optionGroupOption_defaultPort :: (Maybe Int -> f (Maybe Int))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_defaultPort = (OptionGroupOption -> Maybe Int)
-> (OptionGroupOption -> Maybe Int -> OptionGroupOption)
-> Lens OptionGroupOption OptionGroupOption (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe Int
defaultPort :: Maybe Int
$sel:defaultPort:OptionGroupOption' :: OptionGroupOption -> Maybe Int
defaultPort} -> Maybe Int
defaultPort) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe Int
a -> OptionGroupOption
s {$sel:defaultPort:OptionGroupOption' :: Maybe Int
defaultPort = Maybe Int
a} :: OptionGroupOption)

-- | The option settings that are available (and the default value) for each
-- option in an option group.
optionGroupOption_optionGroupOptionSettings :: Lens.Lens' OptionGroupOption (Prelude.Maybe [OptionGroupOptionSetting])
optionGroupOption_optionGroupOptionSettings :: (Maybe [OptionGroupOptionSetting]
 -> f (Maybe [OptionGroupOptionSetting]))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_optionGroupOptionSettings = (OptionGroupOption -> Maybe [OptionGroupOptionSetting])
-> (OptionGroupOption
    -> Maybe [OptionGroupOptionSetting] -> OptionGroupOption)
-> Lens
     OptionGroupOption
     OptionGroupOption
     (Maybe [OptionGroupOptionSetting])
     (Maybe [OptionGroupOptionSetting])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe [OptionGroupOptionSetting]
optionGroupOptionSettings :: Maybe [OptionGroupOptionSetting]
$sel:optionGroupOptionSettings:OptionGroupOption' :: OptionGroupOption -> Maybe [OptionGroupOptionSetting]
optionGroupOptionSettings} -> Maybe [OptionGroupOptionSetting]
optionGroupOptionSettings) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe [OptionGroupOptionSetting]
a -> OptionGroupOption
s {$sel:optionGroupOptionSettings:OptionGroupOption' :: Maybe [OptionGroupOptionSetting]
optionGroupOptionSettings = Maybe [OptionGroupOptionSetting]
a} :: OptionGroupOption) ((Maybe [OptionGroupOptionSetting]
  -> f (Maybe [OptionGroupOptionSetting]))
 -> OptionGroupOption -> f OptionGroupOption)
-> ((Maybe [OptionGroupOptionSetting]
     -> f (Maybe [OptionGroupOptionSetting]))
    -> Maybe [OptionGroupOptionSetting]
    -> f (Maybe [OptionGroupOptionSetting]))
-> (Maybe [OptionGroupOptionSetting]
    -> f (Maybe [OptionGroupOptionSetting]))
-> OptionGroupOption
-> f OptionGroupOption
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [OptionGroupOptionSetting]
  [OptionGroupOptionSetting]
  [OptionGroupOptionSetting]
  [OptionGroupOptionSetting]
-> Iso
     (Maybe [OptionGroupOptionSetting])
     (Maybe [OptionGroupOptionSetting])
     (Maybe [OptionGroupOptionSetting])
     (Maybe [OptionGroupOptionSetting])
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
  [OptionGroupOptionSetting]
  [OptionGroupOptionSetting]
  [OptionGroupOptionSetting]
  [OptionGroupOptionSetting]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | If true, you must enable the Auto Minor Version Upgrade setting for your
-- DB instance before you can use this option. You can enable Auto Minor
-- Version Upgrade when you first create your DB instance, or by modifying
-- your DB instance later.
optionGroupOption_requiresAutoMinorEngineVersionUpgrade :: Lens.Lens' OptionGroupOption (Prelude.Maybe Prelude.Bool)
optionGroupOption_requiresAutoMinorEngineVersionUpgrade :: (Maybe Bool -> f (Maybe Bool))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_requiresAutoMinorEngineVersionUpgrade = (OptionGroupOption -> Maybe Bool)
-> (OptionGroupOption -> Maybe Bool -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe Bool
requiresAutoMinorEngineVersionUpgrade :: Maybe Bool
$sel:requiresAutoMinorEngineVersionUpgrade:OptionGroupOption' :: OptionGroupOption -> Maybe Bool
requiresAutoMinorEngineVersionUpgrade} -> Maybe Bool
requiresAutoMinorEngineVersionUpgrade) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe Bool
a -> OptionGroupOption
s {$sel:requiresAutoMinorEngineVersionUpgrade:OptionGroupOption' :: Maybe Bool
requiresAutoMinorEngineVersionUpgrade = Maybe Bool
a} :: OptionGroupOption)

-- | Specifies whether the option requires a port.
optionGroupOption_portRequired :: Lens.Lens' OptionGroupOption (Prelude.Maybe Prelude.Bool)
optionGroupOption_portRequired :: (Maybe Bool -> f (Maybe Bool))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_portRequired = (OptionGroupOption -> Maybe Bool)
-> (OptionGroupOption -> Maybe Bool -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe Bool
portRequired :: Maybe Bool
$sel:portRequired:OptionGroupOption' :: OptionGroupOption -> Maybe Bool
portRequired} -> Maybe Bool
portRequired) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe Bool
a -> OptionGroupOption
s {$sel:portRequired:OptionGroupOption' :: Maybe Bool
portRequired = Maybe Bool
a} :: OptionGroupOption)

-- | The description of the option.
optionGroupOption_description :: Lens.Lens' OptionGroupOption (Prelude.Maybe Prelude.Text)
optionGroupOption_description :: (Maybe Text -> f (Maybe Text))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_description = (OptionGroupOption -> Maybe Text)
-> (OptionGroupOption -> Maybe Text -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe Text
description :: Maybe Text
$sel:description:OptionGroupOption' :: OptionGroupOption -> Maybe Text
description} -> Maybe Text
description) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe Text
a -> OptionGroupOption
s {$sel:description:OptionGroupOption' :: Maybe Text
description = Maybe Text
a} :: OptionGroupOption)

-- | The options that are prerequisites for this option.
optionGroupOption_optionsDependedOn :: Lens.Lens' OptionGroupOption (Prelude.Maybe [Prelude.Text])
optionGroupOption_optionsDependedOn :: (Maybe [Text] -> f (Maybe [Text]))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_optionsDependedOn = (OptionGroupOption -> Maybe [Text])
-> (OptionGroupOption -> Maybe [Text] -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe [Text]
optionsDependedOn :: Maybe [Text]
$sel:optionsDependedOn:OptionGroupOption' :: OptionGroupOption -> Maybe [Text]
optionsDependedOn} -> Maybe [Text]
optionsDependedOn) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe [Text]
a -> OptionGroupOption
s {$sel:optionsDependedOn:OptionGroupOption' :: Maybe [Text]
optionsDependedOn = Maybe [Text]
a} :: OptionGroupOption) ((Maybe [Text] -> f (Maybe [Text]))
 -> OptionGroupOption -> f OptionGroupOption)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> OptionGroupOption
-> f OptionGroupOption
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | If true, you can only use this option with a DB instance that is in a
-- VPC.
optionGroupOption_vpcOnly :: Lens.Lens' OptionGroupOption (Prelude.Maybe Prelude.Bool)
optionGroupOption_vpcOnly :: (Maybe Bool -> f (Maybe Bool))
-> OptionGroupOption -> f OptionGroupOption
optionGroupOption_vpcOnly = (OptionGroupOption -> Maybe Bool)
-> (OptionGroupOption -> Maybe Bool -> OptionGroupOption)
-> Lens
     OptionGroupOption OptionGroupOption (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\OptionGroupOption' {Maybe Bool
vpcOnly :: Maybe Bool
$sel:vpcOnly:OptionGroupOption' :: OptionGroupOption -> Maybe Bool
vpcOnly} -> Maybe Bool
vpcOnly) (\s :: OptionGroupOption
s@OptionGroupOption' {} Maybe Bool
a -> OptionGroupOption
s {$sel:vpcOnly:OptionGroupOption' :: Maybe Bool
vpcOnly = Maybe Bool
a} :: OptionGroupOption)

instance Core.FromXML OptionGroupOption where
  parseXML :: [Node] -> Either String OptionGroupOption
parseXML [Node]
x =
    Maybe Text
-> Maybe [Text]
-> Maybe Bool
-> Maybe Bool
-> Maybe [OptionVersion]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Int
-> Maybe [OptionGroupOptionSetting]
-> Maybe Bool
-> Maybe Bool
-> Maybe Text
-> Maybe [Text]
-> Maybe Bool
-> OptionGroupOption
OptionGroupOption'
      (Maybe Text
 -> Maybe [Text]
 -> Maybe Bool
 -> Maybe Bool
 -> Maybe [OptionVersion]
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Bool
 -> Maybe Int
 -> Maybe [OptionGroupOptionSetting]
 -> Maybe Bool
 -> Maybe Bool
 -> Maybe Text
 -> Maybe [Text]
 -> Maybe Bool
 -> OptionGroupOption)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [Text]
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe [OptionVersion]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe [OptionGroupOptionSetting]
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Bool
      -> OptionGroupOption)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"MinimumRequiredMinorEngineVersion")
      Either
  String
  (Maybe [Text]
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe [OptionVersion]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe [OptionGroupOptionSetting]
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Bool
   -> OptionGroupOption)
-> Either String (Maybe [Text])
-> Either
     String
     (Maybe Bool
      -> Maybe Bool
      -> Maybe [OptionVersion]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe [OptionGroupOptionSetting]
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Bool
      -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"OptionsConflictsWith"
                      Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [Text]))
-> Either String (Maybe [Text])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [Text])
-> [Node] -> Either String (Maybe [Text])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [Text]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"OptionConflictName")
                  )
      Either
  String
  (Maybe Bool
   -> Maybe Bool
   -> Maybe [OptionVersion]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe [OptionGroupOptionSetting]
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Bool
   -> OptionGroupOption)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe Bool
      -> Maybe [OptionVersion]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe [OptionGroupOptionSetting]
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Bool
      -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Permanent")
      Either
  String
  (Maybe Bool
   -> Maybe [OptionVersion]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe [OptionGroupOptionSetting]
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Bool
   -> OptionGroupOption)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe [OptionVersion]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe [OptionGroupOptionSetting]
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Bool
      -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Persistent")
      Either
  String
  (Maybe [OptionVersion]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe [OptionGroupOptionSetting]
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Bool
   -> OptionGroupOption)
-> Either String (Maybe [OptionVersion])
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe [OptionGroupOptionSetting]
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Bool
      -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"OptionGroupOptionVersions"
                      Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [OptionVersion]))
-> Either String (Maybe [OptionVersion])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [OptionVersion])
-> [Node] -> Either String (Maybe [OptionVersion])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [OptionVersion]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"OptionVersion")
                  )
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe [OptionGroupOptionSetting]
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Bool
   -> OptionGroupOption)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe [OptionGroupOptionSetting]
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Bool
      -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"EngineName")
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe [OptionGroupOptionSetting]
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Bool
   -> OptionGroupOption)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe [OptionGroupOptionSetting]
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Bool
      -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"MajorEngineVersion")
      Either
  String
  (Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe [OptionGroupOptionSetting]
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Bool
   -> OptionGroupOption)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Bool
      -> Maybe Int
      -> Maybe [OptionGroupOptionSetting]
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Bool
      -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Name")
      Either
  String
  (Maybe Bool
   -> Maybe Int
   -> Maybe [OptionGroupOptionSetting]
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Bool
   -> OptionGroupOption)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe Int
      -> Maybe [OptionGroupOptionSetting]
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Bool
      -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"SupportsOptionVersionDowngrade")
      Either
  String
  (Maybe Int
   -> Maybe [OptionGroupOptionSetting]
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Bool
   -> OptionGroupOption)
-> Either String (Maybe Int)
-> Either
     String
     (Maybe [OptionGroupOptionSetting]
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Bool
      -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Int)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"DefaultPort")
      Either
  String
  (Maybe [OptionGroupOptionSetting]
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Bool
   -> OptionGroupOption)
-> Either String (Maybe [OptionGroupOptionSetting])
-> Either
     String
     (Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe Bool
      -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"OptionGroupOptionSettings"
                      Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [OptionGroupOptionSetting]))
-> Either String (Maybe [OptionGroupOptionSetting])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [OptionGroupOptionSetting])
-> [Node] -> Either String (Maybe [OptionGroupOptionSetting])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may
                        (Text -> [Node] -> Either String [OptionGroupOptionSetting]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"OptionGroupOptionSetting")
                  )
      Either
  String
  (Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe Bool
   -> OptionGroupOption)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe Bool
      -> Maybe Text -> Maybe [Text] -> Maybe Bool -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"RequiresAutoMinorEngineVersionUpgrade")
      Either
  String
  (Maybe Bool
   -> Maybe Text -> Maybe [Text] -> Maybe Bool -> OptionGroupOption)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe Text -> Maybe [Text] -> Maybe Bool -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"PortRequired")
      Either
  String
  (Maybe Text -> Maybe [Text] -> Maybe Bool -> OptionGroupOption)
-> Either String (Maybe Text)
-> Either String (Maybe [Text] -> Maybe Bool -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Description")
      Either String (Maybe [Text] -> Maybe Bool -> OptionGroupOption)
-> Either String (Maybe [Text])
-> Either String (Maybe Bool -> OptionGroupOption)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"OptionsDependedOn"
                      Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [Text]))
-> Either String (Maybe [Text])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [Text])
-> [Node] -> Either String (Maybe [Text])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [Text]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"OptionName")
                  )
      Either String (Maybe Bool -> OptionGroupOption)
-> Either String (Maybe Bool) -> Either String OptionGroupOption
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"VpcOnly")

instance Prelude.Hashable OptionGroupOption

instance Prelude.NFData OptionGroupOption