Module: NCore::Identity::ClassMethods
- Defined in:
- lib/ncore/identity.rb
Instance Method Summary collapse
- #attrib_name ⇒ Object (also: #json_root)
- #class_name ⇒ Object
- #module_name ⇒ Object
Instance Method Details
#attrib_name ⇒ Object Also known as: json_root
14 15 16 |
# File 'lib/ncore/identity.rb', line 14 def attrib_name class_name.underscore end |
#class_name ⇒ Object
6 7 8 |
# File 'lib/ncore/identity.rb', line 6 def class_name self.name.split('::')[-1] end |
#module_name ⇒ Object
10 11 12 |
# File 'lib/ncore/identity.rb', line 10 def module_name self.name.split('::')[0..-2].join('::') end |