bruce-models 0.1.6 → 0.1.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.
Files changed (175) hide show
  1. package/dist/bruce-models.es5.js +407 -11
  2. package/dist/bruce-models.es5.js.map +1 -1
  3. package/dist/bruce-models.umd.js +260 -10
  4. package/dist/bruce-models.umd.js.map +1 -1
  5. package/dist/lib/ann-document/ann-document.js +4 -0
  6. package/dist/lib/ann-document/ann-document.js.map +1 -1
  7. package/dist/lib/api/abstract-api.js +3 -0
  8. package/dist/lib/api/abstract-api.js.map +1 -1
  9. package/dist/lib/api/api.js +25 -7
  10. package/dist/lib/api/api.js.map +1 -1
  11. package/dist/lib/api/bruce-api.js +10 -0
  12. package/dist/lib/api/bruce-api.js.map +1 -1
  13. package/dist/lib/api/cam-api.js +10 -0
  14. package/dist/lib/api/cam-api.js.map +1 -1
  15. package/dist/lib/api/global-api.js +10 -0
  16. package/dist/lib/api/global-api.js.map +1 -1
  17. package/dist/lib/api/idm-api.js +10 -0
  18. package/dist/lib/api/idm-api.js.map +1 -1
  19. package/dist/lib/bruce-models.js +1 -0
  20. package/dist/lib/bruce-models.js.map +1 -1
  21. package/dist/lib/calculator/calculator.js +12 -0
  22. package/dist/lib/calculator/calculator.js.map +1 -1
  23. package/dist/lib/common/bruce-event.js +4 -0
  24. package/dist/lib/common/bruce-event.js.map +1 -1
  25. package/dist/lib/common/bruce-variable.js +13 -0
  26. package/dist/lib/common/bruce-variable.js.map +1 -1
  27. package/dist/lib/common/cache.js +3 -0
  28. package/dist/lib/common/cache.js.map +1 -1
  29. package/dist/lib/common/cartes.js +6 -0
  30. package/dist/lib/common/cartes.js.map +1 -1
  31. package/dist/lib/common/carto.js +5 -0
  32. package/dist/lib/common/carto.js.map +1 -1
  33. package/dist/lib/common/color.js +5 -0
  34. package/dist/lib/common/color.js.map +1 -1
  35. package/dist/lib/common/delay-queue.js +4 -0
  36. package/dist/lib/common/delay-queue.js.map +1 -1
  37. package/dist/lib/common/geometry.js +21 -0
  38. package/dist/lib/common/geometry.js.map +1 -1
  39. package/dist/lib/common/utc.js +3 -0
  40. package/dist/lib/common/utc.js.map +1 -1
  41. package/dist/lib/custom-form/custom-form.js +137 -0
  42. package/dist/lib/custom-form/custom-form.js.map +1 -0
  43. package/dist/lib/entity/entity-attachment-type.js +4 -3
  44. package/dist/lib/entity/entity-attachment-type.js.map +1 -1
  45. package/dist/lib/entity/entity-attachment.js +5 -0
  46. package/dist/lib/entity/entity-attachment.js.map +1 -1
  47. package/dist/lib/entity/entity-comment.js +4 -0
  48. package/dist/lib/entity/entity-comment.js.map +1 -1
  49. package/dist/lib/entity/entity-link.js +4 -0
  50. package/dist/lib/entity/entity-link.js.map +1 -1
  51. package/dist/lib/entity/entity-lod.js +6 -0
  52. package/dist/lib/entity/entity-lod.js.map +1 -1
  53. package/dist/lib/entity/entity-relation-type.js +4 -0
  54. package/dist/lib/entity/entity-relation-type.js.map +1 -1
  55. package/dist/lib/entity/entity-relation.js +5 -0
  56. package/dist/lib/entity/entity-relation.js.map +1 -1
  57. package/dist/lib/entity/entity-source.js +5 -0
  58. package/dist/lib/entity/entity-source.js.map +1 -1
  59. package/dist/lib/entity/entity-tag.js +5 -0
  60. package/dist/lib/entity/entity-tag.js.map +1 -1
  61. package/dist/lib/entity/entity-type.js +5 -0
  62. package/dist/lib/entity/entity-type.js.map +1 -1
  63. package/dist/lib/entity/entity.js +5 -0
  64. package/dist/lib/entity/entity.js.map +1 -1
  65. package/dist/lib/entity/getters/batched-data-getter.js +4 -0
  66. package/dist/lib/entity/getters/batched-data-getter.js.map +1 -1
  67. package/dist/lib/entity/getters/entity-filter-getter.js +5 -0
  68. package/dist/lib/entity/getters/entity-filter-getter.js.map +1 -1
  69. package/dist/lib/entity/getters/entity-globe.js +5 -0
  70. package/dist/lib/entity/getters/entity-globe.js.map +1 -1
  71. package/dist/lib/file/client-file.js +4 -0
  72. package/dist/lib/file/client-file.js.map +1 -1
  73. package/dist/lib/markup/markup.js +3 -0
  74. package/dist/lib/markup/markup.js.map +1 -1
  75. package/dist/lib/program-key/program-key.js +4 -0
  76. package/dist/lib/program-key/program-key.js.map +1 -1
  77. package/dist/lib/project/menu-item.js +5 -0
  78. package/dist/lib/project/menu-item.js.map +1 -1
  79. package/dist/lib/project/project-view-bookmark.js +6 -0
  80. package/dist/lib/project/project-view-bookmark.js.map +1 -1
  81. package/dist/lib/project/project-view-tile-source.js +5 -0
  82. package/dist/lib/project/project-view-tile-source.js.map +1 -1
  83. package/dist/lib/project/project-view.js +5 -0
  84. package/dist/lib/project/project-view.js.map +1 -1
  85. package/dist/lib/project/zoom-control.js +4 -0
  86. package/dist/lib/project/zoom-control.js.map +1 -1
  87. package/dist/lib/server/pending-action.js +5 -0
  88. package/dist/lib/server/pending-action.js.map +1 -1
  89. package/dist/lib/style/style.js +7 -0
  90. package/dist/lib/style/style.js.map +1 -1
  91. package/dist/lib/tileset/tileset-entities-map-tiles.js +5 -0
  92. package/dist/lib/tileset/tileset-entities-map-tiles.js.map +1 -1
  93. package/dist/lib/tileset/tileset-ext-map-tiles.js +4 -0
  94. package/dist/lib/tileset/tileset-ext-map-tiles.js.map +1 -1
  95. package/dist/lib/tileset/tileset.js +10 -0
  96. package/dist/lib/tileset/tileset.js.map +1 -1
  97. package/dist/lib/ucs/ucs.js +5 -0
  98. package/dist/lib/ucs/ucs.js.map +1 -1
  99. package/dist/lib/user/session.js +5 -0
  100. package/dist/lib/user/session.js.map +1 -1
  101. package/dist/lib/user/user-group.js +4 -0
  102. package/dist/lib/user/user-group.js.map +1 -1
  103. package/dist/lib/user/user.js +7 -0
  104. package/dist/lib/user/user.js.map +1 -1
  105. package/dist/lib/util/math-utils.js +12 -0
  106. package/dist/lib/util/math-utils.js.map +1 -1
  107. package/dist/lib/util/object-utils.js +4 -0
  108. package/dist/lib/util/object-utils.js.map +1 -1
  109. package/dist/lib/util/path-utils.js +3 -0
  110. package/dist/lib/util/path-utils.js.map +1 -1
  111. package/dist/lib/util/url-utils.js +6 -0
  112. package/dist/lib/util/url-utils.js.map +1 -1
  113. package/dist/types/ann-document/ann-document.d.ts +4 -0
  114. package/dist/types/api/abstract-api.d.ts +3 -0
  115. package/dist/types/api/api.d.ts +26 -8
  116. package/dist/types/api/bruce-api.d.ts +5 -0
  117. package/dist/types/api/cam-api.d.ts +5 -0
  118. package/dist/types/api/global-api.d.ts +5 -0
  119. package/dist/types/api/idm-api.d.ts +5 -0
  120. package/dist/types/bruce-models.d.ts +1 -0
  121. package/dist/types/calculator/calculator.d.ts +12 -0
  122. package/dist/types/common/bounds.d.ts +6 -0
  123. package/dist/types/common/bruce-event.d.ts +4 -0
  124. package/dist/types/common/bruce-variable.d.ts +13 -0
  125. package/dist/types/common/cache.d.ts +3 -0
  126. package/dist/types/common/cartes.d.ts +6 -0
  127. package/dist/types/common/carto.d.ts +5 -0
  128. package/dist/types/common/color.d.ts +5 -0
  129. package/dist/types/common/delay-queue.d.ts +4 -0
  130. package/dist/types/common/geometry.d.ts +21 -0
  131. package/dist/types/common/transform.d.ts +4 -0
  132. package/dist/types/common/utc.d.ts +3 -0
  133. package/dist/types/custom-form/custom-form.d.ts +25 -0
  134. package/dist/types/entity/entity-attachment-type.d.ts +5 -4
  135. package/dist/types/entity/entity-attachment.d.ts +5 -0
  136. package/dist/types/entity/entity-comment.d.ts +4 -0
  137. package/dist/types/entity/entity-link.d.ts +4 -0
  138. package/dist/types/entity/entity-lod.d.ts +6 -0
  139. package/dist/types/entity/entity-relation-type.d.ts +4 -0
  140. package/dist/types/entity/entity-relation.d.ts +5 -0
  141. package/dist/types/entity/entity-source.d.ts +5 -0
  142. package/dist/types/entity/entity-tag.d.ts +5 -0
  143. package/dist/types/entity/entity-type.d.ts +5 -0
  144. package/dist/types/entity/entity.d.ts +5 -0
  145. package/dist/types/entity/getters/batched-data-getter.d.ts +4 -0
  146. package/dist/types/entity/getters/entity-filter-getter.d.ts +5 -0
  147. package/dist/types/entity/getters/entity-globe.d.ts +5 -0
  148. package/dist/types/file/client-file.d.ts +4 -0
  149. package/dist/types/markup/markup.d.ts +3 -0
  150. package/dist/types/program-key/program-key.d.ts +4 -0
  151. package/dist/types/project/menu-item.d.ts +5 -0
  152. package/dist/types/project/project-view-bookmark.d.ts +6 -0
  153. package/dist/types/project/project-view-tile-source.d.ts +5 -0
  154. package/dist/types/project/project-view.d.ts +5 -0
  155. package/dist/types/project/zoom-control.d.ts +4 -0
  156. package/dist/types/server/pending-action.d.ts +5 -0
  157. package/dist/types/style/style.d.ts +7 -0
  158. package/dist/types/tileset/tileset-cad.d.ts +4 -0
  159. package/dist/types/tileset/tileset-entities-map-tiles.d.ts +5 -0
  160. package/dist/types/tileset/tileset-entities.d.ts +4 -0
  161. package/dist/types/tileset/tileset-ext-map-tiles.d.ts +4 -0
  162. package/dist/types/tileset/tileset-ext-terrain-tiles.d.ts +4 -0
  163. package/dist/types/tileset/tileset-map-tiles.d.ts +4 -0
  164. package/dist/types/tileset/tileset-pointcloud.d.ts +4 -0
  165. package/dist/types/tileset/tileset-terrain-tiles.d.ts +4 -0
  166. package/dist/types/tileset/tileset.d.ts +10 -0
  167. package/dist/types/ucs/ucs.d.ts +5 -0
  168. package/dist/types/user/session.d.ts +5 -0
  169. package/dist/types/user/user-group.d.ts +4 -0
  170. package/dist/types/user/user.d.ts +7 -0
  171. package/dist/types/util/math-utils.d.ts +12 -0
  172. package/dist/types/util/object-utils.d.ts +4 -0
  173. package/dist/types/util/path-utils.d.ts +3 -0
  174. package/dist/types/util/url-utils.d.ts +6 -0
  175. package/package.json +1 -1
