Module: IntegerInheritance::Extension::ClassMethods
- Defined in:
- lib/integer-inheritance/extension.rb
Instance Method Summary collapse
- #find_sti_class(type) ⇒ Object
- #sti_name ⇒ Object (also: #inheritance_type)
Instance Method Details
#find_sti_class(type) ⇒ Object
30 31 32 33 |
# File 'lib/integer-inheritance/extension.rb', line 30 def find_sti_class(type) lookup = inheritance_mapping[type.to_i] lookup ? super(lookup) : super end |
#sti_name ⇒ Object Also known as: inheritance_type
23 24 25 |
# File 'lib/integer-inheritance/extension.rb', line 23 def sti_name inheritance_mapping.key(super) end |