Class: AsciiBinderGabrielRH::Site
- Inherits:
-
Object
- Object
- AsciiBinderGabrielRH::Site
- Defined in:
- lib/ascii_binder_gabriel_rh/site.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#url ⇒ Object
readonly
Returns the value of attribute url.
Instance Method Summary collapse
- #errors ⇒ Object
-
#initialize(distro_config) ⇒ Site
constructor
A new instance of Site.
- #is_valid? ⇒ Boolean
Constructor Details
#initialize(distro_config) ⇒ Site
Returns a new instance of Site.
9 10 11 12 13 |
# File 'lib/ascii_binder_gabriel_rh/site.rb', line 9 def initialize(distro_config) @id = distro_config['site'] @name = distro_config['site_name'] @url = distro_config['site_url'] end |
Instance Attribute Details
#id ⇒ Object (readonly)
Returns the value of attribute id.
7 8 9 |
# File 'lib/ascii_binder_gabriel_rh/site.rb', line 7 def id @id end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
7 8 9 |
# File 'lib/ascii_binder_gabriel_rh/site.rb', line 7 def name @name end |
#url ⇒ Object (readonly)
Returns the value of attribute url.
7 8 9 |
# File 'lib/ascii_binder_gabriel_rh/site.rb', line 7 def url @url end |
Instance Method Details
#errors ⇒ Object
19 20 21 |
# File 'lib/ascii_binder_gabriel_rh/site.rb', line 19 def errors validate(true) end |
#is_valid? ⇒ Boolean
15 16 17 |
# File 'lib/ascii_binder_gabriel_rh/site.rb', line 15 def is_valid? validate end |