class Solr4R::Document
Attributes
result[R]
Public Class Methods
new(result, hash)
click to toggle source
# File lib/solr4r/document.rb 34 def initialize(result, hash) 35 @result, @hash = result, hash 36 37 hash.each { |key, val| 38 define_singleton_method(key) { val } unless respond_to?(key, true) } 39 end
Public Instance Methods
id()
click to toggle source
# File lib/solr4r/document.rb 51 def id 52 fetch('id') 53 end
more_like_this_h(*args, &block)
click to toggle source
# File lib/solr4r/document.rb 55 def more_like_this_h(*args, &block) 56 client.more_like_this_h(id, *args, &block) 57 end
more_like_this_q(*args, &block)
click to toggle source
# File lib/solr4r/document.rb 59 def more_like_this_q(*args, &block) 60 client.more_like_this_q(id, *args, &block) 61 end
Also aliased as: more_like_this
to_hash()
click to toggle source
# File lib/solr4r/document.rb 47 def to_hash 48 @hash 49 end