mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2026-04-13 00:00:10 +08:00
Merge in v5 code
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Cordova, Plugin, CordovaCheck, IonicNativePlugin } from '@ionic-native/core';
|
||||
import { Cordova, CordovaCheck, IonicNativePlugin, Plugin } from '@ionic-native/core';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
|
||||
declare const cordova: any;
|
||||
@@ -404,7 +404,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* @returns {IBeaconDelegate} Returns the IBeaconDelegate
|
||||
*/
|
||||
@Cordova()
|
||||
getDelegate(): IBeaconDelegate { return; }
|
||||
getDelegate(): IBeaconDelegate {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {IBeaconDelegate} delegate An instance of a delegate to register with the native layer.
|
||||
@@ -412,7 +414,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* @returns {IBeaconDelegate} Returns the IBeaconDelegate
|
||||
*/
|
||||
@Cordova()
|
||||
setDelegate(delegate: IBeaconDelegate): IBeaconDelegate { return; }
|
||||
setDelegate(delegate: IBeaconDelegate): IBeaconDelegate {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Signals the native layer that the client side is ready to consume messages.
|
||||
@@ -435,7 +439,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* native layer acknowledged the request and started to send events.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
onDomDelegateReady(): Promise<void> { return; }
|
||||
onDomDelegateReady(): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines if bluetooth is switched on, according to the native layer.
|
||||
@@ -443,7 +449,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* indicating whether bluetooth is active.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
isBluetoothEnabled(): Promise<boolean> { return; }
|
||||
isBluetoothEnabled(): Promise<boolean> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Enables Bluetooth using the native Layer. (ANDROID ONLY)
|
||||
@@ -452,7 +460,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* could be enabled. If not, the promise will be rejected with an error.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
enableBluetooth(): Promise<void> { return; }
|
||||
enableBluetooth(): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Disables Bluetooth using the native Layer. (ANDROID ONLY)
|
||||
@@ -461,7 +471,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* could be enabled. If not, the promise will be rejected with an error.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
disableBluetooth(): Promise<void> { return; }
|
||||
disableBluetooth(): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Start monitoring the specified region.
|
||||
@@ -481,7 +493,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* native layer acknowledged the dispatch of the monitoring request.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
startMonitoringForRegion(region: BeaconRegion): Promise<string> { return; }
|
||||
startMonitoringForRegion(region: BeaconRegion): Promise<string> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Stop monitoring the specified region. It is valid to call
|
||||
@@ -498,7 +512,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* native layer acknowledged the dispatch of the request to stop monitoring.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
stopMonitoringForRegion(region: BeaconRegion): Promise<void> { return; }
|
||||
stopMonitoringForRegion(region: BeaconRegion): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Request state the for specified region. When result is ready
|
||||
@@ -514,7 +530,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* native layer acknowledged the dispatch of the request to stop monitoring.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
requestStateForRegion(region: Region): Promise<void> { return; }
|
||||
requestStateForRegion(region: Region): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
@@ -532,7 +550,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* native layer acknowledged the dispatch of the monitoring request.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
startRangingBeaconsInRegion(region: BeaconRegion): Promise<void> { return; }
|
||||
startRangingBeaconsInRegion(region: BeaconRegion): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Stop ranging the specified region. It is valid to call
|
||||
@@ -549,7 +569,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* native layer acknowledged the dispatch of the request to stop monitoring.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
stopRangingBeaconsInRegion(region: BeaconRegion): Promise<void> { return; }
|
||||
stopRangingBeaconsInRegion(region: BeaconRegion): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Queries the native layer to determine the current authorization in effect.
|
||||
@@ -558,7 +580,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* requested authorization status.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
getAuthorizationStatus(): Promise<IBeaconPluginResult> { return; }
|
||||
getAuthorizationStatus(): Promise<IBeaconPluginResult> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* For iOS 8 and above only. The permission model has changed by Apple in iOS 8, making it necessary for apps to
|
||||
@@ -570,7 +594,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* @returns {Promise<void>} Returns a promise that is resolved when the request dialog is shown.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
requestWhenInUseAuthorization(): Promise<void> { return; }
|
||||
requestWhenInUseAuthorization(): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
@@ -580,7 +606,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* shows the request dialog.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
requestAlwaysAuthorization(): Promise<void> { return; }
|
||||
requestAlwaysAuthorization(): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
@@ -588,7 +616,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* of {Region} instances that are being monitored by the native layer.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
getMonitoredRegions(): Promise<Region[]> { return; }
|
||||
getMonitoredRegions(): Promise<Region[]> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
@@ -596,7 +626,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* of {Region} instances that are being ranged by the native layer.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
getRangedRegions(): Promise<Region[]> { return; }
|
||||
getRangedRegions(): Promise<Region[]> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines if ranging is available or not, according to the native layer.
|
||||
@@ -604,7 +636,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* indicating whether ranging is available or not.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
isRangingAvailable(): Promise<boolean> { return; }
|
||||
isRangingAvailable(): Promise<boolean> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines if region type is supported or not, according to the native layer.
|
||||
@@ -616,7 +650,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* indicating whether the region type is supported or not.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
isMonitoringAvailableForClass(region: Region): Promise<boolean> { return; }
|
||||
isMonitoringAvailableForClass(region: Region): Promise<boolean> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Start advertising the specified region.
|
||||
@@ -636,7 +672,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* native layer acknowledged the dispatch of the advertising request.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
startAdvertising(region: Region, measuredPower?: number): Promise<void> { return; }
|
||||
startAdvertising(region: Region, measuredPower?: number): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Stop advertising as a beacon.
|
||||
@@ -647,7 +685,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* native layer acknowledged the dispatch of the request to stop advertising.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
stopAdvertising(region: Region): Promise<void> { return; }
|
||||
stopAdvertising(region: Region): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines if advertising is available or not, according to the native layer.
|
||||
@@ -655,7 +695,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* indicating whether advertising is available or not.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
isAdvertisingAvailable(): Promise<boolean> { return; }
|
||||
isAdvertisingAvailable(): Promise<boolean> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines if advertising is currently active, according to the native layer.
|
||||
@@ -663,7 +705,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* indicating whether advertising is active.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
isAdvertising(): Promise<boolean> { return; }
|
||||
isAdvertising(): Promise<boolean> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Disables debug logging in the native layer. Use this method if you want
|
||||
@@ -673,7 +717,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* native layer has set the logging level accordingly.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
disableDebugLogs(): Promise<void> { return; }
|
||||
disableDebugLogs(): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Enables the posting of debug notifications in the native layer. Use this method if you want
|
||||
@@ -684,7 +730,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* native layer has set the flag to enabled.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
enableDebugNotifications(): Promise<void> { return; }
|
||||
enableDebugNotifications(): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Disables the posting of debug notifications in the native layer. Use this method if you want
|
||||
@@ -694,7 +742,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* native layer has set the flag to disabled.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
disableDebugNotifications(): Promise<void> { return; }
|
||||
disableDebugNotifications(): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Enables debug logging in the native layer. Use this method if you want
|
||||
@@ -704,7 +754,9 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* native layer has set the logging level accordingly.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
enableDebugLogs(): Promise<void> { return; }
|
||||
enableDebugLogs(): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Appends the provided [message] to the device logs.
|
||||
@@ -717,6 +769,8 @@ export class IBeacon extends IonicNativePlugin {
|
||||
* is expected to be equivalent to the one provided in the original call.
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
appendToDeviceLog(message: string): Promise<void> { return; }
|
||||
appendToDeviceLog(message: string): Promise<void> {
|
||||
return;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user