{-# 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.Route53.Types.ResourceRecord -- 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.Route53.Types.ResourceRecord 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 import Amazonka.Route53.Internal -- | Information specific to the resource record. -- -- If you\'re creating an alias resource record set, omit @ResourceRecord@. -- -- /See:/ 'newResourceRecord' smart constructor. data ResourceRecord = ResourceRecord' { -- | The current or new DNS record value, not to exceed 4,000 characters. In -- the case of a @DELETE@ action, if the current value does not match the -- actual value, an error is returned. For descriptions about how to format -- @Value@ for different record types, see -- -- in the /Amazon Route 53 Developer Guide/. -- -- You can specify more than one value for all record types except @CNAME@ -- and @SOA@. -- -- If you\'re creating an alias resource record set, omit @Value@. value :: Prelude.Text } deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic) -- | -- Create a value of 'ResourceRecord' with all optional fields omitted. -- -- Use or to modify other optional fields. -- -- The following record fields are available, with the corresponding lenses provided -- for backwards compatibility: -- -- 'value', 'resourceRecord_value' - The current or new DNS record value, not to exceed 4,000 characters. In -- the case of a @DELETE@ action, if the current value does not match the -- actual value, an error is returned. For descriptions about how to format -- @Value@ for different record types, see -- -- in the /Amazon Route 53 Developer Guide/. -- -- You can specify more than one value for all record types except @CNAME@ -- and @SOA@. -- -- If you\'re creating an alias resource record set, omit @Value@. newResourceRecord :: -- | 'value' Prelude.Text -> ResourceRecord newResourceRecord pValue_ = ResourceRecord' {value = pValue_} -- | The current or new DNS record value, not to exceed 4,000 characters. In -- the case of a @DELETE@ action, if the current value does not match the -- actual value, an error is returned. For descriptions about how to format -- @Value@ for different record types, see -- -- in the /Amazon Route 53 Developer Guide/. -- -- You can specify more than one value for all record types except @CNAME@ -- and @SOA@. -- -- If you\'re creating an alias resource record set, omit @Value@. resourceRecord_value :: Lens.Lens' ResourceRecord Prelude.Text resourceRecord_value = Lens.lens (\ResourceRecord' {value} -> value) (\s@ResourceRecord' {} a -> s {value = a} :: ResourceRecord) instance Data.FromXML ResourceRecord where parseXML x = ResourceRecord' Prelude.<$> (x Data..@ "Value") instance Prelude.Hashable ResourceRecord where hashWithSalt _salt ResourceRecord' {..} = _salt `Prelude.hashWithSalt` value instance Prelude.NFData ResourceRecord where rnf ResourceRecord' {..} = Prelude.rnf value instance Data.ToXML ResourceRecord where toXML ResourceRecord' {..} = Prelude.mconcat ["Value" Data.@= value]