Class: SuperclassBase
- Inherits:
-
BinData::Record
- Object
- BinData::Record
- SuperclassBase
- Defined in:
- lib/helpers/superclass_base.rb
Instance Attribute Summary collapse
-
#type_str ⇒ Object
readonly
Returns the value of attribute type_str.
Instance Method Summary collapse
Instance Attribute Details
#type_str ⇒ Object (readonly)
Returns the value of attribute type_str.
4 5 6 |
# File 'lib/helpers/superclass_base.rb', line 4 def type_str @type_str end |
Instance Method Details
#body_length ⇒ Object
18 19 20 |
# File 'lib/helpers/superclass_base.rb', line 18 def body_length 0 end |
#initialize_instance ⇒ Object
8 9 10 11 12 13 14 15 16 |
# File 'lib/helpers/superclass_base.rb', line 8 def initialize_instance super if self.class.name[2..7] == 'Action' name = self.class.name[8..-1] else name = self.class.name[2..-1] end @type_str = name.gsub(/([A-Z])/, '_\1')[1..-1].downcase end |