{-# 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.Pinpoint.Types.SegmentResponse
-- 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.Pinpoint.Types.SegmentResponse where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.Pinpoint.Types.SegmentDimensions
import Amazonka.Pinpoint.Types.SegmentGroupList
import Amazonka.Pinpoint.Types.SegmentImportResource
import Amazonka.Pinpoint.Types.SegmentType
import qualified Amazonka.Prelude as Prelude

-- | Provides information about the configuration, dimension, and other
-- settings for a segment.
--
-- /See:/ 'newSegmentResponse' smart constructor.
data SegmentResponse = SegmentResponse'
  { -- | The dimension settings for the segment.
    SegmentResponse -> Maybe SegmentDimensions
dimensions :: Prelude.Maybe SegmentDimensions,
    -- | The settings for the import job that\'s associated with the segment.
    SegmentResponse -> Maybe SegmentImportResource
importDefinition :: Prelude.Maybe SegmentImportResource,
    -- | The date and time when the segment was last modified.
    SegmentResponse -> Maybe Text
lastModifiedDate :: Prelude.Maybe Prelude.Text,
    -- | The name of the segment.
    SegmentResponse -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
    -- | A list of one or more segment groups that apply to the segment. Each
    -- segment group consists of zero or more base segments and the dimensions
    -- that are applied to those base segments.
    SegmentResponse -> Maybe SegmentGroupList
segmentGroups :: Prelude.Maybe SegmentGroupList,
    -- | The version number of the segment.
    SegmentResponse -> Maybe Int
version :: Prelude.Maybe Prelude.Int,
    -- | A string-to-string map of key-value pairs that identifies the tags that
    -- are associated with the segment. Each tag consists of a required tag key
    -- and an associated tag value.
    SegmentResponse -> Maybe (HashMap Text Text)
tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
    -- | The segment type. Valid values are:
    --
    -- -   DIMENSIONAL - A dynamic segment, which is a segment that uses
    --     selection criteria that you specify and is based on endpoint data
    --     that\'s reported by your app. Dynamic segments can change over time.
    --
    -- -   IMPORT - A static segment, which is a segment that uses selection
    --     criteria that you specify and is based on endpoint definitions that
    --     you import from a file. Imported segments are static; they don\'t
    --     change over time.
    SegmentResponse -> SegmentType
segmentType :: SegmentType,
    -- | The date and time when the segment was created.
    SegmentResponse -> Text
creationDate :: Prelude.Text,
    -- | The unique identifier for the segment.
    SegmentResponse -> Text
id :: Prelude.Text,
    -- | The Amazon Resource Name (ARN) of the segment.
    SegmentResponse -> Text
arn :: Prelude.Text,
    -- | The unique identifier for the application that the segment is associated
    -- with.
    SegmentResponse -> Text
applicationId :: Prelude.Text
  }
  deriving (SegmentResponse -> SegmentResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: SegmentResponse -> SegmentResponse -> Bool
$c/= :: SegmentResponse -> SegmentResponse -> Bool
== :: SegmentResponse -> SegmentResponse -> Bool
$c== :: SegmentResponse -> SegmentResponse -> Bool
Prelude.Eq, ReadPrec [SegmentResponse]
ReadPrec SegmentResponse
Int -> ReadS SegmentResponse
ReadS [SegmentResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [SegmentResponse]
$creadListPrec :: ReadPrec [SegmentResponse]
readPrec :: ReadPrec SegmentResponse
$creadPrec :: ReadPrec SegmentResponse
readList :: ReadS [SegmentResponse]
$creadList :: ReadS [SegmentResponse]
readsPrec :: Int -> ReadS SegmentResponse
$creadsPrec :: Int -> ReadS SegmentResponse
Prelude.Read, Int -> SegmentResponse -> ShowS
[SegmentResponse] -> ShowS
SegmentResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [SegmentResponse] -> ShowS
$cshowList :: [SegmentResponse] -> ShowS
show :: SegmentResponse -> String
$cshow :: SegmentResponse -> String
showsPrec :: Int -> SegmentResponse -> ShowS
$cshowsPrec :: Int -> SegmentResponse -> ShowS
Prelude.Show, forall x. Rep SegmentResponse x -> SegmentResponse
forall x. SegmentResponse -> Rep SegmentResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep SegmentResponse x -> SegmentResponse
$cfrom :: forall x. SegmentResponse -> Rep SegmentResponse x
Prelude.Generic)

-- |
-- Create a value of 'SegmentResponse' 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:
--
-- 'dimensions', 'segmentResponse_dimensions' - The dimension settings for the segment.
--
-- 'importDefinition', 'segmentResponse_importDefinition' - The settings for the import job that\'s associated with the segment.
--
-- 'lastModifiedDate', 'segmentResponse_lastModifiedDate' - The date and time when the segment was last modified.
--
-- 'name', 'segmentResponse_name' - The name of the segment.
--
-- 'segmentGroups', 'segmentResponse_segmentGroups' - A list of one or more segment groups that apply to the segment. Each
-- segment group consists of zero or more base segments and the dimensions
-- that are applied to those base segments.
--
-- 'version', 'segmentResponse_version' - The version number of the segment.
--
-- 'tags', 'segmentResponse_tags' - A string-to-string map of key-value pairs that identifies the tags that
-- are associated with the segment. Each tag consists of a required tag key
-- and an associated tag value.
--
-- 'segmentType', 'segmentResponse_segmentType' - The segment type. Valid values are:
--
-- -   DIMENSIONAL - A dynamic segment, which is a segment that uses
--     selection criteria that you specify and is based on endpoint data
--     that\'s reported by your app. Dynamic segments can change over time.
--
-- -   IMPORT - A static segment, which is a segment that uses selection
--     criteria that you specify and is based on endpoint definitions that
--     you import from a file. Imported segments are static; they don\'t
--     change over time.
--
-- 'creationDate', 'segmentResponse_creationDate' - The date and time when the segment was created.
--
-- 'id', 'segmentResponse_id' - The unique identifier for the segment.
--
-- 'arn', 'segmentResponse_arn' - The Amazon Resource Name (ARN) of the segment.
--
-- 'applicationId', 'segmentResponse_applicationId' - The unique identifier for the application that the segment is associated
-- with.
newSegmentResponse ::
  -- | 'segmentType'
  SegmentType ->
  -- | 'creationDate'
  Prelude.Text ->
  -- | 'id'
  Prelude.Text ->
  -- | 'arn'
  Prelude.Text ->
  -- | 'applicationId'
  Prelude.Text ->
  SegmentResponse
newSegmentResponse :: SegmentType -> Text -> Text -> Text -> Text -> SegmentResponse
newSegmentResponse
  SegmentType
pSegmentType_
  Text
pCreationDate_
  Text
pId_
  Text
pArn_
  Text
pApplicationId_ =
    SegmentResponse'
      { $sel:dimensions:SegmentResponse' :: Maybe SegmentDimensions
dimensions = forall a. Maybe a
Prelude.Nothing,
        $sel:importDefinition:SegmentResponse' :: Maybe SegmentImportResource
importDefinition = forall a. Maybe a
Prelude.Nothing,
        $sel:lastModifiedDate:SegmentResponse' :: Maybe Text
lastModifiedDate = forall a. Maybe a
Prelude.Nothing,
        $sel:name:SegmentResponse' :: Maybe Text
name = forall a. Maybe a
Prelude.Nothing,
        $sel:segmentGroups:SegmentResponse' :: Maybe SegmentGroupList
segmentGroups = forall a. Maybe a
Prelude.Nothing,
        $sel:version:SegmentResponse' :: Maybe Int
version = forall a. Maybe a
Prelude.Nothing,
        $sel:tags:SegmentResponse' :: Maybe (HashMap Text Text)
tags = forall a. Maybe a
Prelude.Nothing,
        $sel:segmentType:SegmentResponse' :: SegmentType
segmentType = SegmentType
pSegmentType_,
        $sel:creationDate:SegmentResponse' :: Text
creationDate = Text
pCreationDate_,
        $sel:id:SegmentResponse' :: Text
id = Text
pId_,
        $sel:arn:SegmentResponse' :: Text
arn = Text
pArn_,
        $sel:applicationId:SegmentResponse' :: Text
applicationId = Text
pApplicationId_
      }

-- | The dimension settings for the segment.
segmentResponse_dimensions :: Lens.Lens' SegmentResponse (Prelude.Maybe SegmentDimensions)
segmentResponse_dimensions :: Lens' SegmentResponse (Maybe SegmentDimensions)
segmentResponse_dimensions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SegmentResponse' {Maybe SegmentDimensions
dimensions :: Maybe SegmentDimensions
$sel:dimensions:SegmentResponse' :: SegmentResponse -> Maybe SegmentDimensions
dimensions} -> Maybe SegmentDimensions
dimensions) (\s :: SegmentResponse
s@SegmentResponse' {} Maybe SegmentDimensions
a -> SegmentResponse
s {$sel:dimensions:SegmentResponse' :: Maybe SegmentDimensions
dimensions = Maybe SegmentDimensions
a} :: SegmentResponse)

