Class: Google::Apis::WebcontentpublisherV1::NewsletterConfig
- Inherits:
-
Object
- Object
- Google::Apis::WebcontentpublisherV1::NewsletterConfig
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/webcontentpublisher_v1/classes.rb,
lib/google/apis/webcontentpublisher_v1/representations.rb,
lib/google/apis/webcontentpublisher_v1/representations.rb
Overview
Configuration for newsletter signup calls-to-action (CTAs).
Instance Attribute Summary collapse
-
#custom_consent_text ⇒ String
Optional.
-
#custom_message ⇒ String
Optional.
-
#name_required ⇒ Boolean
(also: #name_required?)
Optional.
-
#opt_in_required ⇒ Boolean
(also: #opt_in_required?)
Optional.
-
#title ⇒ String
Required.
Instance Method Summary collapse
-
#initialize(**args) ⇒ NewsletterConfig
constructor
A new instance of NewsletterConfig.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ NewsletterConfig
Returns a new instance of NewsletterConfig.
257 258 259 |
# File 'lib/google/apis/webcontentpublisher_v1/classes.rb', line 257 def initialize(**args) update!(**args) end |
Instance Attribute Details
#custom_consent_text ⇒ String
Optional. Custom consent or disclosure text shown to the user.
Corresponds to the JSON property customConsentText
233 234 235 |
# File 'lib/google/apis/webcontentpublisher_v1/classes.rb', line 233 def @custom_consent_text end |
#custom_message ⇒ String
Optional. A custom message displayed to the user in the signup prompt.
Corresponds to the JSON property customMessage
238 239 240 |
# File 'lib/google/apis/webcontentpublisher_v1/classes.rb', line 238 def @custom_message end |
#name_required ⇒ Boolean Also known as: name_required?
Optional. Whether the user is required to provide their name to sign up.
Corresponds to the JSON property nameRequired
243 244 245 |
# File 'lib/google/apis/webcontentpublisher_v1/classes.rb', line 243 def name_required @name_required end |
#opt_in_required ⇒ Boolean Also known as: opt_in_required?
Optional. Whether checking the opt-in checkbox is required.
Corresponds to the JSON property optInRequired
249 250 251 |
# File 'lib/google/apis/webcontentpublisher_v1/classes.rb', line 249 def opt_in_required @opt_in_required end |
#title ⇒ String
Required. The title of the newsletter signup prompt.
Corresponds to the JSON property title
255 256 257 |
# File 'lib/google/apis/webcontentpublisher_v1/classes.rb', line 255 def title @title end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
262 263 264 265 266 267 268 |
# File 'lib/google/apis/webcontentpublisher_v1/classes.rb', line 262 def update!(**args) @custom_consent_text = args[:custom_consent_text] if args.key?(:custom_consent_text) @custom_message = args[:custom_message] if args.key?(:custom_message) @name_required = args[:name_required] if args.key?(:name_required) @opt_in_required = args[:opt_in_required] if args.key?(:opt_in_required) @title = args[:title] if args.key?(:title) end |