Class SuburbSearchService.SuburbResult

java.lang.Object
com.example.cab302project.SuburbSearchService.SuburbResult
Enclosing class:
SuburbSearchService

public static class SuburbSearchService.SuburbResult extends Object
Result object returned from a suburb search. Contains the display name, bounding box, centroid, and GeoJSON polygon string.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    final double[]
    Bounding box: [minLat, maxLat, minLon, maxLon]
    final String
    Human-readable name of the found location.
    final String
    GeoJSON geometry string for the suburb boundary polygon, or null if unavailable.
    final double
    Centre latitude of the suburb.
    final double
    Centre longitude of the suburb.
  • Constructor Summary

    Constructors
    Constructor
    Description
    SuburbResult(String displayName, double lat, double lon, double[] boundingBox, String geoJson)
    Constructs a suburb search result.
  • Method Summary

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • displayName

      public final String displayName
      Human-readable name of the found location.
    • lat

      public final double lat
      Centre latitude of the suburb.
    • lon

      public final double lon
      Centre longitude of the suburb.
    • boundingBox

      public final double[] boundingBox
      Bounding box: [minLat, maxLat, minLon, maxLon]
    • geoJson

      public final String geoJson
      GeoJSON geometry string for the suburb boundary polygon, or null if unavailable.
  • Constructor Details

    • SuburbResult

      public SuburbResult(String displayName, double lat, double lon, double[] boundingBox, String geoJson)
      Constructs a suburb search result.
      Parameters:
      displayName - the full display name from Nominatim
      lat - the centre latitude
      lon - the centre longitude
      boundingBox - [minLat, maxLat, minLon, maxLon]
      geoJson - GeoJSON geometry string, or null if not available