Class: Google::Apis::FusiontablesV1::StyleFunction::Gradient
- Inherits:
-
Object
- Object
- Google::Apis::FusiontablesV1::StyleFunction::Gradient
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/fusiontables_v1/classes.rb,
generated/google/apis/fusiontables_v1/representations.rb,
generated/google/apis/fusiontables_v1/representations.rb
Overview
Gradient function that interpolates a range of colors based on column value.
Defined Under Namespace
Classes: Color
Instance Attribute Summary collapse
-
#colors ⇒ Array<Google::Apis::FusiontablesV1::StyleFunction::Gradient::Color>
Array with two or more colors.
-
#max ⇒ Float
Higher-end of the interpolation range: rows with this value will be assigned to colors[n-1].
-
#min ⇒ Float
Lower-end of the interpolation range: rows with this value will be assigned to colors[0].
Instance Method Summary collapse
-
#initialize(**args) ⇒ Gradient
constructor
A new instance of Gradient.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ Gradient
Returns a new instance of Gradient
556 557 558 |
# File 'generated/google/apis/fusiontables_v1/classes.rb', line 556 def initialize(**args) update!(**args) end |
Instance Attribute Details
#colors ⇒ Array<Google::Apis::FusiontablesV1::StyleFunction::Gradient::Color>
Array with two or more colors.
Corresponds to the JSON property colors
542 543 544 |
# File 'generated/google/apis/fusiontables_v1/classes.rb', line 542 def colors @colors end |
#max ⇒ Float
Higher-end of the interpolation range: rows with this value will be assigned
to colors[n-1].
Corresponds to the JSON property max
548 549 550 |
# File 'generated/google/apis/fusiontables_v1/classes.rb', line 548 def max @max end |
#min ⇒ Float
Lower-end of the interpolation range: rows with this value will be assigned to
colors[0].
Corresponds to the JSON property min
554 555 556 |
# File 'generated/google/apis/fusiontables_v1/classes.rb', line 554 def min @min end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
561 562 563 564 565 |
# File 'generated/google/apis/fusiontables_v1/classes.rb', line 561 def update!(**args) @colors = args[:colors] if args.key?(:colors) @max = args[:max] if args.key?(:max) @min = args[:min] if args.key?(:min) end |