/** * Check for equality with the Object in question * * @param proj object to check * @return true if they are equal */ public boolean equals(Object proj) { if ( !(proj instanceof FlatEarth)) { return false; } FlatEarth oo = (FlatEarth) proj; return ((this.getOriginLat() == oo.getOriginLat()) && (this.getOriginLon() == oo.getOriginLon()) && (this.rotAngle == oo.rotAngle)); }
/** * Clone this projection. * * @return Clone of this */ public Object clone() { FlatEarth cl = (FlatEarth) super.clone(); cl.origin = new LatLonPointImpl(getOriginLat(), getOriginLon()); return cl; }
/** copy constructor - avoid clone !! */ public ProjectionImpl constructCopy() { return new FlatEarth( getOriginLat(), getOriginLon(), getRotationAngle()); }
/** * origin */ //private LatLonPointImpl origin; // why are we keeping this? @Override public ProjectionImpl constructCopy() { ProjectionImpl result = new FlatEarth(getOriginLat(), getOriginLon(), getRotationAngle()); result.setDefaultMapArea(defaultMapArea); result.setName(name); return result; }
/** * origin */ //private LatLonPointImpl origin; // why are we keeping this? @Override public ProjectionImpl constructCopy() { ProjectionImpl result = new FlatEarth(getOriginLat(), getOriginLon(), getRotationAngle()); result.setDefaultMapArea(defaultMapArea); result.setName(name); return result; }
/** * origin */ //private LatLonPointImpl origin; // why are we keeping this? @Override public ProjectionImpl constructCopy() { ProjectionImpl result = new FlatEarth(getOriginLat(), getOriginLon(), getRotationAngle()); result.setDefaultMapArea(defaultMapArea); result.setName(name); return result; }