bruce-models 1.1.3 → 1.1.6

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 (59) hide show
  1. package/dist/bruce-models.es5.js +58 -46
  2. package/dist/bruce-models.es5.js.map +1 -1
  3. package/dist/bruce-models.umd.js +58 -46
  4. package/dist/bruce-models.umd.js.map +1 -1
  5. package/dist/lib/account/account.js +3 -3
  6. package/dist/lib/account/account.js.map +1 -1
  7. package/dist/lib/ann-document/ann-document.js +2 -2
  8. package/dist/lib/ann-document/ann-document.js.map +1 -1
  9. package/dist/lib/api/abstract-api.js +11 -0
  10. package/dist/lib/api/abstract-api.js.map +1 -1
  11. package/dist/lib/api/api.js +2 -0
  12. package/dist/lib/api/api.js.map +1 -1
  13. package/dist/lib/client-file/client-file.js +1 -1
  14. package/dist/lib/client-file/client-file.js.map +1 -1
  15. package/dist/lib/custom-form/custom-form.js +2 -2
  16. package/dist/lib/custom-form/custom-form.js.map +1 -1
  17. package/dist/lib/entity/entity-attachment-type.js +1 -1
  18. package/dist/lib/entity/entity-attachment-type.js.map +1 -1
  19. package/dist/lib/entity/entity-attachment.js +1 -1
  20. package/dist/lib/entity/entity-attachment.js.map +1 -1
  21. package/dist/lib/entity/entity-comment.js +1 -1
  22. package/dist/lib/entity/entity-comment.js.map +1 -1
  23. package/dist/lib/entity/entity-coords.js +1 -1
  24. package/dist/lib/entity/entity-coords.js.map +1 -1
  25. package/dist/lib/entity/entity-link.js +1 -1
  26. package/dist/lib/entity/entity-link.js.map +1 -1
  27. package/dist/lib/entity/entity-lod.js +2 -2
  28. package/dist/lib/entity/entity-lod.js.map +1 -1
  29. package/dist/lib/entity/entity-relation-type.js +2 -2
  30. package/dist/lib/entity/entity-relation-type.js.map +1 -1
  31. package/dist/lib/entity/entity-relation.js +2 -2
  32. package/dist/lib/entity/entity-relation.js.map +1 -1
  33. package/dist/lib/entity/entity-source.js +2 -2
  34. package/dist/lib/entity/entity-source.js.map +1 -1
  35. package/dist/lib/entity/entity-tag.js +2 -2
  36. package/dist/lib/entity/entity-tag.js.map +1 -1
  37. package/dist/lib/entity/entity-type.js +2 -2
  38. package/dist/lib/entity/entity-type.js.map +1 -1
  39. package/dist/lib/entity/entity.js +2 -2
  40. package/dist/lib/entity/entity.js.map +1 -1
  41. package/dist/lib/import/imported-file.js +2 -2
  42. package/dist/lib/import/imported-file.js.map +1 -1
  43. package/dist/lib/program-key/program-key.js +2 -2
  44. package/dist/lib/program-key/program-key.js.map +1 -1
  45. package/dist/lib/project/project-view-bookmark.js +2 -2
  46. package/dist/lib/project/project-view-bookmark.js.map +1 -1
  47. package/dist/lib/project/project-view.js +2 -2
  48. package/dist/lib/project/project-view.js.map +1 -1
  49. package/dist/lib/style/style.js +2 -2
  50. package/dist/lib/style/style.js.map +1 -1
  51. package/dist/lib/tileset/tileset.js +4 -4
  52. package/dist/lib/tileset/tileset.js.map +1 -1
  53. package/dist/lib/user/session.js +1 -1
  54. package/dist/lib/user/session.js.map +1 -1
  55. package/dist/lib/user/user.js +4 -4
  56. package/dist/lib/user/user.js.map +1 -1
  57. package/dist/types/api/abstract-api.d.ts +1 -0
  58. package/dist/types/api/api.d.ts +1 -0
  59. package/package.json +1 -1
@@ -74,6 +74,8 @@ var Api;
74
74
  EEnv["UAT"] = "UAT";
75
75
  EEnv["PROD"] = "PROD";