@@ -75,6 +75,9 @@ function __generator(thisArg, body) {
75
75
  }
76
76
  }
77
77
 
78
+ /**
79
+ * Contains generic descriptions used for Bruce requests.
80
+ */
78
81
  var Api;
79
82
  (function (Api) {
80
83
  var ECacheKey;
@@ -106,10 +109,27 @@ var Api;
106
109
  ECacheKey["AccessToken"] = "accesstoken";
107
110
  ECacheKey["UserGroup"] = "usergroup";
108
111
  ECacheKey["Account"] = "account";
112
+ ECacheKey["CustomForm"] = "customform";
109
113
  })(ECacheKey = Api.ECacheKey || (Api.ECacheKey = {}));
110
114
  Api.DEFAULT_CACHE_DURATION = 60 * 5; // 5 minutes.
111
115
  Api.TEMPLATE_ACCOUNT_ID = "template";
112
116
  Api.ACCESS_TOKEN_HEADER = "X-Access-Token";
117
+ /**
118
+ * Possible environments we host Bruce apps on.
119
+ * When these are matched, they should be case-insensitive.
120
+ */
121
+ var EEnv;
122
+ (function (EEnv) {
123
+ EEnv["DEV"] = "DEV";
124
+ EEnv["STG"] = "STG";
125
+ EEnv["UAT"] = "UAT";
126
+ EEnv["PROD"] = "PROD";
127
+ })(EEnv = Api.EEnv || (Api.EEnv = {}));
128
+ /**
129
+ * Prepares a string to be included in a url.
130
+ * @param str
131
+ * @returns
132
+ */
113
133
  function Encode(str) {
114
134
  return encodeURIComponent(str.replace(/\+/g, "%2B").replace(/\./g, "%2E"));
115
135
  }
