Class: CooCoo::Dot::Graph::Edge
Instance Attribute Summary collapse
-
#nodes ⇒ Object
readonly
Returns the value of attribute nodes.
-
#options ⇒ Object
readonly
Returns the value of attribute options.
Instance Method Summary collapse
- #add_node(node) ⇒ Object
-
#initialize(nodes, options = {}) ⇒ Edge
constructor
A new instance of Edge.
Constructor Details
#initialize(nodes, options = {}) ⇒ Edge
Returns a new instance of Edge.
28 29 30 31 |
# File 'lib/coo-coo/dot.rb', line 28 def initialize(nodes, = {}) @options = @nodes = nodes.dup end |
Instance Attribute Details
#nodes ⇒ Object (readonly)
Returns the value of attribute nodes.
26 27 28 |
# File 'lib/coo-coo/dot.rb', line 26 def nodes @nodes end |
#options ⇒ Object (readonly)
Returns the value of attribute options.
25 26 27 |
# File 'lib/coo-coo/dot.rb', line 25 def @options end |
Instance Method Details
#add_node(node) ⇒ Object
33 34 35 36 |
# File 'lib/coo-coo/dot.rb', line 33 def add_node(node) @nodes << node self end |