Class: Google::Apis::ChatV1::Section

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

Overview

A section contains a collection of widgets that are rendered (vertically) in the order that they are specified. Across all platforms, cards have a narrow fixed width, so there is currently no need for layout properties (e.g. float).

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Section

Returns a new instance of Section.



2361
2362
2363
# File 'lib/google/apis/chat_v1/classes.rb', line 2361

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

Instance Attribute Details

#headerString

The header of the section, text formatted supported. Corresponds to the JSON property header

Returns:

  • (String)


2354
2355
2356
# File 'lib/google/apis/chat_v1/classes.rb', line 2354

def header
  @header
end

#widgetsArray<Google::Apis::ChatV1::WidgetMarkup>

A section must contain at least 1 widget. Corresponds to the JSON property widgets



2359
2360
2361
# File 'lib/google/apis/chat_v1/classes.rb', line 2359

def widgets
  @widgets
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2366
2367
2368
2369
# File 'lib/google/apis/chat_v1/classes.rb', line 2366

def update!(**args)
  @header = args[:header] if args.key?(:header)
  @widgets = args[:widgets] if args.key?(:widgets)
end