{-# 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.Location.Types.MapConfiguration
-- 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.Location.Types.MapConfiguration 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

-- | Specifies the map tile style selected from an available provider.
--
-- /See:/ 'newMapConfiguration' smart constructor.
data MapConfiguration = MapConfiguration'
  { -- | Specifies the map style selected from an available data provider.
    --
    -- Valid
    -- <https://docs.aws.amazon.com/location/latest/developerguide/esri.html Esri map styles>:
    --
    -- -   @VectorEsriDarkGrayCanvas@ – The Esri Dark Gray Canvas map style. A
    --     vector basemap with a dark gray, neutral background with minimal
    --     colors, labels, and features that\'s designed to draw attention to
    --     your thematic content.
    --
    -- -   @RasterEsriImagery@ – The Esri Imagery map style. A raster basemap
    --     that provides one meter or better satellite and aerial imagery in
    --     many parts of the world and lower resolution satellite imagery
    --     worldwide.
    --
    -- -   @VectorEsriLightGrayCanvas@ – The Esri Light Gray Canvas map style,
    --     which provides a detailed vector basemap with a light gray, neutral
    --     background style with minimal colors, labels, and features that\'s
    --     designed to draw attention to your thematic content.
    --
    -- -   @VectorEsriTopographic@ – The Esri Light map style, which provides a
    --     detailed vector basemap with a classic Esri map style.
    --
    -- -   @VectorEsriStreets@ – The Esri World Streets map style, which
    --     provides a detailed vector basemap for the world symbolized with a
    --     classic Esri street map style. The vector tile layer is similar in
    --     content and style to the World Street Map raster map.
    --
    -- -   @VectorEsriNavigation@ – The Esri World Navigation map style, which
    --     provides a detailed basemap for the world symbolized with a custom
    --     navigation map style that\'s designed for use during the day in
    --     mobile devices.
    --
    -- Valid
    -- <https://docs.aws.amazon.com/location/latest/developerguide/HERE.html HERE Technologies map styles>:
    --
    -- -   @VectorHereContrast@ – The HERE Contrast (Berlin) map style is a
    --     high contrast detailed base map of the world that blends 3D and 2D
    --     rendering.
    --
    --     The @VectorHereContrast@ style has been renamed from
    --     @VectorHereBerlin@. @VectorHereBerlin@ has been deprecated, but will
    --     continue to work in applications that use it.
    --
    -- -   @VectorHereExplore@ – A default HERE map style containing a neutral,
    --     global map and its features including roads, buildings, landmarks,
    --     and water features. It also now includes a fully designed map of
    --     Japan.
    --
    -- -   @VectorHereExploreTruck@ – A global map containing truck
    --     restrictions and attributes (e.g. width \/ height \/ HAZMAT)
    --     symbolized with highlighted segments and icons on top of HERE
    --     Explore to support use cases within transport and logistics.
    --
    -- -   @RasterHereExploreSatellite@ – A global map containing high
    --     resolution satellite imagery.
    --
    -- -   @HybridHereExploreSatellite@ – A global map displaying the road
    --     network, street names, and city labels over satellite imagery. This
    --     style will automatically retrieve both raster and vector tiles, and
    --     your charges will be based on total tiles retrieved.
    --
    --     Hybrid styles use both vector and raster tiles when rendering the
    --     map that you see. This means that more tiles are retrieved than when
    --     using either vector or raster tiles alone. Your charges will include
    --     all tiles retrieved.
    --
    -- Valid
    -- <https://docs.aws.amazon.com/location/latest/developerguide/open-data.html Open Data (Preview) map styles>:
    --
    -- -   @VectorOpenDataStandardLight@ – The Open Data Standard Light
    --     (preview) map style provides a detailed basemap for the world
    --     suitable for website and mobile application use. The map includes
    --     highways major roads, minor roads, railways, water features, cities,
    --     parks, landmarks, building footprints, and administrative
    --     boundaries.
    --
    --     Open Data maps is in preview. We may add, change, or remove features
    --     before announcing general availability. For more information, see
    --     <https://docs.aws.amazon.com/location/latest/developerguide/open-data.html#open-data-preview Open Data is in preview release>.
    MapConfiguration -> Text
style :: Prelude.Text
  }
  deriving (MapConfiguration -> MapConfiguration -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: MapConfiguration -> MapConfiguration -> Bool
$c/= :: MapConfiguration -> MapConfiguration -> Bool
== :: MapConfiguration -> MapConfiguration -> Bool
$c== :: MapConfiguration -> MapConfiguration -> Bool
Prelude.Eq, ReadPrec [MapConfiguration]
ReadPrec MapConfiguration
Int -> ReadS MapConfiguration
ReadS [MapConfiguration]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [MapConfiguration]
$creadListPrec :: ReadPrec [MapConfiguration]
readPrec :: ReadPrec MapConfiguration
$creadPrec :: ReadPrec MapConfiguration
readList :: ReadS [MapConfiguration]
$creadList :: ReadS [MapConfiguration]
readsPrec :: Int -> ReadS MapConfiguration
$creadsPrec :: Int -> ReadS MapConfiguration
Prelude.Read, Int -> MapConfiguration -> ShowS
[MapConfiguration] -> ShowS
MapConfiguration -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [MapConfiguration] -> ShowS
$cshowList :: [MapConfiguration] -> ShowS
show :: MapConfiguration -> String
$cshow :: MapConfiguration -> String
showsPrec :: Int -> MapConfiguration -> ShowS
$cshowsPrec :: Int -> MapConfiguration -> ShowS
Prelude.Show, forall x. Rep MapConfiguration x -> MapConfiguration
forall x. MapConfiguration -> Rep MapConfiguration x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep MapConfiguration x -> MapConfiguration
$cfrom :: forall x. MapConfiguration -> Rep MapConfiguration x
Prelude.Generic)

-- |
-- Create a value of 'MapConfiguration' 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:
--
-- 'style', 'mapConfiguration_style' - Specifies the map style selected from an available data provider.
--
-- Valid
-- <https://docs.aws.amazon.com/location/latest/developerguide/esri.html Esri map styles>:
--
-- -   @VectorEsriDarkGrayCanvas@ – The Esri Dark Gray Canvas map style. A
--     vector basemap with a dark gray, neutral background with minimal
--     colors, labels, and features that\'s designed to draw attention to
--     your thematic content.
--
-- -   @RasterEsriImagery@ – The Esri Imagery map style. A raster basemap
--     that provides one meter or better satellite and aerial imagery in
--     many parts of the world and lower resolution satellite imagery
--     worldwide.
--
-- -   @VectorEsriLightGrayCanvas@ – The Esri Light Gray Canvas map style,
--     which provides a detailed vector basemap with a light gray, neutral
--     background style with minimal colors, labels, and features that\'s
--     designed to draw attention to your thematic content.
--
-- -   @VectorEsriTopographic@ – The Esri Light map style, which provides a
--     detailed vector basemap with a classic Esri map style.
--
-- -   @VectorEsriStreets@ – The Esri World Streets map style, which
--     provides a detailed vector basemap for the world symbolized with a
--     classic Esri street map style. The vector tile layer is similar in
--     content and style to the World Street Map raster map.
--
-- -   @VectorEsriNavigation@ – The Esri World Navigation map style, which
--     provides a detailed basemap for the world symbolized with a custom
--     navigation map style that\'s designed for use during the day in
--     mobile devices.
--
-- Valid
-- <https://docs.aws.amazon.com/location/latest/developerguide/HERE.html HERE Technologies map styles>:
--
-- -   @VectorHereContrast@ – The HERE Contrast (Berlin) map style is a
--     high contrast detailed base map of the world that blends 3D and 2D
--     rendering.
--
--     The @VectorHereContrast@ style has been renamed from
--     @VectorHereBerlin@. @VectorHereBerlin@ has been deprecated, but will
--     continue to work in applications that use it.
--
-- -   @VectorHereExplore@ – A default HERE map style containing a neutral,
--     global map and its features including roads, buildings, landmarks,
--     and water features. It also now includes a fully designed map of
--     Japan.
--
-- -   @VectorHereExploreTruck@ – A global map containing truck
--     restrictions and attributes (e.g. width \/ height \/ HAZMAT)
--     symbolized with highlighted segments and icons on top of HERE
--     Explore to support use cases within transport and logistics.
--
-- -   @RasterHereExploreSatellite@ – A global map containing high
--     resolution satellite imagery.
--
-- -   @HybridHereExploreSatellite@ – A global map displaying the road
--     network, street names, and city labels over satellite imagery. This
--     style will automatically retrieve both raster and vector tiles, and
--     your charges will be based on total tiles retrieved.
--
--     Hybrid styles use both vector and raster tiles when rendering the
--     map that you see. This means that more tiles are retrieved than when
--     using either vector or raster tiles alone. Your charges will include
--     all tiles retrieved.
--
-- Valid
-- <https://docs.aws.amazon.com/location/latest/developerguide/open-data.html Open Data (Preview) map styles>:
--
-- -   @VectorOpenDataStandardLight@ – The Open Data Standard Light
--     (preview) map style provides a detailed basemap for the world
--     suitable for website and mobile application use. The map includes
--     highways major roads, minor roads, railways, water features, cities,
--     parks, landmarks, building footprints, and administrative
--     boundaries.
--
--     Open Data maps is in preview. We may add, change, or remove features
--     before announcing general availability. For more information, see
--     <https://docs.aws.amazon.com/location/latest/developerguide/open-data.html#open-data-preview Open Data is in preview release>.
newMapConfiguration ::
  -- | 'style'
  Prelude.Text ->
  MapConfiguration
newMapConfiguration :: Text -> MapConfiguration
newMapConfiguration Text
pStyle_ =
  MapConfiguration' {$sel:style:MapConfiguration' :: Text
style = Text
pStyle_}

