com.TwentyCodes.android.SkyHook
Class SkyHook

java.lang.Object
  extended by com.TwentyCodes.android.SkyHook.SkyHook

public class SkyHook
extends Object

this calls will be used to create skyhook object that uses an listener interface to interact with the rest of location ringer

Author:
ricky barrette

Field Summary
static int DONE_MESSAGE
           
static int ERROR_MESSAGE
           
static int LOCATION_MESSAGE
           
static String REALM
           
static String TAG
           
static String USERNAME
           
static String USERNAME_FOR_TESTING
           
 
Constructor Summary
SkyHook(Context context)
          Constructors a new skyhook object
SkyHook(Context context, long period)
          Constructors a new skyhook object
 
Method Summary
 void getLoctaion()
          request current user location, note that the listeners onLocationChanged() will be call multiple times.
 void getUpdates()
          Attempts to register the the listener for periodic updates
 void removeUpdates()
          Removes any current registration for location updates of the current activity with the given LocationListener.
 void setLocationListener(XPSLocationListener listener)
          Used for receiving notifications from SkyHook when the location has changed.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TAG

public static final String TAG
See Also:
Constant Field Values

USERNAME

public static final String USERNAME
See Also:
Constant Field Values

USERNAME_FOR_TESTING

public static final String USERNAME_FOR_TESTING
See Also:
Constant Field Values

REALM

public static final String REALM
See Also:
Constant Field Values

LOCATION_MESSAGE

public static final int LOCATION_MESSAGE
See Also:
Constant Field Values

ERROR_MESSAGE

public static final int ERROR_MESSAGE
See Also:
Constant Field Values

DONE_MESSAGE

public static final int DONE_MESSAGE
See Also:
Constant Field Values
Constructor Detail

SkyHook

public SkyHook(Context context)
Constructors a new skyhook object

Parameters:
context -

SkyHook

public SkyHook(Context context,
               long period)
Constructors a new skyhook object

Parameters:
context -
period - between location updates in milliseconds
Method Detail

getLoctaion

public void getLoctaion()
request current user location, note that the listeners onLocationChanged() will be call multiple times. updates will stop once an accurate location is determined.


getUpdates

public void getUpdates()
Attempts to register the the listener for periodic updates


removeUpdates

public void removeUpdates()
Removes any current registration for location updates of the current activity with the given LocationListener. Following this call, updates will no longer occur for this listener.

Parameters:
listener -

setLocationListener

public void setLocationListener(XPSLocationListener listener)
Used for receiving notifications from SkyHook when the location has changed. These methods are called if the LocationListener has been registered with the location manager service using the method.

Parameters:
listener -