bruce-models 0.5.5 → 0.5.7
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/dist/bruce-models.es5.js +47 -8
- package/dist/bruce-models.es5.js.map +1 -1
- package/dist/bruce-models.umd.js +47 -8
- package/dist/bruce-models.umd.js.map +1 -1
- package/dist/lib/client-file/client-file.js +23 -0
- package/dist/lib/client-file/client-file.js.map +1 -1
- package/dist/lib/entity/entity-lod.js +14 -0
- package/dist/lib/entity/entity-lod.js.map +1 -1
- package/dist/lib/entity/getters/batched-data-getter.js +10 -8
- package/dist/lib/entity/getters/batched-data-getter.js.map +1 -1
- package/dist/types/client-file/client-file.d.ts +12 -0
- package/dist/types/entity/entity-lod.d.ts +6 -0
- package/dist/types/entity/getters/batched-data-getter.d.ts +2 -1
- package/package.json +1 -1
package/dist/bruce-models.umd.js
CHANGED
|
@@ -2510,6 +2510,20 @@
|
|
|
2510
2510
|
});
|
|
2511
2511
|
}
|
|
2512
2512
|
EntityLod.GetTypeLods = GetTypeLods;
|
|
2513
|
+
function Update(api, entityId, params) {
|
|
2514
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
2515
|
+
return __generator(this, function (_a) {
|
|
2516
|
+
if (!params["ClientFile.ID"] || !params["LODCategory.Key"] || !params.Level) {
|
|
2517
|
+
throw ("ClientFile.ID, LODCategory.Key and Level are required.");
|
|
2518
|
+
}
|
|
2519
|
+
return [2 /*return*/, api.POST("entity/" + entityId + "/lod/" + params["LODCategory.Key"] + "/" + params.Level, {
|
|
2520
|
+
"Level": 0,
|
|
2521
|
+
"ClientFile.ID": params["ClientFile.ID"]
|
|
2522
|
+
}, exports.Api.PrepReqParams())];
|
|
2523
|
+
});
|
|
2524
|
+
});
|
|
2525
|
+
}
|
|
2526
|
+
EntityLod.Update = Update;
|
|
2513
2527
|
})(exports.EntityLod || (exports.EntityLod = {}));
|
|
2514
2528
|
|
|
2515
2529
|
(function (EntityRelationType) {
|
|
@@ -3610,7 +3624,6 @@
|
|
|
3610
3624
|
(function (BatchedDataGetter) {
|
|
3611
3625
|
var Getter = /** @class */ (function () {
|
|
3612
3626
|
function Getter(data, viewPort, batchSize) {
|
|
3613
|
-
var _this = this;
|
|
3614
3627
|
this.viewPortRemoval = null;
|
|
3615
3628
|
this.viewRect = null;
|
|
3616
3629
|
this.viewCenter = null;
|
|
@@ -3618,10 +3631,6 @@
|
|
|
3618
3631
|
this.data = data;
|
|
3619
3632
|
this.viewPort = viewPort;
|
|
3620
3633
|
this.batchSize = batchSize;
|
|
3621
|
-
this.viewPortRemoval = this.viewPort.Updated().Subscribe(function () {
|
|
3622
|
-
_this.updateViewport();
|
|
3623
|
-
});
|
|
3624
|
-
this.updateViewport();
|
|
3625
3634
|
}
|
|
3626
3635
|
Object.defineProperty(Getter.prototype, "OnUpdate", {
|
|
3627
3636
|
get: function () {
|
|
@@ -3633,14 +3642,21 @@
|
|
|
3633
3642
|
enumerable: false,
|
|
3634
3643
|
configurable: true
|
|
3635
3644
|
});
|
|
3636
|
-
Getter.prototype.
|
|
3637
|
-
this
|
|
3638
|
-
this.
|
|
3645
|
+
Getter.prototype.Start = function () {
|
|
3646
|
+
var _this = this;
|
|
3647
|
+
this.viewPortRemoval = this.viewPort.Updated().Subscribe(function () {
|
|
3648
|
+
_this.updateViewport();
|
|
3649
|
+
});
|
|
3650
|
+
this.updateViewport();
|
|
3639
3651
|
};
|
|
3640
3652
|
Getter.prototype.Dispose = function () {
|
|
3641
3653
|
var _a;
|
|
3642
3654
|
(_a = this.viewPortRemoval) === null || _a === void 0 ? void 0 : _a.call(this);
|
|
3643
3655
|
};
|
|
3656
|
+
Getter.prototype.updateViewport = function () {
|
|
3657
|
+
this.updateBounds();
|
|
3658
|
+
this.startGetterLoop();
|
|
3659
|
+
};
|
|
3644
3660
|
Getter.prototype.updateBounds = function () {
|
|
3645
3661
|
var viewRect = this.viewPort.GetBounds();
|
|
3646
3662
|
var poi = this.viewPort.GetTarget();
|
|
@@ -3802,6 +3818,29 @@
|
|
|
3802
3818
|
})(V1 = Filter.V1 || (Filter.V1 = {}));
|
|
3803
3819
|
// TODO: Helpers for constructing the filter.
|
|
3804
3820
|
})(Filter = ClientFile.Filter || (ClientFile.Filter = {}));
|
|
3821
|
+
var Processor;
|
|
3822
|
+
(function (Processor) {
|
|
3823
|
+
var EConvertExt;
|
|
3824
|
+
(function (EConvertExt) {
|
|
3825
|
+
EConvertExt["GLB"] = ".glb";
|
|
3826
|
+
EConvertExt["SKP"] = ".skp";
|
|
3827
|
+
})(EConvertExt = Processor.EConvertExt || (Processor.EConvertExt = {}));
|
|
3828
|
+
function ConvertFormat(api, clientFileId, ext) {
|
|
3829
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
3830
|
+
return __generator(this, function (_a) {
|
|
3831
|
+
if (!clientFileId || !ext) {
|
|
3832
|
+
throw ("Client File ID and extension are required.");
|
|
3833
|
+
}
|
|
3834
|
+
return [2 /*return*/, api.POST("convertFileToFile", {
|
|
3835
|
+
clientFileId: clientFileId,
|
|
3836
|
+
destinationFormat: ext,
|
|
3837
|
+
operations: []
|
|
3838
|
+
}, exports.Api.PrepReqParams())];
|
|
3839
|
+
});
|
|
3840
|
+
});
|
|
3841
|
+
}
|
|
3842
|
+
Processor.ConvertFormat = ConvertFormat;
|
|
3843
|
+
})(Processor = ClientFile.Processor || (ClientFile.Processor = {}));
|
|
3805
3844
|
})(exports.ClientFile || (exports.ClientFile = {}));
|
|
3806
3845
|
|
|
3807
3846
|
(function (ProgramKey) {
|