Class: Xlsxrb::ChartBuilder::SeriesBuilder

Inherits:
Object
  • Object
show all
Defined in:
lib/xlsxrb.rb,
sig/generated/xlsxrb.rbs

Overview

Builder for a single series entry in block-style chart definitions.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeSeriesBuilder

: () -> void



221
222
223
# File 'lib/xlsxrb.rb', line 221

def initialize
  @options = {}
end

Instance Attribute Details

#optionsObject (readonly)

: Hash[Symbol, untyped]

Returns:

  • (Object)


225
226
227
# File 'lib/xlsxrb.rb', line 225

def options
  @options
end

Instance Method Details

#categories(*args, **kwargs) ⇒ Object

Configures the categories property for this series. : (*untyped args, **untyped kwargs) -> untyped

Parameters:

  • args (Array)

    Positional arguments.

  • kwargs (Hash)

    Keyword arguments.

Returns:

  • (Object)

    the configured property



233
234
235
# File 'lib/xlsxrb.rb', line 233

def categories(*args, **kwargs)
  @options[:categories] = kwargs.empty? ? args.first : kwargs
end

#data_labels(*args, **kwargs) ⇒ Object

Configures the data_labels property for this series. : (*(Hash[Symbol, String | Integer | bool | nil] | String) args, **String | Integer | bool | nil kwargs) -> (Hash[Symbol, String | Integer | bool | nil] | String)

Parameters:

  • args (Array)

    Positional arguments.

  • kwargs (Hash)

    Keyword arguments.

Returns:

  • (Object)

    the configured property



303
304
305
# File 'lib/xlsxrb.rb', line 303

def data_labels(*args, **kwargs)
  @options[:data_labels] = kwargs.empty? ? args.first : kwargs
end

#fill(*args, **kwargs) ⇒ Object

Configures the fill property for this series. : (*(Hash[Symbol, String | Integer | bool | nil] | String) args, **String | Integer | bool | nil kwargs) -> (Hash[Symbol, String | Integer | bool | nil] | String)

Parameters:

  • args (Array)

    Positional arguments.

  • kwargs (Hash)

    Keyword arguments.

Returns:

  • (Object)

    the configured property



273
274
275
# File 'lib/xlsxrb.rb', line 273

def fill(*args, **kwargs)
  @options[:fill] = kwargs.empty? ? args.first : kwargs
end

#line(*args, **kwargs) ⇒ Object

Configures the line property for this series. : (*(Hash[Symbol, String | Integer | bool | nil] | String) args, **String | Integer | bool | nil kwargs) -> (Hash[Symbol, String | Integer | bool | nil] | String)

Parameters:

  • args (Array)

    Positional arguments.

  • kwargs (Hash)

    Keyword arguments.

Returns:

  • (Object)

    the configured property



283
284
285
# File 'lib/xlsxrb.rb', line 283

def line(*args, **kwargs)
  @options[:line] = kwargs.empty? ? args.first : kwargs
end

#marker(*args, **kwargs) ⇒ Object

Configures the marker property for this series. : (*untyped args, **untyped kwargs) -> untyped

Parameters:

  • args (Array)

    Positional arguments.

  • kwargs (Hash)

    Keyword arguments.

Returns:

  • (Object)

    the configured property



263
264
265
# File 'lib/xlsxrb.rb', line 263

def marker(*args, **kwargs)
  @options[:marker] = kwargs.empty? ? args.first : kwargs
end

#name(*args, **kwargs) ⇒ Object

Configures the name property for this series. : (*untyped args, **untyped kwargs) -> untyped

Parameters:

  • args (Array)

    Positional arguments.

  • kwargs (Hash)

    Keyword arguments.

Returns:

  • (Object)

    the configured property



253
254
255
# File 'lib/xlsxrb.rb', line 253

def name(*args, **kwargs)
  @options[:name] = kwargs.empty? ? args.first : kwargs
end

#shape(*args, **kwargs) ⇒ Object

Configures the shape property for this series. : (*(String) args, **String | Integer | bool | nil kwargs) -> String

Parameters:

  • args (Array)

    Positional arguments.

  • kwargs (Hash)

    Keyword arguments.

Returns:

  • (Object)

    the configured property



323
324
325
# File 'lib/xlsxrb.rb', line 323

def shape(*args, **kwargs)
  @options[:shape] = kwargs.empty? ? args.first : kwargs
end

#smooth(*args, **kwargs) ⇒ Object

Configures the smooth property for this series. : (*(bool | String) args, **String | Integer | bool | nil kwargs) -> (bool | String)

Parameters:

  • args (Array)

    Positional arguments.

  • kwargs (Hash)

    Keyword arguments.

Returns:

  • (Object)

    the configured property



313
314
315
# File 'lib/xlsxrb.rb', line 313

def smooth(*args, **kwargs)
  @options[:smooth] = kwargs.empty? ? args.first : kwargs
end

#trendline(*args, **kwargs) ⇒ Object

Configures the trendline property for this series. : (*(Hash[Symbol, String | Integer | bool | nil] | String) args, **String | Integer | bool | nil kwargs) -> (Hash[Symbol, String | Integer | bool | nil] | String)

Parameters:

  • args (Array)

    Positional arguments.

  • kwargs (Hash)

    Keyword arguments.

Returns:

  • (Object)

    the configured property



293
294
295
# File 'lib/xlsxrb.rb', line 293

def trendline(*args, **kwargs)
  @options[:trendline] = kwargs.empty? ? args.first : kwargs
end

#type(*args, **kwargs) ⇒ Object

Configures the type property for this series. : (*(String) args, **String | Integer | bool | nil kwargs) -> String

Parameters:

  • args (Array)

    Positional arguments.

  • kwargs (Hash)

    Keyword arguments.

Returns:

  • (Object)

    the configured property



333
334
335
# File 'lib/xlsxrb.rb', line 333

def type(*args, **kwargs)
  @options[:type] = kwargs.empty? ? args.first : kwargs
end

#values(*args, **kwargs) ⇒ Object

Configures the values property for this series. : (*untyped args, **untyped kwargs) -> untyped

Parameters:

  • args (Array)

    Positional arguments.

  • kwargs (Hash)

    Keyword arguments.

Returns:

  • (Object)

    the configured property



243
244
245
# File 'lib/xlsxrb.rb', line 243

def values(*args, **kwargs)
  @options[:values] = kwargs.empty? ? args.first : kwargs
end