{-# 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.MediaConvert.Types.MsSmoothGroupSettings
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.MediaConvert.Types.MsSmoothGroupSettings where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.MediaConvert.Types.DestinationSettings
import Amazonka.MediaConvert.Types.MsSmoothAdditionalManifest
import Amazonka.MediaConvert.Types.MsSmoothAudioDeduplication
import Amazonka.MediaConvert.Types.MsSmoothEncryptionSettings
import Amazonka.MediaConvert.Types.MsSmoothFragmentLengthControl
import Amazonka.MediaConvert.Types.MsSmoothManifestEncoding
import qualified Amazonka.Prelude as Prelude

-- | Settings related to your Microsoft Smooth Streaming output package. For
-- more information, see
-- https:\/\/docs.aws.amazon.com\/mediaconvert\/latest\/ug\/outputs-file-ABR.html.
-- When you work directly in your JSON job specification, include this
-- object and any required children when you set Type, under
-- OutputGroupSettings, to MS_SMOOTH_GROUP_SETTINGS.
--
-- /See:/ 'newMsSmoothGroupSettings' smart constructor.
data MsSmoothGroupSettings = MsSmoothGroupSettings'
  { -- | By default, the service creates one .ism Microsoft Smooth Streaming
    -- manifest for each Microsoft Smooth Streaming output group in your job.
    -- This default manifest references every output in the output group. To
    -- create additional manifests that reference a subset of the outputs in
    -- the output group, specify a list of them here.
    MsSmoothGroupSettings -> Maybe [MsSmoothAdditionalManifest]
additionalManifests :: Prelude.Maybe [MsSmoothAdditionalManifest],
    -- | COMBINE_DUPLICATE_STREAMS combines identical audio encoding settings
    -- across a Microsoft Smooth output group into a single audio stream.
    MsSmoothGroupSettings -> Maybe MsSmoothAudioDeduplication
audioDeduplication :: Prelude.Maybe MsSmoothAudioDeduplication,
    -- | Use Destination (Destination) to specify the S3 output location and the
    -- output filename base. Destination accepts format identifiers. If you do
    -- not specify the base filename in the URI, the service will use the
    -- filename of the input file. If your job has multiple inputs, the service
    -- uses the filename of the first input file.
    MsSmoothGroupSettings -> Maybe Text
destination :: Prelude.Maybe Prelude.Text,
    -- | Settings associated with the destination. Will vary based on the type of
    -- destination
    MsSmoothGroupSettings -> Maybe DestinationSettings
destinationSettings :: Prelude.Maybe DestinationSettings,
    -- | If you are using DRM, set DRM System (MsSmoothEncryptionSettings) to
    -- specify the value SpekeKeyProvider.
    MsSmoothGroupSettings -> Maybe MsSmoothEncryptionSettings
encryption :: Prelude.Maybe MsSmoothEncryptionSettings,
    -- | Specify how you want MediaConvert to determine the fragment length.
    -- Choose Exact (EXACT) to have the encoder use the exact length that you
    -- specify with the setting Fragment length (FragmentLength). This might
    -- result in extra I-frames. Choose Multiple of GOP (GOP_MULTIPLE) to have
    -- the encoder round up the segment lengths to match the next GOP boundary.
    MsSmoothGroupSettings -> Maybe Natural
fragmentLength :: Prelude.Maybe Prelude.Natural,
    -- | Specify how you want MediaConvert to determine the fragment length.
    -- Choose Exact (EXACT) to have the encoder use the exact length that you
    -- specify with the setting Fragment length (FragmentLength). This might
    -- result in extra I-frames. Choose Multiple of GOP (GOP_MULTIPLE) to have
    -- the encoder round up the segment lengths to match the next GOP boundary.
    MsSmoothGroupSettings -> Maybe MsSmoothFragmentLengthControl
fragmentLengthControl :: Prelude.Maybe MsSmoothFragmentLengthControl,
    -- | Use Manifest encoding (MsSmoothManifestEncoding) to specify the encoding
    -- format for the server and client manifest. Valid options are utf8 and
    -- utf16.
    MsSmoothGroupSettings -> Maybe MsSmoothManifestEncoding
manifestEncoding :: Prelude.Maybe MsSmoothManifestEncoding
  }
  deriving (MsSmoothGroupSettings -> MsSmoothGroupSettings -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: MsSmoothGroupSettings -> MsSmoothGroupSettings -> Bool
$c/= :: MsSmoothGroupSettings -> MsSmoothGroupSettings -> Bool
== :: MsSmoothGroupSettings -> MsSmoothGroupSettings -> Bool
$c== :: MsSmoothGroupSettings -> MsSmoothGroupSettings -> Bool
Prelude.Eq, ReadPrec [MsSmoothGroupSettings]
ReadPrec MsSmoothGroupSettings
Int -> ReadS MsSmoothGroupSettings
ReadS [MsSmoothGroupSettings]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [MsSmoothGroupSettings]
$creadListPrec :: ReadPrec [MsSmoothGroupSettings]
readPrec :: ReadPrec MsSmoothGroupSettings
$creadPrec :: ReadPrec MsSmoothGroupSettings
readList :: ReadS [MsSmoothGroupSettings]
$creadList :: ReadS [MsSmoothGroupSettings]
readsPrec :: Int -> ReadS MsSmoothGroupSettings
$creadsPrec :: Int -> ReadS MsSmoothGroupSettings
Prelude.Read, Int -> MsSmoothGroupSettings -> ShowS
[MsSmoothGroupSettings] -> ShowS
MsSmoothGroupSettings -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [MsSmoothGroupSettings] -> ShowS
$cshowList :: [MsSmoothGroupSettings] -> ShowS
show :: MsSmoothGroupSettings -> String
$cshow :: MsSmoothGroupSettings -> String
showsPrec :: Int -> MsSmoothGroupSettings -> ShowS
$cshowsPrec :: Int -> MsSmoothGroupSettings -> ShowS
Prelude.Show, forall x. Rep MsSmoothGroupSettings x -> MsSmoothGroupSettings
forall x. MsSmoothGroupSettings -> Rep MsSmoothGroupSettings x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep MsSmoothGroupSettings x -> MsSmoothGroupSettings
$cfrom :: forall x. MsSmoothGroupSettings -> Rep MsSmoothGroupSettings x
Prelude.Generic)

-- |
-- Create a value of 'MsSmoothGroupSettings' 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:
--
-- 'additionalManifests', 'msSmoothGroupSettings_additionalManifests' - By default, the service creates one .ism Microsoft Smooth Streaming
-- manifest for each Microsoft Smooth Streaming output group in your job.
-- This default manifest references every output in the output group. To
-- create additional manifests that reference a subset of the outputs in
-- the output group, specify a list of them here.
--
-- 'audioDeduplication', 'msSmoothGroupSettings_audioDeduplication' - COMBINE_DUPLICATE_STREAMS combines identical audio encoding settings
-- across a Microsoft Smooth output group into a single audio stream.
--
-- 'destination', 'msSmoothGroupSettings_destination' - Use Destination (Destination) to specify the S3 output location and the
-- output filename base. Destination accepts format identifiers. If you do
-- not specify the base filename in the URI, the service will use the
-- filename of the input file. If your job has multiple inputs, the service
-- uses the filename of the first input file.
--
-- 'destinationSettings', 'msSmoothGroupSettings_destinationSettings' - Settings associated with the destination. Will vary based on the type of
-- destination
--
-- 'encryption', 'msSmoothGroupSettings_encryption' - If you are using DRM, set DRM System (MsSmoothEncryptionSettings) to
-- specify the value SpekeKeyProvider.
--
-- 'fragmentLength', 'msSmoothGroupSettings_fragmentLength' - Specify how you want MediaConvert to determine the fragment length.
-- Choose Exact (EXACT) to have the encoder use the exact length that you
-- specify with the setting Fragment length (FragmentLength). This might
-- result in extra I-frames. Choose Multiple of GOP (GOP_MULTIPLE) to have
-- the encoder round up the segment lengths to match the next GOP boundary.
--
-- 'fragmentLengthControl', 'msSmoothGroupSettings_fragmentLengthControl' - Specify how you want MediaConvert to determine the fragment length.
-- Choose Exact (EXACT) to have the encoder use the exact length that you
-- specify with the setting Fragment length (FragmentLength). This might
-- result in extra I-frames. Choose Multiple of GOP (GOP_MULTIPLE) to have
-- the encoder round up the segment lengths to match the next GOP boundary.
--
-- 'manifestEncoding', 'msSmoothGroupSettings_manifestEncoding' - Use Manifest encoding (MsSmoothManifestEncoding) to specify the encoding
-- format for the server and client manifest. Valid options are utf8 and
-- utf16.
newMsSmoothGroupSettings ::
  MsSmoothGroupSettings
newMsSmoothGroupSettings :: MsSmoothGroupSettings
newMsSmoothGroupSettings =
  MsSmoothGroupSettings'
    { $sel:additionalManifests:MsSmoothGroupSettings' :: Maybe [MsSmoothAdditionalManifest]
additionalManifests =
        forall a. Maybe a
Prelude.Nothing,
      $sel:audioDeduplication:MsSmoothGroupSettings' :: Maybe MsSmoothAudioDeduplication
audioDeduplication = forall a. Maybe a
Prelude.Nothing,
      $sel:destination:MsSmoothGroupSettings' :: Maybe Text
destination = forall a. Maybe a
Prelude.Nothing,
      $sel:destinationSettings:MsSmoothGroupSettings' :: Maybe DestinationSettings
destinationSettings = forall a. Maybe a
Prelude.Nothing,
      $sel:encryption:MsSmoothGroupSettings' :: Maybe MsSmoothEncryptionSettings
encryption = forall a. Maybe a
Prelude.Nothing,
      $sel:fragmentLength:MsSmoothGroupSettings' :: Maybe Natural
fragmentLength = forall a. Maybe a
Prelude.Nothing,
      $sel:fragmentLengthControl:MsSmoothGroupSettings' :: Maybe MsSmoothFragmentLengthControl
fragmentLengthControl = forall a. Maybe a
Prelude.Nothing,
      $sel:manifestEncoding:MsSmoothGroupSettings' :: Maybe MsSmoothManifestEncoding
manifestEncoding = forall a. Maybe a
Prelude.Nothing
    }

-- | By default, the service creates one .ism Microsoft Smooth Streaming
-- manifest for each Microsoft Smooth Streaming output group in your job.
-- This default manifest references every output in the output group. To
-- create additional manifests that reference a subset of the outputs in
-- the output group, specify a list of them here.
msSmoothGroupSettings_additionalManifests :: Lens.Lens' MsSmoothGroupSettings (Prelude.Maybe [MsSmoothAdditionalManifest])
msSmoothGroupSettings_additionalManifests :: Lens' MsSmoothGroupSettings (Maybe [MsSmoothAdditionalManifest])
msSmoothGroupSettings_additionalManifests = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MsSmoothGroupSettings' {Maybe [MsSmoothAdditionalManifest]
additionalManifests :: Maybe [MsSmoothAdditionalManifest]
$sel:additionalManifests:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe [MsSmoothAdditionalManifest]
additionalManifests} -> Maybe [MsSmoothAdditionalManifest]
additionalManifests) (\s :: MsSmoothGroupSettings
s@MsSmoothGroupSettings' {} Maybe [MsSmoothAdditionalManifest]
a -> MsSmoothGroupSettings
s {$sel:additionalManifests:MsSmoothGroupSettings' :: Maybe [MsSmoothAdditionalManifest]
additionalManifests = Maybe [MsSmoothAdditionalManifest]
a} :: MsSmoothGroupSettings) 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 s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | COMBINE_DUPLICATE_STREAMS combines identical audio encoding settings
-- across a Microsoft Smooth output group into a single audio stream.
msSmoothGroupSettings_audioDeduplication :: Lens.Lens' MsSmoothGroupSettings (Prelude.Maybe MsSmoothAudioDeduplication)
msSmoothGroupSettings_audioDeduplication :: Lens' MsSmoothGroupSettings (Maybe MsSmoothAudioDeduplication)
msSmoothGroupSettings_audioDeduplication = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MsSmoothGroupSettings' {Maybe MsSmoothAudioDeduplication
audioDeduplication :: Maybe MsSmoothAudioDeduplication
$sel:audioDeduplication:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothAudioDeduplication
audioDeduplication} -> Maybe MsSmoothAudioDeduplication
audioDeduplication) (\s :: MsSmoothGroupSettings
s@MsSmoothGroupSettings' {} Maybe MsSmoothAudioDeduplication
a -> MsSmoothGroupSettings
s {$sel:audioDeduplication:MsSmoothGroupSettings' :: Maybe MsSmoothAudioDeduplication
audioDeduplication = Maybe MsSmoothAudioDeduplication
a} :: MsSmoothGroupSettings)