76
76
  })(EEnv = Api.EEnv || (Api.EEnv = {}));
77
+ // False = cache is enabled by default for req-params.
78
+ Api.DEFAULT_NO_CACHE = false;
77
79
  /**
78
80
  * Prepares a string to be included in a url.
79
81
  * @param str
@@ -135,7 +137,7 @@ var AnnDocument;
135
137
  throw ("Doc ID is required.");
136
138
  }
137
139
  const key = GetCacheKey(docId);
138
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(key);
140
+ const cacheData = api.GetCacheItem(key, reqParams);
139
141
  if (cacheData) {
140
142
  return cacheData;
141
143
  }
@@ -150,7 +152,7 @@ var AnnDocument;
150
152
  if (!type) {
151
153
  type = "";
152
154
  }
153
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey(type));
155
+ const cacheData = api.GetCacheItem(GetListCacheKey(type), reqParams);
154
156
  if (cacheData) {
155
157
  return cacheData;
156
158
  }
@@ -198,7 +200,7 @@ var CustomForm;
198
200
  if (!id) {
199
201
  throw ("Id is required.");
200
202
  }
201
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(id));
203
+ const cacheData = api.GetCacheItem(GetCacheKey(id), reqParams);
202
204
  if (cacheData) {
203
205
  return cacheData;
204
206
  }
@@ -221,7 +223,7 @@ var CustomForm;
221
223
  function GetList(api, typeId, reqParams) {
222
224
  return __awaiter(this, void 0, void 0, function* () {
223
225
  const url = typeId ? `entityType/${typeId}/customForms` : "customForms";
224
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey(typeId));
226
+ const cacheData = api.GetCacheItem(GetListCacheKey(typeId), reqParams);
225
227
  if (cacheData) {
226
228
  return cacheData;
227
229
  }
@@ -459,6 +461,16 @@ class AbstractApi {
459
461
  this.Cache = new CacheControl();
460
462
  this.ssidHeader = ssidHeader;
461
463
  }
464
+ GetCacheItem(key, reqParams) {
465
+ let noCache = reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache;
466
+ if (noCache == null) {
467
+ noCache = Api.DEFAULT_NO_CACHE;
468
+ }
469
+ if (noCache) {
470
+ return null;
471
+ }
472
+ return this.Cache.Get(key);
473
+ }
462
474
  GetSessionId() {
463
475
  return this.ssid;
464
476
  }
@@ -660,7 +672,7 @@ var Account;
660
672
  ];
661
673
  function Get(api, id, reqParams) {
662
674
  return __awaiter(this, void 0, void 0, function* () {
663
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(id));
675
+ const cacheData = api.GetCacheItem(GetCacheKey(id), reqParams);
664
676
  if (cacheData) {
665
677
  return cacheData;
666
678
  }
@@ -672,7 +684,7 @@ var Account;
672
684
  Account.Get = Get;
673
685
  function GetRelatedList(api, reqParams) {
674
686
  return __awaiter(this, void 0, void 0, function* () {
675
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey(api.GetSessionId()));
687
+ const cacheData = api.GetCacheItem(GetListCacheKey(api.GetSessionId()), reqParams);
676
688
  if (cacheData) {
677
689
  return cacheData;
678
690
  }
@@ -694,7 +706,7 @@ var Account;
694
706
  Account.GetRelatedList = GetRelatedList;
695
707
  function GetAppSettings(api, id, appId, reqParams) {
696
708
  return __awaiter(this, void 0, void 0, function* () {
697
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(id, appId));
709
+ const cacheData = api.GetCacheItem(GetCacheKey(id, appId), reqParams);
698
710
  if (cacheData) {
699
711
  return cacheData;
700
712
  }
@@ -1438,7 +1450,7 @@ var Entity;
1438
1450
  throw ("Entity ID is required.");
1439
1451
  }
1440
1452
  const key = GetCacheKey(entityId);
1441
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(key);
1453
+ const cacheData = api.GetCacheItem(key, reqParams);
1442
1454
  if (cacheData) {
1443
1455
  return cacheData;
1444
1456
  }
@@ -1458,7 +1470,7 @@ var Entity;
1458
1470
  for (let i = 0; i < entityIds.length; i++) {
1459
1471
  const entityId = entityIds[i];
1460
1472
  const key = GetCacheKey(entityId);
1461
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(key);
1473
+ const cacheData = api.GetCacheItem(key, reqParams);
1462
1474
  if (cacheData) {
1463
1475
  reqs.push(cacheData);
1464
1476
  }
@@ -2437,7 +2449,7 @@ var EntityAttachmentType;
2437
2449
  EntityAttachmentType.Update = Update;
2438
2450
  function GetList(api, reqParams) {
2439
2451
  return __awaiter(this, void 0, void 0, function* () {
2440
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey());
2452
+ const cacheData = api.GetCacheItem(GetListCacheKey(), reqParams);
2441
2453
  if (cacheData) {
2442
2454
  return cacheData;
2443
2455
  }
@@ -2537,7 +2549,7 @@ var EntityAttachment;
2537
2549
  if (!entityId) {
2538
2550
  throw ("Entity ID is required.");
2539
2551
  }
2540
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey(entityId));
2552
+ const cacheData = api.GetCacheItem(GetListCacheKey(entityId), reqParams);
2541
2553
  if (cacheData) {
2542
2554
  return cacheData;
2543
2555
  }
@@ -2612,7 +2624,7 @@ var EntityComment;
2612
2624
  if (!entityId) {
2613
2625
  throw ("Entity ID is required.");
2614
2626
  }
2615
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey(entityId));
2627
+ const cacheData = api.GetCacheItem(GetListCacheKey(entityId), reqParams);
2616
2628
  if (cacheData) {
2617
2629
  return cacheData;
2618
2630
  }
@@ -2675,7 +2687,7 @@ var EntityLink;
2675
2687
  if (!entityId) {
2676
2688
  throw ("Entity ID is required.");
2677
2689
  }
2678
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey(entityId));
2690
+ const cacheData = api.GetCacheItem(GetListCacheKey(entityId), reqParams);
2679
2691
  if (cacheData) {
2680
2692
  return cacheData;
2681
2693
  }
@@ -2733,7 +2745,7 @@ var EntityLod;
2733
2745
  if (!url) {
2734
2746
  throw ("Url is required.");
2735
2747
  }
2736
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(url));
2748
+ const cacheData = api.GetCacheItem(GetCacheKey(url), reqParams);
2737
2749
  if (cacheData) {
2738
2750
  return cacheData;
2739
2751
  }
@@ -2774,7 +2786,7 @@ var EntityLod;
2774
2786
  if (!group) {
2775
2787
  group = "DEFAULT";
2776
2788
  }
2777
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetTypeListKey(typeId, group));
2789
+ const cacheData = api.GetCacheItem(GetTypeListKey(typeId, group), reqParams);
2778
2790
  if (cacheData) {
2779
2791
  return cacheData;
2780
2792
  }
@@ -2828,7 +2840,7 @@ var EntityRelationType;
2828
2840
  throw ("Type ID is required.");
2829
2841
  }
2830
2842
  const key = GetCacheKey(typeId);
2831
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(key);
2843
+ const cacheData = api.GetCacheItem(key, reqParams);
2832
2844
  if (cacheData) {
2833
2845
  return cacheData;
2834
2846
  }
@@ -2851,7 +2863,7 @@ var EntityRelationType;
2851
2863
  EntityRelationType.Delete = Delete;
2852
2864
  function GetList(api, reqParams) {
2853
2865
  return __awaiter(this, void 0, void 0, function* () {
2854
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey());
2866
+ const cacheData = api.GetCacheItem(GetListCacheKey(), reqParams);
2855
2867
  if (cacheData) {
2856
2868
  return cacheData;
2857
2869
  }
@@ -2951,7 +2963,7 @@ var EntityRelation;
2951
2963
  throw ("Entity ID is required.");
2952
2964
  }
2953
2965
  params = Object.assign({ typeId: "", oneWayOnly: false, loadEntityData: false }, params);
2954
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey(entityId, params));
2966
+ const cacheData = api.GetCacheItem(GetListCacheKey(entityId, params), reqParams);
2955
2967
  if (cacheData) {
2956
2968
  return cacheData;
2957
2969
  }
@@ -2979,7 +2991,7 @@ var EntityRelation;
2979
2991
  if (!entityId) {
2980
2992
  throw ("Entity ID is required.");
2981
2993
  }
2982
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetEntityCacheKey(entityId));
2994
+ const cacheData = api.GetCacheItem(GetEntityCacheKey(entityId), reqParams);
2983
2995
  if (cacheData) {
2984
2996
  return cacheData;
2985
2997
  }
@@ -3008,7 +3020,7 @@ var EntitySource;
3008
3020
  throw ("Source ID and Source Key are required.");
3009
3021
  }
3010
3022
  const key = GetCacheKey(sourceId, sourceKey);
3011
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(key);
3023
+ const cacheData = api.GetCacheItem(key, reqParams);
3012
3024
  if (cacheData) {
3013
3025
  return cacheData;
3014
3026
  }
@@ -3027,7 +3039,7 @@ var EntitySource;
3027
3039
  const reqs = [];
3028
3040
  for (let i = 0; i < sourceKeys.length; i++) {
3029
3041
  const sourceKey = sourceKeys[i];
3030
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(sourceId, sourceKey));
3042
+ const cacheData = api.GetCacheItem(GetCacheKey(sourceId, sourceKey), reqParams);
3031
3043
  if (cacheData) {
3032
3044
  reqs.push(cacheData);
3033
3045
  }
@@ -3123,7 +3135,7 @@ var EntityTag;
3123
3135
  const reqs = [];
3124
3136
  for (let i = 0; i < tagIds.length; i++) {
3125
3137
  const tagId = tagIds[i];
3126
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(tagId));
3138
+ const cacheData = api.GetCacheItem(GetCacheKey(tagId), reqParams);
3127
3139
  if (cacheData) {
3128
3140
  reqs.push(cacheData);
3129
3141
  }
@@ -3163,7 +3175,7 @@ var EntityTag;
3163
3175
  EntityTag.GetListByIds = GetListByIds;
3164
3176
  function GetList(api, entityTypeId, reqParams) {
3165
3177
  return __awaiter(this, void 0, void 0, function* () {
3166
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey(entityTypeId));
3178
+ const cacheData = api.GetCacheItem(GetListCacheKey(entityTypeId), reqParams);
3167
3179
  if (cacheData) {
3168
3180
  return cacheData;
3169
3181
  }
@@ -3238,7 +3250,7 @@ var EntityType;
3238
3250
  throw ("Type ID is required.");
3239
3251
  }
3240
3252
  const key = GetCacheKey(typeId);
3241
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(key);
3253
+ const cacheData = api.GetCacheItem(key, reqParams);
3242
3254
  if (cacheData) {
3243
3255
  return cacheData;
3244
3256
  }
@@ -3261,7 +3273,7 @@ var EntityType;
3261
3273
  EntityType.Delete = Delete;
3262
3274
  function GetList(api, reqParams) {
3263
3275
  return __awaiter(this, void 0, void 0, function* () {
3264
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey());
3276
+ const cacheData = api.GetCacheItem(GetListCacheKey(), reqParams);
3265
3277
  if (cacheData) {
3266
3278
  return cacheData;
3267
3279
  }
@@ -3890,7 +3902,7 @@ var EntityCoords;
3890
3902
  EntityCoords.GetCacheKey = GetCacheKey;
3891
3903
  function GetEntityCoords(api, entityId, reqParams) {
3892
3904
  return __awaiter(this, void 0, void 0, function* () {
3893
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(entityId));
3905
+ const cacheData = api.GetCacheItem(GetCacheKey(entityId), reqParams);
3894
3906
  if (cacheData) {
3895
3907
  return cacheData;
3896
3908
  }
@@ -4019,7 +4031,7 @@ var ClientFile;
4019
4031
  throw ("File ID is required.");
4020
4032
  }
4021
4033
  const key = GetCacheKey(fileId);
4022
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(key);
4034
+ const cacheData = api.GetCacheItem(key, reqParams);
4023
4035
  if (cacheData) {
4024
4036
  return cacheData;
4025
4037
  }
@@ -4172,7 +4184,7 @@ var ProgramKey;
4172
4184
  throw ("Program ID is required.");
4173
4185
  }
4174
4186
  const key = GetCacheKey(programId);
4175
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(key);
4187
+ const cacheData = api.GetCacheItem(key, reqParams);
4176
4188
  if (cacheData) {
4177
4189
  return cacheData;
4178
4190
  }
@@ -4184,7 +4196,7 @@ var ProgramKey;
4184
4196
  ProgramKey.Get = Get;
4185
4197
  function GetList(api, reqParams) {
4186
4198
  return __awaiter(this, void 0, void 0, function* () {
4187
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey());
4199
+ const cacheData = api.GetCacheItem(GetListCacheKey(), reqParams);
4188
4200
  if (cacheData) {
4189
4201
  return cacheData;
4190
4202
  }
@@ -4285,7 +4297,7 @@ var Tileset;
4285
4297
  if (!tilesetId) {
4286
4298
  throw ("Tileset ID is required.");
4287
4299
  }
4288
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(tilesetId, loadFiles));
4300
+ const cacheData = api.GetCacheItem(GetCacheKey(tilesetId, loadFiles), reqParams);
4289
4301
  if (cacheData) {
4290
4302
  return cacheData;
4291
4303
  }
@@ -4297,7 +4309,7 @@ var Tileset;
4297
4309
  Tileset.Get = Get;
4298
4310
  function GetList(api, reqParams) {
4299
4311
  return __awaiter(this, void 0, void 0, function* () {
4300
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey());
4312
+ const cacheData = api.GetCacheItem(GetListCacheKey(), reqParams);
4301
4313
  if (cacheData) {
4302
4314
  return cacheData;
4303
4315
  }
@@ -4458,7 +4470,7 @@ var Tileset;
4458
4470
  if (!accountId || !tilesetId) {
4459
4471
  throw ("Client account ID and tileset ID are required.");
4460
4472
  }
4461
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(accountId, tilesetId));
4473
+ const cacheData = api.GetCacheItem(GetCacheKey(accountId, tilesetId), reqParams);
4462
4474
  if (cacheData) {
4463
4475
  return cacheData;
4464
4476
  }
@@ -4473,7 +4485,7 @@ var Tileset;
4473
4485
  if (!accountId) {
4474
4486
  throw ("Client account ID is required.");
4475
4487
  }
4476
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(accountId));
4488
+ const cacheData = api.GetCacheItem(GetCacheKey(accountId), reqParams);
4477
4489
  if (cacheData) {
4478
4490
  return cacheData;
4479
4491
  }
@@ -4637,7 +4649,7 @@ var ProjectViewBookmark;
4637
4649
  throw ("View ID and Bookmark ID are required.");
4638
4650
  }
4639
4651
  const key = GetCacheKey(viewId, bookmarkId);
4640
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(key);
4652
+ const cacheData = api.GetCacheItem(key, reqParams);
4641
4653
  if (cacheData) {
4642
4654
  return cacheData;
4643
4655
  }
@@ -4663,7 +4675,7 @@ var ProjectViewBookmark;
4663
4675
  if (!viewId) {
4664
4676
  throw ("View ID is required.");
4665
4677
  }
4666
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey(viewId));
4678
+ const cacheData = api.GetCacheItem(GetListCacheKey(viewId), reqParams);
4667
4679
  if (cacheData) {
4668
4680
  return cacheData;
4669
4681
  }
@@ -4749,7 +4761,7 @@ var ProjectView;
4749
4761
  throw ("View ID is required.");
4750
4762
  }
4751
4763
  const key = GetCacheKey(viewId);
4752
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(key);
4764
+ const cacheData = api.GetCacheItem(key, reqParams);
4753
4765
  if (cacheData) {
4754
4766
  return cacheData;
4755
4767
  }
@@ -4761,7 +4773,7 @@ var ProjectView;
4761
4773
  ProjectView.Get = Get;
4762
4774
  function GetList(api, reqParams) {
4763
4775
  return __awaiter(this, void 0, void 0, function* () {
4764
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey());
4776
+ const cacheData = api.GetCacheItem(GetListCacheKey(), reqParams);
4765
4777
  if (cacheData) {
4766
4778
  return cacheData;
4767
4779
  }
@@ -5068,7 +5080,7 @@ var Style;
5068
5080
  EPointType["Cylinder"] = "CYLINDER";
5069
5081
  })(EPointType = Style.EPointType || (Style.EPointType = {}));
5070
5082
  function GetList(api, reqParams) {
5071
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey());
5083
+ const cacheData = api.GetCacheItem(GetListCacheKey(), reqParams);
5072
5084
  if (cacheData) {
5073
5085
  return cacheData;
5074
5086
  }
@@ -5089,7 +5101,7 @@ var Style;
5089
5101
  if (!id) {
5090
5102
  throw ("Style ID is required.");
5091
5103
  }
5092
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(id));
5104
+ const cacheData = api.GetCacheItem(GetCacheKey(id), reqParams);
5093
5105
  if (cacheData) {
5094
5106
  return cacheData;
5095
5107
  }
@@ -5191,7 +5203,7 @@ var Session;
5191
5203
  throw ("Session ID is required.");
5192
5204
  }
5193
5205
  const key = GetCacheKey(sessionId);
5194
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(key);
5206
+ const cacheData = api.GetCacheItem(key, reqParams);
5195
5207
  if (cacheData) {
5196
5208
  return cacheData;
5197
5209
  }
@@ -5374,7 +5386,7 @@ var User;
5374
5386
  if (!id) {
5375
5387
  throw ("ID is required.");
5376
5388
  }
5377
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(id, accountId));
5389
+ const cacheData = api.GetCacheItem(GetCacheKey(id, accountId), reqParams);
5378
5390
  if (cacheData) {
5379
5391
  return cacheData;
5380
5392
  }
@@ -5431,7 +5443,7 @@ var User;
5431
5443
  if (!email) {
5432
5444
  throw ("Email is required.");
5433
5445
  }
5434
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetEmailCacheKey(email, accountId));
5446
+ const cacheData = api.GetCacheItem(GetEmailCacheKey(email, accountId), reqParams);
5435
5447
  if (cacheData) {
5436
5448
  return cacheData;
5437
5449
  }
@@ -5449,7 +5461,7 @@ var User;
5449
5461
  if (!exclusive) {
5450
5462
  exclusive = false;
5451
5463
  }
5452
- const cacheData = exclusive || (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey(accountId));
5464
+ const cacheData = exclusive ? null : api.GetCacheItem(GetListCacheKey(accountId), reqParams);
5453
5465
  if (cacheData) {
5454
5466
  return cacheData;
5455
5467
  }
@@ -5590,7 +5602,7 @@ var User;
5590
5602
  AccessToken.GetListCacheKey = GetListCacheKey;
5591
5603
  function GetList(api, accountId, reqParams) {
5592
5604
  return __awaiter(this, void 0, void 0, function* () {
5593
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey(accountId));
5605
+ const cacheData = api.GetCacheItem(GetListCacheKey(accountId), reqParams);
5594
5606
  if (cacheData) {
5595
5607
  return cacheData;
5596
5608
  }
@@ -5879,7 +5891,7 @@ var ImportedFile;
5879
5891
  if (!pageIndex) {
5880
5892
  pageIndex = 0;
5881
5893
  }
5882
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetListCacheKey(type, pageIndex));
5894
+ const cacheData = api.GetCacheItem(GetListCacheKey(type, pageIndex), reqParams);
5883
5895
  if (cacheData) {
5884
5896
  return cacheData;
5885
5897
  }
@@ -5909,7 +5921,7 @@ var ImportedFile;
5909
5921
  ImportedFile.GetList = GetList;
5910
5922
  function Get(api, fileId, reqParams) {
5911
5923
  return __awaiter(this, void 0, void 0, function* () {
5912
- const cacheData = (reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache) ? null : api.Cache.Get(GetCacheKey(fileId));
5924
+ const cacheData = api.GetCacheItem(GetCacheKey(fileId), reqParams);
5913
5925
  if (cacheData) {
5914
5926
  return cacheData;
5915
5927
  }