module Stratosphere.BillingConductor.CustomLineItem.BillingPeriodRangeProperty (
        BillingPeriodRangeProperty(..), mkBillingPeriodRangeProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data BillingPeriodRangeProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-billingconductor-customlineitem-billingperiodrange.html>
    BillingPeriodRangeProperty {BillingPeriodRangeProperty -> ()
haddock_workaround_ :: (),
                                -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-billingconductor-customlineitem-billingperiodrange.html#cfn-billingconductor-customlineitem-billingperiodrange-exclusiveendbillingperiod>
                                BillingPeriodRangeProperty -> Maybe (Value Text)
exclusiveEndBillingPeriod :: (Prelude.Maybe (Value Prelude.Text)),
                                -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-billingconductor-customlineitem-billingperiodrange.html#cfn-billingconductor-customlineitem-billingperiodrange-inclusivestartbillingperiod>
                                BillingPeriodRangeProperty -> Maybe (Value Text)
inclusiveStartBillingPeriod :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (BillingPeriodRangeProperty -> BillingPeriodRangeProperty -> Bool
(BillingPeriodRangeProperty -> BillingPeriodRangeProperty -> Bool)
-> (BillingPeriodRangeProperty
    -> BillingPeriodRangeProperty -> Bool)
-> Eq BillingPeriodRangeProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: BillingPeriodRangeProperty -> BillingPeriodRangeProperty -> Bool
== :: BillingPeriodRangeProperty -> BillingPeriodRangeProperty -> Bool
$c/= :: BillingPeriodRangeProperty -> BillingPeriodRangeProperty -> Bool
/= :: BillingPeriodRangeProperty -> BillingPeriodRangeProperty -> Bool
Prelude.Eq, Int -> BillingPeriodRangeProperty -> ShowS
[BillingPeriodRangeProperty] -> ShowS
BillingPeriodRangeProperty -> String
(Int -> BillingPeriodRangeProperty -> ShowS)
-> (BillingPeriodRangeProperty -> String)
-> ([BillingPeriodRangeProperty] -> ShowS)
-> Show BillingPeriodRangeProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> BillingPeriodRangeProperty -> ShowS
showsPrec :: Int -> BillingPeriodRangeProperty -> ShowS
$cshow :: BillingPeriodRangeProperty -> String
show :: BillingPeriodRangeProperty -> String
$cshowList :: [BillingPeriodRangeProperty] -> ShowS
showList :: [BillingPeriodRangeProperty] -> ShowS
Prelude.Show)
mkBillingPeriodRangeProperty :: BillingPeriodRangeProperty
mkBillingPeriodRangeProperty :: BillingPeriodRangeProperty
mkBillingPeriodRangeProperty
  = BillingPeriodRangeProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (),
       exclusiveEndBillingPeriod :: Maybe (Value Text)
exclusiveEndBillingPeriod = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
       inclusiveStartBillingPeriod :: Maybe (Value Text)
inclusiveStartBillingPeriod = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties BillingPeriodRangeProperty where
  toResourceProperties :: BillingPeriodRangeProperty -> ResourceProperties
toResourceProperties BillingPeriodRangeProperty {Maybe (Value Text)
()
haddock_workaround_ :: BillingPeriodRangeProperty -> ()
exclusiveEndBillingPeriod :: BillingPeriodRangeProperty -> Maybe (Value Text)
inclusiveStartBillingPeriod :: BillingPeriodRangeProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
exclusiveEndBillingPeriod :: Maybe (Value Text)
inclusiveStartBillingPeriod :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::BillingConductor::CustomLineItem.BillingPeriodRange",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
                        ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
                           [Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ExclusiveEndBillingPeriod"
                              (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
exclusiveEndBillingPeriod,
                            Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"InclusiveStartBillingPeriod"
                              (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
inclusiveStartBillingPeriod])}
instance JSON.ToJSON BillingPeriodRangeProperty where
  toJSON :: BillingPeriodRangeProperty -> Value
toJSON BillingPeriodRangeProperty {Maybe (Value Text)
()
haddock_workaround_ :: BillingPeriodRangeProperty -> ()
exclusiveEndBillingPeriod :: BillingPeriodRangeProperty -> Maybe (Value Text)
inclusiveStartBillingPeriod :: BillingPeriodRangeProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
exclusiveEndBillingPeriod :: Maybe (Value Text)
inclusiveStartBillingPeriod :: Maybe (Value Text)
..}
    = [(Key, Value)] -> Value
JSON.object
        ([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
           ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
              [Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ExclusiveEndBillingPeriod"
                 (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
exclusiveEndBillingPeriod,
               Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"InclusiveStartBillingPeriod"
                 (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
inclusiveStartBillingPeriod]))
instance Property "ExclusiveEndBillingPeriod" BillingPeriodRangeProperty where
  type PropertyType "ExclusiveEndBillingPeriod" BillingPeriodRangeProperty = Value Prelude.Text
  set :: PropertyType "ExclusiveEndBillingPeriod" BillingPeriodRangeProperty
-> BillingPeriodRangeProperty -> BillingPeriodRangeProperty
set PropertyType "ExclusiveEndBillingPeriod" BillingPeriodRangeProperty
newValue BillingPeriodRangeProperty {Maybe (Value Text)
()
haddock_workaround_ :: BillingPeriodRangeProperty -> ()
exclusiveEndBillingPeriod :: BillingPeriodRangeProperty -> Maybe (Value Text)
inclusiveStartBillingPeriod :: BillingPeriodRangeProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
exclusiveEndBillingPeriod :: Maybe (Value Text)
inclusiveStartBillingPeriod :: Maybe (Value Text)
..}
    = BillingPeriodRangeProperty
        {exclusiveEndBillingPeriod :: Maybe (Value Text)
exclusiveEndBillingPeriod = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ExclusiveEndBillingPeriod" BillingPeriodRangeProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
inclusiveStartBillingPeriod :: Maybe (Value Text)
haddock_workaround_ :: ()
inclusiveStartBillingPeriod :: Maybe (Value Text)
..}
instance Property "InclusiveStartBillingPeriod" BillingPeriodRangeProperty where
  type PropertyType "InclusiveStartBillingPeriod" BillingPeriodRangeProperty = Value Prelude.Text
  set :: PropertyType
  "InclusiveStartBillingPeriod" BillingPeriodRangeProperty
-> BillingPeriodRangeProperty -> BillingPeriodRangeProperty
set PropertyType
  "InclusiveStartBillingPeriod" BillingPeriodRangeProperty
newValue BillingPeriodRangeProperty {Maybe (Value Text)
()
haddock_workaround_ :: BillingPeriodRangeProperty -> ()
exclusiveEndBillingPeriod :: BillingPeriodRangeProperty -> Maybe (Value Text)
inclusiveStartBillingPeriod :: BillingPeriodRangeProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
exclusiveEndBillingPeriod :: Maybe (Value Text)
inclusiveStartBillingPeriod :: Maybe (Value Text)
..}
    = BillingPeriodRangeProperty
        {inclusiveStartBillingPeriod :: Maybe (Value Text)
inclusiveStartBillingPeriod = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType
  "InclusiveStartBillingPeriod" BillingPeriodRangeProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
exclusiveEndBillingPeriod :: Maybe (Value Text)
haddock_workaround_ :: ()
exclusiveEndBillingPeriod :: Maybe (Value Text)
..}