-- | Use Destination (Destination) to specify the S3 output location and the
-- output filename base. Destination accepts format identifiers. If you do
-- not specify the base filename in the URI, the service will use the
-- filename of the input file. If your job has multiple inputs, the service
-- uses the filename of the first input file.
msSmoothGroupSettings_destination :: Lens.Lens' MsSmoothGroupSettings (Prelude.Maybe Prelude.Text)
msSmoothGroupSettings_destination :: Lens' MsSmoothGroupSettings (Maybe Text)
msSmoothGroupSettings_destination = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MsSmoothGroupSettings' {Maybe Text
destination :: Maybe Text
$sel:destination:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe Text
destination} -> Maybe Text
destination) (\s :: MsSmoothGroupSettings
s@MsSmoothGroupSettings' {} Maybe Text
a -> MsSmoothGroupSettings
s {$sel:destination:MsSmoothGroupSettings' :: Maybe Text
destination = Maybe Text
a} :: MsSmoothGroupSettings)

-- | Settings associated with the destination. Will vary based on the type of
-- destination
msSmoothGroupSettings_destinationSettings :: Lens.Lens' MsSmoothGroupSettings (Prelude.Maybe DestinationSettings)
msSmoothGroupSettings_destinationSettings :: Lens' MsSmoothGroupSettings (Maybe DestinationSettings)
msSmoothGroupSettings_destinationSettings = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MsSmoothGroupSettings' {Maybe DestinationSettings
destinationSettings :: Maybe DestinationSettings
$sel:destinationSettings:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe DestinationSettings
destinationSettings} -> Maybe DestinationSettings
destinationSettings) (\s :: MsSmoothGroupSettings
s@MsSmoothGroupSettings' {} Maybe DestinationSettings
a -> MsSmoothGroupSettings
s {$sel:destinationSettings:MsSmoothGroupSettings' :: Maybe DestinationSettings
destinationSettings = Maybe DestinationSettings
a} :: MsSmoothGroupSettings)

