@platforma-sdk/model 1.42.16 → 1.42.20
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/bconfig/index.d.ts +0 -1
- package/dist/bconfig/lambdas.d.ts +0 -1
- package/dist/bconfig/normalization.cjs +19 -0
- package/dist/bconfig/normalization.cjs.map +1 -0
- package/dist/bconfig/normalization.d.ts +0 -1
- package/dist/bconfig/normalization.js +16 -0
- package/dist/bconfig/normalization.js.map +1 -0
- package/dist/bconfig/types.cjs +8 -0
- package/dist/bconfig/types.cjs.map +1 -0
- package/dist/bconfig/types.d.ts +0 -1
- package/dist/bconfig/types.js +6 -0
- package/dist/bconfig/types.js.map +1 -0
- package/dist/bconfig/util.d.ts +0 -1
- package/dist/bconfig/v3.d.ts +0 -1
- package/dist/block_api_v1.d.ts +0 -1
- package/dist/block_api_v2.d.ts +0 -1
- package/dist/block_state_patch.d.ts +0 -1
- package/dist/block_state_util.cjs +28 -0
- package/dist/block_state_util.cjs.map +1 -0
- package/dist/block_state_util.d.ts +0 -1
- package/dist/block_state_util.js +24 -0
- package/dist/block_state_util.js.map +1 -0
- package/dist/branding.d.ts +0 -1
- package/dist/builder.cjs +166 -0
- package/dist/builder.cjs.map +1 -0
- package/dist/builder.d.ts +0 -1
- package/dist/builder.js +164 -0
- package/dist/builder.js.map +1 -0
- package/dist/components/PFrameForGraphs.cjs +261 -0
- package/dist/components/PFrameForGraphs.cjs.map +1 -0
- package/dist/components/PFrameForGraphs.d.ts +0 -1
- package/dist/components/PFrameForGraphs.js +254 -0
- package/dist/components/PFrameForGraphs.js.map +1 -0
- package/dist/components/PlAnnotations/filter.d.ts +0 -1
- package/dist/components/PlAnnotations/filters_ui.cjs +556 -0
- package/dist/components/PlAnnotations/filters_ui.cjs.map +1 -0
- package/dist/components/PlAnnotations/filters_ui.d.ts +0 -1
- package/dist/components/PlAnnotations/filters_ui.js +548 -0
- package/dist/components/PlAnnotations/filters_ui.js.map +1 -0
- package/dist/components/PlAnnotations/index.d.ts +0 -1
- package/dist/components/PlAnnotations/types.d.ts +0 -1
- package/dist/components/PlDataTable.cjs +337 -0
- package/dist/components/PlDataTable.cjs.map +1 -0
- package/dist/components/PlDataTable.d.ts +0 -1
- package/dist/components/PlDataTable.js +324 -0
- package/dist/components/PlDataTable.js.map +1 -0
- package/dist/components/PlMultiSequenceAlignment.cjs +33 -0
- package/dist/components/PlMultiSequenceAlignment.cjs.map +1 -0
- package/dist/components/PlMultiSequenceAlignment.d.ts +0 -1
- package/dist/components/PlMultiSequenceAlignment.js +31 -0
- package/dist/components/PlMultiSequenceAlignment.js.map +1 -0
- package/dist/components/PlSelectionModel.cjs +11 -0
- package/dist/components/PlSelectionModel.cjs.map +1 -0
- package/dist/components/PlSelectionModel.d.ts +0 -1
- package/dist/components/PlSelectionModel.js +9 -0
- package/dist/components/PlSelectionModel.js.map +1 -0
- package/dist/components/index.d.ts +0 -1
- package/dist/config/actions.cjs +266 -0
- package/dist/config/actions.cjs.map +1 -0
- package/dist/config/actions.d.ts +0 -1
- package/dist/config/actions.js +233 -0
- package/dist/config/actions.js.map +1 -0
- package/dist/config/actions_kinds.d.ts +0 -1
- package/dist/config/index.d.ts +0 -1
- package/dist/config/model.d.ts +0 -1
- package/dist/config/model_meta.d.ts +0 -1
- package/dist/config/type_engine.d.ts +0 -1
- package/dist/config/type_util.d.ts +0 -1
- package/dist/env_value.cjs +11 -0
- package/dist/env_value.cjs.map +1 -0
- package/dist/env_value.d.ts +0 -1
- package/dist/env_value.js +9 -0
- package/dist/env_value.js.map +1 -0
- package/dist/global.d.ts +14 -0
- package/dist/index.cjs +138 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.ts +0 -1
- package/dist/index.js +26 -1
- package/dist/index.js.map +1 -1
- package/dist/internal.cjs +56 -0
- package/dist/internal.cjs.map +1 -0
- package/dist/internal.d.ts +0 -1
- package/dist/internal.js +49 -0
- package/dist/internal.js.map +1 -0
- package/dist/package.json.cjs +6 -0
- package/dist/package.json.cjs.map +1 -0
- package/dist/package.json.js +4 -0
- package/dist/package.json.js.map +1 -0
- package/dist/pframe.cjs +34 -0
- package/dist/pframe.cjs.map +1 -0
- package/dist/pframe.d.ts +0 -1
- package/dist/pframe.js +32 -0
- package/dist/pframe.js.map +1 -0
- package/dist/platforma.d.ts +0 -1
- package/dist/raw_globals.cjs +28 -0
- package/dist/raw_globals.cjs.map +1 -0
- package/dist/raw_globals.d.ts +0 -1
- package/dist/raw_globals.js +25 -0
- package/dist/raw_globals.js.map +1 -0
- package/dist/ref_util.cjs +21 -0
- package/dist/ref_util.cjs.map +1 -0
- package/dist/ref_util.d.ts +11 -12
- package/dist/ref_util.js +18 -0
- package/dist/ref_util.js.map +1 -0
- package/dist/render/accessor.cjs +233 -0
- package/dist/render/accessor.cjs.map +1 -0
- package/dist/render/accessor.d.ts +0 -1
- package/dist/render/accessor.js +230 -0
- package/dist/render/accessor.js.map +1 -0
- package/dist/render/api.cjs +514 -0
- package/dist/render/api.cjs.map +1 -0
- package/dist/render/api.d.ts +0 -1
- package/dist/render/api.js +511 -0
- package/dist/render/api.js.map +1 -0
- package/dist/render/future.cjs +35 -0
- package/dist/render/future.cjs.map +1 -0
- package/dist/render/future.d.ts +0 -1
- package/dist/render/future.js +33 -0
- package/dist/render/future.js.map +1 -0
- package/dist/render/index.d.ts +0 -1
- package/dist/render/internal.cjs +43 -0
- package/dist/render/internal.cjs.map +1 -0
- package/dist/render/internal.d.ts +0 -1
- package/dist/render/internal.js +37 -0
- package/dist/render/internal.js.map +1 -0
- package/dist/render/traversal_ops.d.ts +0 -1
- package/dist/render/util/axis_filtering.cjs +87 -0
- package/dist/render/util/axis_filtering.cjs.map +1 -0
- package/dist/render/util/axis_filtering.d.ts +0 -1
- package/dist/render/util/axis_filtering.js +85 -0
- package/dist/render/util/axis_filtering.js.map +1 -0
- package/dist/render/util/column_collection.cjs +309 -0
- package/dist/render/util/column_collection.cjs.map +1 -0
- package/dist/render/util/column_collection.d.ts +0 -1
- package/dist/render/util/column_collection.js +307 -0
- package/dist/render/util/column_collection.js.map +1 -0
- package/dist/render/util/index.d.ts +0 -1
- package/dist/render/util/label.cjs +153 -0
- package/dist/render/util/label.cjs.map +1 -0
- package/dist/render/util/label.d.ts +0 -1
- package/dist/render/util/label.js +149 -0
- package/dist/render/util/label.js.map +1 -0
- package/dist/render/util/pcolumn_data.cjs +342 -0
- package/dist/render/util/pcolumn_data.cjs.map +1 -0
- package/dist/render/util/pcolumn_data.d.ts +0 -1
- package/dist/render/util/pcolumn_data.js +330 -0
- package/dist/render/util/pcolumn_data.js.map +1 -0
- package/dist/render/util/pframe_upgraders.cjs +47 -0
- package/dist/render/util/pframe_upgraders.cjs.map +1 -0
- package/dist/render/util/pframe_upgraders.d.ts +0 -1
- package/dist/render/util/pframe_upgraders.js +45 -0
- package/dist/render/util/pframe_upgraders.js.map +1 -0
- package/dist/render/util/split_selectors.d.ts +0 -1
- package/dist/sdk_info.cjs +10 -0
- package/dist/sdk_info.cjs.map +1 -0
- package/dist/sdk_info.d.ts +0 -1
- package/dist/sdk_info.js +8 -0
- package/dist/sdk_info.js.map +1 -0
- package/dist/unionize.d.ts +0 -1
- package/dist/version.cjs +8 -0
- package/dist/version.cjs.map +1 -0
- package/dist/version.d.ts +0 -1
- package/dist/version.js +6 -0
- package/dist/version.js.map +1 -0
- package/package.json +16 -18
- package/src/components/PFrameForGraphs.test.ts +2 -2
- package/src/components/PlAnnotations/filters_ui.test.ts +1 -1
- package/src/render/util/label.test.ts +2 -2
- package/src/typing.test.ts +2 -1
- package/dist/bconfig/index.d.ts.map +0 -1
- package/dist/bconfig/lambdas.d.ts.map +0 -1
- package/dist/bconfig/normalization.d.ts.map +0 -1
- package/dist/bconfig/types.d.ts.map +0 -1
- package/dist/bconfig/util.d.ts.map +0 -1
- package/dist/bconfig/v3.d.ts.map +0 -1
- package/dist/block_api_v1.d.ts.map +0 -1
- package/dist/block_api_v2.d.ts.map +0 -1
- package/dist/block_state_patch.d.ts.map +0 -1
- package/dist/block_state_util.d.ts.map +0 -1
- package/dist/branding.d.ts.map +0 -1
- package/dist/builder.d.ts.map +0 -1
- package/dist/components/PFrameForGraphs.d.ts.map +0 -1
- package/dist/components/PlAnnotations/filter.d.ts.map +0 -1
- package/dist/components/PlAnnotations/filters_ui.d.ts.map +0 -1
- package/dist/components/PlAnnotations/index.d.ts.map +0 -1
- package/dist/components/PlAnnotations/types.d.ts.map +0 -1
- package/dist/components/PlDataTable.d.ts.map +0 -1
- package/dist/components/PlMultiSequenceAlignment.d.ts.map +0 -1
- package/dist/components/PlSelectionModel.d.ts.map +0 -1
- package/dist/components/index.d.ts.map +0 -1
- package/dist/config/actions.d.ts.map +0 -1
- package/dist/config/actions_kinds.d.ts.map +0 -1
- package/dist/config/index.d.ts.map +0 -1
- package/dist/config/model.d.ts.map +0 -1
- package/dist/config/model_meta.d.ts.map +0 -1
- package/dist/config/type_engine.d.ts.map +0 -1
- package/dist/config/type_util.d.ts.map +0 -1
- package/dist/env_value.d.ts.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/index.mjs +0 -2845
- package/dist/index.mjs.map +0 -1
- package/dist/internal.d.ts.map +0 -1
- package/dist/pframe.d.ts.map +0 -1
- package/dist/platforma.d.ts.map +0 -1
- package/dist/raw_globals.d.ts.map +0 -1
- package/dist/ref_util.d.ts.map +0 -1
- package/dist/render/accessor.d.ts.map +0 -1
- package/dist/render/api.d.ts.map +0 -1
- package/dist/render/future.d.ts.map +0 -1
- package/dist/render/index.d.ts.map +0 -1
- package/dist/render/internal.d.ts.map +0 -1
- package/dist/render/traversal_ops.d.ts.map +0 -1
- package/dist/render/util/axis_filtering.d.ts.map +0 -1
- package/dist/render/util/column_collection.d.ts.map +0 -1
- package/dist/render/util/index.d.ts.map +0 -1
- package/dist/render/util/label.d.ts.map +0 -1
- package/dist/render/util/pcolumn_data.d.ts.map +0 -1
- package/dist/render/util/pframe_upgraders.d.ts.map +0 -1
- package/dist/render/util/split_selectors.d.ts.map +0 -1
- package/dist/sdk_info.d.ts.map +0 -1
- package/dist/unionize.d.ts.map +0 -1
- package/dist/version.d.ts.map +0 -1
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { registerFutureAwait } from '../internal.js';
|
|
2
|
+
|
|
3
|
+
class FutureRef {
|
|
4
|
+
handle;
|
|
5
|
+
postProcess;
|
|
6
|
+
isResolved = false;
|
|
7
|
+
resolvedValue;
|
|
8
|
+
constructor(handle, postProcess = (v) => v) {
|
|
9
|
+
this.handle = handle;
|
|
10
|
+
this.postProcess = postProcess;
|
|
11
|
+
registerFutureAwait(handle, (value) => {
|
|
12
|
+
this.resolvedValue = postProcess(value);
|
|
13
|
+
this.isResolved = true;
|
|
14
|
+
});
|
|
15
|
+
}
|
|
16
|
+
map(mapping) {
|
|
17
|
+
return new FutureRef(this.handle, (v) => mapping(this.postProcess(v)));
|
|
18
|
+
}
|
|
19
|
+
mapDefined(mapping) {
|
|
20
|
+
return new FutureRef(this.handle, (v) => {
|
|
21
|
+
const vv = this.postProcess(v);
|
|
22
|
+
return vv ? mapping(vv) : undefined;
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
toJSON() {
|
|
26
|
+
return this.isResolved
|
|
27
|
+
? this.resolvedValue
|
|
28
|
+
: { __awaited_futures__: [this.handle] };
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export { FutureRef };
|
|
33
|
+
//# sourceMappingURL=future.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"future.js","sources":["../../src/render/future.ts"],"sourcesContent":["import type { FutureAwait, FutureHandle } from './internal';\nimport { registerFutureAwait } from '../internal';\n\nexport class FutureRef<T = unknown> {\n private isResolved = false;\n private resolvedValue?: T;\n\n constructor(\n private readonly handle: FutureHandle,\n private readonly postProcess: (value: unknown) => T = (v) => v as T,\n ) {\n registerFutureAwait(handle, (value) => {\n this.resolvedValue = postProcess(value);\n this.isResolved = true;\n });\n }\n\n public map<R>(mapping: (v: T) => R): FutureRef<R> {\n return new FutureRef<R>(this.handle, (v) => mapping(this.postProcess(v)));\n }\n\n public mapDefined<R>(mapping: (v: NonNullable<T>) => R): FutureRef<R | undefined> {\n return new FutureRef<R | undefined>(this.handle, (v) => {\n const vv = this.postProcess(v);\n return vv ? mapping(vv) : undefined;\n });\n }\n\n toJSON() {\n return this.isResolved\n ? this.resolvedValue\n : ({ __awaited_futures__: [this.handle] } as FutureAwait);\n }\n}\n\nexport type ExtractFutureRefType<Ref extends FutureRef> =\n Ref extends FutureRef<infer T> ? T : never;\n"],"names":[],"mappings":";;MAGa,SAAS,CAAA;AAKD,IAAA,MAAA;AACA,IAAA,WAAA;IALX,UAAU,GAAG,KAAK;AAClB,IAAA,aAAa;IAErB,WAAA,CACmB,MAAoB,EACpB,WAAA,GAAqC,CAAC,CAAC,KAAK,CAAM,EAAA;QADlD,IAAA,CAAA,MAAM,GAAN,MAAM;QACN,IAAA,CAAA,WAAW,GAAX,WAAW;AAE5B,QAAA,mBAAmB,CAAC,MAAM,EAAE,CAAC,KAAK,KAAI;AACpC,YAAA,IAAI,CAAC,aAAa,GAAG,WAAW,CAAC,KAAK,CAAC;AACvC,YAAA,IAAI,CAAC,UAAU,GAAG,IAAI;AACxB,QAAA,CAAC,CAAC;IACJ;AAEO,IAAA,GAAG,CAAI,OAAoB,EAAA;QAChC,OAAO,IAAI,SAAS,CAAI,IAAI,CAAC,MAAM,EAAE,CAAC,CAAC,KAAK,OAAO,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC;IAC3E;AAEO,IAAA,UAAU,CAAI,OAAiC,EAAA;QACpD,OAAO,IAAI,SAAS,CAAgB,IAAI,CAAC,MAAM,EAAE,CAAC,CAAC,KAAI;YACrD,MAAM,EAAE,GAAG,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC;AAC9B,YAAA,OAAO,EAAE,GAAG,OAAO,CAAC,EAAE,CAAC,GAAG,SAAS;AACrC,QAAA,CAAC,CAAC;IACJ;IAEA,MAAM,GAAA;QACJ,OAAO,IAAI,CAAC;cACR,IAAI,CAAC;cACJ,EAAE,mBAAmB,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,EAAkB;IAC7D;AACD;;;;"}
|
package/dist/render/index.d.ts
CHANGED
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
const StagingAccessorName = 'staging';
|
|
4
|
+
const MainAccessorName = 'main';
|
|
5
|
+
const GlobalCfgRenderCtxFeatureFlags = {
|
|
6
|
+
explicitColumnsSupport: true,
|
|
7
|
+
inlineColumnsSupport: true,
|
|
8
|
+
activeArgs: true,
|
|
9
|
+
pTablePartitionFiltersSupport: true,
|
|
10
|
+
pFrameInSetFilterSupport: true,
|
|
11
|
+
};
|
|
12
|
+
function isFutureAwait(obj) {
|
|
13
|
+
return typeof obj === 'object' && obj !== null && '__awaited_futures__' in obj;
|
|
14
|
+
}
|
|
15
|
+
function addAllFutureAwaits(set, visited, node) {
|
|
16
|
+
if (visited.has(node))
|
|
17
|
+
return;
|
|
18
|
+
visited.add(node);
|
|
19
|
+
const type = typeof node;
|
|
20
|
+
if (type === 'object') {
|
|
21
|
+
if (isFutureAwait(node))
|
|
22
|
+
node.__awaited_futures__.forEach((a) => set.add(a));
|
|
23
|
+
else if (Array.isArray(node))
|
|
24
|
+
for (const nested of node)
|
|
25
|
+
addAllFutureAwaits(set, visited, nested);
|
|
26
|
+
else
|
|
27
|
+
for (const [, nested] of Object.entries(node))
|
|
28
|
+
if (nested !== node)
|
|
29
|
+
addAllFutureAwaits(set, visited, nested);
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
function getAllFutureAwaits(obj) {
|
|
33
|
+
const set = new Set();
|
|
34
|
+
addAllFutureAwaits(set, new Set(), obj);
|
|
35
|
+
return set;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
exports.GlobalCfgRenderCtxFeatureFlags = GlobalCfgRenderCtxFeatureFlags;
|
|
39
|
+
exports.MainAccessorName = MainAccessorName;
|
|
40
|
+
exports.StagingAccessorName = StagingAccessorName;
|
|
41
|
+
exports.getAllFutureAwaits = getAllFutureAwaits;
|
|
42
|
+
exports.isFutureAwait = isFutureAwait;
|
|
43
|
+
//# sourceMappingURL=internal.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"internal.cjs","sources":["../../src/render/internal.ts"],"sourcesContent":["import type { Optional } from 'utility-types';\nimport type { Branded } from '../branding';\nimport type { CommonFieldTraverseOps, FieldTraversalStep, ResourceType } from './traversal_ops';\nimport type {\n ArchiveFormat,\n AnyFunction,\n Option,\n PColumn,\n PColumnValues,\n PFrameDef,\n PFrameHandle,\n PObject,\n PObjectSpec,\n PSpecPredicate,\n PTableDef,\n PTableHandle,\n ResultCollection,\n ValueOrError,\n DataInfo,\n RangeBytes,\n} from '@milaboratories/pl-model-common';\n\nexport const StagingAccessorName = 'staging';\nexport const MainAccessorName = 'main';\n\nexport type AccessorHandle = Branded<string, 'AccessorHandle'>;\nexport type FutureHandle = Branded<string, 'FutureHandle'>;\n\nexport interface GlobalCfgRenderCtxMethods<AHandle = AccessorHandle, FHandle = FutureHandle> {\n\n //\n // Root accessor creation\n //\n\n getAccessorHandleByName(name: string): AHandle | undefined;\n\n //\n // Basic resource accessor actions\n //\n\n resolveWithCommon(\n handle: AHandle,\n commonOptions: CommonFieldTraverseOps,\n ...steps: (FieldTraversalStep | string)[]\n ): AHandle | undefined;\n\n getResourceType(handle: AHandle): ResourceType;\n\n getInputsLocked(handle: AHandle): boolean;\n\n getOutputsLocked(handle: AHandle): boolean;\n\n getIsReadyOrError(handle: AHandle): boolean;\n\n getIsFinal(handle: AHandle): boolean;\n\n getError(handle: AHandle): AHandle | undefined;\n\n listInputFields(handle: AHandle): string[];\n\n listOutputFields(handle: AHandle): string[];\n\n listDynamicFields(handle: AHandle): string[];\n\n getKeyValueBase64(handle: AHandle, key: string): string | undefined;\n\n getKeyValueAsString(handle: AHandle, key: string): string | undefined;\n\n getDataBase64(handle: AHandle): string | undefined;\n\n getDataAsString(handle: AHandle): string | undefined;\n\n /** If not final returns undefined */\n parsePObjectCollection(\n handle: AHandle,\n errorOnUnknownField: boolean,\n prefix: string,\n ...resolvePath: string[]\n ): Record<string, PObject<AHandle>> | undefined;\n\n //\n // Blob\n //\n\n getBlobContentAsBase64(handle: AHandle, range?: RangeBytes): FHandle; // string | undefined\n\n getBlobContentAsString(handle: AHandle, range?: RangeBytes): FHandle; // string | undefined\n\n getDownloadedBlobContentHandle(handle: AHandle): FHandle; // LocalBlobHandleAndSize | undefined;\n\n getOnDemandBlobContentHandle(handle: AHandle): FHandle; // RemoteBlobHandleAndSize | undefined;\n\n //\n // Blobs to URLs\n //\n\n extractArchiveAndGetURL(handle: AHandle, format: ArchiveFormat): FHandle;\n\n //\n // Import progress\n //\n\n getImportProgress(handle: AHandle): FHandle; // ImportProgress;\n\n //\n // Logs\n //\n\n getLastLogs(handle: AHandle, nLines: number): FHandle; // string | undefined;\n\n getProgressLog(handle: AHandle, patternToSearch: string): FHandle; // string | undefined;\n\n getProgressLogWithInfo(handle: AHandle, patternToSearch: string): FHandle; // ProgressLogWithInfo | undefined;\n\n getLogHandle(handle: AHandle): FHandle; // AnyLogHandle | undefined;\n\n //\n // Blocks\n //\n\n /** @deprecated at some point will stop working and will return dummy values */\n getBlockLabel(blockId: string): string;\n\n //\n // Result Pool\n //\n\n getDataFromResultPool(): ResultCollection<PObject<AHandle>>;\n\n getDataWithErrorsFromResultPool(): ResultCollection<\n Optional<PObject<ValueOrError<AHandle, Error>>, 'id'>\n >;\n\n getSpecsFromResultPool(): ResultCollection<PObjectSpec>;\n\n getSpecFromResultPoolByRef(blockId: string, exportName: string): PObjectSpec | undefined;\n\n getDataFromResultPoolByRef(blockId: string, exportName: string): PObject<AHandle> | undefined;\n\n calculateOptions(predicate: PSpecPredicate): Option[];\n\n //\n // PFrame / PTable\n //\n\n createPFrame(def: PFrameDef<AHandle | PColumnValues | DataInfo<AHandle>>): PFrameHandle;\n\n createPTable(def: PTableDef<PColumn<AHandle | PColumnValues | DataInfo<AHandle>>>): PTableHandle;\n\n //\n // Computable\n //\n\n getCurrentUnstableMarker(): string | undefined;\n\n //\n // Logging\n //\n\n logInfo(message: string): void;\n\n logWarn(message: string): void;\n\n logError(message: string): void;\n}\n\nexport const GlobalCfgRenderCtxFeatureFlags = {\n explicitColumnsSupport: true as const,\n inlineColumnsSupport: true as const,\n activeArgs: true as const,\n pTablePartitionFiltersSupport: true as const,\n pFrameInSetFilterSupport: true as const,\n};\n\nexport interface GlobalCfgRenderCtx extends GlobalCfgRenderCtxMethods {\n //\n // State: Args, UI State, Active Args\n //\n // Old runtime injects these values as strings, new runtime injects them as functions\n // that return strings, if block declares supportsLazyState flag.\n // If function not called in lazy state API, then resulting output will not depend on these values,\n // and thus will not be recalculated on corresponding state change.\n //\n\n readonly args: string | (() => string);\n readonly uiState: string | (() => string);\n readonly activeArgs: undefined | string | (() => string | undefined);\n\n // Note: strings below are used because, anyway, using strings is the only way\n // to get data inside the QuickJS context, as it is implemented now. With this\n // approach deserialization can be lazily postponed until it is actually needed.\n readonly callbackRegistry: Record<string, AnyFunction>;\n readonly featureFlags?: typeof GlobalCfgRenderCtxFeatureFlags;\n}\n\nexport type FutureAwait = {\n __awaited_futures__: FutureHandle[];\n};\n\nexport function isFutureAwait(obj: unknown): obj is FutureAwait {\n return typeof obj === 'object' && obj !== null && '__awaited_futures__' in obj;\n}\n\nfunction addAllFutureAwaits(set: Set<string>, visited: Set<unknown>, node: unknown) {\n if (visited.has(node)) return;\n visited.add(node);\n\n const type = typeof node;\n if (type === 'object') {\n if (isFutureAwait(node)) node.__awaited_futures__.forEach((a) => set.add(a));\n else if (Array.isArray(node))\n for (const nested of node) addAllFutureAwaits(set, visited, nested);\n else\n for (const [, nested] of Object.entries(node as object))\n if (nested !== node) addAllFutureAwaits(set, visited, nested);\n }\n}\n\nexport function getAllFutureAwaits(obj: unknown): Set<string> {\n const set = new Set<string>();\n addAllFutureAwaits(set, new Set(), obj);\n return set;\n}\n"],"names":[],"mappings":";;AAsBO,MAAM,mBAAmB,GAAG;AAC5B,MAAM,gBAAgB,GAAG;AA+IzB,MAAM,8BAA8B,GAAG;AAC5C,IAAA,sBAAsB,EAAE,IAAa;AACrC,IAAA,oBAAoB,EAAE,IAAa;AACnC,IAAA,UAAU,EAAE,IAAa;AACzB,IAAA,6BAA6B,EAAE,IAAa;AAC5C,IAAA,wBAAwB,EAAE,IAAa;;AA4BnC,SAAU,aAAa,CAAC,GAAY,EAAA;AACxC,IAAA,OAAO,OAAO,GAAG,KAAK,QAAQ,IAAI,GAAG,KAAK,IAAI,IAAI,qBAAqB,IAAI,GAAG;AAChF;AAEA,SAAS,kBAAkB,CAAC,GAAgB,EAAE,OAAqB,EAAE,IAAa,EAAA;AAChF,IAAA,IAAI,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC;QAAE;AACvB,IAAA,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC;AAEjB,IAAA,MAAM,IAAI,GAAG,OAAO,IAAI;AACxB,IAAA,IAAI,IAAI,KAAK,QAAQ,EAAE;QACrB,IAAI,aAAa,CAAC,IAAI,CAAC;AAAE,YAAA,IAAI,CAAC,mBAAmB,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,GAAG,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;AACvE,aAAA,IAAI,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC;YAC1B,KAAK,MAAM,MAAM,IAAI,IAAI;AAAE,gBAAA,kBAAkB,CAAC,GAAG,EAAE,OAAO,EAAE,MAAM,CAAC;;YAEnE,KAAK,MAAM,GAAG,MAAM,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,IAAc,CAAC;gBACrD,IAAI,MAAM,KAAK,IAAI;AAAE,oBAAA,kBAAkB,CAAC,GAAG,EAAE,OAAO,EAAE,MAAM,CAAC;IACnE;AACF;AAEM,SAAU,kBAAkB,CAAC,GAAY,EAAA;AAC7C,IAAA,MAAM,GAAG,GAAG,IAAI,GAAG,EAAU;IAC7B,kBAAkB,CAAC,GAAG,EAAE,IAAI,GAAG,EAAE,EAAE,GAAG,CAAC;AACvC,IAAA,OAAO,GAAG;AACZ;;;;;;;;"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
const StagingAccessorName = 'staging';
|
|
2
|
+
const MainAccessorName = 'main';
|
|
3
|
+
const GlobalCfgRenderCtxFeatureFlags = {
|
|
4
|
+
explicitColumnsSupport: true,
|
|
5
|
+
inlineColumnsSupport: true,
|
|
6
|
+
activeArgs: true,
|
|
7
|
+
pTablePartitionFiltersSupport: true,
|
|
8
|
+
pFrameInSetFilterSupport: true,
|
|
9
|
+
};
|
|
10
|
+
function isFutureAwait(obj) {
|
|
11
|
+
return typeof obj === 'object' && obj !== null && '__awaited_futures__' in obj;
|
|
12
|
+
}
|
|
13
|
+
function addAllFutureAwaits(set, visited, node) {
|
|
14
|
+
if (visited.has(node))
|
|
15
|
+
return;
|
|
16
|
+
visited.add(node);
|
|
17
|
+
const type = typeof node;
|
|
18
|
+
if (type === 'object') {
|
|
19
|
+
if (isFutureAwait(node))
|
|
20
|
+
node.__awaited_futures__.forEach((a) => set.add(a));
|
|
21
|
+
else if (Array.isArray(node))
|
|
22
|
+
for (const nested of node)
|
|
23
|
+
addAllFutureAwaits(set, visited, nested);
|
|
24
|
+
else
|
|
25
|
+
for (const [, nested] of Object.entries(node))
|
|
26
|
+
if (nested !== node)
|
|
27
|
+
addAllFutureAwaits(set, visited, nested);
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
function getAllFutureAwaits(obj) {
|
|
31
|
+
const set = new Set();
|
|
32
|
+
addAllFutureAwaits(set, new Set(), obj);
|
|
33
|
+
return set;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export { GlobalCfgRenderCtxFeatureFlags, MainAccessorName, StagingAccessorName, getAllFutureAwaits, isFutureAwait };
|
|
37
|
+
//# sourceMappingURL=internal.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"internal.js","sources":["../../src/render/internal.ts"],"sourcesContent":["import type { Optional } from 'utility-types';\nimport type { Branded } from '../branding';\nimport type { CommonFieldTraverseOps, FieldTraversalStep, ResourceType } from './traversal_ops';\nimport type {\n ArchiveFormat,\n AnyFunction,\n Option,\n PColumn,\n PColumnValues,\n PFrameDef,\n PFrameHandle,\n PObject,\n PObjectSpec,\n PSpecPredicate,\n PTableDef,\n PTableHandle,\n ResultCollection,\n ValueOrError,\n DataInfo,\n RangeBytes,\n} from '@milaboratories/pl-model-common';\n\nexport const StagingAccessorName = 'staging';\nexport const MainAccessorName = 'main';\n\nexport type AccessorHandle = Branded<string, 'AccessorHandle'>;\nexport type FutureHandle = Branded<string, 'FutureHandle'>;\n\nexport interface GlobalCfgRenderCtxMethods<AHandle = AccessorHandle, FHandle = FutureHandle> {\n\n //\n // Root accessor creation\n //\n\n getAccessorHandleByName(name: string): AHandle | undefined;\n\n //\n // Basic resource accessor actions\n //\n\n resolveWithCommon(\n handle: AHandle,\n commonOptions: CommonFieldTraverseOps,\n ...steps: (FieldTraversalStep | string)[]\n ): AHandle | undefined;\n\n getResourceType(handle: AHandle): ResourceType;\n\n getInputsLocked(handle: AHandle): boolean;\n\n getOutputsLocked(handle: AHandle): boolean;\n\n getIsReadyOrError(handle: AHandle): boolean;\n\n getIsFinal(handle: AHandle): boolean;\n\n getError(handle: AHandle): AHandle | undefined;\n\n listInputFields(handle: AHandle): string[];\n\n listOutputFields(handle: AHandle): string[];\n\n listDynamicFields(handle: AHandle): string[];\n\n getKeyValueBase64(handle: AHandle, key: string): string | undefined;\n\n getKeyValueAsString(handle: AHandle, key: string): string | undefined;\n\n getDataBase64(handle: AHandle): string | undefined;\n\n getDataAsString(handle: AHandle): string | undefined;\n\n /** If not final returns undefined */\n parsePObjectCollection(\n handle: AHandle,\n errorOnUnknownField: boolean,\n prefix: string,\n ...resolvePath: string[]\n ): Record<string, PObject<AHandle>> | undefined;\n\n //\n // Blob\n //\n\n getBlobContentAsBase64(handle: AHandle, range?: RangeBytes): FHandle; // string | undefined\n\n getBlobContentAsString(handle: AHandle, range?: RangeBytes): FHandle; // string | undefined\n\n getDownloadedBlobContentHandle(handle: AHandle): FHandle; // LocalBlobHandleAndSize | undefined;\n\n getOnDemandBlobContentHandle(handle: AHandle): FHandle; // RemoteBlobHandleAndSize | undefined;\n\n //\n // Blobs to URLs\n //\n\n extractArchiveAndGetURL(handle: AHandle, format: ArchiveFormat): FHandle;\n\n //\n // Import progress\n //\n\n getImportProgress(handle: AHandle): FHandle; // ImportProgress;\n\n //\n // Logs\n //\n\n getLastLogs(handle: AHandle, nLines: number): FHandle; // string | undefined;\n\n getProgressLog(handle: AHandle, patternToSearch: string): FHandle; // string | undefined;\n\n getProgressLogWithInfo(handle: AHandle, patternToSearch: string): FHandle; // ProgressLogWithInfo | undefined;\n\n getLogHandle(handle: AHandle): FHandle; // AnyLogHandle | undefined;\n\n //\n // Blocks\n //\n\n /** @deprecated at some point will stop working and will return dummy values */\n getBlockLabel(blockId: string): string;\n\n //\n // Result Pool\n //\n\n getDataFromResultPool(): ResultCollection<PObject<AHandle>>;\n\n getDataWithErrorsFromResultPool(): ResultCollection<\n Optional<PObject<ValueOrError<AHandle, Error>>, 'id'>\n >;\n\n getSpecsFromResultPool(): ResultCollection<PObjectSpec>;\n\n getSpecFromResultPoolByRef(blockId: string, exportName: string): PObjectSpec | undefined;\n\n getDataFromResultPoolByRef(blockId: string, exportName: string): PObject<AHandle> | undefined;\n\n calculateOptions(predicate: PSpecPredicate): Option[];\n\n //\n // PFrame / PTable\n //\n\n createPFrame(def: PFrameDef<AHandle | PColumnValues | DataInfo<AHandle>>): PFrameHandle;\n\n createPTable(def: PTableDef<PColumn<AHandle | PColumnValues | DataInfo<AHandle>>>): PTableHandle;\n\n //\n // Computable\n //\n\n getCurrentUnstableMarker(): string | undefined;\n\n //\n // Logging\n //\n\n logInfo(message: string): void;\n\n logWarn(message: string): void;\n\n logError(message: string): void;\n}\n\nexport const GlobalCfgRenderCtxFeatureFlags = {\n explicitColumnsSupport: true as const,\n inlineColumnsSupport: true as const,\n activeArgs: true as const,\n pTablePartitionFiltersSupport: true as const,\n pFrameInSetFilterSupport: true as const,\n};\n\nexport interface GlobalCfgRenderCtx extends GlobalCfgRenderCtxMethods {\n //\n // State: Args, UI State, Active Args\n //\n // Old runtime injects these values as strings, new runtime injects them as functions\n // that return strings, if block declares supportsLazyState flag.\n // If function not called in lazy state API, then resulting output will not depend on these values,\n // and thus will not be recalculated on corresponding state change.\n //\n\n readonly args: string | (() => string);\n readonly uiState: string | (() => string);\n readonly activeArgs: undefined | string | (() => string | undefined);\n\n // Note: strings below are used because, anyway, using strings is the only way\n // to get data inside the QuickJS context, as it is implemented now. With this\n // approach deserialization can be lazily postponed until it is actually needed.\n readonly callbackRegistry: Record<string, AnyFunction>;\n readonly featureFlags?: typeof GlobalCfgRenderCtxFeatureFlags;\n}\n\nexport type FutureAwait = {\n __awaited_futures__: FutureHandle[];\n};\n\nexport function isFutureAwait(obj: unknown): obj is FutureAwait {\n return typeof obj === 'object' && obj !== null && '__awaited_futures__' in obj;\n}\n\nfunction addAllFutureAwaits(set: Set<string>, visited: Set<unknown>, node: unknown) {\n if (visited.has(node)) return;\n visited.add(node);\n\n const type = typeof node;\n if (type === 'object') {\n if (isFutureAwait(node)) node.__awaited_futures__.forEach((a) => set.add(a));\n else if (Array.isArray(node))\n for (const nested of node) addAllFutureAwaits(set, visited, nested);\n else\n for (const [, nested] of Object.entries(node as object))\n if (nested !== node) addAllFutureAwaits(set, visited, nested);\n }\n}\n\nexport function getAllFutureAwaits(obj: unknown): Set<string> {\n const set = new Set<string>();\n addAllFutureAwaits(set, new Set(), obj);\n return set;\n}\n"],"names":[],"mappings":"AAsBO,MAAM,mBAAmB,GAAG;AAC5B,MAAM,gBAAgB,GAAG;AA+IzB,M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,IAAA,OAAO,GAAG;AACZ;;;;"}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
function filterDataInfoEntries(dataInfoEntries, axisFilters) {
|
|
4
|
+
// Sort filters by axis index in descending order to safely remove elements from arrays
|
|
5
|
+
const sortedFilters = [...axisFilters].sort((a, b) => b[0] - a[0]);
|
|
6
|
+
// Check for invalid filter axes
|
|
7
|
+
const { type } = dataInfoEntries;
|
|
8
|
+
switch (type) {
|
|
9
|
+
case 'Json': {
|
|
10
|
+
const { keyLength } = dataInfoEntries;
|
|
11
|
+
for (const [axisIdx] of axisFilters)
|
|
12
|
+
if (axisIdx >= keyLength)
|
|
13
|
+
throw new Error(`Can't filter on non-data axis ${axisIdx}. Must be >= ${keyLength}`);
|
|
14
|
+
break;
|
|
15
|
+
}
|
|
16
|
+
case 'JsonPartitioned':
|
|
17
|
+
case 'BinaryPartitioned':
|
|
18
|
+
case 'ParquetPartitioned': {
|
|
19
|
+
const { partitionKeyLength } = dataInfoEntries;
|
|
20
|
+
for (const [axisIdx] of axisFilters)
|
|
21
|
+
if (axisIdx >= partitionKeyLength)
|
|
22
|
+
throw new Error(`Can't filter on non-partitioned axis ${axisIdx}. Must be >= ${partitionKeyLength}`);
|
|
23
|
+
break;
|
|
24
|
+
}
|
|
25
|
+
default:
|
|
26
|
+
// eslint-disable-next-line @typescript-eslint/restrict-template-expressions
|
|
27
|
+
throw new Error(`Unsupported data info type: ${type}`);
|
|
28
|
+
}
|
|
29
|
+
const keyMatchesFilters = (key) => {
|
|
30
|
+
for (const [axisIdx, axisValue] of sortedFilters)
|
|
31
|
+
if (key[axisIdx] !== axisValue)
|
|
32
|
+
return false;
|
|
33
|
+
return true;
|
|
34
|
+
};
|
|
35
|
+
const removeFilteredAxes = (key) => {
|
|
36
|
+
const newKey = [...key];
|
|
37
|
+
// Remove axes in descending order to maintain correct indices
|
|
38
|
+
for (const [axisIdx] of sortedFilters)
|
|
39
|
+
newKey.splice(axisIdx, 1);
|
|
40
|
+
return newKey;
|
|
41
|
+
};
|
|
42
|
+
switch (dataInfoEntries.type) {
|
|
43
|
+
case 'Json': return {
|
|
44
|
+
type: 'Json',
|
|
45
|
+
keyLength: dataInfoEntries.keyLength - axisFilters.length,
|
|
46
|
+
data: dataInfoEntries.data
|
|
47
|
+
.filter((entry) => keyMatchesFilters(entry.key))
|
|
48
|
+
.map((entry) => ({
|
|
49
|
+
key: removeFilteredAxes(entry.key),
|
|
50
|
+
value: entry.value,
|
|
51
|
+
})),
|
|
52
|
+
};
|
|
53
|
+
case 'JsonPartitioned': return {
|
|
54
|
+
type: 'JsonPartitioned',
|
|
55
|
+
partitionKeyLength: dataInfoEntries.partitionKeyLength - axisFilters.length,
|
|
56
|
+
parts: dataInfoEntries.parts
|
|
57
|
+
.filter((entry) => keyMatchesFilters(entry.key))
|
|
58
|
+
.map((entry) => ({
|
|
59
|
+
key: removeFilteredAxes(entry.key),
|
|
60
|
+
value: entry.value,
|
|
61
|
+
})),
|
|
62
|
+
};
|
|
63
|
+
case 'BinaryPartitioned': return {
|
|
64
|
+
type: 'BinaryPartitioned',
|
|
65
|
+
partitionKeyLength: dataInfoEntries.partitionKeyLength - axisFilters.length,
|
|
66
|
+
parts: dataInfoEntries.parts
|
|
67
|
+
.filter((entry) => keyMatchesFilters(entry.key))
|
|
68
|
+
.map((entry) => ({
|
|
69
|
+
key: removeFilteredAxes(entry.key),
|
|
70
|
+
value: entry.value,
|
|
71
|
+
})),
|
|
72
|
+
};
|
|
73
|
+
case 'ParquetPartitioned': return {
|
|
74
|
+
type: 'ParquetPartitioned',
|
|
75
|
+
partitionKeyLength: dataInfoEntries.partitionKeyLength - axisFilters.length,
|
|
76
|
+
parts: dataInfoEntries.parts
|
|
77
|
+
.filter((entry) => keyMatchesFilters(entry.key))
|
|
78
|
+
.map((entry) => ({
|
|
79
|
+
key: removeFilteredAxes(entry.key),
|
|
80
|
+
value: entry.value,
|
|
81
|
+
})),
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
exports.filterDataInfoEntries = filterDataInfoEntries;
|
|
87
|
+
//# sourceMappingURL=axis_filtering.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"axis_filtering.cjs","sources":["../../../src/render/util/axis_filtering.ts"],"sourcesContent":["import type {\n BinaryChunk,\n DataInfoEntries,\n PColumnDataEntry,\n PColumnKey,\n PColumnValue,\n JsonDataInfoEntries,\n JsonPartitionedDataInfoEntries,\n BinaryPartitionedDataInfoEntries,\n ParquetPartitionedDataInfoEntries,\n PartitionedDataInfoEntries,\n} from '@milaboratories/pl-model-common';\nimport type { AxisFilterByIdx } from '@milaboratories/pl-model-common';\n\n/**\n * Filters DataInfoEntries using axis filters, removing specified axes from keys and\n * only keeping entries that match the filter values.\n *\n * @param dataInfoEntries - The data info object to filter\n * @param axisFilters - Array of axis filters (index, value pairs)\n * @throws Error if any filter axis is outside the partitioning axes or data axes for Json data\n */\nexport function filterDataInfoEntries<Blob>(\n dataInfoEntries: ParquetPartitionedDataInfoEntries<Blob>,\n axisFilters: AxisFilterByIdx[],\n): ParquetPartitionedDataInfoEntries<Blob>;\nexport function filterDataInfoEntries<Blob>(\n dataInfoEntries: BinaryPartitionedDataInfoEntries<Blob>,\n axisFilters: AxisFilterByIdx[],\n): BinaryPartitionedDataInfoEntries<Blob>;\nexport function filterDataInfoEntries<Blob>(\n dataInfoEntries: JsonPartitionedDataInfoEntries<Blob>,\n axisFilters: AxisFilterByIdx[],\n): JsonPartitionedDataInfoEntries<Blob>;\nexport function filterDataInfoEntries<Blob>(\n dataInfoEntries: PartitionedDataInfoEntries<Blob>,\n axisFilters: AxisFilterByIdx[],\n): PartitionedDataInfoEntries<Blob>;\nexport function filterDataInfoEntries(\n dataInfoEntries: JsonDataInfoEntries,\n axisFilters: AxisFilterByIdx[],\n): JsonDataInfoEntries;\nexport function filterDataInfoEntries<Blob>(\n dataInfoEntries: DataInfoEntries<Blob>,\n axisFilters: AxisFilterByIdx[],\n): DataInfoEntries<Blob> {\n // Sort filters by axis index in descending order to safely remove elements from arrays\n const sortedFilters = [...axisFilters].sort((a, b) => b[0] - a[0]);\n\n // Check for invalid filter axes\n const { type } = dataInfoEntries;\n switch (type) {\n case 'Json': {\n const { keyLength } = dataInfoEntries;\n for (const [axisIdx] of axisFilters)\n if (axisIdx >= keyLength)\n throw new Error(`Can't filter on non-data axis ${axisIdx}. Must be >= ${keyLength}`);\n break;\n }\n case 'JsonPartitioned':\n case 'BinaryPartitioned':\n case 'ParquetPartitioned': {\n const { partitionKeyLength } = dataInfoEntries;\n for (const [axisIdx] of axisFilters)\n if (axisIdx >= partitionKeyLength)\n throw new Error(`Can't filter on non-partitioned axis ${axisIdx}. Must be >= ${partitionKeyLength}`);\n break;\n }\n default:\n // eslint-disable-next-line @typescript-eslint/restrict-template-expressions\n throw new Error(`Unsupported data info type: ${type satisfies never}`);\n }\n\n const keyMatchesFilters = (key: PColumnKey): boolean => {\n for (const [axisIdx, axisValue] of sortedFilters)\n if (key[axisIdx] !== axisValue)\n return false;\n return true;\n };\n\n const removeFilteredAxes = (key: PColumnKey): PColumnKey => {\n const newKey = [...key];\n\n // Remove axes in descending order to maintain correct indices\n for (const [axisIdx] of sortedFilters)\n newKey.splice(axisIdx, 1);\n\n return newKey;\n };\n\n switch (dataInfoEntries.type) {\n case 'Json': return {\n type: 'Json',\n keyLength: dataInfoEntries.keyLength - axisFilters.length,\n data: dataInfoEntries.data\n .filter((entry) => keyMatchesFilters(entry.key))\n .map((entry) => ({\n key: removeFilteredAxes(entry.key),\n value: entry.value,\n } satisfies PColumnDataEntry<PColumnValue>)),\n };\n case 'JsonPartitioned': return {\n type: 'JsonPartitioned',\n partitionKeyLength: dataInfoEntries.partitionKeyLength - axisFilters.length,\n parts: dataInfoEntries.parts\n .filter((entry) => keyMatchesFilters(entry.key))\n .map((entry) => ({\n key: removeFilteredAxes(entry.key),\n value: entry.value,\n } satisfies PColumnDataEntry<Blob>)),\n };\n case 'BinaryPartitioned': return {\n type: 'BinaryPartitioned',\n partitionKeyLength: dataInfoEntries.partitionKeyLength - axisFilters.length,\n parts: dataInfoEntries.parts\n .filter((entry) => keyMatchesFilters(entry.key))\n .map((entry) => ({\n key: removeFilteredAxes(entry.key),\n value: entry.value,\n } satisfies PColumnDataEntry<BinaryChunk<Blob>>)),\n };\n case 'ParquetPartitioned': return {\n type: 'ParquetPartitioned',\n partitionKeyLength: dataInfoEntries.partitionKeyLength - axisFilters.length,\n parts: dataInfoEntries.parts\n .filter((entry) => keyMatchesFilters(entry.key))\n .map((entry) => ({\n key: removeFilteredAxes(entry.key),\n value: entry.value,\n } satisfies PColumnDataEntry<Blob>)),\n };\n }\n}\n"],"names":[],"mappings":";;AA0CM,SAAU,qBAAqB,CACnC,eAAsC,EACtC,WAA8B,EAAA;;IAG9B,MAAM,aAAa,GAAG,CAAC,GAAG,WAAW,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;;AAGlE,IAAA,MAAM,EAAE,IAAI,EAAE,GAAG,eAAe;IAChC,QAAQ,IAAI;QACV,KAAK,MAAM,EAAE;AACX,YAAA,MAAM,EAAE,SAAS,EAAE,GAAG,eAAe;AACrC,YAAA,KAAK,MAAM,CAAC,OAAO,CAAC,IAAI,WAAW;gBACjC,IAAI,OAAO,IAAI,SAAS;oBACtB,MAAM,IAAI,KAAK,CAAC,CAAA,8BAAA,EAAiC,OAAO,CAAA,aAAA,EAAgB,SAAS,CAAA,CAAE,CAAC;YACxF;QACF;AACA,QAAA,KAAK,iBAAiB;AACtB,QAAA,KAAK,mBAAmB;QACxB,KAAK,oBAAoB,EAAE;AACzB,YAAA,MAAM,EAAE,kBAAkB,EAAE,GAAG,eAAe;AAC9C,YAAA,KAAK,MAAM,CAAC,OAAO,CAAC,IAAI,WAAW;gBACj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}
|
|
@@ -12,4 +12,3 @@ export declare function filterDataInfoEntries<Blob>(dataInfoEntries: BinaryParti
|
|
|
12
12
|
export declare function filterDataInfoEntries<Blob>(dataInfoEntries: JsonPartitionedDataInfoEntries<Blob>, axisFilters: AxisFilterByIdx[]): JsonPartitionedDataInfoEntries<Blob>;
|
|
13
13
|
export declare function filterDataInfoEntries<Blob>(dataInfoEntries: PartitionedDataInfoEntries<Blob>, axisFilters: AxisFilterByIdx[]): PartitionedDataInfoEntries<Blob>;
|
|
14
14
|
export declare function filterDataInfoEntries(dataInfoEntries: JsonDataInfoEntries, axisFilters: AxisFilterByIdx[]): JsonDataInfoEntries;
|
|
15
|
-
//# sourceMappingURL=axis_filtering.d.ts.map
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
function filterDataInfoEntries(dataInfoEntries, axisFilters) {
|
|
2
|
+
// Sort filters by axis index in descending order to safely remove elements from arrays
|
|
3
|
+
const sortedFilters = [...axisFilters].sort((a, b) => b[0] - a[0]);
|
|
4
|
+
// Check for invalid filter axes
|
|
5
|
+
const { type } = dataInfoEntries;
|
|
6
|
+
switch (type) {
|
|
7
|
+
case 'Json': {
|
|
8
|
+
const { keyLength } = dataInfoEntries;
|
|
9
|
+
for (const [axisIdx] of axisFilters)
|
|
10
|
+
if (axisIdx >= keyLength)
|
|
11
|
+
throw new Error(`Can't filter on non-data axis ${axisIdx}. Must be >= ${keyLength}`);
|
|
12
|
+
break;
|
|
13
|
+
}
|
|
14
|
+
case 'JsonPartitioned':
|
|
15
|
+
case 'BinaryPartitioned':
|
|
16
|
+
case 'ParquetPartitioned': {
|
|
17
|
+
const { partitionKeyLength } = dataInfoEntries;
|
|
18
|
+
for (const [axisIdx] of axisFilters)
|
|
19
|
+
if (axisIdx >= partitionKeyLength)
|
|
20
|
+
throw new Error(`Can't filter on non-partitioned axis ${axisIdx}. Must be >= ${partitionKeyLength}`);
|
|
21
|
+
break;
|
|
22
|
+
}
|
|
23
|
+
default:
|
|
24
|
+
// eslint-disable-next-line @typescript-eslint/restrict-template-expressions
|
|
25
|
+
throw new Error(`Unsupported data info type: ${type}`);
|
|
26
|
+
}
|
|
27
|
+
const keyMatchesFilters = (key) => {
|
|
28
|
+
for (const [axisIdx, axisValue] of sortedFilters)
|
|
29
|
+
if (key[axisIdx] !== axisValue)
|
|
30
|
+
return false;
|
|
31
|
+
return true;
|
|
32
|
+
};
|
|
33
|
+
const removeFilteredAxes = (key) => {
|
|
34
|
+
const newKey = [...key];
|
|
35
|
+
// Remove axes in descending order to maintain correct indices
|
|
36
|
+
for (const [axisIdx] of sortedFilters)
|
|
37
|
+
newKey.splice(axisIdx, 1);
|
|
38
|
+
return newKey;
|
|
39
|
+
};
|
|
40
|
+
switch (dataInfoEntries.type) {
|
|
41
|
+
case 'Json': return {
|
|
42
|
+
type: 'Json',
|
|
43
|
+
keyLength: dataInfoEntries.keyLength - axisFilters.length,
|
|
44
|
+
data: dataInfoEntries.data
|
|
45
|
+
.filter((entry) => keyMatchesFilters(entry.key))
|
|
46
|
+
.map((entry) => ({
|
|
47
|
+
key: removeFilteredAxes(entry.key),
|
|
48
|
+
value: entry.value,
|
|
49
|
+
})),
|
|
50
|
+
};
|
|
51
|
+
case 'JsonPartitioned': return {
|
|
52
|
+
type: 'JsonPartitioned',
|
|
53
|
+
partitionKeyLength: dataInfoEntries.partitionKeyLength - axisFilters.length,
|
|
54
|
+
parts: dataInfoEntries.parts
|
|
55
|
+
.filter((entry) => keyMatchesFilters(entry.key))
|
|
56
|
+
.map((entry) => ({
|
|
57
|
+
key: removeFilteredAxes(entry.key),
|
|
58
|
+
value: entry.value,
|
|
59
|
+
})),
|
|
60
|
+
};
|
|
61
|
+
case 'BinaryPartitioned': return {
|
|
62
|
+
type: 'BinaryPartitioned',
|
|
63
|
+
partitionKeyLength: dataInfoEntries.partitionKeyLength - axisFilters.length,
|
|
64
|
+
parts: dataInfoEntries.parts
|
|
65
|
+
.filter((entry) => keyMatchesFilters(entry.key))
|
|
66
|
+
.map((entry) => ({
|
|
67
|
+
key: removeFilteredAxes(entry.key),
|
|
68
|
+
value: entry.value,
|
|
69
|
+
})),
|
|
70
|
+
};
|
|
71
|
+
case 'ParquetPartitioned': return {
|
|
72
|
+
type: 'ParquetPartitioned',
|
|
73
|
+
partitionKeyLength: dataInfoEntries.partitionKeyLength - axisFilters.length,
|
|
74
|
+
parts: dataInfoEntries.parts
|
|
75
|
+
.filter((entry) => keyMatchesFilters(entry.key))
|
|
76
|
+
.map((entry) => ({
|
|
77
|
+
key: removeFilteredAxes(entry.key),
|
|
78
|
+
value: entry.value,
|
|
79
|
+
})),
|
|
80
|
+
};
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export { filterDataInfoEntries };
|
|
85
|
+
//# sourceMappingURL=axis_filtering.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"axis_filtering.js","sources":["../../../src/render/util/axis_filtering.ts"],"sourcesContent":["import type {\n BinaryChunk,\n DataInfoEntries,\n PColumnDataEntry,\n PColumnKey,\n PColumnValue,\n JsonDataInfoEntries,\n JsonPartitionedDataInfoEntries,\n BinaryPartitionedDataInfoEntries,\n ParquetPartitionedDataInfoEntries,\n PartitionedDataInfoEntries,\n} from '@milaboratories/pl-model-common';\nimport type { AxisFilterByIdx } from '@milaboratories/pl-model-common';\n\n/**\n * Filters DataInfoEntries using axis filters, removing specified axes from keys and\n * only keeping entries that match the filter values.\n *\n * @param dataInfoEntries - The data info object to filter\n * @param axisFilters - Array of axis filters (index, value pairs)\n * @throws Error if any filter axis is outside the partitioning axes or data axes for Json data\n */\nexport function filterDataInfoEntries<Blob>(\n dataInfoEntries: ParquetPartitionedDataInfoEntries<Blob>,\n axisFilters: AxisFilterByIdx[],\n): ParquetPartitionedDataInfoEntries<Blob>;\nexport function filterDataInfoEntries<Blob>(\n dataInfoEntries: BinaryPartitionedDataInfoEntries<Blob>,\n axisFilters: AxisFilterByIdx[],\n): BinaryPartitionedDataInfoEntries<Blob>;\nexport function filterDataInfoEntries<Blob>(\n dataInfoEntries: JsonPartitionedDataInfoEntries<Blob>,\n axisFilters: AxisFilterByIdx[],\n): JsonPartitionedDataInfoEntries<Blob>;\nexport function filterDataInfoEntries<Blob>(\n dataInfoEntries: PartitionedDataInfoEntries<Blob>,\n axisFilters: AxisFilterByIdx[],\n): PartitionedDataInfoEntries<Blob>;\nexport function filterDataInfoEntries(\n dataInfoEntries: JsonDataInfoEntries,\n axisFilters: AxisFilterByIdx[],\n): JsonDataInfoEntries;\nexport function filterDataInfoEntries<Blob>(\n dataInfoEntries: DataInfoEntries<Blob>,\n axisFilters: AxisFilterByIdx[],\n): DataInfoEntries<Blob> {\n // Sort filters by axis index in descending order to safely remove elements from arrays\n const sortedFilters = [...axisFilters].sort((a, b) => b[0] - a[0]);\n\n // Check for invalid filter axes\n const { type } = dataInfoEntries;\n switch (type) {\n case 'Json': {\n const { keyLength } = dataInfoEntries;\n for (const [axisIdx] of axisFilters)\n if (axisIdx >= keyLength)\n throw new Error(`Can't filter on non-data axis ${axisIdx}. Must be >= ${keyLength}`);\n break;\n }\n case 'JsonPartitioned':\n case 'BinaryPartitioned':\n case 'ParquetPartitioned': {\n const { partitionKeyLength } = dataInfoEntries;\n for (const [axisIdx] of axisFilters)\n if (axisIdx >= partitionKeyLength)\n throw new Error(`Can't filter on non-partitioned axis ${axisIdx}. Must be >= ${partitionKeyLength}`);\n break;\n }\n default:\n // eslint-disable-next-line @typescript-eslint/restrict-template-expressions\n throw new Error(`Unsupported data info type: ${type satisfies never}`);\n }\n\n const keyMatchesFilters = (key: PColumnKey): boolean => {\n for (const [axisIdx, axisValue] of sortedFilters)\n if (key[axisIdx] !== axisValue)\n return false;\n return true;\n };\n\n const removeFilteredAxes = (key: PColumnKey): PColumnKey => {\n const newKey = [...key];\n\n // Remove axes in descending order to maintain correct indices\n for (const [axisIdx] of sortedFilters)\n newKey.splice(axisIdx, 1);\n\n return newKey;\n };\n\n switch (dataInfoEntries.type) {\n case 'Json': return {\n type: 'Json',\n keyLength: dataInfoEntries.keyLength - axisFilters.length,\n data: dataInfoEntries.data\n .filter((entry) => keyMatchesFilters(entry.key))\n .map((entry) => ({\n key: removeFilteredAxes(entry.key),\n value: entry.value,\n } satisfies PColumnDataEntry<PColumnValue>)),\n };\n case 'JsonPartitioned': return {\n type: 'JsonPartitioned',\n partitionKeyLength: dataInfoEntries.partitionKeyLength - axisFilters.length,\n parts: dataInfoEntries.parts\n .filter((entry) => keyMatchesFilters(entry.key))\n .map((entry) => ({\n key: removeFilteredAxes(entry.key),\n value: entry.value,\n } satisfies PColumnDataEntry<Blob>)),\n };\n case 'BinaryPartitioned': return {\n type: 'BinaryPartitioned',\n partitionKeyLength: dataInfoEntries.partitionKeyLength - axisFilters.length,\n parts: dataInfoEntries.parts\n .filter((entry) => keyMatchesFilters(entry.key))\n .map((entry) => ({\n key: removeFilteredAxes(entry.key),\n value: entry.value,\n } satisfies PColumnDataEntry<BinaryChunk<Blob>>)),\n };\n case 'ParquetPartitioned': return {\n type: 'ParquetPartitioned',\n partitionKeyLength: dataInfoEntries.partitionKeyLength - axisFilters.length,\n parts: dataInfoEntries.parts\n .filter((entry) => keyMatchesFilters(entry.key))\n .map((entry) => ({\n key: removeFilteredAxes(entry.key),\n value: entry.value,\n } satisfies PColumnDataEntry<Blob>)),\n };\n }\n}\n"],"names":[],"mappings":"AA0CM,SAAU,qBAAqB,CACnC,eAAsC,EACtC,WAA8B,EAAA;;IAG9B,MAAM,aAAa,GAAG,CAAC,GAAG,WAAW,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;;AAGlE,IAAA,MAAM,EAAE,IAAI,EAAE,GAAG,eAAe;IAChC,QAAQ,IAAI;QACV,KAAK,MAAM,EAAE;AACX,YAAA,MAAM,EAAE,SAAS,EAAE,GAAG,eAAe;AACrC,YAAA,KAAK,MAA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