Class: MarkLogic::Queries::BoostQuery

Inherits:
BaseQuery
  • Object
show all
Defined in:
lib/marklogic/queries/boost_query.rb

Instance Method Summary collapse

Methods inherited from BaseQuery

#add_sub_query, #query_value

Constructor Details

#initialize(matching_query, boosting_query) ⇒ BoostQuery

Returns a new instance of BoostQuery.



4
5
6
7
# File 'lib/marklogic/queries/boost_query.rb', line 4

def initialize(matching_query, boosting_query)
  @matching_query = matching_query
  @boosting_query = boosting_query
end

Instance Method Details

#to_xqyObject



9
10
11
# File 'lib/marklogic/queries/boost_query.rb', line 9

def to_xqy
  %Q{cts:boost-query(#{@matching_query.to_xqy},#{@boosting_query.to_xqy})}
end