class Blacklight::Solr::Response::Group

Attributes

group[R]
key[R]
response[R]

Public Class Methods

new(key, group, response) click to toggle source
# File lib/blacklight/solr/response/group.rb, line 8
def initialize key, group, response
  @key = key
  @group = group
  @response = response
end

Public Instance Methods

doclist() click to toggle source
# File lib/blacklight/solr/response/group.rb, line 14
def doclist
  group[:doclist]
end
docs() click to toggle source
# File lib/blacklight/solr/response/group.rb, line 27
def docs
  doclist[:docs].map { |doc| SolrDocument.new(doc, response) }
end
field() click to toggle source
# File lib/blacklight/solr/response/group.rb, line 31
def field
  response.group_field
end
start() click to toggle source
# File lib/blacklight/solr/response/group.rb, line 23
def start
  doclist[:start].to_s.to_i
end
total() click to toggle source

short cut to response

# File lib/blacklight/solr/response/group.rb, line 19
def total
  doclist[:numFound].to_s.to_i
end