Class: MOSAIK::Graph::Edge
- Inherits:
-
Object
- Object
- MOSAIK::Graph::Edge
- Extended by:
- T::Sig
- Defined in:
- lib/mosaik/graph/edge.rb
Overview
Edge in the graph
Instance Attribute Summary collapse
-
#attributes ⇒ Object
readonly
Returns the value of attribute attributes.
Instance Method Summary collapse
-
#initialize(attributes = T.let({}, Attributes)) ⇒ Edge
constructor
A new instance of Edge.
- #inspect ⇒ Object
Constructor Details
#initialize(attributes = T.let({}, Attributes)) ⇒ Edge
Returns a new instance of Edge.
17 18 19 |
# File 'lib/mosaik/graph/edge.rb', line 17 def initialize(attributes = T.let({}, Attributes)) @attributes = attributes end |
Instance Attribute Details
#attributes ⇒ Object (readonly)
Returns the value of attribute attributes.
14 15 16 |
# File 'lib/mosaik/graph/edge.rb', line 14 def attributes @attributes end |
Instance Method Details
#inspect ⇒ Object
22 23 24 |
# File 'lib/mosaik/graph/edge.rb', line 22 def inspect "#<#{self.class.name} attributes=#{attributes.map { |k, v| "#{k}: #{v}" }.join(',')}>" end |