Exception: SmartEnum::EnumLocked

Inherits:
StandardError
  • Object
show all
Defined in:
lib/smart_enum.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(klass) ⇒ EnumLocked

Returns a new instance of EnumLocked.



164
165
166
167
# File 'lib/smart_enum.rb', line 164

def initialize(klass)
  @type = klass
  super("#{klass} has been locked and can not be written to")
end

Instance Attribute Details

#typeObject (readonly)

Returns the value of attribute type.



162
163
164
# File 'lib/smart_enum.rb', line 162

def type
  @type
end