Class: Coconut::Job

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

Class Method Summary collapse

Class Method Details

.create(options = {}) ⇒ Object



119
120
121
# File 'lib/coconutrb.rb', line 119

def self.create(options={})
  Coconut.submit(Coconut.config(options), options[:api_key])
end

.get(jid, api_key = nil) ⇒ Object



123
124
125
# File 'lib/coconutrb.rb', line 123

def self.get(jid, api_key=nil)
  Coconut.get("/v1/jobs/#{jid}", api_key)
end

.get_all_metadata(jid, api_key = nil) ⇒ Object



127
128
129
# File 'lib/coconutrb.rb', line 127

def self.(jid, api_key=nil)
  Coconut.get("/v1/metadata/jobs/#{jid}", api_key)
end

.get_metadata_for(jid, source_or_output, api_key = nil) ⇒ Object



131
132
133
# File 'lib/coconutrb.rb', line 131

def self.(jid, source_or_output, api_key=nil)
  Coconut.get("/v1/metadata/jobs/#{jid}/#{source_or_output}", api_key)
end