Class: Staypuft::Deployment::AbstractParamScope
- Inherits:
-
Object
- Object
- Staypuft::Deployment::AbstractParamScope
- Extended by:
- ActiveModel::Callbacks, AttributeParamStorage
- Includes:
- ActiveModel::Validations
- Defined in:
- app/models/staypuft/deployment/abstract_param_scope.rb
Direct Known Subclasses
CephService, CinderService, GlanceService, NeutronService, NovaService, Passwords
Instance Attribute Summary collapse
-
#deployment ⇒ Object
readonly
Returns the value of attribute deployment.
Class Method Summary collapse
Instance Method Summary collapse
- #attributes=(attr_list) ⇒ Object
- #hostgroup ⇒ Object
-
#initialize(deployment) ⇒ AbstractParamScope
constructor
A new instance of AbstractParamScope.
-
#marked_for_destruction? ⇒ Boolean
compatibility with validates_associated.
Methods included from AttributeParamStorage
param_attr, param_attr_array, param_scope
Constructor Details
#initialize(deployment) ⇒ AbstractParamScope
Returns a new instance of AbstractParamScope.
14 15 16 |
# File 'app/models/staypuft/deployment/abstract_param_scope.rb', line 14 def initialize(deployment) @deployment = deployment end |
Instance Attribute Details
#deployment ⇒ Object (readonly)
Returns the value of attribute deployment.
12 13 14 |
# File 'app/models/staypuft/deployment/abstract_param_scope.rb', line 12 def deployment @deployment end |
Class Method Details
.param_scope ⇒ Object
8 9 10 |
# File 'app/models/staypuft/deployment/abstract_param_scope.rb', line 8 def self.param_scope raise NotImplementedError end |
Instance Method Details
#attributes=(attr_list) ⇒ Object
27 28 29 |
# File 'app/models/staypuft/deployment/abstract_param_scope.rb', line 27 def attributes=(attr_list) attr_list.each { |attr, value| send "#{attr}=", value } unless attr_list.nil? end |
#hostgroup ⇒ Object
18 19 20 |
# File 'app/models/staypuft/deployment/abstract_param_scope.rb', line 18 def hostgroup deployment.hostgroup end |
#marked_for_destruction? ⇒ Boolean
compatibility with validates_associated
23 24 25 |
# File 'app/models/staypuft/deployment/abstract_param_scope.rb', line 23 def marked_for_destruction? false end |