-- | The settings for the import job that\'s associated with the segment.
segmentResponse_importDefinition :: Lens.Lens' SegmentResponse (Prelude.Maybe SegmentImportResource)
segmentResponse_importDefinition :: Lens' SegmentResponse (Maybe SegmentImportResource)
segmentResponse_importDefinition = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SegmentResponse' {Maybe SegmentImportResource
importDefinition :: Maybe SegmentImportResource
$sel:importDefinition:SegmentResponse' :: SegmentResponse -> Maybe SegmentImportResource
importDefinition} -> Maybe SegmentImportResource
importDefinition) (\s :: SegmentResponse
s@SegmentResponse' {} Maybe SegmentImportResource
a -> SegmentResponse
s {$sel:importDefinition:SegmentResponse' :: Maybe SegmentImportResource
importDefinition = Maybe SegmentImportResource
a} :: SegmentResponse)

-- | The date and time when the segment was last modified.
segmentResponse_lastModifiedDate :: Lens.Lens' SegmentResponse (Prelude.Maybe Prelude.Text)
segmentResponse_lastModifiedDate :: Lens' SegmentResponse (Maybe Text)
segmentResponse_lastModifiedDate = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SegmentResponse' {Maybe Text
lastModifiedDate :: Maybe Text
$sel:lastModifiedDate:SegmentResponse' :: SegmentResponse -> Maybe Text
lastModifiedDate} -> Maybe Text
lastModifiedDate) (\s :: SegmentResponse
s@SegmentResponse' {} Maybe Text
a -> SegmentResponse
s {$sel:lastModifiedDate:SegmentResponse' :: Maybe Text
lastModifiedDate = Maybe Text
a} :: SegmentResponse)

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

