Class: Pictify::BatchRenderResult

Inherits:
Object
  • Object
show all
Defined in:
lib/pictify/types.rb

Overview

Result of submitting an async batch render (+render_batch+).

The job runs asynchronously: poll Client#get_batch_results with the returned batch_id to track progress. Maps { batchId, status, totalItems }.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data) ⇒ BatchRenderResult

Returns a new instance of BatchRenderResult.



114
115
116
117
118
119
120
# File 'lib/pictify/types.rb', line 114

def initialize(data)
  @raw = data
  @batch_id = data["batchId"]
  @status = data["status"]
  @total_items = data["totalItems"]
  @message = data["message"]
end

Instance Attribute Details

#batch_idObject (readonly)

Returns the value of attribute batch_id.



112
113
114
# File 'lib/pictify/types.rb', line 112

def batch_id
  @batch_id
end

#messageObject (readonly)

Returns the value of attribute message.



112
113
114
# File 'lib/pictify/types.rb', line 112

def message
  @message
end

#rawObject (readonly)

Returns the value of attribute raw.



112
113
114
# File 'lib/pictify/types.rb', line 112

def raw
  @raw
end

#statusObject (readonly)

Returns the value of attribute status.



112
113
114
# File 'lib/pictify/types.rb', line 112

def status
  @status
end

#total_itemsObject (readonly)

Returns the value of attribute total_items.



112
113
114
# File 'lib/pictify/types.rb', line 112

def total_items
  @total_items
end