com.stackmob.sdkapi
Class SMNear

java.lang.Object
  extended by com.stackmob.sdkapi.SMCondition
      extended by com.stackmob.sdkapi.SMNear

public class SMNear
extends SMCondition

A "near" query. A near query will add the distance from the search center to query results, and will automatically sort query results by their distance from the search center.


Constructor Summary
SMNear(String field, double lat, double lon, double dist)
          Create a new SMNear query
SMNear(String field, SMDouble lat, SMDouble lon, SMDouble dist)
          Create a new SMNear query
 
Method Summary
 SMDouble getDist()
           
 String getField()
           
 SMDouble getLat()
           
 SMDouble getLon()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SMNear

public SMNear(String field,
              SMDouble lat,
              SMDouble lon,
              SMDouble dist)
Create a new SMNear query

Parameters:
field - the geoField to query
lat - the latitude of the location to search
lon - the longitude of the location to search
dist - the distance, in radians, to search, used to limit search results

SMNear

public SMNear(String field,
              double lat,
              double lon,
              double dist)
Create a new SMNear query

Parameters:
field - the geoField to query
lat - the latitude of the location to search
lon - the longitude of the location to search
dist - the distance, in radians, to search, used to limit search results
Method Detail

getField

public String getField()

getLat

public SMDouble getLat()

getLon

public SMDouble getLon()

getDist

public SMDouble getDist()

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2012 StackMob. All Rights Reserved.