-- | A list of one or more segment groups that apply to the segment. Each
-- segment group consists of zero or more base segments and the dimensions
-- that are applied to those base segments.
segmentResponse_segmentGroups :: Lens.Lens' SegmentResponse (Prelude.Maybe SegmentGroupList)
segmentResponse_segmentGroups :: Lens' SegmentResponse (Maybe SegmentGroupList)
segmentResponse_segmentGroups = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SegmentResponse' {Maybe SegmentGroupList
segmentGroups :: Maybe SegmentGroupList
$sel:segmentGroups:SegmentResponse' :: SegmentResponse -> Maybe SegmentGroupList
segmentGroups} -> Maybe SegmentGroupList
segmentGroups) (\s :: SegmentResponse
s@SegmentResponse' {} Maybe SegmentGroupList
a -> SegmentResponse
s {$sel:segmentGroups:SegmentResponse' :: Maybe SegmentGroupList
segmentGroups = Maybe SegmentGroupList
a} :: SegmentResponse)

-- | The version number of the segment.
segmentResponse_version :: Lens.Lens' SegmentResponse (Prelude.Maybe Prelude.Int)
segmentResponse_version :: Lens' SegmentResponse (Maybe Int)
segmentResponse_version = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SegmentResponse' {Maybe Int
version :: Maybe Int
$sel:version:SegmentResponse' :: SegmentResponse -> Maybe Int
version} -> Maybe Int
version) (\s :: SegmentResponse
s@SegmentResponse' {} Maybe Int
a -> SegmentResponse
s {$sel:version:SegmentResponse' :: Maybe Int
version = Maybe Int
a} :: SegmentResponse)

-- | A string-to-string map of key-value pairs that identifies the tags that
-- are associated with the segment. Each tag consists of a required tag key
-- and an associated tag value.
segmentResponse_tags :: Lens.Lens' SegmentResponse (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
segmentResponse_tags :: Lens' SegmentResponse (Maybe (HashMap Text Text))
segmentResponse_tags = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SegmentResponse' {Maybe (HashMap Text Text)
tags :: Maybe (HashMap Text Text)
$sel:tags:SegmentResponse' :: SegmentResponse -> Maybe (HashMap Text Text)
tags} -> Maybe (HashMap Text Text)
tags) (\s :: SegmentResponse
s@SegmentResponse' {} Maybe (HashMap Text Text)
a -> SegmentResponse
s {$sel:tags:SegmentResponse' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
a} :: SegmentResponse) 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

