All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.conveyal.gtfs.validator.service.ProjectedCoordinate Maven / Gradle / Ivy

Go to download

A library to load and index GTFS feeds of arbitrary size using disk-backed storage

There is a newer version: 6.2.0
Show newest version
package com.conveyal.gtfs.validator.service;

import org.locationtech.jts.geom.Coordinate;
import org.opengis.referencing.operation.MathTransform;

public class ProjectedCoordinate extends Coordinate {

  private static final long serialVersionUID = 2905131060296578237L;

  final private MathTransform transform;
  final private Coordinate refLatLon;

  public ProjectedCoordinate(MathTransform mathTransform,
    Coordinate to, Coordinate refLatLon) {
    this.transform = mathTransform;
    this.x = to.x;
    this.y = to.y;
    this.refLatLon = refLatLon;
  }

  public String epsgCode() {
    final String epsgCode =
        "EPSG:" + GeoUtils.getEPSGCodefromUTS(refLatLon);
    return epsgCode;
  }

  public Coordinate getReferenceLatLon() {
    return refLatLon;
  }

  public MathTransform getTransform() {
    return transform;
  }
  
  public double getX()
  {
	  return this.x;
  }
  
  public double getY()
  {
	  return this.y;
  }


}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy