Class: Coiasira::JobData

Inherits:
Hash
  • Object
show all
Defined in:
lib/coiasira/job_data.rb

Instance Method Summary collapse

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(sym, value = nil) ⇒ Object



3
4
5
6
7
8
9
10
# File 'lib/coiasira/job_data.rb', line 3

def method_missing(sym, value=nil)
  sym = sym.to_s
  if sym =~ /^(.*)=$/
    return self[$~[1]] = value
  else
    return self[sym]
  end
end