-- | If you are using DRM, set DRM System (MsSmoothEncryptionSettings) to
-- specify the value SpekeKeyProvider.
msSmoothGroupSettings_encryption :: Lens.Lens' MsSmoothGroupSettings (Prelude.Maybe MsSmoothEncryptionSettings)
msSmoothGroupSettings_encryption :: Lens' MsSmoothGroupSettings (Maybe MsSmoothEncryptionSettings)
msSmoothGroupSettings_encryption = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MsSmoothGroupSettings' {Maybe MsSmoothEncryptionSettings
encryption :: Maybe MsSmoothEncryptionSettings
$sel:encryption:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothEncryptionSettings
encryption} -> Maybe MsSmoothEncryptionSettings
encryption) (\s :: MsSmoothGroupSettings
s@MsSmoothGroupSettings' {} Maybe MsSmoothEncryptionSettings
a -> MsSmoothGroupSettings
s {$sel:encryption:MsSmoothGroupSettings' :: Maybe MsSmoothEncryptionSettings
encryption = Maybe MsSmoothEncryptionSettings
a} :: MsSmoothGroupSettings)

-- | Specify how you want MediaConvert to determine the fragment length.
-- Choose Exact (EXACT) to have the encoder use the exact length that you
-- specify with the setting Fragment length (FragmentLength). This might
-- result in extra I-frames. Choose Multiple of GOP (GOP_MULTIPLE) to have
-- the encoder round up the segment lengths to match the next GOP boundary.
msSmoothGroupSettings_fragmentLength :: Lens.Lens' MsSmoothGroupSettings (Prelude.Maybe Prelude.Natural)
msSmoothGroupSettings_fragmentLength :: Lens' MsSmoothGroupSettings (Maybe Natural)
msSmoothGroupSettings_fragmentLength = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MsSmoothGroupSettings' {Maybe Natural
fragmentLength :: Maybe Natural
$sel:fragmentLength:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe Natural
fragmentLength} -> Maybe Natural
fragmentLength) (\s :: MsSmoothGroupSettings
s@MsSmoothGroupSettings' {} Maybe Natural
a -> MsSmoothGroupSettings
s {$sel:fragmentLength:MsSmoothGroupSettings' :: Maybe Natural
fragmentLength = Maybe Natural
a} :: MsSmoothGroupSettings)

