Class: DataMapper::Types::Enum
- Object
- DataMapper::Types::Enum
Public Visibility
Public Instance Methods Inherited from Object
Public Class Method Details
[]
public
[](*flags)
[View source]
24 25 26
# File 'dm-more/dm-types/lib/dm-types/enum.rb', line 24 def self.[](*flags) new(*flags) end
dump
public
dump(value, property)
[View source]
32 33 34
# File 'dm-more/dm-types/lib/dm-types/enum.rb', line 32 def self.dump(value, property) self.flag_map.invert[value] end
flag_map
public
flag_map=(value)
[View source]
9 10 11
# File 'dm-more/dm-types/lib/dm-types/enum.rb', line 9 def self.flag_map=(value) @flag_map = value end
load
public
load(value, property)
[View source]
28 29 30
# File 'dm-more/dm-types/lib/dm-types/enum.rb', line 28 def self.load(value, property) self.flag_map[value] end