Class: Google::Apis::SheetsV4::PivotGroup

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

Overview

A single grouping (either row or column) in a pivot table.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ PivotGroup

Returns a new instance of PivotGroup.



4170
4171
4172
# File 'generated/google/apis/sheets_v4/classes.rb', line 4170

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

Instance Attribute Details

#show_totalsBoolean Also known as: show_totals?

True if the pivot table should include the totals for this grouping. Corresponds to the JSON property showTotals

Returns:

  • (Boolean)


4157
4158
4159
# File 'generated/google/apis/sheets_v4/classes.rb', line 4157

def show_totals
  @show_totals
end

#sort_orderString

The order the values in this group should be sorted. Corresponds to the JSON property sortOrder

Returns:

  • (String)


4144
4145
4146
# File 'generated/google/apis/sheets_v4/classes.rb', line 4144

def sort_order
  @sort_order
end

#source_column_offsetFixnum

The column offset of the source range that this grouping is based on. For example, if the source was C10:E15, a sourceColumnOffset of 0 means this group refers to column C, whereas the offset 1 would refer to column D. Corresponds to the JSON property sourceColumnOffset

Returns:

  • (Fixnum)


4152
4153
4154
# File 'generated/google/apis/sheets_v4/classes.rb', line 4152

def source_column_offset
  @source_column_offset
end

#value_bucketGoogle::Apis::SheetsV4::PivotGroupSortValueBucket

Information about which values in a pivot group should be used for sorting. Corresponds to the JSON property valueBucket



4163
4164
4165
# File 'generated/google/apis/sheets_v4/classes.rb', line 4163

def value_bucket
  @value_bucket
end

#value_metadataArray<Google::Apis::SheetsV4::PivotGroupValueMetadata>

Metadata about values in the grouping. Corresponds to the JSON property valueMetadata



4168
4169
4170
# File 'generated/google/apis/sheets_v4/classes.rb', line 4168

def 
  @value_metadata
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



4175
4176
4177
4178
4179
4180
4181
# File 'generated/google/apis/sheets_v4/classes.rb', line 4175

def update!(**args)
  @sort_order = args[:sort_order] if args.key?(:sort_order)
  @source_column_offset = args[:source_column_offset] if args.key?(:source_column_offset)
  @show_totals = args[:show_totals] if args.key?(:show_totals)
  @value_bucket = args[:value_bucket] if args.key?(:value_bucket)
  @value_metadata = args[:value_metadata] if args.key?(:value_metadata)
end