-- | Specifies the map style selected from an available data provider.
--
-- Valid
-- <https://docs.aws.amazon.com/location/latest/developerguide/esri.html Esri map styles>:
--
-- -   @VectorEsriDarkGrayCanvas@ – The Esri Dark Gray Canvas map style. A
--     vector basemap with a dark gray, neutral background with minimal
--     colors, labels, and features that\'s designed to draw attention to
--     your thematic content.
--
-- -   @RasterEsriImagery@ – The Esri Imagery map style. A raster basemap
--     that provides one meter or better satellite and aerial imagery in
--     many parts of the world and lower resolution satellite imagery
--     worldwide.
--
-- -   @VectorEsriLightGrayCanvas@ – The Esri Light Gray Canvas map style,
--     which provides a detailed vector basemap with a light gray, neutral
--     background style with minimal colors, labels, and features that\'s
--     designed to draw attention to your thematic content.
--
-- -   @VectorEsriTopographic@ – The Esri Light map style, which provides a
--     detailed vector basemap with a classic Esri map style.
--
-- -   @VectorEsriStreets@ – The Esri World Streets map style, which
--     provides a detailed vector basemap for the world symbolized with a
--     classic Esri street map style. The vector tile layer is similar in
--     content and style to the World Street Map raster map.
--
-- -   @VectorEsriNavigation@ – The Esri World Navigation map style, which
--     provides a detailed basemap for the world symbolized with a custom
--     navigation map style that\'s designed for use during the day in
--     mobile devices.
--
-- Valid
-- <https://docs.aws.amazon.com/location/latest/developerguide/HERE.html HERE Technologies map styles>:
--
-- -   @VectorHereContrast@ – The HERE Contrast (Berlin) map style is a
--     high contrast detailed base map of the world that blends 3D and 2D
--     rendering.
--
--     The @VectorHereContrast@ style has been renamed from
--     @VectorHereBerlin@. @VectorHereBerlin@ has been deprecated, but will
--     continue to work in applications that use it.
--
-- -   @VectorHereExplore@ – A default HERE map style containing a neutral,
--     global map and its features including roads, buildings, landmarks,
--     and water features. It also now includes a fully designed map of
--     Japan.
--
-- -   @VectorHereExploreTruck@ – A global map containing truck
--     restrictions and attributes (e.g. width \/ height \/ HAZMAT)
--     symbolized with highlighted segments and icons on top of HERE
--     Explore to support use cases within transport and logistics.
--
-- -   @RasterHereExploreSatellite@ – A global map containing high
--     resolution satellite imagery.
--
-- -   @HybridHereExploreSatellite@ – A global map displaying the road
--     network, street names, and city labels over satellite imagery. This
--     style will automatically retrieve both raster and vector tiles, and
--     your charges will be based on total tiles retrieved.
--
--     Hybrid styles use both vector and raster tiles when rendering the
--     map that you see. This means that more tiles are retrieved than when
--     using either vector or raster tiles alone. Your charges will include
--     all tiles retrieved.
--
-- Valid
-- <https://docs.aws.amazon.com/location/latest/developerguide/open-data.html Open Data (Preview) map styles>:
--
-- -   @VectorOpenDataStandardLight@ – The Open Data Standard Light
--     (preview) map style provides a detailed basemap for the world
--     suitable for website and mobile application use. The map includes
--     highways major roads, minor roads, railways, water features, cities,
--     parks, landmarks, building footprints, and administrative
--     boundaries.
--
--     Open Data maps is in preview. We may add, change, or remove features
--     before announcing general availability. For more information, see
--     <https://docs.aws.amazon.com/location/latest/developerguide/open-data.html#open-data-preview Open Data is in preview release>.
mapConfiguration_style :: Lens.Lens' MapConfiguration Prelude.Text
mapConfiguration_style :: Lens' MapConfiguration Text
mapConfiguration_style = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MapConfiguration' {Text
style :: Text
$sel:style:MapConfiguration' :: MapConfiguration -> Text
style} -> Text
style) (\s :: MapConfiguration
s@MapConfiguration' {} Text
a -> MapConfiguration
s {$sel:style:MapConfiguration' :: Text
style = Text
a} :: MapConfiguration)

instance Data.FromJSON MapConfiguration where
  parseJSON :: Value -> Parser MapConfiguration
parseJSON =
    forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
      String
"MapConfiguration"
      ( \Object
x ->
          Text -> MapConfiguration
MapConfiguration' forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"Style")
      )

instance Prelude.Hashable MapConfiguration where
  hashWithSalt :: Int -> MapConfiguration -> Int
hashWithSalt Int
_salt MapConfiguration' {Text
style :: Text
$sel:style:MapConfiguration' :: MapConfiguration -> Text
..} =
    Int
_salt forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
style

instance Prelude.NFData MapConfiguration where
  rnf :: MapConfiguration -> ()
rnf MapConfiguration' {Text
style :: Text
$sel:style:MapConfiguration' :: MapConfiguration -> Text
..} = forall a. NFData a => a -> ()
Prelude.rnf Text
style

instance Data.ToJSON MapConfiguration where
  toJSON :: MapConfiguration -> Value
toJSON MapConfiguration' {Text
style :: Text
$sel:style:MapConfiguration' :: MapConfiguration -> Text
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [forall a. a -> Maybe a
Prelude.Just (Key
"Style" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
style)]
      )