Class: DMap::Fields

Inherits:
Object
  • Object
show all
Defined in:
lib/dmap/core.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#listObject

Returns the value of attribute list.



26
27
28
# File 'lib/dmap/core.rb', line 26

def list
  @list
end

Class Method Details

.add(field, property = nil) ⇒ Object



32
33
34
# File 'lib/dmap/core.rb', line 32

def self.add(field, property=nil)
  list.store field, property unless property.nil?
end

.listObject



28
29
30
# File 'lib/dmap/core.rb', line 28

def self.list
  @list ||= Hash[]
end