Class: Google::Apis::SheetsV4::DataValidationRule
- Inherits:
-
Object
- Object
- Google::Apis::SheetsV4::DataValidationRule
- 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 data validation rule.
Instance Attribute Summary collapse
-
#condition ⇒ Google::Apis::SheetsV4::BooleanCondition
A condition that can evaluate to true or false.
-
#input_message ⇒ String
A message to show the user when adding data to the cell.
-
#show_custom_ui ⇒ Boolean
(also: #show_custom_ui?)
True if the UI should be customized based on the kind of condition.
-
#strict ⇒ Boolean
(also: #strict?)
True if invalid data should be rejected.
Instance Method Summary collapse
-
#initialize(**args) ⇒ DataValidationRule
constructor
A new instance of DataValidationRule.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ DataValidationRule
Returns a new instance of DataValidationRule
5393 5394 5395 |
# File 'generated/google/apis/sheets_v4/classes.rb', line 5393 def initialize(**args) update!(**args) end |
Instance Attribute Details
#condition ⇒ Google::Apis::SheetsV4::BooleanCondition
A condition that can evaluate to true or false.
BooleanConditions are used by conditional formatting,
data validation, and the criteria in filters.
Corresponds to the JSON property condition
5391 5392 5393 |
# File 'generated/google/apis/sheets_v4/classes.rb', line 5391 def condition @condition end |
#input_message ⇒ String
A message to show the user when adding data to the cell.
Corresponds to the JSON property inputMessage
5384 5385 5386 |
# File 'generated/google/apis/sheets_v4/classes.rb', line 5384 def @input_message end |
#show_custom_ui ⇒ Boolean Also known as: show_custom_ui?
True if the UI should be customized based on the kind of condition.
If true, "List" conditions will show a dropdown.
Corresponds to the JSON property showCustomUi
5372 5373 5374 |
# File 'generated/google/apis/sheets_v4/classes.rb', line 5372 def show_custom_ui @show_custom_ui end |
#strict ⇒ Boolean Also known as: strict?
True if invalid data should be rejected.
Corresponds to the JSON property strict
5378 5379 5380 |
# File 'generated/google/apis/sheets_v4/classes.rb', line 5378 def strict @strict end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
5398 5399 5400 5401 5402 5403 |
# File 'generated/google/apis/sheets_v4/classes.rb', line 5398 def update!(**args) @show_custom_ui = args[:show_custom_ui] if args.key?(:show_custom_ui) @strict = args[:strict] if args.key?(:strict) @input_message = args[:input_message] if args.key?(:input_message) @condition = args[:condition] if args.key?(:condition) end |