@@ -125,19 +145,21 @@ var Api;
125
145
  EEncoding["UTF8"] = "UTF-8";
126
146
  EEncoding["UTF16"] = "UTF-16BE";
127
147
  })(EEncoding = Api.EEncoding || (Api.EEncoding = {}));
128
- var EEnv;
129
- (function (EEnv) {
130
- EEnv["DEV"] = "DEV";
131
- EEnv["STG"] = "STG";
132
- EEnv["UAT"] = "UAT";
133
- EEnv["PROD"] = "PROD";
134
- })(EEnv = Api.EEnv || (Api.EEnv = {}));
148
+ /**
149
+ * Prepares default settings for a request to Bruce Api.
150
+ * Our requests WRONGLY have utf-16 for 95% of them. Please be wary of that.
151
+ * @returns
152
+ */
135
153
  function PrepReqParams() {
136
154
  return { response: { encoding: Api.EEncoding.UTF16 } };
137
155
  }
138
156
  Api.PrepReqParams = PrepReqParams;
139
157
  })(Api || (Api = {}));
140
158
 
159
+ /**
160
+ * Describes communication with the "Annotated Document" concept in Bruce.
161
+ * Annotated documents are files with hotspots that can link to Entity records.
162
+ */
141
163
  var AnnDocument;
