Class: Google::Apis::SheetsV4::CellData
- Inherits:
-
Object
- Object
- Google::Apis::SheetsV4::CellData
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/sheets_v4/classes.rb,
lib/google/apis/sheets_v4/representations.rb,
lib/google/apis/sheets_v4/representations.rb
Overview
Data about a specific cell.
Instance Attribute Summary collapse
-
#chip_runs ⇒ Array<Google::Apis::SheetsV4::ChipRun>
Optional.
-
#data_source_formula ⇒ Google::Apis::SheetsV4::DataSourceFormula
A data source formula.
-
#data_source_table ⇒ Google::Apis::SheetsV4::DataSourceTable
A data source table, which allows the user to import a static table of data from the DataSource into Sheets.
-
#data_validation ⇒ Google::Apis::SheetsV4::DataValidationRule
A data validation rule.
-
#effective_format ⇒ Google::Apis::SheetsV4::CellFormat
The format of a cell.
-
#effective_value ⇒ Google::Apis::SheetsV4::ExtendedValue
The kinds of value that a cell in a spreadsheet can have.
-
#formatted_value ⇒ String
The formatted value of the cell.
-
#hyperlink ⇒ String
A hyperlink this cell points to, if any.
-
#note ⇒ String
Any note on the cell.
-
#pivot_table ⇒ Google::Apis::SheetsV4::PivotTable
A pivot table.
-
#text_format_runs ⇒ Array<Google::Apis::SheetsV4::TextFormatRun>
Runs of rich text applied to subsections of the cell.
-
#user_entered_format ⇒ Google::Apis::SheetsV4::CellFormat
The format of a cell.
-
#user_entered_value ⇒ Google::Apis::SheetsV4::ExtendedValue
The kinds of value that a cell in a spreadsheet can have.
Instance Method Summary collapse
-
#initialize(**args) ⇒ CellData
constructor
A new instance of CellData.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ CellData
Returns a new instance of CellData.
2701 2702 2703 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2701 def initialize(**args) update!(**args) end |
Instance Attribute Details
#chip_runs ⇒ Array<Google::Apis::SheetsV4::ChipRun>
Optional. Runs of chips applied to subsections of the cell. Properties of a
run start at a specific index in the text and continue until the next run.
When reading, all chipped and non-chipped runs are included. Non-chipped runs
will have an empty Chip. When writing, only runs with chips are included. Runs
containing chips are of length 1 and are represented in the user-entered text
by an “@” placeholder symbol. New runs will overwrite any prior runs. Writing
a new user_entered_value will erase previous runs.
Corresponds to the JSON property chipRuns
2626 2627 2628 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2626 def chip_runs @chip_runs end |
#data_source_formula ⇒ Google::Apis::SheetsV4::DataSourceFormula
A data source formula.
Corresponds to the JSON property dataSourceFormula
2631 2632 2633 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2631 def data_source_formula @data_source_formula end |
#data_source_table ⇒ Google::Apis::SheetsV4::DataSourceTable
A data source table, which allows the user to import a static table of data
from the DataSource into Sheets. This is also known as "Extract" in the Sheets
editor.
Corresponds to the JSON property dataSourceTable
2638 2639 2640 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2638 def data_source_table @data_source_table end |
#data_validation ⇒ Google::Apis::SheetsV4::DataValidationRule
A data validation rule.
Corresponds to the JSON property dataValidation
2643 2644 2645 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2643 def data_validation @data_validation end |
#effective_format ⇒ Google::Apis::SheetsV4::CellFormat
The format of a cell.
Corresponds to the JSON property effectiveFormat
2648 2649 2650 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2648 def effective_format @effective_format end |
#effective_value ⇒ Google::Apis::SheetsV4::ExtendedValue
The kinds of value that a cell in a spreadsheet can have.
Corresponds to the JSON property effectiveValue
2653 2654 2655 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2653 def effective_value @effective_value end |
#formatted_value ⇒ String
The formatted value of the cell. This is the value as it's shown to the user.
This field is read-only.
Corresponds to the JSON property formattedValue
2659 2660 2661 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2659 def formatted_value @formatted_value end |
#hyperlink ⇒ String
A hyperlink this cell points to, if any. If the cell contains multiple
hyperlinks, this field will be empty. This field is read-only. To set it, use
a =HYPERLINK formula in the userEnteredValue.formulaValue field. A cell-
level link can also be set from the userEnteredFormat.textFormat field.
Alternatively, set a hyperlink in the textFormatRun.format.link field that
spans the entire cell.
Corresponds to the JSON property hyperlink
2669 2670 2671 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2669 def hyperlink @hyperlink end |
#note ⇒ String
Any note on the cell.
Corresponds to the JSON property note
2674 2675 2676 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2674 def note @note end |
#pivot_table ⇒ Google::Apis::SheetsV4::PivotTable
A pivot table.
Corresponds to the JSON property pivotTable
2679 2680 2681 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2679 def pivot_table @pivot_table end |
#text_format_runs ⇒ Array<Google::Apis::SheetsV4::TextFormatRun>
Runs of rich text applied to subsections of the cell. Runs are only valid on
user entered strings, not formulas, bools, or numbers. Properties of a run
start at a specific index in the text and continue until the next run. Runs
will inherit the properties of the cell unless explicitly changed. When
writing, the new runs will overwrite any prior runs. When writing a new
user_entered_value, previous runs are erased.
Corresponds to the JSON property textFormatRuns
2689 2690 2691 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2689 def text_format_runs @text_format_runs end |
#user_entered_format ⇒ Google::Apis::SheetsV4::CellFormat
The format of a cell.
Corresponds to the JSON property userEnteredFormat
2694 2695 2696 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2694 def user_entered_format @user_entered_format end |
#user_entered_value ⇒ Google::Apis::SheetsV4::ExtendedValue
The kinds of value that a cell in a spreadsheet can have.
Corresponds to the JSON property userEnteredValue
2699 2700 2701 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2699 def user_entered_value @user_entered_value end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 |
# File 'lib/google/apis/sheets_v4/classes.rb', line 2706 def update!(**args) @chip_runs = args[:chip_runs] if args.key?(:chip_runs) @data_source_formula = args[:data_source_formula] if args.key?(:data_source_formula) @data_source_table = args[:data_source_table] if args.key?(:data_source_table) @data_validation = args[:data_validation] if args.key?(:data_validation) @effective_format = args[:effective_format] if args.key?(:effective_format) @effective_value = args[:effective_value] if args.key?(:effective_value) @formatted_value = args[:formatted_value] if args.key?(:formatted_value) @hyperlink = args[:hyperlink] if args.key?(:hyperlink) @note = args[:note] if args.key?(:note) @pivot_table = args[:pivot_table] if args.key?(:pivot_table) @text_format_runs = args[:text_format_runs] if args.key?(:text_format_runs) @user_entered_format = args[:user_entered_format] if args.key?(:user_entered_format) @user_entered_value = args[:user_entered_value] if args.key?(:user_entered_value) end |