-- | The segment type. Valid values are:
--
-- -   DIMENSIONAL - A dynamic segment, which is a segment that uses
--     selection criteria that you specify and is based on endpoint data
--     that\'s reported by your app. Dynamic segments can change over time.
--
-- -   IMPORT - A static segment, which is a segment that uses selection
--     criteria that you specify and is based on endpoint definitions that
--     you import from a file. Imported segments are static; they don\'t
--     change over time.
segmentResponse_segmentType :: Lens.Lens' SegmentResponse SegmentType
segmentResponse_segmentType :: Lens' SegmentResponse SegmentType
segmentResponse_segmentType = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SegmentResponse' {SegmentType
segmentType :: SegmentType
$sel:segmentType:SegmentResponse' :: SegmentResponse -> SegmentType
segmentType} -> SegmentType
segmentType) (\s :: SegmentResponse
s@SegmentResponse' {} SegmentType
a -> SegmentResponse
s {$sel:segmentType:SegmentResponse' :: SegmentType
segmentType = SegmentType
a} :: SegmentResponse)

-- | The date and time when the segment was created.
segmentResponse_creationDate :: Lens.Lens' SegmentResponse Prelude.Text
segmentResponse_creationDate :: Lens' SegmentResponse Text
segmentResponse_creationDate = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SegmentResponse' {Text
creationDate :: Text
$sel:creationDate:SegmentResponse' :: SegmentResponse -> Text
creationDate} -> Text
creationDate) (\s :: SegmentResponse
s@SegmentResponse' {} Text
a -> SegmentResponse
s {$sel:creationDate:SegmentResponse' :: Text
creationDate = Text
a} :: SegmentResponse)

-- | The unique identifier for the segment.
segmentResponse_id :: Lens.Lens' SegmentResponse Prelude.Text
segmentResponse_id :: Lens' SegmentResponse Text
segmentResponse_id = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SegmentResponse' {Text
id :: Text
$sel:id:SegmentResponse' :: SegmentResponse -> Text
id} -> Text
id) (\s :: SegmentResponse
s@SegmentResponse' {} Text
a -> SegmentResponse
s {$sel:id:SegmentResponse' :: Text
id = Text
a} :: SegmentResponse)

-- | The Amazon Resource Name (ARN) of the segment.
segmentResponse_arn :: Lens.Lens' SegmentResponse Prelude.Text
segmentResponse_arn :: Lens' SegmentResponse Text
segmentResponse_arn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SegmentResponse' {Text
arn :: Text
$sel:arn:SegmentResponse' :: SegmentResponse -> Text
arn} -> Text
arn) (\s :: SegmentResponse
s@SegmentResponse' {} Text
a -> SegmentResponse
s {$sel:arn:SegmentResponse' :: Text
arn = Text
a} :: SegmentResponse)

-- | The unique identifier for the application that the segment is associated
-- with.
segmentResponse_applicationId :: Lens.Lens' SegmentResponse Prelude.Text
segmentResponse_applicationId :: Lens' SegmentResponse Text
segmentResponse_applicationId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SegmentResponse' {Text
applicationId :: Text
$sel:applicationId:SegmentResponse' :: SegmentResponse -> Text
applicationId} -> Text
applicationId) (\s :: SegmentResponse
s@SegmentResponse' {} Text
a -> SegmentResponse
s {$sel:applicationId:SegmentResponse' :: Text
applicationId = Text
a} :: SegmentResponse)

instance Data.FromJSON SegmentResponse where
  parseJSON :: Value -> Parser SegmentResponse
parseJSON =
    forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
      String
"SegmentResponse"
      ( \Object
x ->
          Maybe SegmentDimensions
-> Maybe SegmentImportResource
-> Maybe Text
-> Maybe Text
-> Maybe SegmentGroupList
-> Maybe Int
-> Maybe (HashMap Text Text)
-> SegmentType
-> Text
-> Text
-> Text
-> Text
-> SegmentResponse
SegmentResponse'
            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
"Dimensions")
            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
"ImportDefinition")
            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
"LastModifiedDate")
            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
"SegmentGroups")
            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
"Version")
            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
