Class: Google::Apis::WalletobjectsV1::Message
- Inherits:
-
Object
- Object
- Google::Apis::WalletobjectsV1::Message
- 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
A message that will be displayed with a Valuable
Instance Attribute Summary collapse
-
#body ⇒ String
The message body.
-
#display_interval ⇒ Google::Apis::WalletobjectsV1::TimeInterval
The period of time that the message will be displayed to users.
-
#header ⇒ String
The message header.
-
#id ⇒ String
The ID associated with a message.
-
#kind ⇒ String
Identifies what kind of resource this is.
-
#localized_body ⇒ Google::Apis::WalletobjectsV1::LocalizedString
Translated strings for the message body.
-
#localized_header ⇒ Google::Apis::WalletobjectsV1::LocalizedString
Translated strings for the message header.
-
#message_type ⇒ String
The message type.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Message
constructor
A new instance of Message.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Message
Returns a new instance of Message.
6091 6092 6093 |
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 6091 def initialize(**args) update!(**args) end |
Instance Attribute Details
#body ⇒ String
The message body.
Corresponds to the JSON property body
6046 6047 6048 |
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 6046 def body @body end |
#display_interval ⇒ Google::Apis::WalletobjectsV1::TimeInterval
The period of time that the message will be displayed to users. You can define
both a startTime
and endTime
for each message. A message is displayed
immediately after a Wallet Object is inserted unless a startTime
is set. The
message will appear in a list of messages indefinitely if endTime
is not
provided.
Corresponds to the JSON property displayInterval
6055 6056 6057 |
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 6055 def display_interval @display_interval end |
#header ⇒ String
The message header.
Corresponds to the JSON property header
6060 6061 6062 |
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 6060 def header @header end |
#id ⇒ String
The ID associated with a message. This field is here to enable ease of
management of messages. Notice ID values could possibly duplicate across
multiple messages in the same class/instance, and care must be taken to select
a reasonable ID for each message.
Corresponds to the JSON property id
6068 6069 6070 |
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 6068 def id @id end |
#kind ⇒ String
Identifies what kind of resource this is. Value: the fixed string "
walletobjects#walletObjectMessage"
.
Corresponds to the JSON property kind
6074 6075 6076 |
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 6074 def kind @kind end |
#localized_body ⇒ Google::Apis::WalletobjectsV1::LocalizedString
Translated strings for the message body.
Corresponds to the JSON property localizedBody
6079 6080 6081 |
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 6079 def localized_body @localized_body end |
#localized_header ⇒ Google::Apis::WalletobjectsV1::LocalizedString
Translated strings for the message header.
Corresponds to the JSON property localizedHeader
6084 6085 6086 |
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 6084 def localized_header @localized_header end |
#message_type ⇒ String
The message type.
Corresponds to the JSON property messageType
6089 6090 6091 |
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 6089 def @message_type end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
6096 6097 6098 6099 6100 6101 6102 6103 6104 6105 |
# File 'lib/google/apis/walletobjects_v1/classes.rb', line 6096 def update!(**args) @body = args[:body] if args.key?(:body) @display_interval = args[:display_interval] if args.key?(:display_interval) @header = args[:header] if args.key?(:header) @id = args[:id] if args.key?(:id) @kind = args[:kind] if args.key?(:kind) @localized_body = args[:localized_body] if args.key?(:localized_body) @localized_header = args[:localized_header] if args.key?(:localized_header) @message_type = args[:message_type] if args.key?(:message_type) end |