Class GlobeCoordinatesValueImpl

java.lang.Object
org.wikidata.wdtk.datamodel.implementation.ValueImpl
org.wikidata.wdtk.datamodel.implementation.GlobeCoordinatesValueImpl
All Implemented Interfaces:
GlobeCoordinatesValue, Value

public class GlobeCoordinatesValueImpl extends ValueImpl implements GlobeCoordinatesValue
Jackson implementation of GlobeCoordinatesValue.
Author:
Fredo Erxleben, Antonin Delpeuch, Markus Kroetzsch
  • Constructor Details

    • GlobeCoordinatesValueImpl

      public GlobeCoordinatesValueImpl(double latitude, double longitude, double precision, String globe)
      Constructor.
      Parameters:
      latitude - the latitude of the coordinates in degrees
      longitude - the longitude of the coordinates in degrees
      precision - the precision of the coordinates in degrees
      globe - IRI specifying the celestial objects of the coordinates
  • Method Details

    • getValue

      public org.wikidata.wdtk.datamodel.implementation.GlobeCoordinatesValueImpl.JacksonInnerGlobeCoordinates getValue()
      Returns the inner value helper object. Only for use by Jackson during serialization.
      Returns:
      the inner globe coordinates value
    • getLatitude

      public double getLatitude()
      Description copied from interface: GlobeCoordinatesValue
      Get the latitude of this value in degrees. For Earth, the latitude value is generally the geographic latitude (as opposed to the geocentric latitude etc.). For other celestial bodies, the meaning of the latitude can vary. It is part of the semantics of the property to specify which coordinate system should be assumed for each globe (possibly depending on further information, such as qualifiers).
      Specified by:
      getLatitude in interface GlobeCoordinatesValue
      Returns:
      latitude in degrees
    • getLongitude

      public double getLongitude()
      Description copied from interface: GlobeCoordinatesValue
      Get the longitude of this value in degrees. For celestial bodies other than Earth, the meaning of the longitude can vary. It is part of the semantics of the property to specify which coordinate system should be assumed for each globe (possibly depending on further information, such as qualifiers).
      Specified by:
      getLongitude in interface GlobeCoordinatesValue
      Returns:
      longitude in degrees
    • getPrecision

      public double getPrecision()
      Description copied from interface: GlobeCoordinatesValue
      Get the precision of the value in degrees. This value indicates that both latitude and longitude might be off by that precision. Obviously, since the absolute distance of one degree may vary depending on the coordinates, this leads to a non-uniform notion of precision. For example, precision of one whole degree at coordinates 80N, 145E is a much smaller distance from the spot than the same precision at 10N, 145E.
      Specified by:
      getPrecision in interface GlobeCoordinatesValue
      Returns:
      precision in degrees
    • getGlobe

      public String getGlobe()
      Description copied from interface: GlobeCoordinatesValue
      Get the IRI of the globe that these coordinates refer to. In most cases this is GlobeCoordinatesValue.GLOBE_EARTH.
      Specified by:
      getGlobe in interface GlobeCoordinatesValue
      Returns:
      IRI of a globe.
    • getGlobeItemId

      public ItemIdValue getGlobeItemId()
      Description copied from interface: GlobeCoordinatesValue
      Get the ItemIdValue of the globe that these coordinates refer to.
      Specified by:
      getGlobeItemId in interface GlobeCoordinatesValue
    • accept

      public <T> T accept(ValueVisitor<T> valueVisitor)
      Description copied from interface: Value
      Accept a ValueVisitor and return its output.
      Specified by:
      accept in interface Value
      Parameters:
      valueVisitor - the ValueVisitor
      Returns:
      output of the visitor
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object