fix(native-geocoder): fix callback order
This commit is contained in:
parent
911537b61b
commit
dbf95ea4bd
@ -12,11 +12,13 @@ import { Plugin, Cordova } from './plugin';
|
|||||||
* NativeGeocoder.reverseGeocode(52.5072095, 13.1452818)
|
* NativeGeocoder.reverseGeocode(52.5072095, 13.1452818)
|
||||||
* .then((result: ReverseResult) => console.log("The address is " + result.address + " in " + result.countryCode))
|
* .then((result: ReverseResult) => console.log("The address is " + result.address + " in " + result.countryCode))
|
||||||
* .catch((error: any) => console.log(error));
|
* .catch((error: any) => console.log(error));
|
||||||
*
|
*
|
||||||
* NativeGeocoder.forwardGeocode("Berlin")
|
* NativeGeocoder.forwardGeocode("Berlin")
|
||||||
* .then((coordinates: ForwardResult) => console.log("The coordinates are latitude=" + coordinates.latitude + " and longitude=" + coordinates.longitude))
|
* .then((coordinates: ForwardResult) => console.log("The coordinates are latitude=" + coordinates.latitude + " and longitude=" + coordinates.longitude))
|
||||||
* .catch((error: any) => console.log(error));
|
* .catch((error: any) => console.log(error));
|
||||||
* ```
|
* ```
|
||||||
|
* @interfaces
|
||||||
|
*
|
||||||
*/
|
*/
|
||||||
@Plugin({
|
@Plugin({
|
||||||
name: 'NativeGeocoder',
|
name: 'NativeGeocoder',
|
||||||
@ -33,7 +35,9 @@ export class NativeGeocoder {
|
|||||||
* @param longitude {number} The longitude
|
* @param longitude {number} The longitude
|
||||||
* @return {Promise<any>}
|
* @return {Promise<any>}
|
||||||
*/
|
*/
|
||||||
@Cordova()
|
@Cordova({
|
||||||
|
callbackOrder: 'reverse'
|
||||||
|
})
|
||||||
static reverseGeocode(latitude: number, longitude: number): Promise<ReverseResult> { return; }
|
static reverseGeocode(latitude: number, longitude: number): Promise<ReverseResult> { return; }
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -41,7 +45,9 @@ export class NativeGeocoder {
|
|||||||
* @param addressString {string} The address to be geocoded
|
* @param addressString {string} The address to be geocoded
|
||||||
* @return {Promise<any>}
|
* @return {Promise<any>}
|
||||||
*/
|
*/
|
||||||
@Cordova()
|
@Cordova({
|
||||||
|
callbackOrder: 'reverse'
|
||||||
|
})
|
||||||
static forwardGeocode(addressString: string): Promise<ForwardResult> { return; }
|
static forwardGeocode(addressString: string): Promise<ForwardResult> { return; }
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user