Class: PureData::PdObject
- Inherits:
-
Object
- Object
- PureData::PdObject
- Defined in:
- lib/puredata/pdobject/pdobject.rb
Instance Attribute Summary collapse
-
#canvas ⇒ Object
readonly
Returns the value of attribute canvas.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#pdobjid ⇒ Object
readonly
Returns the value of attribute pdobjid.
Instance Method Summary collapse
- #<<(other) ⇒ Object
- #>>(other) ⇒ Object
-
#initialize(pd, canvas, pdobjid, name, *args) ⇒ PdObject
constructor
A new instance of PdObject.
- #inlet(idx = 0) ⇒ Object
- #inlet_pair ⇒ Object
- #outlet(idx = 0) ⇒ Object
- #outlet_pair ⇒ Object
Constructor Details
#initialize(pd, canvas, pdobjid, name, *args) ⇒ PdObject
Returns a new instance of PdObject.
22 23 24 25 26 27 28 |
# File 'lib/puredata/pdobject/pdobject.rb', line 22 def initialize(pd, canvas, pdobjid, name, *args) @pd = pd @canvas = canvas @pdobjid = pdobjid @name = name @args = args end |
Instance Attribute Details
#canvas ⇒ Object (readonly)
Returns the value of attribute canvas.
29 30 31 |
# File 'lib/puredata/pdobject/pdobject.rb', line 29 def canvas @canvas end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
29 30 31 |
# File 'lib/puredata/pdobject/pdobject.rb', line 29 def name @name end |
#pdobjid ⇒ Object (readonly)
Returns the value of attribute pdobjid.
29 30 31 |
# File 'lib/puredata/pdobject/pdobject.rb', line 29 def pdobjid @pdobjid end |
Instance Method Details
#<<(other) ⇒ Object
47 48 49 |
# File 'lib/puredata/pdobject/pdobject.rb', line 47 def <<(other) self.inlet << other end |
#>>(other) ⇒ Object
51 52 53 |
# File 'lib/puredata/pdobject/pdobject.rb', line 51 def >>(other) self.outlet >> other end |
#inlet(idx = 0) ⇒ Object
31 32 33 |
# File 'lib/puredata/pdobject/pdobject.rb', line 31 def inlet(idx=0) Inlet.new(self, idx) end |
#inlet_pair ⇒ Object
35 36 37 |
# File 'lib/puredata/pdobject/pdobject.rb', line 35 def inlet_pair [self, 0] end |
#outlet(idx = 0) ⇒ Object
39 40 41 |
# File 'lib/puredata/pdobject/pdobject.rb', line 39 def outlet(idx=0) Outlet.new(self, idx) end |
#outlet_pair ⇒ Object
43 44 45 |
# File 'lib/puredata/pdobject/pdobject.rb', line 43 def outlet_pair [self, 0] end |