UNPKG

universal-geocoder

Version:

Universal geocoding abstraction server-side and client-side with multiple built-in providers

53 lines 2.1 kB
import AdminLevel from "./AdminLevel"; import { BoundingBox, Coordinates } from "./types"; export interface GeocodedObject { readonly [property: string]: any; readonly coordinates?: Coordinates; readonly bounds?: BoundingBox; readonly formattedAddress?: string; readonly streetNumber?: string; readonly streetName?: string; readonly subLocality?: string; readonly locality?: string; readonly postalCode?: string; readonly region?: string; readonly adminLevels?: AdminLevel[]; readonly country?: string; readonly countryCode?: string; readonly timezone?: string; } export default class Geocoded { private readonly coordinates?; private readonly bounds?; private readonly formattedAddress?; private readonly streetNumber?; private readonly streetName?; private readonly subLocality?; private readonly locality?; private readonly postalCode?; private readonly region?; private readonly adminLevels; private readonly country?; private readonly countryCode?; private readonly timezone?; protected constructor({ coordinates, bounds, formattedAddress, streetNumber, streetName, subLocality, locality, postalCode, region, adminLevels, country, countryCode, timezone, }: GeocodedObject); static create(object: GeocodedObject): Geocoded; toObject(): GeocodedObject; withBounds(bounds: BoundingBox): Geocoded; withCoordinates(coordinates: Coordinates): Geocoded; getCoordinates(): undefined | Coordinates; getBounds(): undefined | BoundingBox; getFormattedAddress(): undefined | string; getStreetNumber(): undefined | string; getStreetName(): undefined | string; getSubLocality(): undefined | string; getLocality(): undefined | string; getPostalCode(): undefined | string; getRegion(): undefined | string; addAdminLevel(adminLevel: AdminLevel): void; getAdminLevels(): AdminLevel[]; getCountry(): undefined | string; getCountryCode(): undefined | string; getTimezone(): undefined | string; } //# sourceMappingURL=Geocoded.d.ts.map