Class: Deploio::AppRef
- Inherits:
-
Object
- Object
- Deploio::AppRef
- Defined in:
- lib/deploio/app_ref.rb
Instance Attribute Summary collapse
-
#app_name ⇒ Object
readonly
Returns the value of attribute app_name.
-
#project_name ⇒ Object
readonly
Returns the value of attribute project_name.
Instance Method Summary collapse
- #==(other) ⇒ Object
- #full_name ⇒ Object
-
#initialize(input, available_apps: {}) ⇒ AppRef
constructor
The input is given in the format "
- ". - #to_s ⇒ Object
Constructor Details
#initialize(input, available_apps: {}) ⇒ AppRef
The input is given in the format "
11 12 13 14 |
# File 'lib/deploio/app_ref.rb', line 11 def initialize(input, available_apps: {}) @input = input.to_s parse_from_available_apps(available_apps) end |
Instance Attribute Details
#app_name ⇒ Object (readonly)
Returns the value of attribute app_name.
8 9 10 |
# File 'lib/deploio/app_ref.rb', line 8 def app_name @app_name end |
#project_name ⇒ Object (readonly)
Returns the value of attribute project_name.
8 9 10 |
# File 'lib/deploio/app_ref.rb', line 8 def project_name @project_name end |
Instance Method Details
#==(other) ⇒ Object
24 25 26 27 28 |
# File 'lib/deploio/app_ref.rb', line 24 def ==(other) return false unless other.is_a?(AppRef) project_name == other.project_name && app_name == other.app_name end |
#full_name ⇒ Object
16 17 18 |
# File 'lib/deploio/app_ref.rb', line 16 def full_name "#{project_name}-#{app_name}" end |
#to_s ⇒ Object
20 21 22 |
# File 'lib/deploio/app_ref.rb', line 20 def to_s full_name end |