Class: Couchbase::Cluster::SearchSort

Inherits:
Object
  • Object
show all
Defined in:
lib/couchbase/search_options.rb,
/Users/sergey.auseyau/code/couchbase-ruby-client/lib/couchbase/search_options.rb
more...

Defined Under Namespace

Classes: SearchSortField, SearchSortGeoDistance, SearchSortId, SearchSortScore

Class Method Summary collapse

Class Method Details

.field(name) {|| ... } ⇒ SearchSortField

Parameters:

  • name (String)

    field name

Yield Parameters:

Returns:

[View source]

1001
1002
1003
# File 'lib/couchbase/search_options.rb', line 1001

def self.field(name, &block)
  SearchSortField.new(name, &block)
end

.geo_distance(name, longitude, latitude) {|| ... } ⇒ SearchSortGeoDistance

Parameters:

  • name (String)

    field name

  • longitude (Float)
  • latitude (Float)

Yield Parameters:

Returns:

[View source]

1010
1011
1012
# File 'lib/couchbase/search_options.rb', line 1010

def self.geo_distance(name, longitude, latitude, &block)
  SearchSortGeoDistance.new(name, longitude, latitude, &block)
end

.id {|| ... } ⇒ SearchSortScore

Yield Parameters:

Returns:

[View source]

994
995
996
# File 'lib/couchbase/search_options.rb', line 994

def self.id(&block)
  SearchSortId.new(&block)
end

.score {|| ... } ⇒ SearchSortScore

Yield Parameters:

Returns:

[View source]

988
989
990
# File 'lib/couchbase/search_options.rb', line 988

def self.score(&block)
  SearchSortScore.new(&block)
end