Class: Chef::Knife::Scrub::AttributeExtractor::Weird
- Inherits:
-
Base
- Object
- Base
- Chef::Knife::Scrub::AttributeExtractor::Weird
show all
- Defined in:
- lib/chef/knife/scrub/attribute_extractor.rb
Instance Method Summary
collapse
Methods inherited from Base
#initialize
Instance Method Details
#delete(path) ⇒ Object
99
100
101
102
|
# File 'lib/chef/knife/scrub/attribute_extractor.rb', line 99
def delete(path)
base, key = (attributes, path)
base.delete_from_component(base.send(@precedence), key)
end
|
#fetch(path) ⇒ Object
94
95
96
97
|
# File 'lib/chef/knife/scrub/attribute_extractor.rb', line 94
def fetch(path)
base, key = (attributes, path)
base.value_at_current_nesting(base.send(@precedence), key).fetch(key)
end
|
#has_key?(path) ⇒ Boolean
89
90
91
92
|
# File 'lib/chef/knife/scrub/attribute_extractor.rb', line 89
def has_key?(path)
base, key = (attributes, path)
!base.nil? && base.component_has_key?(base.send(@precedence), key)
end
|