Class: Tupelo::Client::Worker::Subspace

Inherits:
Object
  • Object
show all
Defined in:
lib/tupelo/client/worker.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(metatuple, worker) ⇒ Subspace

Returns a new instance of Subspace.



59
60
61
62
63
64
65
# File 'lib/tupelo/client/worker.rb', line 59

def initialize metatuple, worker
  @metatuple = metatuple
  @tag = metatuple["tag"]

  spec = Marshal.load(Marshal.dump(metatuple["template"]))
  @pot = worker.pot_for(spec).optimize!
end

Instance Attribute Details

#tagObject (readonly)

Returns the value of attribute tag.



57
58
59
# File 'lib/tupelo/client/worker.rb', line 57

def tag
  @tag
end

Instance Method Details

#===(tuple) ⇒ Object



67
68
69
# File 'lib/tupelo/client/worker.rb', line 67

def === tuple
  @pot === tuple
end