import L from "leaflet";

export default class NominatimResponse {
  lat;
  lon;
  boundingBox;

  constructor(init) {
    if (init !== undefined) {
      this.lat = Number(init.lat);
      this.lon = Number(init.lon);
      this.boundingBox = new L.LatLngBounds(
        [init.boundingbox[0], init.boundingbox[2]],
        [init.boundingbox[1], init.boundingbox[3]],
      );
    }
  }
}
