@intuitionrobotics/file-upload 0.41.69 → 0.41.72
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/app-backend/api/_upload.js +1 -1
- package/app-backend/api/_upload.js.map +1 -1
- package/app-backend/api/v1/upload/get-url.js +10 -54
- package/app-backend/api/v1/upload/get-url.js.map +1 -1
- package/app-backend/core/module-pack.js +8 -14
- package/app-backend/core/module-pack.js.map +1 -1
- package/app-backend/modules/BucketListener.js +17 -68
- package/app-backend/modules/BucketListener.js.map +1 -1
- package/app-backend/modules/ServerUploaderModule.js +16 -59
- package/app-backend/modules/ServerUploaderModule.js.map +1 -1
- package/app-backend/modules/UploaderModule.js +89 -200
- package/app-backend/modules/UploaderModule.js.map +1 -1
- package/app-backend/modules/UploaderTempFileModule.js +20 -35
- package/app-backend/modules/UploaderTempFileModule.js.map +1 -1
- package/app-frontend/core/module-pack.js +5 -11
- package/app-frontend/core/module-pack.js.map +1 -1
- package/app-frontend/modules/UploaderModule.js +25 -76
- package/app-frontend/modules/UploaderModule.js.map +1 -1
- package/package.json +4 -4
- package/shared/modules/BaseUploaderModule.js +75 -155
- package/shared/modules/BaseUploaderModule.js.map +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
|
|
3
|
+
const backend_1 = require("@intuitionrobotics/thunderstorm/backend");
|
|
4
4
|
module.exports = new backend_1.RouteResolver(require, __dirname);
|
|
5
5
|
//# sourceMappingURL=_upload.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"_upload.js","sourceRoot":"","sources":["../../../src/main/app-backend/api/_upload.ts"],"names":[],"mappings":";;AAAA,
|
|
1
|
+
{"version":3,"file":"_upload.js","sourceRoot":"","sources":["../../../src/main/app-backend/api/_upload.ts"],"names":[],"mappings":";;AAAA,qEAAsE;AAEtE,MAAM,CAAC,OAAO,GAAG,IAAI,uBAAa,CAAC,OAAO,EAAE,SAAS,CAAC,CAAC"}
|
|
@@ -17,19 +17,6 @@
|
|
|
17
17
|
* See the License for the specific language governing permissions and
|
|
18
18
|
* limitations under the License.
|
|
19
19
|
*/
|
|
20
|
-
var __extends = (this && this.__extends) || (function () {
|
|
21
|
-
var extendStatics = function (d, b) {
|
|
22
|
-
extendStatics = Object.setPrototypeOf ||
|
|
23
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
24
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
25
|
-
return extendStatics(d, b);
|
|
26
|
-
};
|
|
27
|
-
return function (d, b) {
|
|
28
|
-
extendStatics(d, b);
|
|
29
|
-
function __() { this.constructor = d; }
|
|
30
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
31
|
-
};
|
|
32
|
-
})();
|
|
33
20
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
34
21
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
35
22
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -39,49 +26,18 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
39
26
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
40
27
|
});
|
|
41
28
|
};
|
|
42
|
-
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
43
|
-
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
44
|
-
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
45
|
-
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
46
|
-
function step(op) {
|
|
47
|
-
if (f) throw new TypeError("Generator is already executing.");
|
|
48
|
-
while (_) try {
|
|
49
|
-
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
50
|
-
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
51
|
-
switch (op[0]) {
|
|
52
|
-
case 0: case 1: t = op; break;
|
|
53
|
-
case 4: _.label++; return { value: op[1], done: false };
|
|
54
|
-
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
55
|
-
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
56
|
-
default:
|
|
57
|
-
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
58
|
-
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
59
|
-
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
60
|
-
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
61
|
-
if (t[2]) _.ops.pop();
|
|
62
|
-
_.trys.pop(); continue;
|
|
63
|
-
}
|
|
64
|
-
op = body.call(thisArg, _);
|
|
65
|
-
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
66
|
-
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
67
|
-
}
|
|
68
|
-
};
|
|
69
29
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
return _super.call(this, 'get-url') || this;
|
|
30
|
+
const backend_1 = require("@intuitionrobotics/thunderstorm/backend");
|
|
31
|
+
const UploaderModule_1 = require("../../../modules/UploaderModule");
|
|
32
|
+
class ServerApi_GetUploadUrl extends backend_1.ServerApi_Post {
|
|
33
|
+
constructor() {
|
|
34
|
+
super('get-url');
|
|
76
35
|
}
|
|
77
|
-
|
|
78
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
79
|
-
return
|
|
80
|
-
return [2 /*return*/, UploaderModule_1.UploaderModule.getUrl(body)];
|
|
81
|
-
});
|
|
36
|
+
process(request, response, queryParams, body) {
|
|
37
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
38
|
+
return UploaderModule_1.UploaderModule.getUrl(body);
|
|
82
39
|
});
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
}(backend_1.ServerApi_Post));
|
|
40
|
+
}
|
|
41
|
+
}
|
|
86
42
|
module.exports = new ServerApi_GetUploadUrl();
|
|
87
43
|
//# sourceMappingURL=get-url.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-url.js","sourceRoot":"","sources":["../../../../../src/main/app-backend/api/v1/upload/get-url.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;GAiBG
|
|
1
|
+
{"version":3,"file":"get-url.js","sourceRoot":"","sources":["../../../../../src/main/app-backend/api/v1/upload/get-url.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;GAiBG;;;;;;;;;;;AAEH,qEAIiD;AAMjD,oEAA+D;AAG/D,MAAM,sBACL,SAAQ,wBAAgC;IACxC;QACC,KAAK,CAAC,SAAS,CAAC,CAAA;IACjB,CAAC;IAEe,OAAO,CAAC,OAAuB,EAAE,QAAqB,EAAE,WAAwB,EAAE,IAAwB;;YACzH,OAAO,+BAAc,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;QACpC,CAAC;KAAA;CACD;AAED,MAAM,CAAC,OAAO,GAAG,IAAI,sBAAsB,EAAE,CAAA"}
|
|
@@ -17,24 +17,18 @@
|
|
|
17
17
|
* See the License for the specific language governing permissions and
|
|
18
18
|
* limitations under the License.
|
|
19
19
|
*/
|
|
20
|
-
var __spreadArrays = (this && this.__spreadArrays) || function () {
|
|
21
|
-
for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
|
|
22
|
-
for (var r = Array(s), k = 0, i = 0; i < il; i++)
|
|
23
|
-
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
|
|
24
|
-
r[k] = a[j];
|
|
25
|
-
return r;
|
|
26
|
-
};
|
|
27
20
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
28
21
|
exports.Backend_ModulePack_Uploader = void 0;
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
exports.Backend_ModulePack_Uploader =
|
|
22
|
+
const UploaderModule_1 = require("../modules/UploaderModule");
|
|
23
|
+
const UploaderTempFileModule_1 = require("../modules/UploaderTempFileModule");
|
|
24
|
+
const BucketListener_1 = require("../modules/BucketListener");
|
|
25
|
+
const backend_1 = require("@intuitionrobotics/push-pub-sub/backend");
|
|
26
|
+
const ServerUploaderModule_1 = require("../modules/ServerUploaderModule");
|
|
27
|
+
exports.Backend_ModulePack_Uploader = [
|
|
28
|
+
...backend_1.Backend_ModulePack_PushPubSub,
|
|
35
29
|
ServerUploaderModule_1.ServerUploaderModule,
|
|
36
30
|
UploaderModule_1.UploaderModule,
|
|
37
31
|
UploaderTempFileModule_1.UploaderTempFileModule,
|
|
38
32
|
BucketListener_1.BucketListener
|
|
39
|
-
]
|
|
33
|
+
];
|
|
40
34
|
//# sourceMappingURL=module-pack.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"module-pack.js","sourceRoot":"","sources":["../../../src/main/app-backend/core/module-pack.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;GAiBG
|
|
1
|
+
{"version":3,"file":"module-pack.js","sourceRoot":"","sources":["../../../src/main/app-backend/core/module-pack.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;GAiBG;;;AAEH,8DAAyD;AACzD,8EAAyE;AACzE,8DAAyD;AACzD,qEAAsF;AACtF,0EAAqE;AAExD,QAAA,2BAA2B,GAAG;IAC1C,GAAG,uCAA6B;IAChC,2CAAoB;IACpB,+BAAc;IACd,+CAAsB;IACtB,+BAAc;CACd,CAAC"}
|
|
@@ -16,19 +16,6 @@
|
|
|
16
16
|
* See the License for the specific language governing permissions and
|
|
17
17
|
* limitations under the License.
|
|
18
18
|
*/
|
|
19
|
-
var __extends = (this && this.__extends) || (function () {
|
|
20
|
-
var extendStatics = function (d, b) {
|
|
21
|
-
extendStatics = Object.setPrototypeOf ||
|
|
22
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
23
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
24
|
-
return extendStatics(d, b);
|
|
25
|
-
};
|
|
26
|
-
return function (d, b) {
|
|
27
|
-
extendStatics(d, b);
|
|
28
|
-
function __() { this.constructor = d; }
|
|
29
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
30
|
-
};
|
|
31
|
-
})();
|
|
32
19
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
33
20
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
34
21
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -38,67 +25,29 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
38
25
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
39
26
|
});
|
|
40
27
|
};
|
|
41
|
-
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
42
|
-
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
43
|
-
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
44
|
-
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
45
|
-
function step(op) {
|
|
46
|
-
if (f) throw new TypeError("Generator is already executing.");
|
|
47
|
-
while (_) try {
|
|
48
|
-
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
49
|
-
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
50
|
-
switch (op[0]) {
|
|
51
|
-
case 0: case 1: t = op; break;
|
|
52
|
-
case 4: _.label++; return { value: op[1], done: false };
|
|
53
|
-
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
54
|
-
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
55
|
-
default:
|
|
56
|
-
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
57
|
-
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
58
|
-
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
59
|
-
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
60
|
-
if (t[2]) _.ops.pop();
|
|
61
|
-
_.trys.pop(); continue;
|
|
62
|
-
}
|
|
63
|
-
op = body.call(thisArg, _);
|
|
64
|
-
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
65
|
-
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
66
|
-
}
|
|
67
|
-
};
|
|
68
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
69
29
|
exports.BucketListener = exports.BucketListener_Class = void 0;
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
return _super.call(this) || this;
|
|
30
|
+
const backend_functions_1 = require("@intuitionrobotics/firebase/backend-functions");
|
|
31
|
+
const ts_common_1 = require("@intuitionrobotics/ts-common");
|
|
32
|
+
const dispatcher_onFileUploaded = new ts_common_1.Dispatcher("__onFileUploaded");
|
|
33
|
+
class BucketListener_Class extends backend_functions_1.Firebase_StorageFunction {
|
|
34
|
+
constructor() {
|
|
35
|
+
super();
|
|
77
36
|
}
|
|
78
|
-
|
|
79
|
-
|
|
37
|
+
init() {
|
|
38
|
+
super.init();
|
|
80
39
|
// @ts-ignore
|
|
81
40
|
this.logInfo("bucketName", this.config.bucketName);
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
filePath = object.name;
|
|
90
|
-
return [4 /*yield*/, dispatcher_onFileUploaded.dispatchModuleAsync([filePath])];
|
|
91
|
-
case 1:
|
|
92
|
-
_a.sent();
|
|
93
|
-
this.logInfo("Object is ", object);
|
|
94
|
-
this.logInfo("Context is ", context);
|
|
95
|
-
return [2 /*return*/];
|
|
96
|
-
}
|
|
97
|
-
});
|
|
41
|
+
}
|
|
42
|
+
onFinalize(object, context) {
|
|
43
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
44
|
+
const filePath = object.name;
|
|
45
|
+
yield dispatcher_onFileUploaded.dispatchModuleAsync([filePath]);
|
|
46
|
+
this.logInfo("Object is ", object);
|
|
47
|
+
this.logInfo("Context is ", context);
|
|
98
48
|
});
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
}(backend_functions_1.Firebase_StorageFunction));
|
|
49
|
+
}
|
|
50
|
+
}
|
|
102
51
|
exports.BucketListener_Class = BucketListener_Class;
|
|
103
52
|
exports.BucketListener = new BucketListener_Class();
|
|
104
53
|
//# sourceMappingURL=BucketListener.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BucketListener.js","sourceRoot":"","sources":["../../../src/main/app-backend/modules/BucketListener.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;GAgBG
|
|
1
|
+
{"version":3,"file":"BucketListener.js","sourceRoot":"","sources":["../../../src/main/app-backend/modules/BucketListener.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;GAgBG;;;;;;;;;;;;AAEH,qFAAuF;AAGvF,4DAAwD;AAMxD,MAAM,yBAAyB,GAAG,IAAI,sBAAU,CAAqC,kBAAkB,CAAC,CAAC;AAGzG,MAAa,oBACZ,SAAQ,4CAAwB;IAChC;QACC,KAAK,EAAE,CAAC;IACT,CAAC;IAGD,IAAI;QACH,KAAK,CAAC,IAAI,EAAE,CAAC;QACb,aAAa;QACb,IAAI,CAAC,OAAO,CAAC,YAAY,EAAE,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC;IACpD,CAAC;IAEK,UAAU,CAAC,MAAsB,EAAE,OAAqB;;YAC7D,MAAM,QAAQ,GAAG,MAAM,CAAC,IAAI,CAAC;YAC7B,MAAM,yBAAyB,CAAC,mBAAmB,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;YAChE,IAAI,CAAC,OAAO,CAAC,YAAY,EAAE,MAAM,CAAC,CAAC;YACnC,IAAI,CAAC,OAAO,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC;QACtC,CAAC;KAAA;CAED;AApBD,oDAoBC;AAEY,QAAA,cAAc,GAAG,IAAI,oBAAoB,EAAE,CAAC"}
|
|
@@ -17,19 +17,6 @@
|
|
|
17
17
|
* See the License for the specific language governing permissions and
|
|
18
18
|
* limitations under the License.
|
|
19
19
|
*/
|
|
20
|
-
var __extends = (this && this.__extends) || (function () {
|
|
21
|
-
var extendStatics = function (d, b) {
|
|
22
|
-
extendStatics = Object.setPrototypeOf ||
|
|
23
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
24
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
25
|
-
return extendStatics(d, b);
|
|
26
|
-
};
|
|
27
|
-
return function (d, b) {
|
|
28
|
-
extendStatics(d, b);
|
|
29
|
-
function __() { this.constructor = d; }
|
|
30
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
31
|
-
};
|
|
32
|
-
})();
|
|
33
20
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
34
21
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
35
22
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -39,58 +26,28 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
39
26
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
40
27
|
});
|
|
41
28
|
};
|
|
42
|
-
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
43
|
-
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
44
|
-
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
45
|
-
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
46
|
-
function step(op) {
|
|
47
|
-
if (f) throw new TypeError("Generator is already executing.");
|
|
48
|
-
while (_) try {
|
|
49
|
-
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
50
|
-
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
51
|
-
switch (op[0]) {
|
|
52
|
-
case 0: case 1: t = op; break;
|
|
53
|
-
case 4: _.label++; return { value: op[1], done: false };
|
|
54
|
-
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
55
|
-
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
56
|
-
default:
|
|
57
|
-
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
58
|
-
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
59
|
-
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
60
|
-
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
61
|
-
if (t[2]) _.ops.pop();
|
|
62
|
-
_.trys.pop(); continue;
|
|
63
|
-
}
|
|
64
|
-
op = body.call(thisArg, _);
|
|
65
|
-
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
66
|
-
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
67
|
-
}
|
|
68
|
-
};
|
|
69
29
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
70
30
|
exports.ServerUploaderModule = exports.ServerUploaderModule_Class = void 0;
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
return _super.call(this, backend_1.AxiosHttpModule) || this;
|
|
31
|
+
const BaseUploaderModule_1 = require("../../shared/modules/BaseUploaderModule");
|
|
32
|
+
const backend_1 = require("@intuitionrobotics/thunderstorm/backend");
|
|
33
|
+
class ServerUploaderModule_Class extends BaseUploaderModule_1.BaseUploaderModule_Class {
|
|
34
|
+
constructor() {
|
|
35
|
+
super(backend_1.AxiosHttpModule);
|
|
77
36
|
}
|
|
78
|
-
|
|
79
|
-
|
|
37
|
+
init() {
|
|
38
|
+
super.init();
|
|
80
39
|
backend_1.AxiosHttpModule.setRequestOption(this.config.requestConfig);
|
|
81
|
-
}
|
|
82
|
-
|
|
40
|
+
}
|
|
41
|
+
upload(files) {
|
|
83
42
|
return this.uploadImpl(files);
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
});
|
|
43
|
+
}
|
|
44
|
+
subscribeToPush(toSubscribe) {
|
|
45
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
46
|
+
// Not sure now
|
|
47
|
+
// We said timeout
|
|
90
48
|
});
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
}(BaseUploaderModule_1.BaseUploaderModule_Class));
|
|
49
|
+
}
|
|
50
|
+
}
|
|
94
51
|
exports.ServerUploaderModule_Class = ServerUploaderModule_Class;
|
|
95
52
|
exports.ServerUploaderModule = new ServerUploaderModule_Class();
|
|
96
53
|
//# sourceMappingURL=ServerUploaderModule.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ServerUploaderModule.js","sourceRoot":"","sources":["../../../src/main/app-backend/modules/ServerUploaderModule.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;GAiBG
|
|
1
|
+
{"version":3,"file":"ServerUploaderModule.js","sourceRoot":"","sources":["../../../src/main/app-backend/modules/ServerUploaderModule.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;GAiBG;;;;;;;;;;;;AAOH,gFAEiD;AACjD,qEAIiD;AAMjD,MAAa,0BACZ,SAAQ,6CAAuF;IAE/F;QACC,KAAK,CAAC,yBAAe,CAAC,CAAC;IACxB,CAAC;IAED,IAAI;QACH,KAAK,CAAC,IAAI,EAAE,CAAC;QACb,yBAAe,CAAC,gBAAgB,CAAC,IAAI,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC;IAC7D,CAAC;IAED,MAAM,CAAC,KAA4B;QAClC,OAAO,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC;IAC/B,CAAC;IAEe,eAAe,CAAC,WAA4B;;YAC3D,eAAe;YACf,kBAAkB;QACnB,CAAC;KAAA;CACD;AApBD,gEAoBC;AAEY,QAAA,oBAAoB,GAAG,IAAI,0BAA0B,EAAE,CAAC"}
|