class Xlsxrb::ChartBuilder::SeriesBuilder
Builder for a single series entry in block-style chart definitions.
@api public
Attributes
Hash[Symbol, untyped]
@return [Hash{Symbol => Object}]
Public Class Methods
() → void
Source
# File lib/xlsxrb/chart_builder.rb, line 203 def initialize @options = {} end
Public Instance Methods
(*untyped args, **untyped kwargs) → untyped
Source
# File lib/xlsxrb/chart_builder.rb, line 218 def categories(*args, **kwargs) @options[:categories] = kwargs.empty? ? args.first : kwargs end
Configures categories reference for this series (e.g. “Sheet1!$A$2:$A$10”).
@param args [Array] Positional arguments. @param kwargs [Hash] Keyword arguments. @return [Object] @api public
(*(Hash[Symbol, String | Integer | bool | nil] | String) args, **String | Integer | bool | nil kwargs) → (Hash[Symbol, String | Integer | bool | nil] | String)
Source
# File lib/xlsxrb/chart_builder.rb, line 295 def data_labels(*args, **kwargs) @options[:data_labels] = kwargs.empty? ? args.first : kwargs end
Configures data labels for this series.
@param args [Array] Positional arguments. @param kwargs [Hash] Keyword arguments. @return [Object] @api public
(*(Hash[Symbol, String | Integer | bool | nil] | String) args, **String | Integer | bool | nil kwargs) → (Hash[Symbol, String | Integer | bool | nil] | String)
Source
# File lib/xlsxrb/chart_builder.rb, line 262 def fill(*args, **kwargs) @options[:fill] = kwargs.empty? ? args.first : kwargs end
Configures fill color/pattern for this series.
@param args [Array] Positional arguments. @param kwargs [Hash] Keyword arguments. @return [Object] @api public
(*(Hash[Symbol, String | Integer | bool | nil] | String) args, **String | Integer | bool | nil kwargs) → (Hash[Symbol, String | Integer | bool | nil] | String)
Source
# File lib/xlsxrb/chart_builder.rb, line 273 def line(*args, **kwargs) @options[:line] = kwargs.empty? ? args.first : kwargs end
Configures line color/thickness for this series.
@param args [Array] Positional arguments. @param kwargs [Hash] Keyword arguments. @return [Object] @api public
(*untyped args, **untyped kwargs) → untyped
Source
# File lib/xlsxrb/chart_builder.rb, line 251 def marker(*args, **kwargs) @options[:marker] = kwargs.empty? ? args.first : kwargs end
Configures data markers for this series.
@param args [Array] Positional arguments. @param kwargs [Hash] Keyword arguments. @return [Object] @api public
(*untyped args, **untyped kwargs) → untyped
Source
# File lib/xlsxrb/chart_builder.rb, line 240 def name(*args, **kwargs) @options[:name] = kwargs.empty? ? args.first : kwargs end
Configures the name for this series (e.g. “Total Sales” or cell reference “Sheet1!$B$1”).
@param args [Array] Positional arguments. @param kwargs [Hash] Keyword arguments. @return [Object] @api public
(*(String) args, **String | Integer | bool | nil kwargs) → String
Source
# File lib/xlsxrb/chart_builder.rb, line 317 def shape(*args, **kwargs) @options[:shape] = kwargs.empty? ? args.first : kwargs end
Configures 3D bar/column shape (e.g. “cylinder”, “cone”, “pyramid”).
@param args [Array] Positional arguments. @param kwargs [Hash] Keyword arguments. @return [String] @api public
(*(bool | String) args, **String | Integer | bool | nil kwargs) → (bool | String)
Source
# File lib/xlsxrb/chart_builder.rb, line 306 def smooth(*args, **kwargs) @options[:smooth] = kwargs.empty? ? args.first : kwargs end
Configures line smoothing for this series.
@param args [Array] Positional arguments. @param kwargs [Hash] Keyword arguments. @return [Boolean, String] @api public
(*(Hash[Symbol, String | Integer | bool | nil] | String) args, **String | Integer | bool | nil kwargs) → (Hash[Symbol, String | Integer | bool | nil] | String)
Source
# File lib/xlsxrb/chart_builder.rb, line 284 def trendline(*args, **kwargs) @options[:trendline] = kwargs.empty? ? args.first : kwargs end
Configures trendline for this series.
@param args [Array] Positional arguments. @param kwargs [Hash] Keyword arguments. @return [Object] @api public
(*(String) args, **String | Integer | bool | nil kwargs) → String
Source
# File lib/xlsxrb/chart_builder.rb, line 328 def type(*args, **kwargs) @options[:type] = kwargs.empty? ? args.first : kwargs end
Configures individual series chart type override in combo charts.
@param args [Array] Positional arguments. @param kwargs [Hash] Keyword arguments. @return [String] @api public
(*untyped args, **untyped kwargs) → untyped
Source
# File lib/xlsxrb/chart_builder.rb, line 229 def values(*args, **kwargs) @options[:values] = kwargs.empty? ? args.first : kwargs end
Configures values reference for this series (e.g. “Sheet1!$B$2:$B$10”).
@param args [Array] Positional arguments. @param kwargs [Hash] Keyword arguments. @return [Object] @api public