Module: Solrbee
- Defined in:
- lib/solrbee.rb,
lib/solrbee/version.rb
Constant Summary collapse
- VERSION =
"0.3.0"
Class Method Summary collapse
-
.config ⇒ ROM::Configuration
Configuration.
- .container ⇒ Object
-
.documents ⇒ Solrbee::Documents
Factory method.
-
.gateway ⇒ ROM::Solr::Gateway
Factory method.
- .schema ⇒ Object
Class Method Details
.config ⇒ ROM::Configuration
Returns configuration.
26 27 28 29 30 31 32 33 |
# File 'lib/solrbee.rb', line 26 def self.config @config ||= ROM::Configuration.new(:solr) do |config| config.register_relation( ROM::Solr::SelectRelation, ROM::Solr::SchemaRelation ) end end |
.container ⇒ Object
35 36 37 |
# File 'lib/solrbee.rb', line 35 def self.container ROM.container(config) end |
.documents ⇒ Solrbee::Documents
Factory method
17 18 19 |
# File 'lib/solrbee.rb', line 17 def self.documents container.relations[:search] end |
.gateway ⇒ ROM::Solr::Gateway
Factory method
10 11 12 |
# File 'lib/solrbee.rb', line 10 def self.gateway ROM::Gateway.setup(:solr) end |
.schema ⇒ Object
21 22 23 |
# File 'lib/solrbee.rb', line 21 def self.schema container.relations[:schema_info] end |