Module: ActiveFedora::QueryResultBuilder
- Defined in:
- lib/active_fedora/query_result_builder.rb
Constant Summary collapse
- HAS_MODEL_SOLR_FIELD =
ActiveFedora.index_field_mapper.solr_name("has_model", :symbol).freeze
Class Method Summary collapse
- .lazy_reify_solr_results(solr_results, opts = {}) ⇒ Object
- .reify_solr_results(solr_results, opts = {}) ⇒ Object
Class Method Details
.lazy_reify_solr_results(solr_results, opts = {}) ⇒ Object
3 4 5 6 7 8 9 |
# File 'lib/active_fedora/query_result_builder.rb', line 3 def self.lazy_reify_solr_results(solr_results, opts = {}) return to_enum(:lazy_reify_solr_results, solr_results, opts) unless block_given? solr_results.each do |hit| yield ActiveFedora::SolrHit.for(hit).reify(opts) end end |
.reify_solr_results(solr_results, opts = {}) ⇒ Object
11 12 13 |
# File 'lib/active_fedora/query_result_builder.rb', line 11 def self.reify_solr_results(solr_results, opts = {}) lazy_reify_solr_results(solr_results, opts).to_a end |