Class: Google::Apis::WalletobjectsV1::TextModuleData

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/walletobjects_v1/classes.rb,
lib/google/apis/walletobjects_v1/representations.rb,
lib/google/apis/walletobjects_v1/representations.rb

Overview

Data for Text module. All fields are optional. Header will be displayed if available, different types of bodies will be concatenated if they are defined.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ TextModuleData

Returns a new instance of TextModuleData.



7024
7025
7026
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 7024

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

Instance Attribute Details

#bodyString

The body of the Text Module, which is defined as an uninterrupted string. Recommended maximum length is 500 characters to ensure full string is displayed on smaller screens. Corresponds to the JSON property body

Returns:

  • (String)


6998
6999
7000
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 6998

def body
  @body
end

#headerString

The header of the Text Module. Recommended maximum length is 35 characters to ensure full string is displayed on smaller screens. Corresponds to the JSON property header

Returns:

  • (String)


7004
7005
7006
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 7004

def header
  @header
end

#idString

The ID associated with a text module. This field is here to enable ease of management of text modules. Corresponds to the JSON property id

Returns:

  • (String)


7010
7011
7012
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 7010

def id
  @id
end

#localized_bodyGoogle::Apis::WalletobjectsV1::LocalizedString

Translated strings for the body. Recommended maximum length is 500 characters to ensure full string is displayed on smaller screens. Corresponds to the JSON property localizedBody



7016
7017
7018
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 7016

def localized_body
  @localized_body
end

#localized_headerGoogle::Apis::WalletobjectsV1::LocalizedString

Translated strings for the header. Recommended maximum length is 35 characters to ensure full string is displayed on smaller screens. Corresponds to the JSON property localizedHeader



7022
7023
7024
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 7022

def localized_header
  @localized_header
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



7029
7030
7031
7032
7033
7034
7035
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 7029

def update!(**args)
  @body = args[:body] if args.key?(:body)
  @header = args[:header] if args.key?(:header)
  @id = args[:id] if args.key?(:id)
  @localized_body = args[:localized_body] if args.key?(:localized_body)
  @localized_header = args[:localized_header] if args.key?(:localized_header)
end