This commit is contained in:
Max Lynch
2015-11-30 11:09:50 -06:00
parent 226c182039
commit b6e612209a
17 changed files with 155 additions and 42 deletions
+44 -29
View File
@@ -1,4 +1,4 @@
if (typeof __decorate !== "function") __decorate = function (decorators, target, key, desc) {
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") return Reflect.decorate(decorators, target, key, desc);
switch (arguments.length) {
case 2: return decorators.reduceRight(function(o, d) { return (d && d(o)) || o; }, target);
@@ -11,37 +11,52 @@ var BLE = (function () {
function BLE() {
}
BLE.scan = function (services, seconds) { };
BLE.startScan = function (services) { };
;
BLE.stopScan = function () { };
;
BLE.connect = function (deviceId) { };
;
BLE.disconnect = function (deviceId) { };
;
BLE.read = function (deviceId, serviceUUID, characteristicUUID) { };
;
BLE.write = function (deviceId, serviceUUID, characteristicUUID, value) { };
;
BLE.writeWithoutResponse = function (deviceId, serviceUUID, characteristicUUID, value) { };
;
Object.defineProperty(BLE, "scan",
__decorate([
plugin_1.Cordova({
successIndex: 2,
errIndex: 3
})
plugin_1.Cordova()
], BLE, "scan", Object.getOwnPropertyDescriptor(BLE, "scan")));
__decorate([
plugin_1.Cordova({
successIndex: 1,
errIndex: 2
})
], BLE, "startScan");
__decorate([
plugin_1.Cordova({
successIndex: 0,
errIndex: 1
})
], BLE, "stopScan");
__decorate([
plugin_1.Cordova({
successIndex: 1,
errIndex: 2
})
], BLE, "connect");
__decorate([
plugin_1.Cordova({
successIndex: 1,
errIndex: 2
})
], BLE, "disconnect");
Object.defineProperty(BLE, "startScan",
__decorate([
plugin_1.Cordova()
], BLE, "startScan", Object.getOwnPropertyDescriptor(BLE, "startScan")));
Object.defineProperty(BLE, "stopScan",
__decorate([
plugin_1.Cordova()
], BLE, "stopScan", Object.getOwnPropertyDescriptor(BLE, "stopScan")));
Object.defineProperty(BLE, "connect",
__decorate([
plugin_1.Cordova()
], BLE, "connect", Object.getOwnPropertyDescriptor(BLE, "connect")));
Object.defineProperty(BLE, "disconnect",
__decorate([
plugin_1.Cordova()
], BLE, "disconnect", Object.getOwnPropertyDescriptor(BLE, "disconnect")));
Object.defineProperty(BLE, "read",
__decorate([
plugin_1.Cordova()
], BLE, "read", Object.getOwnPropertyDescriptor(BLE, "read")));
Object.defineProperty(BLE, "write",
__decorate([
plugin_1.Cordova()
], BLE, "write", Object.getOwnPropertyDescriptor(BLE, "write")));
Object.defineProperty(BLE, "writeWithoutResponse",
__decorate([
plugin_1.Cordova()
], BLE, "writeWithoutResponse", Object.getOwnPropertyDescriptor(BLE, "writeWithoutResponse")));
BLE = __decorate([
plugin_1.Plugin({
name: 'BluetoothLowEnergy',