Class: SimpleEnum::Accessors::IgnoreAccessor

Inherits:
Accessor
  • Object
show all
Defined in:
lib/simple_enum/accessors/ignore_accessor.rb

Instance Attribute Summary

Attributes inherited from Accessor

#enum, #name, #source

Instance Method Summary collapse

Methods inherited from Accessor

#changed?, #initialize, #prefix, #read, #scope, #selected?, #to_s, #was

Constructor Details

This class inherits a constructor from SimpleEnum::Accessors::Accessor

Instance Method Details

#write(object, key) ⇒ Object


6
7
8
# File 'lib/simple_enum/accessors/ignore_accessor.rb', line 6

def write(object, key)
  super if !key || enum.include?(key)
end