Class: Google::Apis::SheetsV4::MoveDimensionRequest
- Inherits:
-
Object
- Object
- Google::Apis::SheetsV4::MoveDimensionRequest
- 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
Moves one or more rows or columns.
Instance Attribute Summary collapse
-
#destination_index ⇒ Fixnum
The zero-based start index of where to move the source data to, based on the coordinates before the source data is removed from the grid.
-
#source ⇒ Google::Apis::SheetsV4::DimensionRange
A range along a single dimension on a sheet.
Instance Method Summary collapse
-
#initialize(**args) ⇒ MoveDimensionRequest
constructor
A new instance of MoveDimensionRequest.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ MoveDimensionRequest
Returns a new instance of MoveDimensionRequest.
2342 2343 2344 |
# File 'generated/google/apis/sheets_v4/classes.rb', line 2342 def initialize(**args) update!(**args) end |
Instance Attribute Details
#destination_index ⇒ Fixnum
The zero-based start index of where to move the source data to,
based on the coordinates before the source data is removed
from the grid. Existing data will be shifted down or right
(depending on the dimension) to make room for the moved dimensions.
The source dimensions are removed from the grid, so the
the data may end up in a different index than specified.
For example, given A1..A5
of 0, 1, 2, 3, 4
and wanting to move
"1"
and "2"
to between "3"
and "4"
, the source would be
ROWS [1..3)
,and the destination index would be "4"
(the zero-based index of row 5).
The end result would be A1..A5
of 0, 3, 1, 2, 4
.
Corresponds to the JSON property destinationIndex
2340 2341 2342 |
# File 'generated/google/apis/sheets_v4/classes.rb', line 2340 def destination_index @destination_index end |
#source ⇒ Google::Apis::SheetsV4::DimensionRange
A range along a single dimension on a sheet.
All indexes are zero-based.
Indexes are half open: the start index is inclusive
and the end index is exclusive.
Missing indexes indicate the range is unbounded on that side.
Corresponds to the JSON property source
2325 2326 2327 |
# File 'generated/google/apis/sheets_v4/classes.rb', line 2325 def source @source end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
2347 2348 2349 2350 |
# File 'generated/google/apis/sheets_v4/classes.rb', line 2347 def update!(**args) @source = args[:source] if args.key?(:source) @destination_index = args[:destination_index] if args.key?(:destination_index) end |