Class: Indexes::Definitions
- Inherits:
-
Object
- Object
- Indexes::Definitions
- Defined in:
- lib/indexes/definitions.rb
Instance Method Summary collapse
Instance Method Details
#add(*args) ⇒ Object
4 5 6 7 |
# File 'lib/indexes/definitions.rb', line 4 def add(*args) index = Index.new(*args) registry[index.name] = index end |
#each(&block) ⇒ Object
14 15 16 |
# File 'lib/indexes/definitions.rb', line 14 def each(&block) registry.values.sort.each &block end |
#find(name) ⇒ Object Also known as: []
9 10 11 |
# File 'lib/indexes/definitions.rb', line 9 def find(name) registry[name] end |