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

com.mapbox.geojson.shifter.CoordinateShifter Maven / Gradle / Ivy

There is a newer version: 5.9.0-alpha.1
Show newest version
package com.mapbox.geojson.shifter;

import com.mapbox.geojson.Point;

import java.util.List;

/**
 * ShifterManager allows the movement of all Point objects according to a custom algorithm.
 * Once set, it will be applied to all Point objects created through this method.
 *
 * @since 4.2.0
 */
public interface CoordinateShifter {

  /**
   * Shifted coordinate values according to its algorithm.
   *
   * @param lon unshifted longitude
   * @param lat unshifted latitude
   * @return shifted longitude, shifted latitude in the form of a List of Double values
   * @since 4.2.0
   */
  List shiftLonLat(double lon, double lat);

  /**
   * Shifted coordinate values according to its algorithm.
   *
   * @param lon unshifted longitude
   * @param lat unshifted latitude
   * @param altitude  unshifted altitude
   * @return shifted longitude, shifted latitude, shifted altitude in the form of a
   *         List of Double values
   * @since 4.2.0
   */
  List shiftLonLatAlt(double lon, double lat, double altitude);

  /**
   * Unshifted coordinate values according to its algorithm.
   *
   * @param shiftedPoint shifted point
   * @return unshifted longitude, shifted latitude,
   *         and altitude (if present) in the form of List of Double
   * @since 4.2.0
   */
  List unshiftPoint(Point shiftedPoint);


  /**
   * Unshifted coordinate values according to its algorithm.
   *
   * @param shiftedCoordinates shifted point
   * @return unshifted longitude, shifted latitude,
   *         and altitude (if present) in the form of List of Double
   * @since 4.2.0
   */
  List unshiftPoint(List shiftedCoordinates);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy