@twin.org/auditable-item-graph-models 0.0.1-next.16 → 0.0.1-next.18
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/cjs/index.cjs +6 -7
- package/dist/esm/index.mjs +6 -7
- package/dist/types/models/IAuditableItemGraphAlias.d.ts +6 -2
- package/dist/types/models/IAuditableItemGraphAuditedElement.d.ts +1 -1
- package/dist/types/models/IAuditableItemGraphComponent.d.ts +13 -12
- package/dist/types/models/IAuditableItemGraphEdge.d.ts +6 -2
- package/dist/types/models/IAuditableItemGraphVertex.d.ts +6 -2
- package/dist/types/models/api/IAuditableItemGraphCreateRequest.d.ts +4 -4
- package/dist/types/models/api/IAuditableItemGraphListRequest.d.ts +5 -1
- package/dist/types/models/api/IAuditableItemGraphUpdateRequest.d.ts +4 -4
- package/docs/changelog.md +1 -1
- package/docs/reference/interfaces/IAuditableItemGraphAlias.md +15 -15
- package/docs/reference/interfaces/IAuditableItemGraphAuditedElement.md +2 -2
- package/docs/reference/interfaces/IAuditableItemGraphComponent.md +13 -7
- package/docs/reference/interfaces/IAuditableItemGraphCreateRequest.md +2 -2
- package/docs/reference/interfaces/IAuditableItemGraphEdge.md +15 -15
- package/docs/reference/interfaces/IAuditableItemGraphListRequest.md +7 -1
- package/docs/reference/interfaces/IAuditableItemGraphResource.md +2 -2
- package/docs/reference/interfaces/IAuditableItemGraphUpdateRequest.md +2 -2
- package/docs/reference/interfaces/IAuditableItemGraphVertex.md +15 -15
- package/package.json +3 -3
package/dist/cjs/index.cjs
CHANGED
|
@@ -88,9 +88,9 @@ var properties$6 = {
|
|
|
88
88
|
"const": "AuditableItemGraphAlias",
|
|
89
89
|
description: "JSON-LD Type."
|
|
90
90
|
},
|
|
91
|
-
|
|
91
|
+
annotationObject: {
|
|
92
92
|
$ref: "https://schema.twindev.org/json-ld/JsonLdNodeObject",
|
|
93
|
-
description: "The JSON-LD object for the alias."
|
|
93
|
+
description: "The JSON-LD annotation object for the alias."
|
|
94
94
|
},
|
|
95
95
|
aliasFormat: {
|
|
96
96
|
type: "string",
|
|
@@ -233,9 +233,9 @@ var properties$4 = {
|
|
|
233
233
|
"const": "AuditableItemGraphEdge",
|
|
234
234
|
description: "JSON-LD Type."
|
|
235
235
|
},
|
|
236
|
-
|
|
236
|
+
annotationObject: {
|
|
237
237
|
$ref: "https://schema.twindev.org/json-ld/JsonLdNodeObject",
|
|
238
|
-
description: "The JSON-LD object for the edge."
|
|
238
|
+
description: "The JSON-LD annotation object for the edge."
|
|
239
239
|
},
|
|
240
240
|
edgeRelationship: {
|
|
241
241
|
type: "string",
|
|
@@ -381,7 +381,6 @@ var properties$2 = {
|
|
|
381
381
|
var required$2 = [
|
|
382
382
|
"@context",
|
|
383
383
|
"dateCreated",
|
|
384
|
-
"id",
|
|
385
384
|
"type"
|
|
386
385
|
];
|
|
387
386
|
var additionalProperties$2 = false;
|
|
@@ -443,9 +442,9 @@ var properties$1 = {
|
|
|
443
442
|
type: "string",
|
|
444
443
|
description: "The identity of the node which controls the vertex."
|
|
445
444
|
},
|
|
446
|
-
|
|
445
|
+
annotationObject: {
|
|
447
446
|
$ref: "https://schema.twindev.org/json-ld/JsonLdNodeObject",
|
|
448
|
-
description: "The JSON-LD object for the vertex."
|
|
447
|
+
description: "The JSON-LD annotation object for the vertex."
|
|
449
448
|
},
|
|
450
449
|
aliases: {
|
|
451
450
|
type: "array",
|
package/dist/esm/index.mjs
CHANGED
|
@@ -86,9 +86,9 @@ var properties$6 = {
|
|
|
86
86
|
"const": "AuditableItemGraphAlias",
|
|
87
87
|
description: "JSON-LD Type."
|
|
88
88
|
},
|
|
89
|
-
|
|
89
|
+
annotationObject: {
|
|
90
90
|
$ref: "https://schema.twindev.org/json-ld/JsonLdNodeObject",
|
|
91
|
-
description: "The JSON-LD object for the alias."
|
|
91
|
+
description: "The JSON-LD annotation object for the alias."
|
|
92
92
|
},
|
|
93
93
|
aliasFormat: {
|
|
94
94
|
type: "string",
|
|
@@ -231,9 +231,9 @@ var properties$4 = {
|
|
|
231
231
|
"const": "AuditableItemGraphEdge",
|
|
232
232
|
description: "JSON-LD Type."
|
|
233
233
|
},
|
|
234
|
-
|
|
234
|
+
annotationObject: {
|
|
235
235
|
$ref: "https://schema.twindev.org/json-ld/JsonLdNodeObject",
|
|
236
|
-
description: "The JSON-LD object for the edge."
|
|
236
|
+
description: "The JSON-LD annotation object for the edge."
|
|
237
237
|
},
|
|
238
238
|
edgeRelationship: {
|
|
239
239
|
type: "string",
|
|
@@ -379,7 +379,6 @@ var properties$2 = {
|
|
|
379
379
|
var required$2 = [
|
|
380
380
|
"@context",
|
|
381
381
|
"dateCreated",
|
|
382
|
-
"id",
|
|
383
382
|
"type"
|
|
384
383
|
];
|
|
385
384
|
var additionalProperties$2 = false;
|
|
@@ -441,9 +440,9 @@ var properties$1 = {
|
|
|
441
440
|
type: "string",
|
|
442
441
|
description: "The identity of the node which controls the vertex."
|
|
443
442
|
},
|
|
444
|
-
|
|
443
|
+
annotationObject: {
|
|
445
444
|
$ref: "https://schema.twindev.org/json-ld/JsonLdNodeObject",
|
|
446
|
-
description: "The JSON-LD object for the vertex."
|
|
445
|
+
description: "The JSON-LD annotation object for the vertex."
|
|
447
446
|
},
|
|
448
447
|
aliases: {
|
|
449
448
|
type: "array",
|
|
@@ -9,14 +9,18 @@ export interface IAuditableItemGraphAlias extends IAuditableItemGraphAuditedElem
|
|
|
9
9
|
* JSON-LD Context.
|
|
10
10
|
*/
|
|
11
11
|
"@context": typeof AuditableItemGraphTypes.ContextRoot | [typeof AuditableItemGraphTypes.ContextRoot, ...string[]];
|
|
12
|
+
/**
|
|
13
|
+
* The id of the element.
|
|
14
|
+
*/
|
|
15
|
+
id: string;
|
|
12
16
|
/**
|
|
13
17
|
* JSON-LD Type.
|
|
14
18
|
*/
|
|
15
19
|
type: typeof AuditableItemGraphTypes.Alias;
|
|
16
20
|
/**
|
|
17
|
-
* The JSON-LD object for the alias.
|
|
21
|
+
* The JSON-LD annotation object for the alias.
|
|
18
22
|
*/
|
|
19
|
-
|
|
23
|
+
annotationObject?: IJsonLdNodeObject;
|
|
20
24
|
/**
|
|
21
25
|
* The format of the id in the alias.
|
|
22
26
|
*/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { IComponent } from "@twin.org/core";
|
|
2
2
|
import type { IJsonLdNodeObject } from "@twin.org/data-json-ld";
|
|
3
|
-
import type { SortDirection } from "@twin.org/entity";
|
|
3
|
+
import type { IComparator, SortDirection } from "@twin.org/entity";
|
|
4
4
|
import type { IAuditableItemGraphVertex } from "./IAuditableItemGraphVertex";
|
|
5
5
|
import type { IAuditableItemGraphVertexList } from "./IAuditableItemGraphVertexList";
|
|
6
6
|
import type { VerifyDepth } from "./verifyDepth";
|
|
@@ -10,7 +10,7 @@ import type { VerifyDepth } from "./verifyDepth";
|
|
|
10
10
|
export interface IAuditableItemGraphComponent extends IComponent {
|
|
11
11
|
/**
|
|
12
12
|
* Create a new graph vertex.
|
|
13
|
-
* @param
|
|
13
|
+
* @param annotationObject The annotation object for the vertex as JSON-LD.
|
|
14
14
|
* @param aliases Alternative aliases that can be used to identify the vertex.
|
|
15
15
|
* @param resources The resources attached to the vertex.
|
|
16
16
|
* @param edges The edges connected to the vertex.
|
|
@@ -18,22 +18,22 @@ export interface IAuditableItemGraphComponent extends IComponent {
|
|
|
18
18
|
* @param nodeIdentity The node identity to use for vault operations.
|
|
19
19
|
* @returns The id of the new graph item.
|
|
20
20
|
*/
|
|
21
|
-
create(
|
|
21
|
+
create(annotationObject?: IJsonLdNodeObject, aliases?: {
|
|
22
22
|
id: string;
|
|
23
23
|
aliasFormat?: string;
|
|
24
|
-
|
|
24
|
+
annotationObject?: IJsonLdNodeObject;
|
|
25
25
|
}[], resources?: {
|
|
26
|
-
id
|
|
26
|
+
id?: string;
|
|
27
27
|
resourceObject?: IJsonLdNodeObject;
|
|
28
28
|
}[], edges?: {
|
|
29
29
|
id: string;
|
|
30
30
|
edgeRelationship: string;
|
|
31
|
-
|
|
31
|
+
annotationObject?: IJsonLdNodeObject;
|
|
32
32
|
}[], userIdentity?: string, nodeIdentity?: string): Promise<string>;
|
|
33
33
|
/**
|
|
34
34
|
* Update a graph vertex.
|
|
35
35
|
* @param id The id of the vertex to update.
|
|
36
|
-
* @param
|
|
36
|
+
* @param annotationObject The annotation object for the vertex as JSON-LD.
|
|
37
37
|
* @param aliases Alternative aliases that can be used to identify the vertex.
|
|
38
38
|
* @param resources The resources attached to the vertex.
|
|
39
39
|
* @param edges The edges connected to the vertex.
|
|
@@ -41,17 +41,17 @@ export interface IAuditableItemGraphComponent extends IComponent {
|
|
|
41
41
|
* @param nodeIdentity The node identity to use for vault operations.
|
|
42
42
|
* @returns Nothing.
|
|
43
43
|
*/
|
|
44
|
-
update(id: string,
|
|
44
|
+
update(id: string, annotationObject?: IJsonLdNodeObject, aliases?: {
|
|
45
45
|
id: string;
|
|
46
46
|
aliasFormat?: string;
|
|
47
|
-
|
|
47
|
+
annotationObject?: IJsonLdNodeObject;
|
|
48
48
|
}[], resources?: {
|
|
49
|
-
id
|
|
49
|
+
id?: string;
|
|
50
50
|
resourceObject?: IJsonLdNodeObject;
|
|
51
51
|
}[], edges?: {
|
|
52
52
|
id: string;
|
|
53
53
|
edgeRelationship: string;
|
|
54
|
-
|
|
54
|
+
annotationObject?: IJsonLdNodeObject;
|
|
55
55
|
}[], userIdentity?: string, nodeIdentity?: string): Promise<void>;
|
|
56
56
|
/**
|
|
57
57
|
* Get a graph vertex.
|
|
@@ -81,6 +81,7 @@ export interface IAuditableItemGraphComponent extends IComponent {
|
|
|
81
81
|
* @param options The query options.
|
|
82
82
|
* @param options.id The optional id to look for.
|
|
83
83
|
* @param options.idMode Look in id, alias or both, defaults to both.
|
|
84
|
+
* @param conditions Conditions to use in the query.
|
|
84
85
|
* @param orderBy The order for the results, defaults to dateCreated.
|
|
85
86
|
* @param orderByDirection The direction for the order, defaults to descending.
|
|
86
87
|
* @param properties The properties to return, if not provided defaults to id, dateCreated, aliases and object.
|
|
@@ -91,5 +92,5 @@ export interface IAuditableItemGraphComponent extends IComponent {
|
|
|
91
92
|
query(options?: {
|
|
92
93
|
id?: string;
|
|
93
94
|
idMode?: "id" | "alias" | "both";
|
|
94
|
-
}, orderBy?: keyof Pick<IAuditableItemGraphVertex, "dateCreated" | "dateModified">, orderByDirection?: SortDirection, properties?: (keyof IAuditableItemGraphVertex)[], cursor?: string, pageSize?: number): Promise<IAuditableItemGraphVertexList>;
|
|
95
|
+
}, conditions?: IComparator[], orderBy?: keyof Pick<IAuditableItemGraphVertex, "dateCreated" | "dateModified">, orderByDirection?: SortDirection, properties?: (keyof IAuditableItemGraphVertex)[], cursor?: string, pageSize?: number): Promise<IAuditableItemGraphVertexList>;
|
|
95
96
|
}
|
|
@@ -9,14 +9,18 @@ export interface IAuditableItemGraphEdge extends IAuditableItemGraphAuditedEleme
|
|
|
9
9
|
* JSON-LD Context.
|
|
10
10
|
*/
|
|
11
11
|
"@context": typeof AuditableItemGraphTypes.ContextRoot | [typeof AuditableItemGraphTypes.ContextRoot, ...string[]];
|
|
12
|
+
/**
|
|
13
|
+
* The id of the element.
|
|
14
|
+
*/
|
|
15
|
+
id: string;
|
|
12
16
|
/**
|
|
13
17
|
* JSON-LD Type.
|
|
14
18
|
*/
|
|
15
19
|
type: typeof AuditableItemGraphTypes.Edge;
|
|
16
20
|
/**
|
|
17
|
-
* The JSON-LD object for the edge.
|
|
21
|
+
* The JSON-LD annotation object for the edge.
|
|
18
22
|
*/
|
|
19
|
-
|
|
23
|
+
annotationObject?: IJsonLdNodeObject;
|
|
20
24
|
/**
|
|
21
25
|
* The relationship between the two vertices.
|
|
22
26
|
*/
|
|
@@ -13,6 +13,10 @@ export interface IAuditableItemGraphVertex extends Omit<IAuditableItemGraphAudit
|
|
|
13
13
|
* JSON-LD Context.
|
|
14
14
|
*/
|
|
15
15
|
"@context": typeof AuditableItemGraphTypes.ContextRoot | [typeof AuditableItemGraphTypes.ContextRoot, ...string[]];
|
|
16
|
+
/**
|
|
17
|
+
* The id of the element.
|
|
18
|
+
*/
|
|
19
|
+
id: string;
|
|
16
20
|
/**
|
|
17
21
|
* JSON-LD Type.
|
|
18
22
|
*/
|
|
@@ -22,9 +26,9 @@ export interface IAuditableItemGraphVertex extends Omit<IAuditableItemGraphAudit
|
|
|
22
26
|
*/
|
|
23
27
|
nodeIdentity?: string;
|
|
24
28
|
/**
|
|
25
|
-
* The JSON-LD object for the vertex.
|
|
29
|
+
* The JSON-LD annotation object for the vertex.
|
|
26
30
|
*/
|
|
27
|
-
|
|
31
|
+
annotationObject?: IJsonLdNodeObject;
|
|
28
32
|
/**
|
|
29
33
|
* Alternative aliases that can be used to identify the vertex.
|
|
30
34
|
*/
|
|
@@ -10,20 +10,20 @@ export interface IAuditableItemGraphCreateRequest {
|
|
|
10
10
|
/**
|
|
11
11
|
* The object to be used in the vertex as JSON-LD.
|
|
12
12
|
*/
|
|
13
|
-
|
|
13
|
+
annotationObject?: IJsonLdNodeObject;
|
|
14
14
|
/**
|
|
15
15
|
* Alternative aliases that can be used to identify the vertex.
|
|
16
16
|
*/
|
|
17
17
|
aliases?: {
|
|
18
18
|
id: string;
|
|
19
19
|
aliasFormat?: string;
|
|
20
|
-
|
|
20
|
+
annotationObject?: IJsonLdNodeObject;
|
|
21
21
|
}[];
|
|
22
22
|
/**
|
|
23
23
|
* The resources attached to the vertex.
|
|
24
24
|
*/
|
|
25
25
|
resources?: {
|
|
26
|
-
id
|
|
26
|
+
id?: string;
|
|
27
27
|
resourceObject?: IJsonLdNodeObject;
|
|
28
28
|
}[];
|
|
29
29
|
/**
|
|
@@ -32,7 +32,7 @@ export interface IAuditableItemGraphCreateRequest {
|
|
|
32
32
|
edges?: {
|
|
33
33
|
id: string;
|
|
34
34
|
edgeRelationship: string;
|
|
35
|
-
|
|
35
|
+
annotationObject?: IJsonLdNodeObject;
|
|
36
36
|
}[];
|
|
37
37
|
};
|
|
38
38
|
}
|
|
@@ -23,6 +23,10 @@ export interface IAuditableItemGraphListRequest {
|
|
|
23
23
|
* Which field to look in with the id, defaults to both.
|
|
24
24
|
*/
|
|
25
25
|
idMode?: "id" | "alias" | "both";
|
|
26
|
+
/**
|
|
27
|
+
* The conditions to filter the streams, JSON stringified IComparator[].
|
|
28
|
+
*/
|
|
29
|
+
conditions?: string;
|
|
26
30
|
/**
|
|
27
31
|
* The order for the results, default to dateCreated.
|
|
28
32
|
*/
|
|
@@ -32,7 +36,7 @@ export interface IAuditableItemGraphListRequest {
|
|
|
32
36
|
*/
|
|
33
37
|
orderByDirection?: SortDirection;
|
|
34
38
|
/**
|
|
35
|
-
* The properties to return as a comma separated list, defaults to "id,dateCreated,aliases,
|
|
39
|
+
* The properties to return as a comma separated list, defaults to "id,dateCreated,aliases,annotationObject".
|
|
36
40
|
*/
|
|
37
41
|
properties?: string;
|
|
38
42
|
/**
|
|
@@ -19,20 +19,20 @@ export interface IAuditableItemGraphUpdateRequest {
|
|
|
19
19
|
/**
|
|
20
20
|
* The object to be used in the vertex as JSON-LD.
|
|
21
21
|
*/
|
|
22
|
-
|
|
22
|
+
annotationObject?: IJsonLdNodeObject;
|
|
23
23
|
/**
|
|
24
24
|
* Alternative aliases that can be used to identify the vertex.
|
|
25
25
|
*/
|
|
26
26
|
aliases?: {
|
|
27
27
|
id: string;
|
|
28
28
|
aliasFormat?: string;
|
|
29
|
-
|
|
29
|
+
annotationObject?: IJsonLdNodeObject;
|
|
30
30
|
}[];
|
|
31
31
|
/**
|
|
32
32
|
* The resources attached to the vertex.
|
|
33
33
|
*/
|
|
34
34
|
resources?: {
|
|
35
|
-
id
|
|
35
|
+
id?: string;
|
|
36
36
|
resourceObject?: IJsonLdNodeObject;
|
|
37
37
|
}[];
|
|
38
38
|
/**
|
|
@@ -41,7 +41,7 @@ export interface IAuditableItemGraphUpdateRequest {
|
|
|
41
41
|
edges?: {
|
|
42
42
|
id: string;
|
|
43
43
|
edgeRelationship: string;
|
|
44
|
-
|
|
44
|
+
annotationObject?: IJsonLdNodeObject;
|
|
45
45
|
}[];
|
|
46
46
|
};
|
|
47
47
|
}
|
package/docs/changelog.md
CHANGED
|
@@ -16,6 +16,18 @@ JSON-LD Context.
|
|
|
16
16
|
|
|
17
17
|
***
|
|
18
18
|
|
|
19
|
+
### id
|
|
20
|
+
|
|
21
|
+
> **id**: `string`
|
|
22
|
+
|
|
23
|
+
The id of the element.
|
|
24
|
+
|
|
25
|
+
#### Overrides
|
|
26
|
+
|
|
27
|
+
[`IAuditableItemGraphAuditedElement`](IAuditableItemGraphAuditedElement.md).[`id`](IAuditableItemGraphAuditedElement.md#id)
|
|
28
|
+
|
|
29
|
+
***
|
|
30
|
+
|
|
19
31
|
### type
|
|
20
32
|
|
|
21
33
|
> **type**: `"AuditableItemGraphAlias"`
|
|
@@ -24,11 +36,11 @@ JSON-LD Type.
|
|
|
24
36
|
|
|
25
37
|
***
|
|
26
38
|
|
|
27
|
-
###
|
|
39
|
+
### annotationObject?
|
|
28
40
|
|
|
29
|
-
> `optional` **
|
|
41
|
+
> `optional` **annotationObject**: `IJsonLdNodeObject`
|
|
30
42
|
|
|
31
|
-
The JSON-LD object for the alias.
|
|
43
|
+
The JSON-LD annotation object for the alias.
|
|
32
44
|
|
|
33
45
|
***
|
|
34
46
|
|
|
@@ -40,18 +52,6 @@ The format of the id in the alias.
|
|
|
40
52
|
|
|
41
53
|
***
|
|
42
54
|
|
|
43
|
-
### id
|
|
44
|
-
|
|
45
|
-
> **id**: `string`
|
|
46
|
-
|
|
47
|
-
The id of the element.
|
|
48
|
-
|
|
49
|
-
#### Inherited from
|
|
50
|
-
|
|
51
|
-
[`IAuditableItemGraphAuditedElement`](IAuditableItemGraphAuditedElement.md).[`id`](IAuditableItemGraphAuditedElement.md#id)
|
|
52
|
-
|
|
53
|
-
***
|
|
54
|
-
|
|
55
55
|
### dateCreated
|
|
56
56
|
|
|
57
57
|
> **dateCreated**: `string`
|
|
@@ -10,17 +10,17 @@ Interface describing an auditable item graph contract.
|
|
|
10
10
|
|
|
11
11
|
### create()
|
|
12
12
|
|
|
13
|
-
> **create**(`
|
|
13
|
+
> **create**(`annotationObject`?, `aliases`?, `resources`?, `edges`?, `userIdentity`?, `nodeIdentity`?): `Promise`\<`string`\>
|
|
14
14
|
|
|
15
15
|
Create a new graph vertex.
|
|
16
16
|
|
|
17
17
|
#### Parameters
|
|
18
18
|
|
|
19
|
-
#####
|
|
19
|
+
##### annotationObject?
|
|
20
20
|
|
|
21
21
|
`IJsonLdNodeObject`
|
|
22
22
|
|
|
23
|
-
The object for the vertex as JSON-LD.
|
|
23
|
+
The annotation object for the vertex as JSON-LD.
|
|
24
24
|
|
|
25
25
|
##### aliases?
|
|
26
26
|
|
|
@@ -62,7 +62,7 @@ The id of the new graph item.
|
|
|
62
62
|
|
|
63
63
|
### update()
|
|
64
64
|
|
|
65
|
-
> **update**(`id`, `
|
|
65
|
+
> **update**(`id`, `annotationObject`?, `aliases`?, `resources`?, `edges`?, `userIdentity`?, `nodeIdentity`?): `Promise`\<`void`\>
|
|
66
66
|
|
|
67
67
|
Update a graph vertex.
|
|
68
68
|
|
|
@@ -74,11 +74,11 @@ Update a graph vertex.
|
|
|
74
74
|
|
|
75
75
|
The id of the vertex to update.
|
|
76
76
|
|
|
77
|
-
#####
|
|
77
|
+
##### annotationObject?
|
|
78
78
|
|
|
79
79
|
`IJsonLdNodeObject`
|
|
80
80
|
|
|
81
|
-
The object for the vertex as JSON-LD.
|
|
81
|
+
The annotation object for the vertex as JSON-LD.
|
|
82
82
|
|
|
83
83
|
##### aliases?
|
|
84
84
|
|
|
@@ -200,7 +200,7 @@ NotFoundError if the vertex is not found.
|
|
|
200
200
|
|
|
201
201
|
### query()
|
|
202
202
|
|
|
203
|
-
> **query**(`options`?, `orderBy`?, `orderByDirection`?, `properties`?, `cursor`?, `pageSize`?): `Promise`\<[`IAuditableItemGraphVertexList`](IAuditableItemGraphVertexList.md)\>
|
|
203
|
+
> **query**(`options`?, `conditions`?, `orderBy`?, `orderByDirection`?, `properties`?, `cursor`?, `pageSize`?): `Promise`\<[`IAuditableItemGraphVertexList`](IAuditableItemGraphVertexList.md)\>
|
|
204
204
|
|
|
205
205
|
Query the graph for vertices.
|
|
206
206
|
|
|
@@ -222,6 +222,12 @@ The optional id to look for.
|
|
|
222
222
|
|
|
223
223
|
Look in id, alias or both, defaults to both.
|
|
224
224
|
|
|
225
|
+
##### conditions?
|
|
226
|
+
|
|
227
|
+
`IComparator`[]
|
|
228
|
+
|
|
229
|
+
Conditions to use in the query.
|
|
230
|
+
|
|
225
231
|
##### orderBy?
|
|
226
232
|
|
|
227
233
|
The order for the results, defaults to dateCreated.
|
|
@@ -10,9 +10,9 @@ Create an auditable item graph vertex.
|
|
|
10
10
|
|
|
11
11
|
The data to be used in the vertex.
|
|
12
12
|
|
|
13
|
-
####
|
|
13
|
+
#### annotationObject?
|
|
14
14
|
|
|
15
|
-
> `optional` **
|
|
15
|
+
> `optional` **annotationObject**: `IJsonLdNodeObject`
|
|
16
16
|
|
|
17
17
|
The object to be used in the vertex as JSON-LD.
|
|
18
18
|
|
|
@@ -8,18 +8,6 @@ Interface describing an edge between two vertices in an auditable item graph.
|
|
|
8
8
|
|
|
9
9
|
## Properties
|
|
10
10
|
|
|
11
|
-
### id
|
|
12
|
-
|
|
13
|
-
> **id**: `string`
|
|
14
|
-
|
|
15
|
-
The id of the element.
|
|
16
|
-
|
|
17
|
-
#### Inherited from
|
|
18
|
-
|
|
19
|
-
[`IAuditableItemGraphAuditedElement`](IAuditableItemGraphAuditedElement.md).[`id`](IAuditableItemGraphAuditedElement.md#id)
|
|
20
|
-
|
|
21
|
-
***
|
|
22
|
-
|
|
23
11
|
### dateCreated
|
|
24
12
|
|
|
25
13
|
> **dateCreated**: `string`
|
|
@@ -64,6 +52,18 @@ JSON-LD Context.
|
|
|
64
52
|
|
|
65
53
|
***
|
|
66
54
|
|
|
55
|
+
### id
|
|
56
|
+
|
|
57
|
+
> **id**: `string`
|
|
58
|
+
|
|
59
|
+
The id of the element.
|
|
60
|
+
|
|
61
|
+
#### Overrides
|
|
62
|
+
|
|
63
|
+
[`IAuditableItemGraphAuditedElement`](IAuditableItemGraphAuditedElement.md).[`id`](IAuditableItemGraphAuditedElement.md#id)
|
|
64
|
+
|
|
65
|
+
***
|
|
66
|
+
|
|
67
67
|
### type
|
|
68
68
|
|
|
69
69
|
> **type**: `"AuditableItemGraphEdge"`
|
|
@@ -72,11 +72,11 @@ JSON-LD Type.
|
|
|
72
72
|
|
|
73
73
|
***
|
|
74
74
|
|
|
75
|
-
###
|
|
75
|
+
### annotationObject?
|
|
76
76
|
|
|
77
|
-
> `optional` **
|
|
77
|
+
> `optional` **annotationObject**: `IJsonLdNodeObject`
|
|
78
78
|
|
|
79
|
-
The JSON-LD object for the edge.
|
|
79
|
+
The JSON-LD annotation object for the edge.
|
|
80
80
|
|
|
81
81
|
***
|
|
82
82
|
|
|
@@ -34,6 +34,12 @@ The id or alias to try and find.
|
|
|
34
34
|
|
|
35
35
|
Which field to look in with the id, defaults to both.
|
|
36
36
|
|
|
37
|
+
#### conditions?
|
|
38
|
+
|
|
39
|
+
> `optional` **conditions**: `string`
|
|
40
|
+
|
|
41
|
+
The conditions to filter the streams, JSON stringified IComparator[].
|
|
42
|
+
|
|
37
43
|
#### orderBy?
|
|
38
44
|
|
|
39
45
|
> `optional` **orderBy**: `"dateCreated"` \| `"dateModified"`
|
|
@@ -50,7 +56,7 @@ The direction for the order, defaults to desc.
|
|
|
50
56
|
|
|
51
57
|
> `optional` **properties**: `string`
|
|
52
58
|
|
|
53
|
-
The properties to return as a comma separated list, defaults to "id,dateCreated,aliases,
|
|
59
|
+
The properties to return as a comma separated list, defaults to "id,dateCreated,aliases,annotationObject".
|
|
54
60
|
|
|
55
61
|
#### cursor?
|
|
56
62
|
|
|
@@ -24,9 +24,9 @@ The id of the vertex to update.
|
|
|
24
24
|
|
|
25
25
|
The data to be used in the vertex.
|
|
26
26
|
|
|
27
|
-
####
|
|
27
|
+
#### annotationObject?
|
|
28
28
|
|
|
29
|
-
> `optional` **
|
|
29
|
+
> `optional` **annotationObject**: `IJsonLdNodeObject`
|
|
30
30
|
|
|
31
31
|
The object to be used in the vertex as JSON-LD.
|
|
32
32
|
|
|
@@ -8,18 +8,6 @@ Interface describing an auditable item graph vertex.
|
|
|
8
8
|
|
|
9
9
|
## Properties
|
|
10
10
|
|
|
11
|
-
### id
|
|
12
|
-
|
|
13
|
-
> **id**: `string`
|
|
14
|
-
|
|
15
|
-
The id of the element.
|
|
16
|
-
|
|
17
|
-
#### Inherited from
|
|
18
|
-
|
|
19
|
-
`Omit.id`
|
|
20
|
-
|
|
21
|
-
***
|
|
22
|
-
|
|
23
11
|
### dateCreated
|
|
24
12
|
|
|
25
13
|
> **dateCreated**: `string`
|
|
@@ -64,6 +52,18 @@ JSON-LD Context.
|
|
|
64
52
|
|
|
65
53
|
***
|
|
66
54
|
|
|
55
|
+
### id
|
|
56
|
+
|
|
57
|
+
> **id**: `string`
|
|
58
|
+
|
|
59
|
+
The id of the element.
|
|
60
|
+
|
|
61
|
+
#### Overrides
|
|
62
|
+
|
|
63
|
+
`Omit.id`
|
|
64
|
+
|
|
65
|
+
***
|
|
66
|
+
|
|
67
67
|
### type
|
|
68
68
|
|
|
69
69
|
> **type**: `"AuditableItemGraphVertex"`
|
|
@@ -80,11 +80,11 @@ The identity of the node which controls the vertex.
|
|
|
80
80
|
|
|
81
81
|
***
|
|
82
82
|
|
|
83
|
-
###
|
|
83
|
+
### annotationObject?
|
|
84
84
|
|
|
85
|
-
> `optional` **
|
|
85
|
+
> `optional` **annotationObject**: `IJsonLdNodeObject`
|
|
86
86
|
|
|
87
|
-
The JSON-LD object for the vertex.
|
|
87
|
+
The JSON-LD annotation object for the vertex.
|
|
88
88
|
|
|
89
89
|
***
|
|
90
90
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@twin.org/auditable-item-graph-models",
|
|
3
|
-
"version": "0.0.1-next.
|
|
3
|
+
"version": "0.0.1-next.18",
|
|
4
4
|
"description": "Models which define the structure of the auditable item graph connectors and services",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -27,9 +27,9 @@
|
|
|
27
27
|
"types": "./dist/types/index.d.ts",
|
|
28
28
|
"exports": {
|
|
29
29
|
".": {
|
|
30
|
+
"types": "./dist/types/index.d.ts",
|
|
30
31
|
"require": "./dist/cjs/index.cjs",
|
|
31
|
-
"import": "./dist/esm/index.mjs"
|
|
32
|
-
"types": "./dist/types/index.d.ts"
|
|
32
|
+
"import": "./dist/esm/index.mjs"
|
|
33
33
|
},
|
|
34
34
|
"./locales/*.json": "./locales/*.json"
|
|
35
35
|
},
|