Class: CommandTower::Configuration::Registry::PrincipalCapabilities::CapabilityDefinition
- Inherits:
-
Object
- Object
- CommandTower::Configuration::Registry::PrincipalCapabilities::CapabilityDefinition
- Includes:
- ClassComposer::Generator
- Defined in:
- lib/command_tower/configuration/registry/principal_capabilities/capability_definition.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
Returns the value of attribute id.
-
#owner ⇒ Object
Returns the value of attribute owner.
Instance Method Summary collapse
Instance Attribute Details
#id ⇒ Object
Returns the value of attribute id.
18 19 20 |
# File 'lib/command_tower/configuration/registry/principal_capabilities/capability_definition.rb', line 18 def id @id end |
#owner ⇒ Object
Returns the value of attribute owner.
18 19 20 |
# File 'lib/command_tower/configuration/registry/principal_capabilities/capability_definition.rb', line 18 def owner @owner end |
Instance Method Details
#validate_definition!(name:) ⇒ Object
20 21 22 23 24 25 26 |
# File 'lib/command_tower/configuration/registry/principal_capabilities/capability_definition.rb', line 20 def validate_definition!(name:) self.id = name.to_s self.owner = owner&.to_sym || :host entity = required_entity.to_s.strip entity = name.to_s if entity.empty? self.required_entity = require_segment!(entity, field: "required_entity", name:) end |