# Class NominatimService

#### Hierarchy

- NominatimService

- Defined in src/routing/NominatimService.js:55

#####
Index

### Properties

$http_
ngeoDebounce_
nominatimUrl_
searchDefaultParams_
typeaheadDebounceDelay_
typeaheadSourceDebounced

### Methods

reverse
search
typeaheadSource_

## Properties

### $http_

$http_: IHttpService

- Defined in src/routing/NominatimService.js:59

### ngeoDebounce_

ngeoDebounce_: miscDebounce<((arg0: string, arg1: ((arg0: NominatimSearchResult[]) => void), arg2: ((arg0: NominatimSearchResult[]) => void)) => void)>

- Defined in src/routing/NominatimService.js:64

### nominatimUrl_

nominatimUrl_: string

URL for Nominatim backend Defaults openstreetmap instance.

- Defined in src/routing/NominatimService.js:72

### searchDefaultParams_

searchDefaultParams_: Object

- Defined in src/routing/NominatimService.js:82

### typeaheadDebounceDelay_

typeaheadDebounceDelay_: number

Delay (in milliseconds) to avoid calling the API too often. Only if there were no calls for that many milliseconds, the last call will be executed.

- Defined in src/routing/NominatimService.js:91

### typeaheadSourceDebounced

typeaheadSourceDebounced: ((query: string, syncResults: ((result: NominatimSearchResult[]) => void), asyncResults: ((result: NominatimSearchResult[]) => void)) => void)

#### Type declaration

- - (query: string, syncResults: ((result: NominatimSearchResult[]) => void), asyncResults: ((result: NominatimSearchResult[]) => void)): void

  - #### Parameters

    - ##### query: string

    - ##### syncResults: ((result: NominatimSearchResult[]) => void)

      - - (result: NominatimSearchResult[]): void

        - #### Parameters

          - ##### result: NominatimSearchResult[]

          #### Returns void

    - ##### asyncResults: ((result: NominatimSearchResult[]) => void)

      - - (result: NominatimSearchResult[]): void

        - #### Parameters

          - ##### result: NominatimSearchResult[]

          #### Returns void

- Defined in src/routing/NominatimService.js:96

## Methods

### reverse

- reverse(coordinate: Coordinate, params: Object): IHttpPromise<NominatimSearchResponseResult>

- Reverse Geocoding

  ### Returns

  promise of the Nominatim API request

  ### See

  https://wiki.openstreetmap.org/wiki/Nominatim#Reverse_Geocoding

  #### Parameters

  - ##### coordinate: Coordinate

    Search coordinate in LonLat projection

  - ##### params: Object

    Optional parameters

  #### Returns IHttpPromise<NominatimSearchResponseResult>

  - Defined in src/routing/NominatimService.js:140

### search

- search(query: string, params: Object): IHttpPromise<NominatimSearchResponseResult[]>

- Search by name

  ### Returns

  promise of the Nominatim API request

  ### See

  https://wiki.openstreetmap.org/wiki/Nominatim#Search

  #### Parameters

  - ##### query: string

    Search query

  - ##### params: Object

    Optional parameters

  #### Returns IHttpPromise<NominatimSearchResponseResult[]>

  - Defined in src/routing/NominatimService.js:111

### typeaheadSource_

- typeaheadSource_(query: string, syncResults: ((result: NominatimSearchResult[]) => void), asyncResults?: ((result: NominatimSearchResult[]) => void)): void

- #### Parameters

  - ##### query: string

    Search query

  - ##### syncResults: ((result: NominatimSearchResult[]) => void)

    Callback for synchronous execution, unused

    - - (result: NominatimSearchResult[]): void

      - #### Parameters

        - ##### result: NominatimSearchResult[]

        #### Returns void

  - ##### `Optional` asyncResults: ((result: NominatimSearchResult[]) => void)

    Callback for asynchronous execution

    - - (result: NominatimSearchResult[]): void

      - #### Parameters

        - ##### result: NominatimSearchResult[]

        #### Returns void

  - Defined in src/routing/NominatimService.js:169

Generated using TypeDoc