Code example for Location

Methods: getLatitudegetLongitude

0
		return new Point(aGP.getLongitudeE6(), aGP.getLatitudeE6());
	} 
 
	/** Converts an {@link Location} to an {@link Point}. */ 
	public static Point location2Point(final Location aLocation){
		return new Point((int) (aLocation.getLongitude() * 1E6),
				(int) (aLocation.getLatitude() * 1E6));
	} 
 
	/** Converts an {@link Location} to a {@link GeoPoint}. */ 
	public static GeoPoint location2GeoPoint(final Location aLocation){
		return new GeoPoint((int) (aLocation.getLatitude() * 1E6),
				(int) (aLocation.getLongitude() * 1E6));
	} 
 
	/** 
	 * Calculates the bearing of the two Locations supplied and returns the 
	 * Angle in the following (GPS-likely) manner: <br /> 
	 * <code>N:0°, E:90°, S:180°, W:270°</code> 
	 */ 
Connect your IDE to all the code out there  Get Codota for Java