Class: Google::Apis::ContentV2sandbox::OrderCustomer

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
generated/google/apis/content_v2sandbox/classes.rb,
generated/google/apis/content_v2sandbox/representations.rb,
generated/google/apis/content_v2sandbox/representations.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Google::Apis::Core::JsonObjectSupport

#to_json

Methods included from Google::Apis::Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ OrderCustomer

Returns a new instance of OrderCustomer



362
363
364
# File 'generated/google/apis/content_v2sandbox/classes.rb', line 362

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#emailString

Email address that should be used for order related communications. In certain cases this might not be a real users email, but a proxy email. Corresponds to the JSON property email

Returns:

  • (String)


346
347
348
# File 'generated/google/apis/content_v2sandbox/classes.rb', line 346

def email
  @email
end

#explicit_marketing_preferenceBoolean Also known as: explicit_marketing_preference?

If set, this indicates the user explicitly chose to opt in or out of providing marketing rights to the merchant. If unset, this indicates the user has already made this choice in a previous purchase, and was thus not shown the marketing right opt in/out checkbox during the checkout flow. Corresponds to the JSON property explicitMarketingPreference

Returns:

  • (Boolean)


354
355
356
# File 'generated/google/apis/content_v2sandbox/classes.rb', line 354

def explicit_marketing_preference
  @explicit_marketing_preference
end

#full_nameString

Full name of the customer. Corresponds to the JSON property fullName

Returns:

  • (String)


360
361
362
# File 'generated/google/apis/content_v2sandbox/classes.rb', line 360

def full_name
  @full_name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



367
368
369
370
371
# File 'generated/google/apis/content_v2sandbox/classes.rb', line 367

def update!(**args)
  @email = args[:email] if args.key?(:email)
  @explicit_marketing_preference = args[:explicit_marketing_preference] if args.key?(:explicit_marketing_preference)
  @full_name = args[:full_name] if args.key?(:full_name)
end