142
164
  (function (AnnDocument) {
143
165
  function GetCacheKey(id) {
@@ -211,6 +233,103 @@ var AnnDocument;
211
233
  AnnDocument.GetList = GetList;
212
234
  })(AnnDocument || (AnnDocument = {}));
213
235
 
236
+ /**
237
+ * Describes the "Custom Form" concept within Bruce.
238
+ * Custom forms are dynamic dialogs that get populated with Entity data.
239
+ */
240
+ var CustomForm;
241
+ (function (CustomForm) {
242
+ function GetCacheKey(id) {
243
+ return Api.ECacheKey.CustomForm + Api.ECacheKey.Id + id;
244
+ }
245
+ CustomForm.GetCacheKey = GetCacheKey;
246
+ function GetListCacheKey(typeId) {
247
+ if (typeId) {
248
+ return Api.ECacheKey.CustomForm + Api.ECacheKey.EntityType + Api.ECacheKey.Id + typeId;
249
+ }
250
+ return Api.ECacheKey.CustomForm;
251
+ }
252
+ CustomForm.GetListCacheKey = GetListCacheKey;
253
+ var EType;
254
+ (function (EType) {
255
+ EType["Form"] = "GENERIC";
256
+ EType["Markup"] = "MARKUP";
257
+ })(EType = CustomForm.EType || (CustomForm.EType = {}));
258
+ function Get(api, id) {
259
+ return __awaiter(this, void 0, void 0, function () {
260
+ var cacheData, req;
261
+ return __generator(this, function (_a) {
262
+ if (!id) {
263
+ throw ("Id is required.");
264
+ }
265
+ cacheData = api.Cache.Get(GetCacheKey(id));
266
+ if (cacheData) {
267
+ return [2 /*return*/, cacheData];
268
+ }
269
+ req = api.GET("customForm/" + id, Api.PrepReqParams());
270
+ api.Cache.Set(GetCacheKey(id), req, Api.DEFAULT_CACHE_DURATION);
271
+ return [2 /*return*/, req];
272
+ });
273
+ });
274
+ }
275
+ CustomForm.Get = Get;
276
+ function Delete(api, id) {
277
+ return __awaiter(this, void 0, void 0, function () {
278
+ return __generator(this, function (_a) {
279
+ switch (_a.label) {
280
+ case 0:
281
+ if (!id) {
282
+ throw ("Id is required.");
283
+ }
284
+ return [4 /*yield*/, api.DELETE("customForm/" + id, Api.PrepReqParams())];
285
+ case 1:
286
+ _a.sent();
287
+ api.Cache.RemoveByStartsWith(Api.ECacheKey.CustomForm);
288
+ return [2 /*return*/];
289
+ }
290
+ });
291
+ });
292
+ }
293
+ CustomForm.Delete = Delete;
294
+ function GetList(api, typeId) {
295
+ return __awaiter(this, void 0, void 0, function () {
296
+ var url, cacheData, req, prom;
297
+ return __generator(this, function (_a) {
298
+ url = typeId ? "entityType/" + typeId + "/customForms" : "customForms";
299
+ cacheData = api.Cache.Get(GetListCacheKey(typeId));
300
+ if (cacheData) {
301
+ return [2 /*return*/, cacheData];
302
+ }
303
+ req = api.GET(url, Api.PrepReqParams());
304
+ prom = req.then(function (data) {
305
+ return data.Items;
306
+ });
307
+ api.Cache.Set(GetListCacheKey(typeId), prom, Api.DEFAULT_CACHE_DURATION);
308
+ return [2 /*return*/, prom];
309
+ });
310
+ });
311
+ }
312
+ CustomForm.GetList = GetList;
313
+ function Update(api, data) {
314
+ return __awaiter(this, void 0, void 0, function () {
315
+ return __generator(this, function (_a) {
316
+ switch (_a.label) {
317
+ case 0:
318
+ if (!data.ID) {
319
+ data.ID = 0;
320
+ }
321
+ return [4 /*yield*/, api.POST("customForm/" + data.ID, data, Api.PrepReqParams())];
322
+ case 1:
323
+ data = _a.sent();
324
+ api.Cache.RemoveByStartsWith(Api.ECacheKey.CustomForm);
325
+ return [2 /*return*/, data];
326
+ }
327
+ });
328
+ });
329
+ }
330
+ CustomForm.Update = Update;
331
+ })(CustomForm || (CustomForm = {}));
332
+
214
333
  var CacheItem = /** @class */ (function () {
215
334
  function CacheItem(id, data, duration) {
216
335
  this.Id = id;
@@ -226,6 +345,9 @@ var CacheItem = /** @class */ (function () {
226
345
  };
227
346
  return CacheItem;
228
347
  }());
348
+ /**
349
+ * Simple local cache controller.
350
+ */
229
351
  var CacheControl = /** @class */ (function () {
230
352
  function CacheControl() {
231
353
  this.data = {};
@@ -314,6 +436,9 @@ function parseResult(data, encoding) {
314
436
  });
315
437
  });
316
438
  }
439
+ /**
440
+ * This is a base class for communication with an arbitrary Bruce Api.
441
+ */
317
442
  var AbstractApi = /** @class */ (function () {
318
443
  function AbstractApi(ssidHeader) {
319
444
  this.ssid = "";
@@ -468,6 +593,10 @@ var AbstractApi = /** @class */ (function () {
468
593
  return AbstractApi;
469
594
  }());
470
595
 
596
+ /**
597
+ * This is the request handler for Bruce Api,
598
+ * it should be passed to any method that wants to communicate with this particular api.
599
+ */
471
600
  var BruceApi = /** @class */ (function (_super) {
472
601
  __extends(BruceApi, _super);
473
602
  function BruceApi(accountId, env) {
@@ -503,6 +632,12 @@ var BruceApi = /** @class */ (function (_super) {
503
632
  BruceApi.prototype.GetBaseUrl = function () {
504
633
  return this.baseUrl;
505
634
  };
635
+ BruceApi.prototype.SetBaseUrl = function (url) {
636
+ this.baseUrl = url;
637
+ if (!this.baseUrl.endsWith("/")) {
638
+ this.baseUrl += "/";
639
+ }
640
+ };
506
641
  BruceApi.prototype.GET = function (url, params) {
507
642
  return __awaiter(this, void 0, void 0, function () {
508
643
  return __generator(this, function (_a) {
@@ -534,6 +669,10 @@ var BruceApi = /** @class */ (function (_super) {
534
669
  return BruceApi;
535
670
  }(AbstractApi));
536
671
 
672
+ /**
673
+ * This is the request handler for Cam Api,
674
+ * it should be passed to any method that wants to communicate with this particular api.
675
+ */
537
676
  var CamApi = /** @class */ (function (_super) {
538
677
  __extends(CamApi, _super);
539
678
  function CamApi(env) {
@@ -568,6 +707,12 @@ var CamApi = /** @class */ (function (_super) {
568
707
  CamApi.prototype.GetBaseUrl = function () {
569
708
  return this.baseUrl;
570
709
  };
710
+ CamApi.prototype.SetBaseUrl = function (url) {
711
+ this.baseUrl = url;
712
+ if (!this.baseUrl.endsWith("/")) {
713
+ this.baseUrl += "/";
714
+ }
715
+ };
571
716
  CamApi.prototype.GET = function (url, params) {
572
717
  return __awaiter(this, void 0, void 0, function () {
573
718
  return __generator(this, function (_a) {
@@ -599,6 +744,10 @@ var CamApi = /** @class */ (function (_super) {
599
744
  return CamApi;
600
745
  }(AbstractApi));
601
746
 
747
+ /**
748
+ * This is the request handler for Idm Api,
749
+ * it should be passed to any method that wants to communicate with this particular api.
750
+ */
602
751
  var IdmApi = /** @class */ (function (_super) {
603
752
  __extends(IdmApi, _super);
604
753
  function IdmApi(env) {
@@ -633,6 +782,12 @@ var IdmApi = /** @class */ (function (_super) {
633
782
  IdmApi.prototype.GetBaseUrl = function () {
634
783
  return this.baseUrl;
635
784
  };
785
+ IdmApi.prototype.SetBaseUrl = function (url) {
786
+ this.baseUrl = url;
787
+ if (!this.baseUrl.endsWith("/")) {
788
+ this.baseUrl += "/";
789
+ }
790
+ };
636
791
  IdmApi.prototype.GET = function (url, params) {
637
792
  return __awaiter(this, void 0, void 0, function () {
638
793
  return __generator(this, function (_a) {
@@ -684,6 +839,11 @@ var Color;
684
839
  return ColorFromStr(str);
685
840
  }
686
841
  Color.RandomColor = RandomColor;
842
+ /**
843
+ * Attempts to parse a given color string into a model.
844
+ * @param str
845
+ * @returns
846
+ */
687
847
  function ColorFromStr(str) {
688
848
  var r, g, b, a;
689
849
  var rgba = /^rgba?\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(?:,\s*([^\)]+)\s*)?\)$/.exec(str);
@@ -745,6 +905,10 @@ var Color;
745
905
 
746
906
  var ObjectUtils;
747
907
  (function (ObjectUtils) {
908
+ /**
909
+ * Generates a Bruce compatible UID.
910
+ * @returns
911
+ */
748
912
  function UId() {
749
913
  return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function (c) {
750
914
  var r = Math.random() * 16 | 0, v = c == "x" ? r : (r & 0x3 | 0x8);
@@ -754,6 +918,9 @@ var ObjectUtils;
754
918
  ObjectUtils.UId = UId;
755
919
  })(ObjectUtils || (ObjectUtils = {}));
756
920
 
921
+ /**
922
+ * Utility to help with parsing and wrapping Bruce paths.
923
+ */
757
924
  var PathUtils;
758
925
  (function (PathUtils) {
759
926
  function Parse(str) {
@@ -810,6 +977,11 @@ var PathUtils;
810
977
  PathUtils.ParseLegacy = ParseLegacy;
811
978
  })(PathUtils || (PathUtils = {}));
812
979
 
980
+ /**
981
+ * Describes the "Entity" concept within Bruce.
982
+ * An entity is a JSON blob containing both internal data and user-defined data.
983
+ * Entity records have many thinks linked to them through their UIDs such as links, files and relationships.
984
+ */
813
985
  var Entity;
814
986
  (function (Entity) {
815
987
  function GetCacheKey(entityId) {
@@ -1090,8 +1262,21 @@ function getVariable(str) {
1090
1262
  }
1091
1263
  return null;
1092
1264
  }
1265
+ /**
1266
+ * Utilities for parsing "Bruce variables", typically within strings.
1267
+ *
1268
+ * A Bruce variable is a string that starts with "${" and ends with "}".
1269
+ * Within those brackets is a path to an attribute in an entity.
1270
+ */
1093
1271
  var BruceVariable;
1094
1272
  (function (BruceVariable) {
1273
+ /**
1274
+ * Replaces all Bruce variables in a string with the value of the attribute.
1275
+ * @param str
1276
+ * @param data
1277
+ * @param legacyParse
1278
+ * @returns
1279
+ */
1095
1280
  function SwapValues(str, data, legacyParse) {
1096
1281
  if (!legacyParse) {
1097
1282
  legacyParse = false;
@@ -1115,6 +1300,10 @@ var BruceVariable;
1115
1300
  BruceVariable.SwapValues = SwapValues;
1116
1301
  })(BruceVariable || (BruceVariable = {}));
1117
1302
 
1303
+ /**
1304
+ * Utility for calculating values from Bruce fields.
1305
+ * These fields are typically found in entity styles.
1306
+ */
1118
1307
  var Calculator;
1119
1308
  (function (Calculator) {
1120
1309
  var EValueType;
@@ -1126,6 +1315,14 @@ var Calculator;
1126
1315
  EValueType[EValueType["TagColor"] = 4] = "TagColor";
1127
1316
  EValueType[EValueType["RandomColor"] = 5] = "RandomColor";
1128
1317
  })(EValueType = Calculator.EValueType || (Calculator.EValueType = {}));
1318
+ /**
1319
+ * Calculates the value of arbitrary field options.
1320
+ * The context calling this should validate results and parse stuff if needed.
1321
+ * @param fields
1322
+ * @param entity
1323
+ * @param tags
1324
+ * @returns
1325
+ */
1129
1326
  function GetValue(fields, entity, tags) {
1130
1327
  if (!tags) {
1131
1328
  tags = [];
@@ -1247,6 +1444,10 @@ var Calculator;
1247
1444
  Calculator.GetInputValue = GetInputValue;
1248
1445
  })(Calculator || (Calculator = {}));
1249
1446
 
1447
+ /**
1448
+ * Simple event utility.
1449
+ * Instantiate the model, then subscribe and trigger events.
1450
+ */
1250
1451
  var BruceEvent = /** @class */ (function () {
1251
1452
  function BruceEvent() {
1252
1453
  // Counter to help differentiate subscriptions.
@@ -1297,6 +1498,12 @@ var Camera;
1297
1498
  })(EFrustum = Camera.EFrustum || (Camera.EFrustum = {}));
1298
1499
  })(Camera || (Camera = {}));
1299
1500
 
1501
+ /**
1502
+ * Describes 2d and 3d coordinates.
1503
+ *
1504
+ * In 2d the x/y typically refers to a window left/top offset.
1505
+ * In 3d the x/y/z, the units are in meters.
1506
+ */
1300
1507
  var Cartes;
1301
1508
  (function (Cartes) {
1302
1509
  function ValidateCartes2(cartes) {
@@ -1344,6 +1551,11 @@ var Cartes;
1344
1551
  Cartes.IsEqualCartes3 = IsEqualCartes3;
1345
1552
  })(Cartes || (Cartes = {}));
1346
1553
 
1554
+ /**
1555
+ * Describes a geographic point.
1556
+ * The units of the stored data should be in Degrees.
1557
+ * Utilities may use this in Radians for temporary calculations.
1558
+ */
1347
1559
  var Carto;
1348
1560
  (function (Carto) {
1349
1561
  function ValidateCarto(carto) {
@@ -1397,6 +1609,10 @@ var Carto;
1397
1609
  Carto.GetCenter = GetCenter;
1398
1610
  })(Carto || (Carto = {}));
1399
1611
 
1612
+ /**
1613
+ * Controls the flow of method calls.
1614
+ * If you have a method that may be called often, but you don't want it to run often, use this.
1615
+ */
1400
1616
  var DelayQueue = /** @class */ (function () {
1401
1617
  function DelayQueue(callback, delay) {
1402
1618
  if (delay === void 0) { delay = 200; }
@@ -1450,6 +1666,9 @@ var DelayQueue = /** @class */ (function () {
1450
1666
  return DelayQueue;
1451
1667
  }());
1452
1668
 
1669
+ /**
1670
+ * Describes vector geometry that Bruce uses.
1671
+ */
1453
1672
  var Geometry;
1454
1673
  (function (Geometry) {
1455
1674
  var EPolygonRingType;
@@ -1457,6 +1676,12 @@ var Geometry;
1457
1676
  EPolygonRingType["Boundaries"] = "out";
1458
1677
  EPolygonRingType["Hole"] = "in";
1459
1678
  })(EPolygonRingType = Geometry.EPolygonRingType || (Geometry.EPolygonRingType = {}));
1679
+ /**
1680
+ * Turns an array of points into string vector geometry that Bruce can use.
1681
+ * This is used for saving polyline and polygon data.
1682
+ * @param points
1683
+ * @returns
1684
+ */
1460
1685
  function LineStrFromPoints(points) {
1461
1686
  if (!points.length) {
1462
1687
  throw ("points is empty.");
@@ -1470,6 +1695,12 @@ var Geometry;
1470
1695
  return lineString;
1471
1696
  }
1472
1697
  Geometry.LineStrFromPoints = LineStrFromPoints;
1698
+ /**
1699
+ * Removes same points that occur in a row.
1700
+ * This will not modify the original array.
1701
+ * @param positions
1702
+ * @returns
1703
+ */
1473
1704
  function RemoveRepeatPoints(positions) {
1474
1705
  var filteredList = [];
1475
1706
  for (var i = 0; i < positions.length; i++) {
@@ -1517,6 +1748,12 @@ var Geometry;
1517
1748
  return result;
1518
1749
  }
1519
1750
  Geometry.ParsePoints = ParsePoints;
1751
+ /**
1752
+ * Parses both string and object Bruce geometry.
1753
+ * String geometry is legacy Bruce data.
1754
+ * @param geometry
1755
+ * @returns
1756
+ */
1520
1757
  function ParseGeometry(geometry) {
1521
1758
  if (typeof geometry == "string") {
1522
1759
  var positions = [];
@@ -1547,6 +1784,9 @@ var Geometry;
1547
1784
  Geometry.ParseGeometry = ParseGeometry;
1548
1785
  })(Geometry || (Geometry = {}));
1549
1786
 
1787
+ /**
1788
+ * Describes a Bruce stored date.
1789
+ */
1550
1790
  var UTC;
1551
1791
  (function (UTC) {
1552
1792
  var EMonth;
@@ -1581,6 +1821,10 @@ var UTC;
1581
1821
  UTC.FromDate = FromDate;
1582
1822
  })(UTC || (UTC = {}));
1583
1823
 
1824
+ /**
1825
+ * Describes the "Entity Attachment Type" concept within Bruce.
1826
+ * It is a record that describes the purpose of an attachment.
1827
+ */
1584
1828
  var EntityAttachmentType;
1585
1829
  (function (EntityAttachmentType) {
1586
1830
  function GetCacheKey(id) {
@@ -1595,9 +1839,6 @@ var EntityAttachmentType;
1595
1839
  (function (EType) {
1596
1840
  EType["Photo"] = "photo";
1597
1841
  EType["Document"] = "document";
1598
- EType["Video"] = "video";
1599
- EType["Drawing"] = "drawing";
1600
- EType["Model"] = "model";
1601
1842
  })(EType = EntityAttachmentType.EType || (EntityAttachmentType.EType = {}));
1602
1843
  function Delete(api, id) {
1603
1844
  return __awaiter(this, void 0, void 0, function () {
@@ -1673,6 +1914,11 @@ var EntityAttachmentType;
1673
1914
  EntityAttachmentType.GetList = GetList;
1674
1915
  })(EntityAttachmentType || (EntityAttachmentType = {}));
1675
1916
 
1917
+ /**
1918
+ * Describes the "Entity Attachment" concept within Bruce.
1919
+ * An entity attachment is an arbitrary file record that is linked to an entity record.
1920
+ * The same file can be attached to multiple entities.
1921
+ */
1676
1922
  var EntityAttachment;
1677
1923
  (function (EntityAttachment) {
1678
1924
  function GetCacheKey(entityId, typeId, fileId) {
@@ -1837,6 +2083,10 @@ var EntityAttachment;
1837
2083
  EntityAttachment.Upload = Upload;
1838
2084
  })(EntityAttachment || (EntityAttachment = {}));
1839
2085
 
2086
+ /**
2087
+ * Describes the "Entity Comment" concept within Bruce.
2088
+ * An entity comment is a user written message that is linked to an entity record.
2089
+ */
1840
2090
  var EntityComment;
1841
2091
  (function (EntityComment) {
1842
2092
  function GetCacheKey(id) {
@@ -1926,6 +2176,10 @@ var EntityComment;
1926
2176
  EntityComment.GetListByEntityId = GetListByEntityId;
1927
2177
  })(EntityComment || (EntityComment = {}));
1928
2178
 
2179
+ /**
2180
+ * Describes the "Entity Link" concept within Bruce.
2181
+ * An entity link is a URL linked to an entity record.
2182
+ */
1929
2183
  var EntityLink;
1930
2184
  (function (EntityLink) {
1931
2185
  function GetCacheKey(id) {
@@ -2015,6 +2269,12 @@ var EntityLink;
2015
2269
  EntityLink.GetListByEntityId = GetListByEntityId;
2016
2270
  })(EntityLink || (EntityLink = {}));
2017
2271
 
2272
+ /**
2273
+ * Describes the "Entity LOD" concept within Bruce.
2274
+ * LOD stands for Level of Detail.
2275
+ * An lod record is a possible 2d/3d visualization of the entity record.
2276
+ * The most common kind is a GLB.
2277
+ */
2018
2278
  var EntityLod;
2019
2279
  (function (EntityLod) {
2020
2280
  function GetCacheKey(url) {
@@ -2096,6 +2356,10 @@ var EntityLod;
2096
2356
  EntityLod.GetLods = GetLods;
2097
2357
  })(EntityLod || (EntityLod = {}));
2098
2358
 
2359
+ /**
2360
+ * Describes the "Entity Relationship Type" concept within Bruce.
2361
+ * A relationship type record describes the purpose of a relationship.
2362
+ */
2099
2363
  var EntityRelationType;
2100
2364
  (function (EntityRelationType) {
2101
2365
  function GetCacheKey(id) {
@@ -2202,6 +2466,11 @@ var EntityRelationType;
2202
2466
  EntityRelationType.Update = Update;
2203
2467
  })(EntityRelationType || (EntityRelationType = {}));
2204
2468
 
2469
+ /**
2470
+ * Describes the "Entity Relationship" concept within Bruce.
2471
+ * An entity relationship is an arbitrary link between two entity records.
2472
+ * The relationship can have a "data entity" linked to it as well for the relationship to store arbitrary data about itself.
2473
+ */
2205
2474
  var EntityRelation;
2206
2475
  (function (EntityRelation) {
2207
2476
  function GetCacheKey(entityA, entityB, typeId) {
@@ -2304,6 +2573,11 @@ var EntityRelation;
2304
2573
  EntityRelation.GetByDataEntityId = GetByDataEntityId;
2305
2574
  })(EntityRelation || (EntityRelation = {}));
2306
2575
 
2576
+ /**
2577
+ * Describes the "Entity Source" concept within Bruce.
2578
+ * An entity source is a record which links an arbitrary source id to a Bruce entity id.
2579
+ * For example an OSM building id to a Bruce entity id.
2580
+ */
2307
2581
  var EntitySource;
2308
2582
  (function (EntitySource) {
2309
2583
  function GetCacheKey(sourceId, sourceKey) {
@@ -2436,6 +2710,11 @@ var EntitySource;
2436
2710
  EntitySource.GetEntityIdsBySourceKeys = GetEntityIdsBySourceKeys;
2437
2711
  })(EntitySource || (EntitySource = {}));
2438
2712
 
2713
+ /**
2714
+ * Describes the "Entity Tag" concept within Bruce.
2715
+ * An entity tag is used to categorize an entity record.
2716
+ * Entity tags can be used in filters, or to restrict entity access.
2717
+ */
2439
2718
  var EntityTag;
2440
2719
  (function (EntityTag) {
2441
2720
  function GetCacheKey(tagId) {
@@ -2621,6 +2900,11 @@ var EntityTag;
2621
2900
  EntityTag.Update = Update;
2622
2901
  })(EntityTag || (EntityTag = {}));
2623
2902
 
2903
+ /**
2904
+ * Describes the "Entity Type" concept within Bruce.
2905
+ * An entity type is an "expectation" of what data "should" look like in a particular entity record.
2906
+ * The schema is stencils onto entity data to filter out what we should display or search against.
2907
+ */
2624
2908
  var EntityType;
2625
2909
  (function (EntityType) {
2626
2910
  function GetCacheKey(typeId) {
@@ -2831,6 +3115,11 @@ function getOrCreateCell(cells, cellSize, lon, maxLon, lat, maxLat) {
2831
3115
  }
2832
3116
  return cell;
2833
3117
  }
3118
+ /**
3119
+ * This is a helper for making entity requests based on a grid area.
3120
+ * It will return grid cells based on given view-area then will remember when stuff-
3121
+ * was fully-fetched for those cells to avoid making duplicate requests.
3122
+ */
2834
3123
  var EntityGlobe;
2835
3124
  (function (EntityGlobe) {
2836
3125
  var Grid = /** @class */ (function () {
@@ -2890,6 +3179,11 @@ function delay(milliseconds) {
2890
3179
  });
2891
3180
  });
2892
3181
  }
3182
+ /**
3183
+ * This is a batched entity getter.
3184
+ * It will scan for entity records in a view-area and emit them in batches.
3185
+ * It will restart scanning if the camera moves.
3186
+ */
2893
3187
  var EntityFilterGetter;
2894
3188
  (function (EntityFilterGetter) {
2895
3189
  var EStatus;
@@ -3165,6 +3459,10 @@ var EntityFilterGetter;
3165
3459
 
3166
3460
  var MAX_AREA_IN_DEGREES$1 = 90;
3167
3461
  var GETTER_DELAY = 50;
3462
+ /**
3463
+ * This is a batched "arbitrary data" getter.
3464
+ * You feed it an array of data, then it will emit that data in batches when the view changes.
3465
+ */
3168
3466
  var BatchedDataGetter;
3169
3467
  (function (BatchedDataGetter) {
3170
3468
  var Getter = /** @class */ (function () {
@@ -3236,6 +3534,10 @@ var BatchedDataGetter;
3236
3534
  BatchedDataGetter.Getter = Getter;
3237
3535
  })(BatchedDataGetter || (BatchedDataGetter = {}));
3238
3536
 
3537
+ /**
3538
+ * Describes the "Client File" concept within Bruce.
3539
+ * A client file is a record of a file uploaded to Bruce.
3540
+ */
3239
3541
  var ClientFile;
3240
3542
  (function (ClientFile) {
3241
3543
  function GetCacheKey(fileId) {
@@ -3348,6 +3650,10 @@ var ClientFile;
3348
3650
  })(Filter = ClientFile.Filter || (ClientFile.Filter = {}));
3349
3651
  })(ClientFile || (ClientFile = {}));
3350
3652
 
3653
+ /**
3654
+ * Describes the "Program Key" concept within Bruce.
3655
+ * A program key is an access token for an arbitrary software.
3656
+ */
3351
3657
  var ProgramKey;
3352
3658
  (function (ProgramKey) {
3353
3659
  function GetCacheKey(programId) {
@@ -3457,6 +3763,10 @@ var ProgramKey;
3457
3763
  ProgramKey.Update = Update;
3458
3764
  })(ProgramKey || (ProgramKey = {}));
3459
3765
 
3766
+ /**
3767
+ * Describes an expectation on what should be rendered for a menu item-
3768
+ * between a min-max distance of an entity to the camera.
3769
+ */
3460
3770
  var ZoomControl;
3461
3771
  (function (ZoomControl) {
3462
3772
  var EDisplayType;
@@ -3468,6 +3778,16 @@ var ZoomControl;
3468
3778
  })(EDisplayType = ZoomControl.EDisplayType || (ZoomControl.EDisplayType = {}));
3469
3779
  })(ZoomControl || (ZoomControl = {}));
3470
3780
 
3781
+ /**
3782
+ * Describes the "Tileset" concept in Bruce.
3783
+ *
3784
+ * Tilesets come in three possible variants,
3785
+ * 1- A set of instructions to generate a tileset.
3786
+ * 2- Settings to load a tileset hosted elsewhere.
3787
+ * 3- A set of user-provided files to serve.
3788
+ *
3789
+ * Read the individual tileset-type settings for each variant.
3790
+ */
3471
3791
  var Tileset;
3472
3792
  (function (Tileset) {
3473
3793
  function GetCacheKey(tilesetId, loadFiles) {
@@ -3805,6 +4125,11 @@ var Tileset;
3805
4125
  })(Publish = Tileset.Publish || (Tileset.Publish = {}));
3806
4126
  })(Tileset || (Tileset = {}));
3807
4127
 
4128
+ /**
4129
+ * Describes a menu item found in project views.
4130
+ * Menu items are used to dictate what data to load in a scene.
4131
+ * A menu item may be a container for other items.
4132
+ */
3808
4133
  var MenuItem;
3809
4134
  (function (MenuItem) {
3810
4135
  var EType;
@@ -3910,6 +4235,12 @@ var MenuItem;
3910
4235
  MenuItem.CreateFromTilesetId = CreateFromTilesetId;
3911
4236
  })(MenuItem || (MenuItem = {}));
3912
4237
 
4238
+ /**
4239
+ * Describe the "Project View Bookmark" concept within Bruce.
4240
+ * This is referred to as "slides" in older code.
4241
+ *
4242
+ * A bookmark is a snapshot of what should be displayed and how in a particular project view.
4243
+ */
3913
4244
  var ProjectViewBookmark;
3914
4245
  (function (ProjectViewBookmark) {
3915
4246
  function GetCacheKey(viewId, bookmarkId) {
@@ -4019,6 +4350,11 @@ var ProjectViewBookmark;
4019
4350
  ProjectViewBookmark.Update = Update;
4020
4351
  })(ProjectViewBookmark || (ProjectViewBookmark = {}));
4021
4352
 
4353
+ /**
4354
+ * Describes the "Project View" concept within Bruce.
4355
+ * A project view is a collection of settings for a visualization application we support.
4356
+ * It will describe what panels to show and how, it will also describe all possible ways data can be displayed.
4357
+ */
4022
4358
  var ProjectView;
4023
4359
  (function (ProjectView) {
4024
4360
  function GetCacheKey(viewId) {
@@ -4125,6 +4461,11 @@ var ProjectView;
4125
4461
  ProjectView.Update = Update;
4126
4462
  })(ProjectView || (ProjectView = {}));
4127
4463
 
4464
+ /**
4465
+ * Describes the "Pending Action" concept within Bruce.
4466
+ * A pending action is a record of a server-side background process.
4467
+ * This record is used to monitor its progress and completion state.
4468
+ */
4128
4469
  var PendingAction;
4129
4470
  (function (PendingAction) {
4130
4471
  var EStatus;
@@ -4187,6 +4528,13 @@ var PendingAction;
4187
4528
  PendingAction.GetMessages = GetMessages;
4188
4529
  })(PendingAction || (PendingAction = {}));
4189
4530
 
4531
+ /**
4532
+ * Describes the "Style" concept within Bruce.
4533
+ * A legacy way of referring to styles is "entity display settings".
4534
+ *
4535
+ * A style is a collection of settings (which can be calculations to perform on entity data) that
4536
+ * describe how an entity should be displayed.
4537
+ */
4190
4538
  var Style;
4191
4539
  (function (Style) {
4192
4540
  function GetCacheKey(id) {
@@ -4293,6 +4641,11 @@ var Style;
4293
4641
  Style.Delete = Delete;
4294
4642
  })(Style || (Style = {}));
4295
4643
 
4644
+ /**
4645
+ * Describes expected settings for an entities-map tileset.
4646
+ * This is the kind of tileset generated from arbitrary Bruce entities-
4647
+ * which produced map tiles of the entity vector geometry.
4648
+ */
4296
4649
  var TilesetEntitiesMapTiles;
4297
4650
  (function (TilesetEntitiesMapTiles) {
4298
4651
  var ETileSize;
@@ -4304,6 +4657,10 @@ var TilesetEntitiesMapTiles;
4304
4657
  })(ETileSize = TilesetEntitiesMapTiles.ETileSize || (TilesetEntitiesMapTiles.ETileSize = {}));
4305
4658
  })(TilesetEntitiesMapTiles || (TilesetEntitiesMapTiles = {}));
4306
4659
 
4660
+ /**
4661
+ * Describes settings for an external map-tiles tileset.
4662
+ * This will serve content from elsewhere with the assumption that the data is valid map tiles.
4663
+ */
4307
4664
  var TilesetExtMapTiles;
4308
4665
  (function (TilesetExtMapTiles) {
4309
4666
  var EType;
@@ -4315,6 +4672,11 @@ var TilesetExtMapTiles;
4315
4672
  })(EType = TilesetExtMapTiles.EType || (TilesetExtMapTiles.EType = {}));
4316
4673
  })(TilesetExtMapTiles || (TilesetExtMapTiles = {}));
4317
4674
 
4675
+ /**
4676
+ * Describes the "UCS" concept within Bruce.
4677
+ * A UCS is a user-coordinate-system.
4678
+ * It is a description of an offset to apply to tilesets so that they can all align with each other.
4679
+ */
4318
4680
  var Ucs;
4319
4681
  (function (Ucs) {
4320
4682
  function GetCacheKey(id, expandUsage) {
@@ -4424,6 +4786,11 @@ var Permission;
4424
4786
  })(EPermPrefix = Permission.EPermPrefix || (Permission.EPermPrefix = {}));
4425
4787
  })(Permission || (Permission = {}));
4426
4788
 
4789
+ /**
4790
+ * Describes the "Session" concept within Bruce.
4791
+ * A session is a set of settings produced from a user or access token login.
4792
+ * The session describes what the access should be allowed to do.
4793
+ */
4427
4794
  var Session;
4428
4795
  (function (Session) {
4429
4796
  function GetCacheKey(sessionId) {
@@ -4523,6 +4890,10 @@ var Session;
4523
4890
  Session.IsSuperAdmin = IsSuperAdmin;
4524
4891
  })(Session || (Session = {}));
4525
4892
 
4893
+ /**
4894
+ * Describes the "User Group" concept within Bruce.
4895
+ * A user group is a collection of permissions ("Features") and what users should be in the group.
4896
+ */
4526
4897
  var UserGroup;
4527
4898
  (function (UserGroup) {
4528
4899
  function GetByName(api, accountId, name) {
@@ -4620,6 +4991,13 @@ var UserGroup;
4620
4991
  UserGroup.Update = Update;
4621
4992
  })(UserGroup || (UserGroup = {}));
4622
4993
 
4994
+ /**
4995
+ * Describes the "User" concept within Bruce.
4996
+ * A user is either a login-user or an access-token.
4997
+ *
4998
+ * You cannot login using an access-token, but both concepts are-
4999
+ * treated the same way in terms of permissions and user groups.
5000
+ */
4623
5001
  var User;
4624
5002
  (function (User) {
4625
5003
  function GetCacheKey(userId, accountId) {
@@ -4839,6 +5217,12 @@ var EncryptUtils;
4839
5217
 
4840
5218
  var MathUtils;
4841
5219
  (function (MathUtils) {
5220
+ /**
5221
+ * Rounds a number to a given number of decimal places.
5222
+ * @param num
5223
+ * @param decimals
5224
+ * @returns
5225
+ */
4842
5226
  function Round(num, decimals) {
4843
5227
  if (decimals === void 0) { decimals = 0; }
4844
5228
  if (decimals <= 0) {
@@ -4852,6 +5236,12 @@ var MathUtils;
4852
5236
  return Math.round((num + Number.EPSILON) * d) / d;
4853
5237
  }
4854
5238
  MathUtils.Round = Round;
5239
+ /**
5240
+ * Returns a random integer between min (inclusive) and max (inclusive).
5241
+ * @param min
5242
+ * @param max
5243
+ * @returns
5244
+ */
4855
5245
  function RandInt(min, max) {
4856
5246
  if (min == max) {
4857
5247
  return min;
@@ -4864,6 +5254,9 @@ var MathUtils;
4864
5254
  MathUtils.RandInt = RandInt;
4865
5255
  })(MathUtils || (MathUtils = {}));
4866
5256
 
5257
+ /**
5258
+ * Utility to help with url manipulation.
5259
+ */
4867
5260
  var UrlUtils;
4868
5261
  (function (UrlUtils) {
4869
5262
  function GetQueryString(doc) {
@@ -4882,6 +5275,9 @@ var UrlUtils;
4882
5275
  return qs;
4883
5276
  }
4884
5277
  UrlUtils.GetQueryString = GetQueryString;
5278
+ /**
5279
+ * Helper to get and set url params for a given window.
5280
+ */
4885
5281
  var Handler = /** @class */ (function () {
4886
5282
  function Handler(window, allowedKeys) {
4887
5283
  this._allowedKeys = null;
@@ -4963,5 +5359,5 @@ var UrlUtils;
4963
5359
  UrlUtils.Handler = Handler;
4964
5360
  })(UrlUtils || (UrlUtils = {}));
4965
5361
 
4966
- export { AnnDocument, AbstractApi, Api, BruceApi, CamApi, IdmApi, Calculator, BruceEvent, CacheControl, Camera, Cartes, Carto, Color, DelayQueue, Geometry, UTC, EntityAttachmentType, EntityAttachment, EntityComment, EntityLink, EntityLod, EntityRelationType, EntityRelation, EntitySource, EntityTag, EntityType, Entity, EntityGlobe, EntityFilterGetter, BatchedDataGetter, ClientFile, ProgramKey, ZoomControl, MenuItem, ProjectViewBookmark, ProjectView, PendingAction, Style, TilesetEntitiesMapTiles, TilesetExtMapTiles, Tileset, Ucs, Permission, Session, UserGroup, User, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils };
5362
+ export { AnnDocument, CustomForm, AbstractApi, Api, BruceApi, CamApi, IdmApi, Calculator, BruceEvent, CacheControl, Camera, Cartes, Carto, Color, DelayQueue, Geometry, UTC, EntityAttachmentType, EntityAttachment, EntityComment, EntityLink, EntityLod, EntityRelationType, EntityRelation, EntitySource, EntityTag, EntityType, Entity, EntityGlobe, EntityFilterGetter, BatchedDataGetter, ClientFile, ProgramKey, ZoomControl, MenuItem, ProjectViewBookmark, ProjectView, PendingAction, Style, TilesetEntitiesMapTiles, TilesetExtMapTiles, Tileset, Ucs, Permission, Session, UserGroup, User, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils };
4967
5363
  //# sourceMappingURL=bruce-models.es5.js.map