Newer
Older
MapPush / src / Map.java
public class Map {
	private D d;
	private B b;
	private C c;
	private A a;
	private Presenter presenter;
	
	public Map() {
		this.d = new D();
		this.b = new B(d);
		this.c = new C();
		this.a = new A(c);
	}
	public double getMapLongitude() {
		return d.getValue();
	}
	public double getLongitude() {
		return b.getValue();
	}
	public void updateGPS(double lat2, double long2) {
        this.presenter.updateGPS(lat2, long2);
    }
	public double getMapLatitude() {
		return c.getValue();
	}
	public double getLatitude() {
		return a.getValue();
	}
}


//import java.util.*;
//
//public class Map {
//	private MapLongitude mapLongitude;
//	private Longitude longitude;
//	private MapLatitude mapLatitude;
//	private Latitude latitude;
//	public Map() {
//		this.mapLongitude = new MapLongitude();
//		this.longitude = new Longitude(mapLongitude);
//		this.mapLatitude = new MapLatitude();
//		this.latitude = new Latitude(mapLatitude);
//	}
//	public double getMapLongitude() {
//		return mapLongitude.getValue();
//	}
//	public double getLongitude() {
//		return longitude.getValue();
//	}
//	public void updateGPS(double lat2, double long2) {
//		this.longitude.updateGPS(lat2, long2);
//		this.latitude.updateGPS(lat2, long2);
//	}
//	public double getMapLatitude() {
//		return mapLatitude.getValue();
//	}
//	public double getLatitude() {
//		return latitude.getValue();
//	}
//}