bruce-models 3.8.4 → 3.8.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.
@@ -1,5 +1,6 @@
1
1
  import { Api } from "../api/api";
2
2
  import { BruceApi } from "../api/bruce-api";
3
+ import { PendingAction } from "../bruce-models";
3
4
  import { UTC } from "../common/utc";
4
5
  import { Entity } from "./entity";
5
6
  import { EntityAttribute } from "./entity-attribute";
@@ -84,6 +85,29 @@ export declare namespace EntityType {
84
85
  }): Promise<{
85
86
  entityType: IType;
86
87
  }>;
88
+ /**
89
+ * Starts a re-index background action on a specified Entity Type.
90
+ * This will ensure searchable data follows the current schema version.
91
+ * This will also perform certain data cleanup so that the data is consistent.
92
+ * @param params
93
+ * @returns
94
+ */
95
+ function ReIndex(params: {
96
+ api?: BruceApi.Api;
97
+ entityTypeId: string;
98
+ dataTransformId?: number;
99
+ req?: Api.IReqParams;
100
+ }): Promise<PendingAction.IAction>;
101
+ /**
102
+ * Counts the total number of Entities in an Entity Type.
103
+ * @param params
104
+ * @returns
105
+ */
106
+ function Count(params: {
107
+ entityTypeId: string;
108
+ api?: BruceApi.Api;
109
+ req?: Api.IReqParams;
110
+ }): Promise<number>;
87
111
  /**
88
112
  * Returns cache identifier for an entity type.
89
113
  * Example: {
@@ -26,6 +26,8 @@ export declare namespace Entity {
26
26
  ID?: string;
27
27
  "Layer.ID"?: number[];
28
28
  relations?: IRelationData[];
29
+ historicAttrKey?: string;
30
+ historicDateTime?: string;
29
31
  };
30
32
  location?: Carto.ICarto;
31
33
  boundaries?: Bounds.IBounds;
@@ -55,6 +57,9 @@ export declare namespace Entity {
55
57
  entityTypeId?: string;
56
58
  expandLocation?: boolean;
57
59
  expandRelations?: boolean;
60
+ historicKey?: string;
61
+ historicFrom?: string;
62
+ historicTo?: string;
58
63
  req?: Api.IReqParams;
59
64
  }): Promise<{
60
65
  entity: IEntity;
@@ -69,6 +74,9 @@ export declare namespace Entity {
69
74
  entityIds: string[];
70
75
  expandLocation?: boolean;
71
76
  expandRelations?: boolean;
77
+ historicKey?: string;
78
+ historicFrom?: string;
79
+ historicTo?: string;
72
80
  req?: Api.IReqParams;
73
81
  }): Promise<{
74
82
  entities: IEntity[];
@@ -199,6 +207,9 @@ export declare namespace Entity {
199
207
  analysis?: boolean;
200
208
  viaCdn?: boolean;
201
209
  viaCdnCacheToken?: number | string;
210
+ historicKey?: string;
211
+ historicFrom?: string;
212
+ historicTo?: string;
202
213
  req?: Api.IReqParams;
203
214
  }): Promise<{
204
215
  entities?: IEntity[];
@@ -226,6 +237,9 @@ export declare namespace Entity {
226
237
  entityTypeId?: string;
227
238
  expandLocation?: boolean;
228
239
  expandRelations?: boolean;
240
+ historicKey?: string;
241
+ historicFrom?: string;
242
+ historicTo?: string;
229
243
  }): string;
230
244
  /**
231
245
  * Returns cache identifier for an entity record.
@@ -238,5 +252,11 @@ export declare namespace Entity {
238
252
  * @returns
239
253
  */
240
254
  function GetContainsKey(entityId: string): string;
255
+ /**
256
+ * Returns cache identifier for entity records that have historic data.
257
+ * @param attrKey
258
+ * @returns
259
+ */
260
+ function GetHistoricContainsKey(attrKey: string): string;
241
261
  }
242
262
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bruce-models",
3
- "version": "3.8.4",
3
+ "version": "3.8.6",
4
4
  "description": "",
5
5
  "keywords": [],
6
6
  "main": "dist/bruce-models.umd.js",