Class: SolrMakr::SolrAPI::ClusterResponse
- Defined in:
- lib/solr_makr/solr_api/cluster_response.rb
Instance Attribute Summary collapse
Attributes inherited from Response
#failure, #raw_response, #response_header
Instance Method Summary collapse
Methods inherited from Response
#array, #dig, #initialize, #success?, #to_s
Constructor Details
This class inherits a constructor from SolrMakr::SolrAPI::Response
Instance Attribute Details
#collections ⇒ ActiveSupport::HashWithIndifferentAccess (readonly)
6 7 8 |
# File 'lib/solr_makr/solr_api/cluster_response.rb', line 6 attr_lazy_reader :collections do dig(:cluster, :collections) || {}.with_indifferent_access end |
Instance Method Details
#each_collection ⇒ Object
10 11 12 13 14 15 16 17 18 |
# File 'lib/solr_makr/solr_api/cluster_response.rb', line 10 def each_collection return enum_for(__method__) unless block_given? collections = dig(:cluster, :collections) collections.each do |(key, info)| yield key, info end end |