Class: Lono::Inspector::Graph::Node
- Inherits:
-
Object
- Object
- Lono::Inspector::Graph::Node
- Defined in:
- lib/lono/inspector/graph.rb
Instance Attribute Summary collapse
-
#children ⇒ Object
Returns the value of attribute children.
-
#depends_on ⇒ Object
Returns the value of attribute depends_on.
-
#name ⇒ Object
Returns the value of attribute name.
-
#resource_type ⇒ Object
Returns the value of attribute resource_type.
Instance Method Summary collapse
- #graph_name ⇒ Object
-
#initialize(name) ⇒ Node
constructor
A new instance of Node.
Constructor Details
#initialize(name) ⇒ Node
Returns a new instance of Node.
113 114 115 116 117 |
# File 'lib/lono/inspector/graph.rb', line 113 def initialize(name) @name = name @children = [] @depends_on = [] end |
Instance Attribute Details
#children ⇒ Object
Returns the value of attribute children.
112 113 114 |
# File 'lib/lono/inspector/graph.rb', line 112 def children @children end |
#depends_on ⇒ Object
Returns the value of attribute depends_on.
112 113 114 |
# File 'lib/lono/inspector/graph.rb', line 112 def depends_on @depends_on end |
#name ⇒ Object
Returns the value of attribute name.
112 113 114 |
# File 'lib/lono/inspector/graph.rb', line 112 def name @name end |
#resource_type ⇒ Object
Returns the value of attribute resource_type.
112 113 114 |
# File 'lib/lono/inspector/graph.rb', line 112 def resource_type @resource_type end |
Instance Method Details
#graph_name ⇒ Object
119 120 121 122 |
# File 'lib/lono/inspector/graph.rb', line 119 def graph_name type = "(#{resource_type})" if resource_type [name, type].compact.join("\n") end |