{-# 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 #-}
module Amazonka.BillingConductor.Types.PricingPlanListElement where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
data PricingPlanListElement = PricingPlanListElement'
{
PricingPlanListElement -> Maybe Text
arn :: Prelude.Maybe Prelude.Text,
PricingPlanListElement -> Maybe Integer
creationTime :: Prelude.Maybe Prelude.Integer,
PricingPlanListElement -> Maybe (Sensitive Text)
description :: Prelude.Maybe (Data.Sensitive Prelude.Text),
PricingPlanListElement -> Maybe Integer
lastModifiedTime :: Prelude.Maybe Prelude.Integer,
PricingPlanListElement -> Maybe (Sensitive Text)
name :: Prelude.Maybe (Data.Sensitive Prelude.Text),
PricingPlanListElement -> Maybe Natural
size :: Prelude.Maybe Prelude.Natural
}
deriving (PricingPlanListElement -> PricingPlanListElement -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PricingPlanListElement -> PricingPlanListElement -> Bool
$c/= :: PricingPlanListElement -> PricingPlanListElement -> Bool
== :: PricingPlanListElement -> PricingPlanListElement -> Bool
$c== :: PricingPlanListElement -> PricingPlanListElement -> Bool
Prelude.Eq, Int -> PricingPlanListElement -> ShowS
[PricingPlanListElement] -> ShowS
PricingPlanListElement -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PricingPlanListElement] -> ShowS
$cshowList :: [PricingPlanListElement] -> ShowS
show :: PricingPlanListElement -> String
$cshow :: PricingPlanListElement -> String
showsPrec :: Int -> PricingPlanListElement -> ShowS
$cshowsPrec :: Int -> PricingPlanListElement -> ShowS
Prelude.Show, forall x. Rep PricingPlanListElement x -> PricingPlanListElement
forall x. PricingPlanListElement -> Rep PricingPlanListElement x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep PricingPlanListElement x -> PricingPlanListElement
$cfrom :: forall x. PricingPlanListElement -> Rep PricingPlanListElement x
Prelude.Generic)
newPricingPlanListElement ::
PricingPlanListElement
newPricingPlanListElement :: PricingPlanListElement
newPricingPlanListElement =
PricingPlanListElement'
{ $sel:arn:PricingPlanListElement' :: Maybe Text
arn = forall a. Maybe a
Prelude.Nothing,
$sel:creationTime:PricingPlanListElement' :: Maybe Integer
creationTime = forall a. Maybe a
Prelude.Nothing,
$sel:description:PricingPlanListElement' :: Maybe (Sensitive Text)
description = forall a. Maybe a
Prelude.Nothing,
$sel:lastModifiedTime:PricingPlanListElement' :: Maybe Integer
lastModifiedTime = forall a. Maybe a
Prelude.Nothing,
$sel:name:PricingPlanListElement' :: Maybe (Sensitive Text)
name = forall a. Maybe a
Prelude.Nothing,
$sel:size:PricingPlanListElement' :: Maybe Natural
size = forall a. Maybe a
Prelude.Nothing
}
pricingPlanListElement_arn :: Lens.Lens' PricingPlanListElement (Prelude.Maybe Prelude.Text)
pricingPlanListElement_arn :: Lens' PricingPlanListElement (Maybe Text)
pricingPlanListElement_arn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PricingPlanListElement' {Maybe Text
arn :: Maybe Text
$sel:arn:PricingPlanListElement' :: PricingPlanListElement -> Maybe Text
arn} -> Maybe Text
arn) (\s :: PricingPlanListElement
s@PricingPlanListElement' {} Maybe Text
a -> PricingPlanListElement
s {$sel:arn:PricingPlanListElement' :: Maybe Text
arn = Maybe Text
a} :: PricingPlanListElement)
pricingPlanListElement_creationTime :: Lens.Lens' PricingPlanListElement (Prelude.Maybe Prelude.Integer)
pricingPlanListElement_creationTime :: Lens' PricingPlanListElement (Maybe Integer)
pricingPlanListElement_creationTime = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PricingPlanListElement' {Maybe Integer
creationTime :: Maybe Integer
$sel:creationTime:PricingPlanListElement' :: PricingPlanListElement -> Maybe Integer
creationTime} -> Maybe Integer
creationTime) (\s :: PricingPlanListElement
s@PricingPlanListElement' {} Maybe Integer
a -> PricingPlanListElement
s {$sel:creationTime:PricingPlanListElement' :: Maybe Integer
creationTime = Maybe Integer
a} :: PricingPlanListElement)
pricingPlanListElement_description :: Lens.Lens' PricingPlanListElement (Prelude.Maybe Prelude.Text)
pricingPlanListElement_description :: Lens' PricingPlanListElement (Maybe Text)
pricingPlanListElement_description = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PricingPlanListElement' {Maybe (Sensitive Text)
description :: Maybe (Sensitive Text)
$sel:description:PricingPlanListElement' :: PricingPlanListElement -> Maybe (Sensitive Text)
description} -> Maybe (Sensitive Text)
description) (\s :: PricingPlanListElement
s@PricingPlanListElement' {} Maybe (Sensitive Text)
a -> PricingPlanListElement
s {$sel:description:PricingPlanListElement' :: Maybe (Sensitive Text)
description = Maybe (Sensitive Text)
a} :: PricingPlanListElement) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall a. Iso' (Sensitive a) a
Data._Sensitive
pricingPlanListElement_lastModifiedTime :: Lens.Lens' PricingPlanListElement (Prelude.Maybe Prelude.Integer)
pricingPlanListElement_lastModifiedTime :: Lens' PricingPlanListElement (Maybe Integer)
pricingPlanListElement_lastModifiedTime = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PricingPlanListElement' {Maybe Integer
lastModifiedTime :: Maybe Integer
$sel:lastModifiedTime:PricingPlanListElement' :: PricingPlanListElement -> Maybe Integer
lastModifiedTime} -> Maybe Integer
lastModifiedTime) (\s :: PricingPlanListElement
s@PricingPlanListElement' {} Maybe Integer
a -> PricingPlanListElement
s {$sel:lastModifiedTime:PricingPlanListElement' :: Maybe Integer
lastModifiedTime = Maybe Integer
a} :: PricingPlanListElement)
pricingPlanListElement_name :: Lens.Lens' PricingPlanListElement (Prelude.Maybe Prelude.Text)
pricingPlanListElement_name :: Lens' PricingPlanListElement (Maybe Text)
pricingPlanListElement_name = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PricingPlanListElement' {Maybe (Sensitive Text)
name :: Maybe (Sensitive Text)
$sel:name:PricingPlanListElement' :: PricingPlanListElement -> Maybe (Sensitive Text)
name} -> Maybe (Sensitive Text)
name) (\s :: PricingPlanListElement
s@PricingPlanListElement' {} Maybe (Sensitive Text)
a -> PricingPlanListElement
s {$sel:name:PricingPlanListElement' :: Maybe (Sensitive Text)
name = Maybe (Sensitive Text)
a} :: PricingPlanListElement) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall a. Iso' (Sensitive a) a
Data._Sensitive
pricingPlanListElement_size :: Lens.Lens' PricingPlanListElement (Prelude.Maybe Prelude.Natural)
pricingPlanListElement_size :: Lens' PricingPlanListElement (Maybe Natural)
pricingPlanListElement_size = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PricingPlanListElement' {Maybe Natural
size :: Maybe Natural
$sel:size:PricingPlanListElement' :: PricingPlanListElement -> Maybe Natural
size} -> Maybe Natural
size) (\s :: PricingPlanListElement
s@PricingPlanListElement' {} Maybe Natural
a -> PricingPlanListElement
s {$sel:size:PricingPlanListElement' :: Maybe Natural
size = Maybe Natural
a} :: PricingPlanListElement)
instance Data.FromJSON PricingPlanListElement where
parseJSON :: Value -> Parser PricingPlanListElement
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"PricingPlanListElement"
( \Object
x ->
Maybe Text
-> Maybe Integer
-> Maybe (Sensitive Text)
-> Maybe Integer
-> Maybe (Sensitive Text)
-> Maybe Natural
-> PricingPlanListElement
PricingPlanListElement'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Arn")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"CreationTime")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Description")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"LastModifiedTime")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Name")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Size")
)
instance Prelude.Hashable PricingPlanListElement where
hashWithSalt :: Int -> PricingPlanListElement -> Int
hashWithSalt Int
_salt PricingPlanListElement' {Maybe Integer
Maybe Natural
Maybe Text
Maybe (Sensitive Text)
size :: Maybe Natural
name :: Maybe (Sensitive Text)
lastModifiedTime :: Maybe Integer
description :: Maybe (Sensitive Text)
creationTime :: Maybe Integer
arn :: Maybe Text
$sel:size:PricingPlanListElement' :: PricingPlanListElement -> Maybe Natural
$sel:name:PricingPlanListElement' :: PricingPlanListElement -> Maybe (Sensitive Text)
$sel:lastModifiedTime:PricingPlanListElement' :: PricingPlanListElement -> Maybe Integer
$sel:description:PricingPlanListElement' :: PricingPlanListElement -> Maybe (Sensitive Text)
$sel:creationTime:PricingPlanListElement' :: PricingPlanListElement -> Maybe Integer
$sel:arn:PricingPlanListElement' :: PricingPlanListElement -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
arn
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Integer
creationTime
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (Sensitive Text)
description
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Integer
lastModifiedTime
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (Sensitive Text)
name
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
size
instance Prelude.NFData PricingPlanListElement where
rnf :: PricingPlanListElement -> ()
rnf PricingPlanListElement' {Maybe Integer
Maybe Natural
Maybe Text
Maybe (Sensitive Text)
size :: Maybe Natural
name :: Maybe (Sensitive Text)
lastModifiedTime :: Maybe Integer
description :: Maybe (Sensitive Text)
creationTime :: Maybe Integer
arn :: Maybe Text
$sel:size:PricingPlanListElement' :: PricingPlanListElement -> Maybe Natural
$sel:name:PricingPlanListElement' :: PricingPlanListElement -> Maybe (Sensitive Text)
$sel:lastModifiedTime:PricingPlanListElement' :: PricingPlanListElement -> Maybe Integer
$sel:description:PricingPlanListElement' :: PricingPlanListElement -> Maybe (Sensitive Text)
$sel:creationTime:PricingPlanListElement' :: PricingPlanListElement -> Maybe Integer
$sel:arn:PricingPlanListElement' :: PricingPlanListElement -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
arn
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Integer
creationTime
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (Sensitive Text)
description
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Integer
lastModifiedTime
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (Sensitive Text)
name
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
size