Module: Ribbon::Intercom::Packageable::Mixin
- Included in:
- Ribbon::Intercom::Packageable
- Defined in:
- lib/ribbon/intercom/packageable/mixin.rb
Defined Under Namespace
Modules: ClassMethods
Class Method Summary collapse
Instance Method Summary collapse
-
#package_data ⇒ Object
Returns the package data for the instance as a hash.
Class Method Details
.included(base) ⇒ Object
7 8 9 |
# File 'lib/ribbon/intercom/packageable/mixin.rb', line 7 def included(base) base.extend(ClassMethods) end |
Instance Method Details
#package_data ⇒ Object
Returns the package data for the instance as a hash.
24 25 26 |
# File 'lib/ribbon/intercom/packageable/mixin.rb', line 24 def package_data self.class._package_with_methods.map { |meth| [meth, public_send(meth)] }.to_h end |