-- | Specify how you want MediaConvert to determine the fragment length.
-- Choose Exact (EXACT) to have the encoder use the exact length that you
-- specify with the setting Fragment length (FragmentLength). This might
-- result in extra I-frames. Choose Multiple of GOP (GOP_MULTIPLE) to have
-- the encoder round up the segment lengths to match the next GOP boundary.
msSmoothGroupSettings_fragmentLengthControl :: Lens.Lens' MsSmoothGroupSettings (Prelude.Maybe MsSmoothFragmentLengthControl)
msSmoothGroupSettings_fragmentLengthControl :: Lens' MsSmoothGroupSettings (Maybe MsSmoothFragmentLengthControl)
msSmoothGroupSettings_fragmentLengthControl = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MsSmoothGroupSettings' {Maybe MsSmoothFragmentLengthControl
fragmentLengthControl :: Maybe MsSmoothFragmentLengthControl
$sel:fragmentLengthControl:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothFragmentLengthControl
fragmentLengthControl} -> Maybe MsSmoothFragmentLengthControl
fragmentLengthControl) (\s :: MsSmoothGroupSettings
s@MsSmoothGroupSettings' {} Maybe MsSmoothFragmentLengthControl
a -> MsSmoothGroupSettings
s {$sel:fragmentLengthControl:MsSmoothGroupSettings' :: Maybe MsSmoothFragmentLengthControl
fragmentLengthControl = Maybe MsSmoothFragmentLengthControl
a} :: MsSmoothGroupSettings)