"tags" 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 a
Data..: Key
"SegmentType")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"CreationDate")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"Id")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser 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 a
Data..: Key
"ApplicationId")
      )

instance Prelude.Hashable SegmentResponse where
  hashWithSalt :: Int -> SegmentResponse -> Int
hashWithSalt Int
_salt SegmentResponse' {Maybe Int
Maybe Text
Maybe (HashMap Text Text)
Maybe SegmentImportResource
Maybe SegmentDimensions
Maybe SegmentGroupList
Text
SegmentType
applicationId :: Text
arn :: Text
id :: Text
creationDate :: Text
segmentType :: SegmentType
tags :: Maybe (HashMap Text Text)
version :: Maybe Int
segmentGroups :: Maybe SegmentGroupList
name :: Maybe Text
lastModifiedDate :: Maybe Text
importDefinition :: Maybe SegmentImportResource
dimensions :: Maybe SegmentDimensions
$sel:applicationId:SegmentResponse' :: SegmentResponse -> Text
$sel:arn:SegmentResponse' :: SegmentResponse -> Text
$sel:id:SegmentResponse' :: SegmentResponse -> Text
$sel:creationDate:SegmentResponse' :: SegmentResponse -> Text
$sel:segmentType:SegmentResponse' :: SegmentResponse -> SegmentType
$sel:tags:SegmentResponse' :: SegmentResponse -> Maybe (HashMap Text Text)
$sel:version:SegmentResponse' :: SegmentResponse -> Maybe Int
$sel:segmentGroups:SegmentResponse' :: SegmentResponse -> Maybe SegmentGroupList
$sel:name:SegmentResponse' :: SegmentResponse -> Maybe Text
$sel:lastModifiedDate:SegmentResponse' :: SegmentResponse -> Maybe Text
$sel:importDefinition:SegmentResponse' :: SegmentResponse -> Maybe SegmentImportResource
$sel:dimensions:SegmentResponse' :: SegmentResponse -> Maybe SegmentDimensions
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe SegmentDimensions
dimensions
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe SegmentImportResource
importDefinition
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
lastModifiedDate
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
name
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe SegmentGroupList
segmentGroups
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Int
version
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (HashMap Text Text)
tags
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` SegmentType
segmentType
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
creationDate
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
id
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
arn
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
applicationId

instance Prelude.NFData SegmentResponse where
  rnf :: SegmentResponse -> ()
rnf SegmentResponse' {Maybe Int
Maybe Text
Maybe (HashMap Text Text)
Maybe SegmentImportResource
Maybe SegmentDimensions
Maybe SegmentGroupList
Text
SegmentType
applicationId :: Text
arn :: Text
id :: Text
creationDate :: Text
segmentType :: SegmentType
tags :: Maybe (HashMap Text Text)
version :: Maybe Int
segmentGroups :: Maybe SegmentGroupList
name :: Maybe Text
lastModifiedDate :: Maybe Text
importDefinition :: Maybe SegmentImportResource
dimensions :: Maybe SegmentDimensions
$sel:applicationId:SegmentResponse' :: SegmentResponse -> Text
$sel:arn:SegmentResponse' :: SegmentResponse -> Text
$sel:id:SegmentResponse' :: SegmentResponse -> Text
$sel:creationDate:SegmentResponse' :: SegmentResponse -> Text
$sel:segmentType:SegmentResponse' :: SegmentResponse -> SegmentType
$sel:tags:SegmentResponse' :: SegmentResponse -> Maybe (HashMap Text Text)
$sel:version:SegmentResponse' :: SegmentResponse -> Maybe Int
$sel:segmentGroups:SegmentResponse' :: SegmentResponse -> Maybe SegmentGroupList
$sel:name:SegmentResponse' :: SegmentResponse -> Maybe Text
$sel:lastModifiedDate:SegmentResponse' :: SegmentResponse -> Maybe Text
$sel:importDefinition:SegmentResponse' :: SegmentResponse -> Maybe SegmentImportResource
$sel:dimensions:SegmentResponse' :: SegmentResponse -> Maybe SegmentDimensions
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe SegmentDimensions
dimensions
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe SegmentImportResource
importDefinition
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
lastModifiedDate
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
name
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe SegmentGroupList
segmentGroups
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Int
version
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (HashMap Text Text)
tags
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf SegmentType
segmentType
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
creationDate
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
id
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
arn
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
applicationId