module Stratosphere.S3.StorageLensGroup.MatchObjectAgeProperty (
        MatchObjectAgeProperty(..), mkMatchObjectAgeProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data MatchObjectAgeProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-storagelensgroup-matchobjectage.html>
    MatchObjectAgeProperty {MatchObjectAgeProperty -> ()
haddock_workaround_ :: (),
                            -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-storagelensgroup-matchobjectage.html#cfn-s3-storagelensgroup-matchobjectage-daysgreaterthan>
                            MatchObjectAgeProperty -> Maybe (Value Integer)
daysGreaterThan :: (Prelude.Maybe (Value Prelude.Integer)),
                            -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-storagelensgroup-matchobjectage.html#cfn-s3-storagelensgroup-matchobjectage-dayslessthan>
                            MatchObjectAgeProperty -> Maybe (Value Integer)
daysLessThan :: (Prelude.Maybe (Value Prelude.Integer))}
  deriving stock (MatchObjectAgeProperty -> MatchObjectAgeProperty -> Bool
(MatchObjectAgeProperty -> MatchObjectAgeProperty -> Bool)
-> (MatchObjectAgeProperty -> MatchObjectAgeProperty -> Bool)
-> Eq MatchObjectAgeProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: MatchObjectAgeProperty -> MatchObjectAgeProperty -> Bool
== :: MatchObjectAgeProperty -> MatchObjectAgeProperty -> Bool
$c/= :: MatchObjectAgeProperty -> MatchObjectAgeProperty -> Bool
/= :: MatchObjectAgeProperty -> MatchObjectAgeProperty -> Bool
Prelude.Eq, Int -> MatchObjectAgeProperty -> ShowS
[MatchObjectAgeProperty] -> ShowS
MatchObjectAgeProperty -> String
(Int -> MatchObjectAgeProperty -> ShowS)
-> (MatchObjectAgeProperty -> String)
-> ([MatchObjectAgeProperty] -> ShowS)
-> Show MatchObjectAgeProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> MatchObjectAgeProperty -> ShowS
showsPrec :: Int -> MatchObjectAgeProperty -> ShowS
$cshow :: MatchObjectAgeProperty -> String
show :: MatchObjectAgeProperty -> String
$cshowList :: [MatchObjectAgeProperty] -> ShowS
showList :: [MatchObjectAgeProperty] -> ShowS
Prelude.Show)
mkMatchObjectAgeProperty :: MatchObjectAgeProperty
mkMatchObjectAgeProperty :: MatchObjectAgeProperty
mkMatchObjectAgeProperty
  = MatchObjectAgeProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), daysGreaterThan :: Maybe (Value Integer)
daysGreaterThan = Maybe (Value Integer)
forall a. Maybe a
Prelude.Nothing,
       daysLessThan :: Maybe (Value Integer)
daysLessThan = Maybe (Value Integer)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties MatchObjectAgeProperty where
  toResourceProperties :: MatchObjectAgeProperty -> ResourceProperties
toResourceProperties MatchObjectAgeProperty {Maybe (Value Integer)
()
haddock_workaround_ :: MatchObjectAgeProperty -> ()
daysGreaterThan :: MatchObjectAgeProperty -> Maybe (Value Integer)
daysLessThan :: MatchObjectAgeProperty -> Maybe (Value Integer)
haddock_workaround_ :: ()
daysGreaterThan :: Maybe (Value Integer)
daysLessThan :: Maybe (Value Integer)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::S3::StorageLensGroup.MatchObjectAge",
         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 Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"DaysGreaterThan" (Value Integer -> (Key, Value))
-> Maybe (Value Integer) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Integer)
daysGreaterThan,
                            Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"DaysLessThan" (Value Integer -> (Key, Value))
-> Maybe (Value Integer) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Integer)
daysLessThan])}
instance JSON.ToJSON MatchObjectAgeProperty where
  toJSON :: MatchObjectAgeProperty -> Value
toJSON MatchObjectAgeProperty {Maybe (Value Integer)
()
haddock_workaround_ :: MatchObjectAgeProperty -> ()
daysGreaterThan :: MatchObjectAgeProperty -> Maybe (Value Integer)
daysLessThan :: MatchObjectAgeProperty -> Maybe (Value Integer)
haddock_workaround_ :: ()
daysGreaterThan :: Maybe (Value Integer)
daysLessThan :: Maybe (Value Integer)
..}
    = [(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 Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"DaysGreaterThan" (Value Integer -> (Key, Value))
-> Maybe (Value Integer) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Integer)
daysGreaterThan,
               Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"DaysLessThan" (Value Integer -> (Key, Value))
-> Maybe (Value Integer) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Integer)
daysLessThan]))
instance Property "DaysGreaterThan" MatchObjectAgeProperty where
  type PropertyType "DaysGreaterThan" MatchObjectAgeProperty = Value Prelude.Integer
  set :: PropertyType "DaysGreaterThan" MatchObjectAgeProperty
-> MatchObjectAgeProperty -> MatchObjectAgeProperty
set PropertyType "DaysGreaterThan" MatchObjectAgeProperty
newValue MatchObjectAgeProperty {Maybe (Value Integer)
()
haddock_workaround_ :: MatchObjectAgeProperty -> ()
daysGreaterThan :: MatchObjectAgeProperty -> Maybe (Value Integer)
daysLessThan :: MatchObjectAgeProperty -> Maybe (Value Integer)
haddock_workaround_ :: ()
daysGreaterThan :: Maybe (Value Integer)
daysLessThan :: Maybe (Value Integer)
..}
    = MatchObjectAgeProperty
        {daysGreaterThan :: Maybe (Value Integer)
daysGreaterThan = Value Integer -> Maybe (Value Integer)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "DaysGreaterThan" MatchObjectAgeProperty
Value Integer
newValue, Maybe (Value Integer)
()
haddock_workaround_ :: ()
daysLessThan :: Maybe (Value Integer)
haddock_workaround_ :: ()
daysLessThan :: Maybe (Value Integer)
..}
instance Property "DaysLessThan" MatchObjectAgeProperty where
  type PropertyType "DaysLessThan" MatchObjectAgeProperty = Value Prelude.Integer
  set :: PropertyType "DaysLessThan" MatchObjectAgeProperty
-> MatchObjectAgeProperty -> MatchObjectAgeProperty
set PropertyType "DaysLessThan" MatchObjectAgeProperty
newValue MatchObjectAgeProperty {Maybe (Value Integer)
()
haddock_workaround_ :: MatchObjectAgeProperty -> ()
daysGreaterThan :: MatchObjectAgeProperty -> Maybe (Value Integer)
daysLessThan :: MatchObjectAgeProperty -> Maybe (Value Integer)
haddock_workaround_ :: ()
daysGreaterThan :: Maybe (Value Integer)
daysLessThan :: Maybe (Value Integer)
..}
    = MatchObjectAgeProperty {daysLessThan :: Maybe (Value Integer)
daysLessThan = Value Integer -> Maybe (Value Integer)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "DaysLessThan" MatchObjectAgeProperty
Value Integer
newValue, Maybe (Value Integer)
()
haddock_workaround_ :: ()
daysGreaterThan :: Maybe (Value Integer)
haddock_workaround_ :: ()
daysGreaterThan :: Maybe (Value Integer)
..}