Class: Arcenciel::Surfaces::Controller::DSL

Inherits:
DSLBase
  • Object
show all
Defined in:
lib/arcenciel/surfaces.rb

Instance Attribute Summary

Attributes inherited from DSLBase

#opts

Instance Method Summary collapse

Methods inherited from DSLBase

eval, #initialize

Constructor Details

This class inherits a constructor from Arcenciel::DSLBase

Instance Method Details

#knob(&blk) ⇒ Object

Add a new logical knob (encoder) to the controller.



17
18
19
20
# File 'lib/arcenciel/surfaces.rb', line 17

def knob(&blk)
  opts[:knobs] ||= []
  opts[:knobs] << Knob.from_dsl(&blk)
end

#name(name) ⇒ Object

Set the name of this logical controller.



12
13
14
# File 'lib/arcenciel/surfaces.rb', line 12

def name(name)
  opts[:name] = name
end