Class: ExtensisPortfolio::Job

Inherits:
Object
  • Object
show all
Defined in:
lib/extensis_portfolio/job.rb

Instance Method Summary collapse

Constructor Details

#initialize(source_image, tasks) ⇒ Job

Creates a new instance of ExtensisPortfolio::Job

Parameters:

  • source_image (String)

    source image, either ‘original` or `preview`

  • tasks (Array)

    array of tasks



7
8
9
10
# File 'lib/extensis_portfolio/job.rb', line 7

def initialize(source_image, tasks)
  @source_image = source_image
  @tasks = tasks.map(&:to_hash)
end

Instance Method Details

#to_hashHash

Returns a Hash for use in a soap request

Returns:

  • (Hash)


15
16
17
18
19
20
# File 'lib/extensis_portfolio/job.rb', line 15

def to_hash
  {
    source_image: @source_image,
    tasks: @tasks
  }
end