Module: Puppet::Util::Cacher
- Included in:
- Node::Environment
- Defined in:
- lib/vendor/puppet/util/cacher.rb
Defined Under Namespace
Modules: ClassMethods, InstanceMethods
Class Method Summary collapse
-
.extended(other) ⇒ Object
Our module has been extended in a class; we can only add the Instance methods, which become class methods in the class.
-
.included(other) ⇒ Object
Our module has been included in a class, which means the class gets the class methods and all of its instances get the instance methods.
Class Method Details
.extended(other) ⇒ Object
Our module has been extended in a class; we can only add the Instance methods, which become class methods in the class.
6 7 8 9 10 11 |
# File 'lib/vendor/puppet/util/cacher.rb', line 6 def self.extended(other) class << other extend ClassMethods include InstanceMethods end end |
.included(other) ⇒ Object
Our module has been included in a class, which means the class gets the class methods and all of its instances get the instance methods.
15 16 17 18 |
# File 'lib/vendor/puppet/util/cacher.rb', line 15 def self.included(other) other.extend(ClassMethods) other.send(:include, InstanceMethods) end |