Sha256: 342249816a8f7729ed0a89553198217c6e7ebd3ff4e729c1302f602292cf5e22
Contents?: true
Size: 634 Bytes
Versions: 2
Compression:
Stored size: 634 Bytes
Contents
# This is the module that will be prepended to the base (target) class where `include SuperCallbacks` # have been called. This will be always a new instance of a Module, and will not be a permanent # Module. This is important because, this module-instance is used by SuperCallbacks to define # the methods whenever `before` or `after` is called. These defined methods here will then have a # `super` inside it, which then will also call the "real" method defined in the target class. module SuperCallbacks class Prepended < Module attr_accessor :base def initialize(base) @base = base end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
super_callbacks-1.3.1 | lib/super_callbacks/prepended.rb |
super_callbacks-1.3.0 | lib/super_callbacks/prepended.rb |