-- | Use Manifest encoding (MsSmoothManifestEncoding) to specify the encoding
-- format for the server and client manifest. Valid options are utf8 and
-- utf16.
msSmoothGroupSettings_manifestEncoding :: Lens.Lens' MsSmoothGroupSettings (Prelude.Maybe MsSmoothManifestEncoding)
msSmoothGroupSettings_manifestEncoding :: Lens' MsSmoothGroupSettings (Maybe MsSmoothManifestEncoding)
msSmoothGroupSettings_manifestEncoding = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MsSmoothGroupSettings' {Maybe MsSmoothManifestEncoding
manifestEncoding :: Maybe MsSmoothManifestEncoding
$sel:manifestEncoding:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothManifestEncoding
manifestEncoding} -> Maybe MsSmoothManifestEncoding
manifestEncoding) (\s :: MsSmoothGroupSettings
s@MsSmoothGroupSettings' {} Maybe MsSmoothManifestEncoding
a -> MsSmoothGroupSettings
s {$sel:manifestEncoding:MsSmoothGroupSettings' :: Maybe MsSmoothManifestEncoding
manifestEncoding = Maybe MsSmoothManifestEncoding
a} :: MsSmoothGroupSettings)

instance Data.FromJSON MsSmoothGroupSettings where
  parseJSON :: Value -> Parser MsSmoothGroupSettings
parseJSON =
    forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
      String
"MsSmoothGroupSettings"
      ( \Object
x ->
          Maybe [MsSmoothAdditionalManifest]
-> Maybe MsSmoothAudioDeduplication
-> Maybe Text
-> Maybe DestinationSettings
-> Maybe MsSmoothEncryptionSettings
-> Maybe Natural
-> Maybe MsSmoothFragmentLengthControl
-> Maybe MsSmoothManifestEncoding
-> MsSmoothGroupSettings
MsSmoothGroupSettings'
            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
"additionalManifests"
                            forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty
                        )
            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
"audioDeduplication")
            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
"destination")
            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
"destinationSettings")
            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
"encryption")
            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
"fragmentLength")
            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
"fragmentLengthControl")
            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
"manifestEncoding")
      )

instance Prelude.Hashable MsSmoothGroupSettings where
  hashWithSalt :: Int -> MsSmoothGroupSettings -> Int
hashWithSalt Int
_salt MsSmoothGroupSettings' {Maybe Natural
Maybe [MsSmoothAdditionalManifest]
Maybe Text
Maybe MsSmoothAudioDeduplication
Maybe MsSmoothFragmentLengthControl
Maybe MsSmoothManifestEncoding
Maybe DestinationSettings
Maybe MsSmoothEncryptionSettings
manifestEncoding :: Maybe MsSmoothManifestEncoding
fragmentLengthControl :: Maybe MsSmoothFragmentLengthControl
fragmentLength :: Maybe Natural
encryption :: Maybe MsSmoothEncryptionSettings
destinationSettings :: Maybe DestinationSettings
destination :: Maybe Text
audioDeduplication :: Maybe MsSmoothAudioDeduplication
additionalManifests :: Maybe [MsSmoothAdditionalManifest]
$sel:manifestEncoding:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothManifestEncoding
$sel:fragmentLengthControl:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothFragmentLengthControl
$sel:fragmentLength:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe Natural
$sel:encryption:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothEncryptionSettings
$sel:destinationSettings:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe DestinationSettings
$sel:destination:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe Text
$sel:audioDeduplication:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothAudioDeduplication
$sel:additionalManifests:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe [MsSmoothAdditionalManifest]
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [MsSmoothAdditionalManifest]
additionalManifests
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe MsSmoothAudioDeduplication
audioDeduplication
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
destination
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe DestinationSettings
destinationSettings
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe MsSmoothEncryptionSettings
encryption
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
fragmentLength
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe MsSmoothFragmentLengthControl
fragmentLengthControl
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe MsSmoothManifestEncoding
manifestEncoding

