module PoiseDerived::DSL
Public Class Methods
install()
click to toggle source
Install the DSL
addition globally.
@return [void]
# File lib/poise_derived/dsl.rb, line 31 def self.install Chef::Log.debug('[poise-derived] Installing node DSL') Chef::Node.prepend(self) alias_method(:lazy, :_lazy_attribute) end
uninstall()
click to toggle source
Disable the DSL
extension so `node.lazy` will no longer work.
@return [void]
# File lib/poise_derived/dsl.rb, line 40 def self.uninstall Chef::Log.debug('[poise-derived] Uninstalling node DSL') remove_method(:lazy) end
Public Instance Methods
_lazy_attribute(str=nil, &block)
click to toggle source
# File lib/poise_derived/dsl.rb, line 24 def _lazy_attribute(str=nil, &block) PoiseDerived::LazyAttribute.new(self, str, &block) end