Class: HeatLoss::ChartExporter::Result

Inherits:
Data
  • Object
show all
Defined in:
app/services/heat_loss/chart_exporter.rb

Overview

Service object: result.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(success: false, image_data: nil, content_type: nil, error: nil) ⇒ Result

Returns a new instance of Result.



18
19
20
# File 'app/services/heat_loss/chart_exporter.rb', line 18

def initialize(success: false, image_data: nil, content_type: nil, error: nil)
  super
end

Instance Attribute Details

#content_typeObject (readonly)

Returns the value of attribute content_type

Returns:

  • (Object)

    the current value of content_type



17
18
19
# File 'app/services/heat_loss/chart_exporter.rb', line 17

def content_type
  @content_type
end

#errorObject (readonly)

Returns the value of attribute error

Returns:

  • (Object)

    the current value of error



17
18
19
# File 'app/services/heat_loss/chart_exporter.rb', line 17

def error
  @error
end

#image_dataObject (readonly)

Returns the value of attribute image_data

Returns:

  • (Object)

    the current value of image_data



17
18
19
# File 'app/services/heat_loss/chart_exporter.rb', line 17

def image_data
  @image_data
end

#successObject (readonly)

Returns the value of attribute success

Returns:

  • (Object)

    the current value of success



17
18
19
# File 'app/services/heat_loss/chart_exporter.rb', line 17

def success
  @success
end