instance Prelude.NFData MsSmoothGroupSettings where
  rnf :: MsSmoothGroupSettings -> ()
rnf MsSmoothGroupSettings' {Maybe Natural
Maybe [MsSmoothAdditionalManifest]
Maybe Text
Maybe MsSmoothAudioDeduplication
Maybe MsSmoothFragmentLengthControl
Maybe MsSmoothManifestEncoding
Maybe DestinationSettings
Maybe MsSmoothEncryptionSettings
manifestEncoding :: Maybe MsSmoothManifestEncoding
fragmentLengthControl :: Maybe MsSmoothFragmentLengthControl
fragmentLength :: Maybe Natural
encryption :: Maybe MsSmoothEncryptionSettings
destinationSettings :: Maybe DestinationSettings
destination :: Maybe Text
audioDeduplication :: Maybe MsSmoothAudioDeduplication
additionalManifests :: Maybe [MsSmoothAdditionalManifest]
$sel:manifestEncoding:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothManifestEncoding
$sel:fragmentLengthControl:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothFragmentLengthControl
$sel:fragmentLength:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe Natural
$sel:encryption:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothEncryptionSettings
$sel:destinationSettings:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe DestinationSettings
$sel:destination:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe Text
$sel:audioDeduplication:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothAudioDeduplication
$sel:additionalManifests:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe [MsSmoothAdditionalManifest]
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe [MsSmoothAdditionalManifest]
additionalManifests
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe MsSmoothAudioDeduplication
audioDeduplication
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
destination
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe DestinationSettings
destinationSettings
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe MsSmoothEncryptionSettings
encryption
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
fragmentLength
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe MsSmoothFragmentLengthControl
fragmentLengthControl
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe MsSmoothManifestEncoding
manifestEncoding

instance Data.ToJSON MsSmoothGroupSettings where
  toJSON :: MsSmoothGroupSettings -> Value
toJSON MsSmoothGroupSettings' {Maybe Natural
Maybe [MsSmoothAdditionalManifest]
Maybe Text
Maybe MsSmoothAudioDeduplication
Maybe MsSmoothFragmentLengthControl
Maybe MsSmoothManifestEncoding
Maybe DestinationSettings
Maybe MsSmoothEncryptionSettings
manifestEncoding :: Maybe MsSmoothManifestEncoding
fragmentLengthControl :: Maybe MsSmoothFragmentLengthControl
fragmentLength :: Maybe Natural
encryption :: Maybe MsSmoothEncryptionSettings
destinationSettings :: Maybe DestinationSettings
destination :: Maybe Text
audioDeduplication :: Maybe MsSmoothAudioDeduplication
additionalManifests :: Maybe [MsSmoothAdditionalManifest]
$sel:manifestEncoding:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothManifestEncoding
$sel:fragmentLengthControl:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothFragmentLengthControl
$sel:fragmentLength:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe Natural
$sel:encryption:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothEncryptionSettings
$sel:destinationSettings:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe DestinationSettings
$sel:destination:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe Text
$sel:audioDeduplication:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe MsSmoothAudioDeduplication
$sel:additionalManifests:MsSmoothGroupSettings' :: MsSmoothGroupSettings -> Maybe [MsSmoothAdditionalManifest]
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Key
"additionalManifests" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [MsSmoothAdditionalManifest]
additionalManifests,
            (Key
"audioDeduplication" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe MsSmoothAudioDeduplication
audioDeduplication,
            (Key
"destination" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
destination,
            (Key
"destinationSettings" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe DestinationSettings
destinationSettings,
            (Key
"encryption" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe MsSmoothEncryptionSettings
encryption,
            (Key
"fragmentLength" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Natural
fragmentLength,
            (Key
"fragmentLengthControl" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe MsSmoothFragmentLengthControl
fragmentLengthControl,
            (Key
"manifestEncoding" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe MsSmoothManifestEncoding
manifestEncoding
          ]
      )