@astrale-os/kernel-core 0.9.0-beta.65 → 0.9.0-beta.67
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/auth/authority/admission/admission.d.ts +0 -1
- package/dist/auth/authority/admission/admission.js +8 -141
- package/dist/auth/authority/admission/references.d.ts +13 -0
- package/dist/auth/authority/admission/references.js +38 -0
- package/dist/auth/authority/admission/term.d.ts +6 -0
- package/dist/auth/authority/admission/term.js +60 -0
- package/dist/auth/authority/admission/wire.d.ts +8 -0
- package/dist/auth/authority/admission/wire.js +33 -0
- package/dist/auth/authority/semantics/interpret.d.ts +6 -0
- package/dist/auth/authority/semantics/interpret.js +187 -14
- package/dist/auth/authority/semantics/snapshot.d.ts +6 -0
- package/dist/graph/graph/index.d.ts +1 -1
- package/dist/graph/graph/index.js +1 -1
- package/dist/graph/graph/model/codec.js +3 -3
- package/dist/graph/graph/model/index.d.ts +1 -1
- package/dist/graph/graph/model/index.js +1 -1
- package/dist/graph/graph/model/model.d.ts +7 -7
- package/dist/graph/graph/model/model.js +6 -6
- package/dist/graph/graph/model/wire.d.ts +0 -20
- package/dist/graph/graph/model/wire.js +2 -2
- package/dist/graph/mutate/authoring/builder.d.ts +2 -2
- package/dist/graph/mutate/authoring/builder.js +2 -2
- package/dist/graph/mutate/index.d.ts +1 -1
- package/dist/graph/mutate/language/codec.js +3 -3
- package/dist/graph/mutate/language/model.d.ts +4 -4
- package/dist/graph/mutate/language/wire.d.ts +11 -0
- package/dist/graph/mutate/result/index.d.ts +4 -3
- package/dist/graph/mutate/result/index.js +8 -6
- package/dist/graph/mutate/result/wire.d.ts +1 -0
- package/dist/graph/mutate/result/wire.js +5 -2
- package/dist/graph/node/identity/id.d.ts +0 -3
- package/dist/graph/node/identity/id.js +0 -4
- package/dist/graph/node/identity/order.js +20 -0
- package/dist/graph/query/authoring/builder.js +29 -2
- package/dist/graph/query/authoring/model.d.ts +20 -1
- package/dist/graph/query/index.d.ts +3 -3
- package/dist/graph/query/index.js +1 -1
- package/dist/graph/query/language/codec.js +18 -3
- package/dist/graph/query/language/fingerprint.js +8 -0
- package/dist/graph/query/language/model.d.ts +22 -4
- package/dist/graph/query/language/wire.d.ts +11 -0
- package/dist/graph/query/language/wire.js +8 -1
- package/dist/graph/query/order/index.d.ts +8 -1
- package/dist/graph/query/order/index.js +20 -0
- package/dist/graph/query/reference/evaluate.js +5 -3
- package/dist/graph/reconcile/condition/model.d.ts +2 -2
- package/dist/graph/reconcile/condition/references.d.ts +0 -1
- package/dist/graph/reconcile/condition/references.js +4 -4
- package/dist/graph/reconcile/correspondence.d.ts +9 -8
- package/dist/graph/reconcile/evidence.d.ts +2 -2
- package/dist/graph/reconcile/mutation/assess.d.ts +2 -1
- package/dist/graph/reconcile/observation.d.ts +4 -3
- package/dist/graph/reconcile/planning/context.d.ts +3 -3
- package/dist/graph/reconcile/planning/model.d.ts +4 -4
- package/dist/schema/callables/{view-for.d.ts → entrypoint.d.ts} +7 -5
- package/dist/schema/callables/entrypoint.js +12 -0
- package/dist/schema/callables/function.d.ts +0 -120
- package/dist/schema/callables/index.d.ts +1 -1
- package/dist/schema/callables/index.js +1 -1
- package/dist/schema/callables/view.d.ts +2 -24
- package/dist/schema/domain/domain.d.ts +2 -121
- package/dist/schema/domain/domain.js +3 -0
- package/dist/schema/identity/identity.d.ts +0 -8
- package/dist/schema/kernel/projection/core.d.ts +7 -0
- package/dist/schema/kernel/projection/core.js +51 -0
- package/dist/schema/kernel/projection/definitions.d.ts +13 -0
- package/dist/schema/kernel/projection/definitions.js +71 -0
- package/dist/schema/kernel/projection/methods.d.ts +5 -0
- package/dist/schema/kernel/projection/methods.js +41 -0
- package/dist/schema/kernel/projection/part.d.ts +34 -0
- package/dist/schema/kernel/projection/part.js +42 -0
- package/dist/schema/kernel/projection/paths.d.ts +6 -0
- package/dist/schema/kernel/projection/{keys.js → paths.js} +11 -12
- package/dist/schema/kernel/projection/project.d.ts +1 -1
- package/dist/schema/kernel/projection/project.js +16 -290
- package/dist/schema/kernel/projection/properties.d.ts +11 -0
- package/dist/schema/kernel/projection/properties.js +36 -0
- package/dist/schema/kernel/projection/relations.d.ts +7 -0
- package/dist/schema/kernel/projection/relations.js +49 -0
- package/dist/schema/kernel/projection/types.d.ts +4 -4
- package/dist/schema/kernel/schema.d.ts +174 -409
- package/dist/schema/kernel/schema.js +3 -2
- package/dist/schema/kernel/syscalls/contracts/blob.d.ts +12 -2
- package/dist/schema/kernel/syscalls/contracts/blob.js +10 -2
- package/dist/schema/kernel/syscalls/contracts/delegate.d.ts +0 -4
- package/dist/schema/kernel/syscalls/contracts/delegate.js +0 -3
- package/dist/schema/kernel/syscalls/contracts/index.d.ts +1 -1
- package/dist/schema/kernel/syscalls/contracts/index.js +1 -1
- package/dist/schema/kernel/syscalls/contracts/install.d.ts +3 -20
- package/dist/schema/kernel/syscalls/contracts/install.js +0 -2
- package/dist/schema/kernel/syscalls/contracts/installation.d.ts +0 -36
- package/dist/schema/kernel/syscalls/contracts/installation.js +3 -3
- package/dist/schema/kernel/syscalls/contracts/mutate.d.ts +13 -0
- package/dist/schema/kernel/syscalls/contracts/mutate.js +2 -1
- package/dist/schema/kernel/syscalls/contracts/query.d.ts +11 -0
- package/dist/schema/kernel/syscalls/contracts/view-resolve.d.ts +3 -14
- package/dist/schema/kernel/syscalls/contracts/view-resolve.js +3 -18
- package/dist/schema/kernel/syscalls/declarations/delegate.d.ts +0 -4
- package/dist/schema/kernel/syscalls/declarations/download.d.ts +5 -0
- package/dist/schema/kernel/syscalls/declarations/index.d.ts +30 -24
- package/dist/schema/kernel/syscalls/declarations/install.d.ts +0 -8
- package/dist/schema/kernel/syscalls/declarations/mutate.d.ts +13 -0
- package/dist/schema/kernel/syscalls/declarations/query.d.ts +11 -0
- package/dist/schema/kernel/syscalls/declarations/view-resolve.d.ts +1 -12
- package/dist/schema/kernel/syscalls/descriptors/identity.d.ts +0 -4
- package/dist/schema/kernel/syscalls/descriptors/results/view-resolution.d.ts +2 -13
- package/dist/schema/kernel/syscalls/descriptors/results/view-resolution.js +4 -119
- package/dist/schema/kernel/syscalls/descriptors/view.d.ts +1 -12
- package/package.json +2 -2
- package/dist/schema/callables/view-for.js +0 -12
- package/dist/schema/kernel/projection/keys.d.ts +0 -3
- package/dist/schema/kernel/syscalls/contracts/legacy/delegate.d.ts +0 -5
- package/dist/schema/kernel/syscalls/contracts/legacy/delegate.js +0 -25
- package/dist/schema/kernel/syscalls/contracts/legacy/install.d.ts +0 -22
- package/dist/schema/kernel/syscalls/contracts/legacy/install.js +0 -31
|
@@ -38,10 +38,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
38
38
|
principal: string;
|
|
39
39
|
audience: string;
|
|
40
40
|
ttlSeconds: number;
|
|
41
|
-
attenuation?: {
|
|
42
|
-
kind: "identity";
|
|
43
|
-
self: true;
|
|
44
|
-
} | undefined;
|
|
45
41
|
}, {
|
|
46
42
|
readonly mode: 'value';
|
|
47
43
|
readonly value: string;
|
|
@@ -183,10 +179,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
183
179
|
principal: string;
|
|
184
180
|
audience: string;
|
|
185
181
|
ttlSeconds: number;
|
|
186
|
-
attenuation?: {
|
|
187
|
-
kind: "identity";
|
|
188
|
-
self: true;
|
|
189
|
-
} | undefined;
|
|
190
182
|
}, {
|
|
191
183
|
readonly mode: 'value';
|
|
192
184
|
readonly value: string;
|
|
@@ -316,10 +308,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
316
308
|
principal: string;
|
|
317
309
|
audience: string;
|
|
318
310
|
ttlSeconds: number;
|
|
319
|
-
attenuation?: {
|
|
320
|
-
kind: "identity";
|
|
321
|
-
self: true;
|
|
322
|
-
} | undefined;
|
|
323
311
|
}, {
|
|
324
312
|
readonly mode: 'value';
|
|
325
313
|
readonly value: string;
|
|
@@ -412,10 +400,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
412
400
|
principal: string;
|
|
413
401
|
audience: string;
|
|
414
402
|
ttlSeconds: number;
|
|
415
|
-
attenuation?: {
|
|
416
|
-
kind: "identity";
|
|
417
|
-
self: true;
|
|
418
|
-
} | undefined;
|
|
419
403
|
}, {
|
|
420
404
|
readonly mode: 'value';
|
|
421
405
|
readonly value: string;
|
|
@@ -545,10 +529,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
545
529
|
principal: string;
|
|
546
530
|
audience: string;
|
|
547
531
|
ttlSeconds: number;
|
|
548
|
-
attenuation?: {
|
|
549
|
-
kind: "identity";
|
|
550
|
-
self: true;
|
|
551
|
-
} | undefined;
|
|
552
532
|
}, {
|
|
553
533
|
readonly mode: 'value';
|
|
554
534
|
readonly value: string;
|
|
@@ -641,10 +621,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
641
621
|
principal: string;
|
|
642
622
|
audience: string;
|
|
643
623
|
ttlSeconds: number;
|
|
644
|
-
attenuation?: {
|
|
645
|
-
kind: "identity";
|
|
646
|
-
self: true;
|
|
647
|
-
} | undefined;
|
|
648
624
|
}, {
|
|
649
625
|
readonly mode: 'value';
|
|
650
626
|
readonly value: string;
|
|
@@ -774,10 +750,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
774
750
|
principal: string;
|
|
775
751
|
audience: string;
|
|
776
752
|
ttlSeconds: number;
|
|
777
|
-
attenuation?: {
|
|
778
|
-
kind: "identity";
|
|
779
|
-
self: true;
|
|
780
|
-
} | undefined;
|
|
781
753
|
}, {
|
|
782
754
|
readonly mode: 'value';
|
|
783
755
|
readonly value: string;
|
|
@@ -870,10 +842,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
870
842
|
principal: string;
|
|
871
843
|
audience: string;
|
|
872
844
|
ttlSeconds: number;
|
|
873
|
-
attenuation?: {
|
|
874
|
-
kind: "identity";
|
|
875
|
-
self: true;
|
|
876
|
-
} | undefined;
|
|
877
845
|
}, {
|
|
878
846
|
readonly mode: 'value';
|
|
879
847
|
readonly value: string;
|
|
@@ -1003,10 +971,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
1003
971
|
principal: string;
|
|
1004
972
|
audience: string;
|
|
1005
973
|
ttlSeconds: number;
|
|
1006
|
-
attenuation?: {
|
|
1007
|
-
kind: "identity";
|
|
1008
|
-
self: true;
|
|
1009
|
-
} | undefined;
|
|
1010
974
|
}, {
|
|
1011
975
|
readonly mode: 'value';
|
|
1012
976
|
readonly value: string;
|
|
@@ -1119,10 +1083,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
1119
1083
|
principal: string;
|
|
1120
1084
|
audience: string;
|
|
1121
1085
|
ttlSeconds: number;
|
|
1122
|
-
attenuation?: {
|
|
1123
|
-
kind: "identity";
|
|
1124
|
-
self: true;
|
|
1125
|
-
} | undefined;
|
|
1126
1086
|
}, {
|
|
1127
1087
|
readonly mode: 'value';
|
|
1128
1088
|
readonly value: string;
|
|
@@ -1252,10 +1212,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
1252
1212
|
principal: string;
|
|
1253
1213
|
audience: string;
|
|
1254
1214
|
ttlSeconds: number;
|
|
1255
|
-
attenuation?: {
|
|
1256
|
-
kind: "identity";
|
|
1257
|
-
self: true;
|
|
1258
|
-
} | undefined;
|
|
1259
1215
|
}, {
|
|
1260
1216
|
readonly mode: 'value';
|
|
1261
1217
|
readonly value: string;
|
|
@@ -1316,10 +1272,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
1316
1272
|
principal: string;
|
|
1317
1273
|
audience: string;
|
|
1318
1274
|
ttlSeconds: number;
|
|
1319
|
-
attenuation?: {
|
|
1320
|
-
kind: "identity";
|
|
1321
|
-
self: true;
|
|
1322
|
-
} | undefined;
|
|
1323
1275
|
}, {
|
|
1324
1276
|
readonly mode: 'value';
|
|
1325
1277
|
readonly value: string;
|
|
@@ -1359,10 +1311,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
1359
1311
|
principal: string;
|
|
1360
1312
|
audience: string;
|
|
1361
1313
|
ttlSeconds: number;
|
|
1362
|
-
attenuation?: {
|
|
1363
|
-
kind: "identity";
|
|
1364
|
-
self: true;
|
|
1365
|
-
} | undefined;
|
|
1366
1314
|
}, {
|
|
1367
1315
|
readonly mode: 'value';
|
|
1368
1316
|
readonly value: string;
|
|
@@ -1492,10 +1440,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
1492
1440
|
principal: string;
|
|
1493
1441
|
audience: string;
|
|
1494
1442
|
ttlSeconds: number;
|
|
1495
|
-
attenuation?: {
|
|
1496
|
-
kind: "identity";
|
|
1497
|
-
self: true;
|
|
1498
|
-
} | undefined;
|
|
1499
1443
|
}, {
|
|
1500
1444
|
readonly mode: 'value';
|
|
1501
1445
|
readonly value: string;
|
|
@@ -1595,10 +1539,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
1595
1539
|
principal: string;
|
|
1596
1540
|
audience: string;
|
|
1597
1541
|
ttlSeconds: number;
|
|
1598
|
-
attenuation?: {
|
|
1599
|
-
kind: "identity";
|
|
1600
|
-
self: true;
|
|
1601
|
-
} | undefined;
|
|
1602
1542
|
}, {
|
|
1603
1543
|
readonly mode: 'value';
|
|
1604
1544
|
readonly value: string;
|
|
@@ -1728,10 +1668,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
1728
1668
|
principal: string;
|
|
1729
1669
|
audience: string;
|
|
1730
1670
|
ttlSeconds: number;
|
|
1731
|
-
attenuation?: {
|
|
1732
|
-
kind: "identity";
|
|
1733
|
-
self: true;
|
|
1734
|
-
} | undefined;
|
|
1735
1671
|
}, {
|
|
1736
1672
|
readonly mode: 'value';
|
|
1737
1673
|
readonly value: string;
|
|
@@ -1830,10 +1766,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
1830
1766
|
principal: string;
|
|
1831
1767
|
audience: string;
|
|
1832
1768
|
ttlSeconds: number;
|
|
1833
|
-
attenuation?: {
|
|
1834
|
-
kind: "identity";
|
|
1835
|
-
self: true;
|
|
1836
|
-
} | undefined;
|
|
1837
1769
|
}, {
|
|
1838
1770
|
readonly mode: 'value';
|
|
1839
1771
|
readonly value: string;
|
|
@@ -1963,10 +1895,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
1963
1895
|
principal: string;
|
|
1964
1896
|
audience: string;
|
|
1965
1897
|
ttlSeconds: number;
|
|
1966
|
-
attenuation?: {
|
|
1967
|
-
kind: "identity";
|
|
1968
|
-
self: true;
|
|
1969
|
-
} | undefined;
|
|
1970
1898
|
}, {
|
|
1971
1899
|
readonly mode: 'value';
|
|
1972
1900
|
readonly value: string;
|
|
@@ -2082,10 +2010,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
2082
2010
|
principal: string;
|
|
2083
2011
|
audience: string;
|
|
2084
2012
|
ttlSeconds: number;
|
|
2085
|
-
attenuation?: {
|
|
2086
|
-
kind: "identity";
|
|
2087
|
-
self: true;
|
|
2088
|
-
} | undefined;
|
|
2089
2013
|
}, {
|
|
2090
2014
|
readonly mode: 'value';
|
|
2091
2015
|
readonly value: string;
|
|
@@ -2215,10 +2139,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
2215
2139
|
principal: string;
|
|
2216
2140
|
audience: string;
|
|
2217
2141
|
ttlSeconds: number;
|
|
2218
|
-
attenuation?: {
|
|
2219
|
-
kind: "identity";
|
|
2220
|
-
self: true;
|
|
2221
|
-
} | undefined;
|
|
2222
2142
|
}, {
|
|
2223
2143
|
readonly mode: 'value';
|
|
2224
2144
|
readonly value: string;
|
|
@@ -2328,10 +2248,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
2328
2248
|
principal: string;
|
|
2329
2249
|
audience: string;
|
|
2330
2250
|
ttlSeconds: number;
|
|
2331
|
-
attenuation?: {
|
|
2332
|
-
kind: "identity";
|
|
2333
|
-
self: true;
|
|
2334
|
-
} | undefined;
|
|
2335
2251
|
}, {
|
|
2336
2252
|
readonly mode: 'value';
|
|
2337
2253
|
readonly value: string;
|
|
@@ -2461,10 +2377,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
2461
2377
|
principal: string;
|
|
2462
2378
|
audience: string;
|
|
2463
2379
|
ttlSeconds: number;
|
|
2464
|
-
attenuation?: {
|
|
2465
|
-
kind: "identity";
|
|
2466
|
-
self: true;
|
|
2467
|
-
} | undefined;
|
|
2468
2380
|
}, {
|
|
2469
2381
|
readonly mode: 'value';
|
|
2470
2382
|
readonly value: string;
|
|
@@ -2524,6 +2436,7 @@ export declare const Domain: builder.NodeClass<{
|
|
|
2524
2436
|
}, "authenticated", true, false, undefined>>, "can", unknown>>>>];
|
|
2525
2437
|
readonly properties: {
|
|
2526
2438
|
readonly origin: builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, true, "origin", "self", undefined>;
|
|
2439
|
+
readonly name: builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, true, "name", "self", undefined>;
|
|
2527
2440
|
readonly dependencyContext: builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, false, "dependencyContext", "self", never>;
|
|
2528
2441
|
readonly schema: builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, true, "schema", "self", never>;
|
|
2529
2442
|
readonly schemaRevision: builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, true, "schemaRevision", "self", never>;
|
|
@@ -2587,10 +2500,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
2587
2500
|
principal: string;
|
|
2588
2501
|
audience: string;
|
|
2589
2502
|
ttlSeconds: number;
|
|
2590
|
-
attenuation?: {
|
|
2591
|
-
kind: "identity";
|
|
2592
|
-
self: true;
|
|
2593
|
-
} | undefined;
|
|
2594
2503
|
}, {
|
|
2595
2504
|
readonly mode: 'value';
|
|
2596
2505
|
readonly value: string;
|
|
@@ -2720,10 +2629,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
2720
2629
|
principal: string;
|
|
2721
2630
|
audience: string;
|
|
2722
2631
|
ttlSeconds: number;
|
|
2723
|
-
attenuation?: {
|
|
2724
|
-
kind: "identity";
|
|
2725
|
-
self: true;
|
|
2726
|
-
} | undefined;
|
|
2727
2632
|
}, {
|
|
2728
2633
|
readonly mode: 'value';
|
|
2729
2634
|
readonly value: string;
|
|
@@ -2816,10 +2721,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
2816
2721
|
principal: string;
|
|
2817
2722
|
audience: string;
|
|
2818
2723
|
ttlSeconds: number;
|
|
2819
|
-
attenuation?: {
|
|
2820
|
-
kind: "identity";
|
|
2821
|
-
self: true;
|
|
2822
|
-
} | undefined;
|
|
2823
2724
|
}, {
|
|
2824
2725
|
readonly mode: 'value';
|
|
2825
2726
|
readonly value: string;
|
|
@@ -2949,10 +2850,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
2949
2850
|
principal: string;
|
|
2950
2851
|
audience: string;
|
|
2951
2852
|
ttlSeconds: number;
|
|
2952
|
-
attenuation?: {
|
|
2953
|
-
kind: "identity";
|
|
2954
|
-
self: true;
|
|
2955
|
-
} | undefined;
|
|
2956
2853
|
}, {
|
|
2957
2854
|
readonly mode: 'value';
|
|
2958
2855
|
readonly value: string;
|
|
@@ -3045,10 +2942,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
3045
2942
|
principal: string;
|
|
3046
2943
|
audience: string;
|
|
3047
2944
|
ttlSeconds: number;
|
|
3048
|
-
attenuation?: {
|
|
3049
|
-
kind: "identity";
|
|
3050
|
-
self: true;
|
|
3051
|
-
} | undefined;
|
|
3052
2945
|
}, {
|
|
3053
2946
|
readonly mode: 'value';
|
|
3054
2947
|
readonly value: string;
|
|
@@ -3178,10 +3071,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
3178
3071
|
principal: string;
|
|
3179
3072
|
audience: string;
|
|
3180
3073
|
ttlSeconds: number;
|
|
3181
|
-
attenuation?: {
|
|
3182
|
-
kind: "identity";
|
|
3183
|
-
self: true;
|
|
3184
|
-
} | undefined;
|
|
3185
3074
|
}, {
|
|
3186
3075
|
readonly mode: 'value';
|
|
3187
3076
|
readonly value: string;
|
|
@@ -3274,10 +3163,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
3274
3163
|
principal: string;
|
|
3275
3164
|
audience: string;
|
|
3276
3165
|
ttlSeconds: number;
|
|
3277
|
-
attenuation?: {
|
|
3278
|
-
kind: "identity";
|
|
3279
|
-
self: true;
|
|
3280
|
-
} | undefined;
|
|
3281
3166
|
}, {
|
|
3282
3167
|
readonly mode: 'value';
|
|
3283
3168
|
readonly value: string;
|
|
@@ -3407,10 +3292,6 @@ export declare const Domain: builder.NodeClass<{
|
|
|
3407
3292
|
principal: string;
|
|
3408
3293
|
audience: string;
|
|
3409
3294
|
ttlSeconds: number;
|
|
3410
|
-
attenuation?: {
|
|
3411
|
-
kind: "identity";
|
|
3412
|
-
self: true;
|
|
3413
|
-
} | undefined;
|
|
3414
3295
|
}, {
|
|
3415
3296
|
readonly mode: 'value';
|
|
3416
3297
|
readonly value: string;
|
|
@@ -3467,7 +3348,7 @@ export declare const Domain: builder.NodeClass<{
|
|
|
3467
3348
|
allowed: boolean;
|
|
3468
3349
|
}[];
|
|
3469
3350
|
};
|
|
3470
|
-
}, "authenticated", true, false, undefined>>, "can", unknown>>, never> | (builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, false, "dependencyContext", "self", never> | builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, true, "origin", "self", undefined> | builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, true, "schema", "self", never> | builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, true, "schemaRevision", "self", never>);
|
|
3351
|
+
}, "authenticated", true, false, undefined>>, "can", unknown>>, never> | (builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, false, "dependencyContext", "self", never> | builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, true, "name", "self", undefined> | builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, true, "origin", "self", undefined> | builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, true, "schema", "self", never> | builder.AuthoredPropertyProjection<import("@astrale-os/kernel-dsl/value").Value, import("@astrale-os/kernel-dsl/value").Value, true, "schemaRevision", "self", never>);
|
|
3471
3352
|
readonly abstractInstanceMethods: never;
|
|
3472
3353
|
readonly abstractStaticMethods: never;
|
|
3473
3354
|
readonly effectiveInstanceMethods: never;
|
|
@@ -9,6 +9,9 @@ export const Domain = nodeClass({
|
|
|
9
9
|
type: 'string',
|
|
10
10
|
pattern: '[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?(\\.[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)+',
|
|
11
11
|
},
|
|
12
|
+
// The authored display name; a revision that predates it projects its origin instead, which
|
|
13
|
+
// is why the bound admits a complete origin rather than only an authored name.
|
|
14
|
+
name: { type: 'string', minLength: 1, maxLength: 253 },
|
|
12
15
|
dependencyContext: property({ type: 'array', items: { type: 'object' } }, { required: false }),
|
|
13
16
|
schema: property({ type: 'object' }, {}),
|
|
14
17
|
schemaRevision: property({ type: 'string', pattern: 'sha256:[0-9a-f]{64}' }, {}),
|
|
@@ -41,10 +41,6 @@ export declare const Identity: builder.NodeClass<{
|
|
|
41
41
|
principal: string;
|
|
42
42
|
audience: string;
|
|
43
43
|
ttlSeconds: number;
|
|
44
|
-
attenuation?: {
|
|
45
|
-
kind: "identity";
|
|
46
|
-
self: true;
|
|
47
|
-
} | undefined;
|
|
48
44
|
}, {
|
|
49
45
|
readonly mode: 'value';
|
|
50
46
|
readonly value: string;
|
|
@@ -178,10 +174,6 @@ export declare const Identity: builder.NodeClass<{
|
|
|
178
174
|
principal: string;
|
|
179
175
|
audience: string;
|
|
180
176
|
ttlSeconds: number;
|
|
181
|
-
attenuation?: {
|
|
182
|
-
kind: "identity";
|
|
183
|
-
self: true;
|
|
184
|
-
} | undefined;
|
|
185
177
|
}, {
|
|
186
178
|
readonly mode: 'value';
|
|
187
179
|
readonly value: string;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { SourceDomain, schema } from '@astrale-os/kernel-dsl/v1';
|
|
2
|
+
import { type Edge, type Part, type Payload } from './part.js';
|
|
3
|
+
/**
|
|
4
|
+
* Declare each authored Core Node, then each authored Core Edge, and return the locators that
|
|
5
|
+
* associate every Core Node with its Domain.
|
|
6
|
+
*/
|
|
7
|
+
export declare function projectCore<Extra extends object>(domain: SourceDomain<schema.DomainSchema>, core: Part<Extra>, payload: Payload<Extra>): Edge<Extra>[];
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { ClassKey } from '@astrale-os/kernel-dsl/v1/addressing';
|
|
2
|
+
import { Path } from '#graph/path';
|
|
3
|
+
import { K } from '../index.js';
|
|
4
|
+
import { projectedMethodPath } from './callables.js';
|
|
5
|
+
import { ProjectionError } from './diagnostics.js';
|
|
6
|
+
import { edge } from './part.js';
|
|
7
|
+
import { memberProperties } from './properties.js';
|
|
8
|
+
/**
|
|
9
|
+
* Declare each authored Core Node, then each authored Core Edge, and return the locators that
|
|
10
|
+
* associate every Core Node with its Domain.
|
|
11
|
+
*/
|
|
12
|
+
export function projectCore(domain, core, payload) {
|
|
13
|
+
// The Domain Node is persisted before its Core part, so locators address it by its Path.
|
|
14
|
+
const domainEndpoint = Object.freeze({ path: Path.domain(domain.origin).raw });
|
|
15
|
+
const locators = [];
|
|
16
|
+
for (const [slug, declaration] of Object.entries(domain.source.core.nodes)) {
|
|
17
|
+
assertAuthenticationUnowned(domain, declaration.class, declaration.properties, slug);
|
|
18
|
+
const created = core.node(Path.project({ origin: domain.origin, kind: 'core', name: slug }).raw, ClassKey.of(declaration.class), payload(() => declaration.properties));
|
|
19
|
+
locators.push(edge(created, domainEndpoint, K.classes.of_domain.ref, payload(() => memberProperties(`core.${slug}`))));
|
|
20
|
+
}
|
|
21
|
+
// Resolved edges carry each endpoint's own identity; the source IR only names it.
|
|
22
|
+
for (const authored of domain.core.edges) {
|
|
23
|
+
core.edges.push(edge(endpoint(authored.source, domain, core, domainEndpoint), endpoint(authored.target, domain, core, domainEndpoint), authored.class.ref, payload(() => authored.properties)));
|
|
24
|
+
}
|
|
25
|
+
return locators;
|
|
26
|
+
}
|
|
27
|
+
/** Authentication of a Core Identity is established only by the credential-evidenced lifecycle. */
|
|
28
|
+
function assertAuthenticationUnowned(domain, classRef, properties, slug) {
|
|
29
|
+
const definition = domain.definition(classRef);
|
|
30
|
+
if (definition?.ref.kind !== 'class' ||
|
|
31
|
+
definition.kind !== 'node' ||
|
|
32
|
+
!definition.satisfies(K.classes.Identity)) {
|
|
33
|
+
return;
|
|
34
|
+
}
|
|
35
|
+
const hasIssuer = Object.hasOwn(properties, K.classes.Identity.properties.iss.key);
|
|
36
|
+
const hasSubject = Object.hasOwn(properties, K.classes.Identity.properties.sub.key);
|
|
37
|
+
if (hasIssuer || hasSubject) {
|
|
38
|
+
throw new ProjectionError('PROJECTION_INVALID', `Core Identity ${domain.origin}:core.${slug} cannot declare protected Authentication properties iss or sub.`);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* A Core Node binds inside the Core part; every other local Definition is already projected as a
|
|
43
|
+
* managed declaration, so it is addressed by its canonical Path exactly like the owning Domain.
|
|
44
|
+
*/
|
|
45
|
+
function endpoint(value, domain, core, domainEndpoint) {
|
|
46
|
+
if ('ref' in value)
|
|
47
|
+
return core.endpoint(Path.project(value.ref).raw);
|
|
48
|
+
if ('owner' in value)
|
|
49
|
+
return core.endpoint(projectedMethodPath(domain, value));
|
|
50
|
+
return domainEndpoint;
|
|
51
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { SourceDomain, schema } from '@astrale-os/kernel-dsl/v1';
|
|
2
|
+
import type { ResolvedDefinition, ResolvedDefinitionOf } from '@astrale-os/kernel-dsl/v1/language';
|
|
3
|
+
import { ClassKey } from '@astrale-os/kernel-dsl/v1/addressing';
|
|
4
|
+
import type { GraphSpecEndpoint } from '#graph/graph';
|
|
5
|
+
import { type Part, type Payload } from './part.js';
|
|
6
|
+
/** Declare the Domain Node, the target of every of_domain locator. */
|
|
7
|
+
export declare function projectDomain<Extra extends object>(domain: SourceDomain<schema.DomainSchema>, managed: Part<Extra>, payload: Payload<Extra>): GraphSpecEndpoint;
|
|
8
|
+
/** Declare each local Definition's Node and its of_domain locator. */
|
|
9
|
+
export declare function projectDefinitions<Extra extends object>(domain: SourceDomain<schema.DomainSchema>, managed: Part<Extra>, domainEndpoint: GraphSpecEndpoint, payload: Payload<Extra>): void;
|
|
10
|
+
/** Each local Definition projected as a managed declaration, with the Kernel Class it projects to. */
|
|
11
|
+
export declare function projectedDefinitions(domain: SourceDomain<schema.DomainSchema>): Generator<readonly [ResolvedDefinition, ClassKey]>;
|
|
12
|
+
/** Whether a resolved Definition is of the given kind. */
|
|
13
|
+
export declare function is<Kind extends ResolvedDefinition['ref']['kind']>(definition: ResolvedDefinition, kind: Kind): definition is ResolvedDefinitionOf<Kind>;
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { ClassKey } from '@astrale-os/kernel-dsl/v1/addressing';
|
|
2
|
+
import { Path } from '#graph/path';
|
|
3
|
+
import { normalizeProperties } from '#graph/properties';
|
|
4
|
+
import { K } from '../index.js';
|
|
5
|
+
import { edge } from './part.js';
|
|
6
|
+
import { EMPTY_PROPERTIES, callableProperties, descriptionProperties, memberProperties, } from './properties.js';
|
|
7
|
+
/** Declare the Domain Node, the target of every of_domain locator. */
|
|
8
|
+
export function projectDomain(domain, managed, payload) {
|
|
9
|
+
return managed.node(Path.domain(domain.origin).raw, ClassKey.of(K.classes.Domain.ref), payload(() => domainProperties(domain)));
|
|
10
|
+
}
|
|
11
|
+
/** Declare each local Definition's Node and its of_domain locator. */
|
|
12
|
+
export function projectDefinitions(domain, managed, domainEndpoint, payload) {
|
|
13
|
+
for (const [definition, projectedClass] of projectedDefinitions(domain)) {
|
|
14
|
+
const definitionEndpoint = managed.node(Path.project(definition.ref).raw, projectedClass, payload(() => definitionProperties(definition)));
|
|
15
|
+
managed.edges.push(edge(definitionEndpoint, domainEndpoint, K.classes.of_domain.ref, payload(() => memberProperties(`${definition.ref.kind}.${definition.ref.name}`))));
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
/** Each local Definition projected as a managed declaration, with the Kernel Class it projects to. */
|
|
19
|
+
export function* projectedDefinitions(domain) {
|
|
20
|
+
for (const definition of domain.definitions()) {
|
|
21
|
+
if (definition.ref.origin !== domain.origin)
|
|
22
|
+
continue;
|
|
23
|
+
const projectedClass = classOf(definition);
|
|
24
|
+
if (projectedClass !== undefined)
|
|
25
|
+
yield [definition, projectedClass];
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
/** Whether a resolved Definition is of the given kind. */
|
|
29
|
+
export function is(definition, kind) {
|
|
30
|
+
return definition.ref.kind === kind;
|
|
31
|
+
}
|
|
32
|
+
function classOf(definition) {
|
|
33
|
+
switch (definition.ref.kind) {
|
|
34
|
+
case 'class':
|
|
35
|
+
return ClassKey.of(K.classes.Class.ref);
|
|
36
|
+
case 'function':
|
|
37
|
+
return ClassKey.of(K.classes.Function.ref);
|
|
38
|
+
case 'policy':
|
|
39
|
+
return ClassKey.of(K.classes.Policy.ref);
|
|
40
|
+
case 'view':
|
|
41
|
+
return ClassKey.of(K.classes.View.ref);
|
|
42
|
+
default:
|
|
43
|
+
return undefined;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
/** Identity properties are supplied atomically by trusted lifecycle materialization. */
|
|
47
|
+
function domainProperties(domain) {
|
|
48
|
+
return normalizeProperties({
|
|
49
|
+
[K.classes.Domain.self.properties.origin.key]: domain.origin,
|
|
50
|
+
[K.classes.Domain.self.properties.name.key]: domain.source.name,
|
|
51
|
+
[K.classes.Domain.self.properties.schema.key]: domain.source,
|
|
52
|
+
[K.classes.Domain.self.properties.schemaRevision.key]: domain.revision,
|
|
53
|
+
});
|
|
54
|
+
}
|
|
55
|
+
function definitionProperties(definition) {
|
|
56
|
+
if (is(definition, 'function'))
|
|
57
|
+
return callableProperties(definition.definition);
|
|
58
|
+
if (is(definition, 'core'))
|
|
59
|
+
return EMPTY_PROPERTIES;
|
|
60
|
+
const metadata = descriptionProperties(definition.definition.description);
|
|
61
|
+
if (!is(definition, 'class'))
|
|
62
|
+
return normalizeProperties(metadata);
|
|
63
|
+
const declaration = definition.definition;
|
|
64
|
+
const icon = declaration.kind === 'node' ? declaration.icon : undefined;
|
|
65
|
+
return normalizeProperties({
|
|
66
|
+
...metadata,
|
|
67
|
+
[K.classes.Class.self.properties.kind.key]: declaration.kind,
|
|
68
|
+
[K.classes.Class.self.properties.abstract.key]: declaration.abstract,
|
|
69
|
+
...(icon !== undefined ? { [K.classes.Iconable.self.properties.icon.key]: icon } : {}),
|
|
70
|
+
});
|
|
71
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { SourceDomain, schema } from '@astrale-os/kernel-dsl/v1';
|
|
2
|
+
import type { GraphSpecEndpoint } from '#graph/graph';
|
|
3
|
+
import { type Part, type Payload } from './part.js';
|
|
4
|
+
/** Declare each executable local Method as a Function Node, with its method_of and of_domain Edges. */
|
|
5
|
+
export declare function projectMethods<Extra extends object>(domain: SourceDomain<schema.DomainSchema>, managed: Part<Extra>, domainEndpoint: GraphSpecEndpoint, payload: Payload<Extra>): void;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { ClassKey } from '@astrale-os/kernel-dsl/v1/addressing';
|
|
2
|
+
import { Path } from '#graph/path';
|
|
3
|
+
import { normalizeProperties } from '#graph/properties';
|
|
4
|
+
import { K } from '../index.js';
|
|
5
|
+
import { projectedMethodPath } from './callables.js';
|
|
6
|
+
import { ProjectionError } from './diagnostics.js';
|
|
7
|
+
import { edge } from './part.js';
|
|
8
|
+
import { callableProperties, memberProperties } from './properties.js';
|
|
9
|
+
/** Declare each executable local Method as a Function Node, with its method_of and of_domain Edges. */
|
|
10
|
+
export function projectMethods(domain, managed, domainEndpoint, payload) {
|
|
11
|
+
for (const method of executableMethods(domain)) {
|
|
12
|
+
const methodEndpoint = managed.node(projectedMethodPath(domain, method), ClassKey.of(K.classes.Function.ref), payload(() => callableProperties(method.definition)));
|
|
13
|
+
managed.edges.push(edge(methodEndpoint, managed.endpoint(Path.project(method.owner.ref).raw), K.classes.method_of.ref, payload(() => normalizeProperties({
|
|
14
|
+
[K.classes.method_of.self.properties.name.key]: method.name,
|
|
15
|
+
[K.classes.method_of.self.properties.static.key]: method.definition.static,
|
|
16
|
+
}))));
|
|
17
|
+
// This structural check must also execute when no Property payload is requested.
|
|
18
|
+
const member = memberOf(domain, method);
|
|
19
|
+
managed.edges.push(edge(methodEndpoint, domainEndpoint, K.classes.of_domain.ref, payload(() => memberProperties(member))));
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
/** Each local executable Method once, instance and static, across every Class of the Domain. */
|
|
23
|
+
function executableMethods(domain) {
|
|
24
|
+
const methods = new Map();
|
|
25
|
+
for (const definition of Object.values(domain.classes)) {
|
|
26
|
+
for (const method of [...definition.methods, ...definition.static.methods]) {
|
|
27
|
+
if (method.owner.ref.origin === domain.origin && method.executable) {
|
|
28
|
+
methods.set(method.key, method);
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
return methods.values();
|
|
33
|
+
}
|
|
34
|
+
/** The Method's member name within its Domain. */
|
|
35
|
+
function memberOf(domain, method) {
|
|
36
|
+
const prefix = `${domain.origin}:`;
|
|
37
|
+
if (!method.key.startsWith(prefix)) {
|
|
38
|
+
throw new ProjectionError('PROJECTION_INVALID', 'Method key belongs to another Domain.');
|
|
39
|
+
}
|
|
40
|
+
return method.key.slice(prefix.length);
|
|
41
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import type { ClassRef } from '@astrale-os/kernel-dsl/v1';
|
|
2
|
+
import { ClassKey } from '@astrale-os/kernel-dsl/v1/addressing';
|
|
3
|
+
import type { GraphSpecEndpoint } from '#graph/graph';
|
|
4
|
+
import type { NodePath } from '#graph/path';
|
|
5
|
+
import type { Properties } from '#graph/properties';
|
|
6
|
+
import { LocalAlias } from '#graph/graph';
|
|
7
|
+
import type { ProjectionTopologyEdge, ProjectionTopologyNode } from './types.js';
|
|
8
|
+
/**
|
|
9
|
+
* What each declaration carries besides its identity: full projection evaluates the Property
|
|
10
|
+
* factory, topology projection never does. Call it in argument position, before `node` or `edge`
|
|
11
|
+
* runs its own checks, so both projections throw the same error first.
|
|
12
|
+
*/
|
|
13
|
+
export type Payload<Extra extends object> = (properties: () => Properties) => Extra;
|
|
14
|
+
export type Node<Extra extends object> = ProjectionTopologyNode & Extra;
|
|
15
|
+
export type Edge<Extra extends object> = ProjectionTopologyEdge & Extra;
|
|
16
|
+
/** One graph part under construction: its local bindings, its declared Nodes and its Edges. */
|
|
17
|
+
export declare class Part<Extra extends object> {
|
|
18
|
+
#private;
|
|
19
|
+
readonly edges: Edge<Extra>[];
|
|
20
|
+
/** Bind each Path, in the given order, to the next local binding `n0`, `n1`, ... */
|
|
21
|
+
constructor(paths: readonly NodePath[]);
|
|
22
|
+
/** A Path declared in this part is addressed by its binding, any other by the Path itself. */
|
|
23
|
+
endpoint(path: NodePath): GraphSpecEndpoint;
|
|
24
|
+
/** Declare the Node at a bound Path once; declaring it again returns the first binding. */
|
|
25
|
+
node(path: NodePath, classKey: ClassKey, payload: Extra): GraphSpecEndpoint;
|
|
26
|
+
/** The declared Nodes and Edges in declaration order, with each binding's Path. */
|
|
27
|
+
done(): Readonly<{
|
|
28
|
+
nodes: readonly Node<Extra>[];
|
|
29
|
+
edges: readonly Edge<Extra>[];
|
|
30
|
+
paths: Map<LocalAlias, import("../../../graph/path/language/model.js").NodePath>;
|
|
31
|
+
}>;
|
|
32
|
+
}
|
|
33
|
+
/** One projected Edge. */
|
|
34
|
+
export declare function edge<Extra extends object>(source: GraphSpecEndpoint, target: GraphSpecEndpoint, classRef: ClassRef, payload: Extra): Edge<Extra>;
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { ClassKey } from '@astrale-os/kernel-dsl/v1/addressing';
|
|
2
|
+
import { LocalAlias } from '#graph/graph';
|
|
3
|
+
import { ProjectionError } from './diagnostics.js';
|
|
4
|
+
/** One graph part under construction: its local bindings, its declared Nodes and its Edges. */
|
|
5
|
+
export class Part {
|
|
6
|
+
edges = [];
|
|
7
|
+
#bindings;
|
|
8
|
+
#nodes = new Map();
|
|
9
|
+
/** Bind each Path, in the given order, to the next local binding `n0`, `n1`, ... */
|
|
10
|
+
constructor(paths) {
|
|
11
|
+
this.#bindings = new Map(paths.map((path, index) => [path, LocalAlias(`n${index}`)]));
|
|
12
|
+
}
|
|
13
|
+
/** A Path declared in this part is addressed by its binding, any other by the Path itself. */
|
|
14
|
+
endpoint(path) {
|
|
15
|
+
const created = this.#bindings.get(path);
|
|
16
|
+
return created === undefined ? Object.freeze({ path }) : Object.freeze({ created });
|
|
17
|
+
}
|
|
18
|
+
/** Declare the Node at a bound Path once; declaring it again returns the first binding. */
|
|
19
|
+
node(path, classKey, payload) {
|
|
20
|
+
const existing = this.#nodes.get(path);
|
|
21
|
+
if (existing !== undefined)
|
|
22
|
+
return Object.freeze({ created: existing.as });
|
|
23
|
+
const as = this.#bindings.get(path);
|
|
24
|
+
if (as === undefined) {
|
|
25
|
+
throw new ProjectionError('PROJECTION_INVALID', `Projection has no binding for ${path}.`);
|
|
26
|
+
}
|
|
27
|
+
this.#nodes.set(path, Object.freeze({ as, class: classKey, ...payload }));
|
|
28
|
+
return Object.freeze({ created: as });
|
|
29
|
+
}
|
|
30
|
+
/** The declared Nodes and Edges in declaration order, with each binding's Path. */
|
|
31
|
+
done() {
|
|
32
|
+
return Object.freeze({
|
|
33
|
+
nodes: Object.freeze([...this.#nodes.values()]),
|
|
34
|
+
edges: Object.freeze(this.edges),
|
|
35
|
+
paths: new Map([...this.#bindings].map(([path, binding]) => [binding, path])),
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
/** One projected Edge. */
|
|
40
|
+
export function edge(source, target, classRef, payload) {
|
|
41
|
+
return Object.freeze({ source, target, class: ClassKey.of(classRef), ...payload });
|
|
42
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { Domain } from '@astrale-os/kernel-dsl/v1';
|
|
2
|
+
import type { NodePath } from '#graph/path';
|
|
3
|
+
/** Sorted Paths of the Domain Node, its local Definitions and their executable Methods. */
|
|
4
|
+
export declare function managedPaths(domain: Domain): readonly NodePath[];
|
|
5
|
+
/** Sorted Paths of the Domain's authored Core Nodes. */
|
|
6
|
+
export declare function corePaths(domain: Domain): readonly NodePath[];
|