Class: Hiiro::App
- Inherits:
-
Object
- Object
- Hiiro::App
- Defined in:
- lib/hiiro/tasks.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#relative_path ⇒ Object
readonly
Returns the value of attribute relative_path.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(name:, path:) ⇒ App
constructor
A new instance of App.
- #resolve(tree_root) ⇒ Object
- #to_s ⇒ Object
Constructor Details
#initialize(name:, path:) ⇒ App
Returns a new instance of App.
1649 1650 1651 1652 |
# File 'lib/hiiro/tasks.rb', line 1649 def initialize(name:, path:) @name = name @relative_path = path end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name.
1647 1648 1649 |
# File 'lib/hiiro/tasks.rb', line 1647 def name @name end |
#relative_path ⇒ Object (readonly)
Returns the value of attribute relative_path.
1647 1648 1649 |
# File 'lib/hiiro/tasks.rb', line 1647 def relative_path @relative_path end |
Instance Method Details
#==(other) ⇒ Object
1658 1659 1660 |
# File 'lib/hiiro/tasks.rb', line 1658 def ==(other) other.is_a?(App) && name == other.name end |
#resolve(tree_root) ⇒ Object
1654 1655 1656 |
# File 'lib/hiiro/tasks.rb', line 1654 def resolve(tree_root) File.join(tree_root, relative_path) end |
#to_s ⇒ Object
1662 1663 1664 |
# File 'lib/hiiro/tasks.rb', line 1662 def to_s name end |