@milaboratories/pl-model-common 1.25.1 → 1.25.3
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/_virtual/_rolldown/runtime.cjs +29 -0
- package/dist/author_marker.d.ts +9 -6
- package/dist/base32_encode.cjs +40 -46
- package/dist/base32_encode.cjs.map +1 -1
- package/dist/base32_encode.js +40 -45
- package/dist/base32_encode.js.map +1 -1
- package/dist/base64.cjs +5 -4
- package/dist/base64.cjs.map +1 -1
- package/dist/base64.d.ts +10 -6
- package/dist/base64.js +5 -3
- package/dist/base64.js.map +1 -1
- package/dist/block_state.d.ts +21 -23
- package/dist/bmodel/block_config.cjs +9 -10
- package/dist/bmodel/block_config.cjs.map +1 -1
- package/dist/bmodel/block_config.d.ts +53 -72
- package/dist/bmodel/block_config.js +9 -9
- package/dist/bmodel/block_config.js.map +1 -1
- package/dist/bmodel/code.cjs +7 -6
- package/dist/bmodel/code.cjs.map +1 -1
- package/dist/bmodel/code.d.ts +17 -13
- package/dist/bmodel/code.js +6 -4
- package/dist/bmodel/code.js.map +1 -1
- package/dist/bmodel/container.d.ts +46 -44
- package/dist/bmodel/index.cjs +3 -0
- package/dist/bmodel/index.d.ts +5 -6
- package/dist/bmodel/index.js +3 -0
- package/dist/bmodel/normalization.cjs +90 -106
- package/dist/bmodel/normalization.cjs.map +1 -1
- package/dist/bmodel/normalization.d.ts +7 -3
- package/dist/bmodel/normalization.js +90 -105
- package/dist/bmodel/normalization.js.map +1 -1
- package/dist/bmodel/types.d.ts +4 -1
- package/dist/branding.d.ts +5 -5
- package/dist/common_types.d.ts +19 -15
- package/dist/driver_kit.d.ts +25 -17
- package/dist/drivers/ChunkedStreamReader.cjs +168 -203
- package/dist/drivers/ChunkedStreamReader.cjs.map +1 -1
- package/dist/drivers/ChunkedStreamReader.d.ts +104 -100
- package/dist/drivers/ChunkedStreamReader.js +168 -202
- package/dist/drivers/ChunkedStreamReader.js.map +1 -1
- package/dist/drivers/blob.cjs +15 -17
- package/dist/drivers/blob.cjs.map +1 -1
- package/dist/drivers/blob.d.ts +35 -35
- package/dist/drivers/blob.js +14 -15
- package/dist/drivers/blob.js.map +1 -1
- package/dist/drivers/index.cjs +18 -0
- package/dist/drivers/index.d.ts +29 -9
- package/dist/drivers/index.js +18 -0
- package/dist/drivers/interfaces.d.ts +17 -14
- package/dist/drivers/log.cjs +4 -3
- package/dist/drivers/log.cjs.map +1 -1
- package/dist/drivers/log.d.ts +52 -49
- package/dist/drivers/log.js +4 -2
- package/dist/drivers/log.js.map +1 -1
- package/dist/drivers/ls.cjs +16 -19
- package/dist/drivers/ls.cjs.map +1 -1
- package/dist/drivers/ls.d.ts +73 -76
- package/dist/drivers/ls.js +16 -17
- package/dist/drivers/ls.js.map +1 -1
- package/dist/drivers/pframe/column_filter.d.ts +19 -15
- package/dist/drivers/pframe/data_info.cjs +201 -252
- package/dist/drivers/pframe/data_info.cjs.map +1 -1
- package/dist/drivers/pframe/data_info.d.ts +84 -109
- package/dist/drivers/pframe/data_info.js +201 -250
- package/dist/drivers/pframe/data_info.js.map +1 -1
- package/dist/drivers/pframe/data_types.cjs +38 -63
- package/dist/drivers/pframe/data_types.cjs.map +1 -1
- package/dist/drivers/pframe/data_types.d.ts +91 -93
- package/dist/drivers/pframe/data_types.js +38 -61
- package/dist/drivers/pframe/data_types.js.map +1 -1
- package/dist/drivers/pframe/driver.cjs +7 -0
- package/dist/drivers/pframe/driver.cjs.map +1 -0
- package/dist/drivers/pframe/driver.d.ts +50 -45
- package/dist/drivers/pframe/driver.js +6 -0
- package/dist/drivers/pframe/driver.js.map +1 -0
- package/dist/drivers/pframe/filter_spec.d.ts +127 -123
- package/dist/drivers/pframe/find_columns.d.ts +21 -17
- package/dist/drivers/pframe/index.cjs +15 -0
- package/dist/drivers/pframe/index.d.ts +23 -16
- package/dist/drivers/pframe/index.js +15 -0
- package/dist/drivers/pframe/linker_columns.cjs +184 -238
- package/dist/drivers/pframe/linker_columns.cjs.map +1 -1
- package/dist/drivers/pframe/linker_columns.d.ts +45 -38
- package/dist/drivers/pframe/linker_columns.js +184 -236
- package/dist/drivers/pframe/linker_columns.js.map +1 -1
- package/dist/drivers/pframe/pframe.d.ts +26 -21
- package/dist/drivers/pframe/query/index.cjs +1 -0
- package/dist/drivers/pframe/query/index.d.ts +3 -4
- package/dist/drivers/pframe/query/index.js +1 -0
- package/dist/drivers/pframe/query/query_common.d.ts +205 -247
- package/dist/drivers/pframe/query/query_data.d.ts +25 -23
- package/dist/drivers/pframe/query/query_spec.d.ts +30 -29
- package/dist/drivers/pframe/query/utils.cjs +164 -183
- package/dist/drivers/pframe/query/utils.cjs.map +1 -1
- package/dist/drivers/pframe/query/utils.d.ts +13 -12
- package/dist/drivers/pframe/query/utils.js +164 -181
- package/dist/drivers/pframe/query/utils.js.map +1 -1
- package/dist/drivers/pframe/spec/anchored.cjs +178 -216
- package/dist/drivers/pframe/spec/anchored.cjs.map +1 -1
- package/dist/drivers/pframe/spec/anchored.d.ts +53 -49
- package/dist/drivers/pframe/spec/anchored.js +176 -214
- package/dist/drivers/pframe/spec/anchored.js.map +1 -1
- package/dist/drivers/pframe/spec/filtered_column.cjs +8 -7
- package/dist/drivers/pframe/spec/filtered_column.cjs.map +1 -1
- package/dist/drivers/pframe/spec/filtered_column.d.ts +20 -17
- package/dist/drivers/pframe/spec/filtered_column.js +8 -6
- package/dist/drivers/pframe/spec/filtered_column.js.map +1 -1
- package/dist/drivers/pframe/spec/ids.cjs +16 -14
- package/dist/drivers/pframe/spec/ids.cjs.map +1 -1
- package/dist/drivers/pframe/spec/ids.d.ts +13 -8
- package/dist/drivers/pframe/spec/ids.js +14 -12
- package/dist/drivers/pframe/spec/ids.js.map +1 -1
- package/dist/drivers/pframe/spec/index.cjs +6 -0
- package/dist/drivers/pframe/spec/index.d.ts +6 -7
- package/dist/drivers/pframe/spec/index.js +6 -0
- package/dist/drivers/pframe/spec/native_id.cjs +16 -16
- package/dist/drivers/pframe/spec/native_id.cjs.map +1 -1
- package/dist/drivers/pframe/spec/native_id.d.ts +9 -4
- package/dist/drivers/pframe/spec/native_id.js +13 -13
- package/dist/drivers/pframe/spec/native_id.js.map +1 -1
- package/dist/drivers/pframe/spec/selectors.cjs +72 -112
- package/dist/drivers/pframe/spec/selectors.cjs.map +1 -1
- package/dist/drivers/pframe/spec/selectors.d.ts +99 -94
- package/dist/drivers/pframe/spec/selectors.js +72 -110
- package/dist/drivers/pframe/spec/selectors.js.map +1 -1
- package/dist/drivers/pframe/spec/spec.cjs +282 -324
- package/dist/drivers/pframe/spec/spec.cjs.map +1 -1
- package/dist/drivers/pframe/spec/spec.d.ts +263 -272
- package/dist/drivers/pframe/spec/spec.js +281 -322
- package/dist/drivers/pframe/spec/spec.js.map +1 -1
- package/dist/drivers/pframe/table.d.ts +28 -24
- package/dist/drivers/pframe/table_calculate.cjs +117 -147
- package/dist/drivers/pframe/table_calculate.cjs.map +1 -1
- package/dist/drivers/pframe/table_calculate.d.ts +219 -220
- package/dist/drivers/pframe/table_calculate.js +117 -145
- package/dist/drivers/pframe/table_calculate.js.map +1 -1
- package/dist/drivers/pframe/table_common.cjs +13 -14
- package/dist/drivers/pframe/table_common.cjs.map +1 -1
- package/dist/drivers/pframe/table_common.d.ts +24 -19
- package/dist/drivers/pframe/table_common.js +13 -13
- package/dist/drivers/pframe/table_common.js.map +1 -1
- package/dist/drivers/pframe/unique_values.d.ts +23 -18
- package/dist/drivers/upload.d.ts +21 -18
- package/dist/drivers/urls.cjs +5 -6
- package/dist/drivers/urls.cjs.map +1 -1
- package/dist/drivers/urls.d.ts +12 -9
- package/dist/drivers/urls.js +5 -5
- package/dist/drivers/urls.js.map +1 -1
- package/dist/errors.cjs +65 -86
- package/dist/errors.cjs.map +1 -1
- package/dist/errors.d.ts +36 -33
- package/dist/errors.js +65 -85
- package/dist/errors.js.map +1 -1
- package/dist/flags/block_flags.cjs +7 -6
- package/dist/flags/block_flags.cjs.map +1 -1
- package/dist/flags/block_flags.d.ts +12 -8
- package/dist/flags/block_flags.js +7 -5
- package/dist/flags/block_flags.js.map +1 -1
- package/dist/flags/flag_utils.cjs +69 -108
- package/dist/flags/flag_utils.cjs.map +1 -1
- package/dist/flags/flag_utils.d.ts +40 -42
- package/dist/flags/flag_utils.js +70 -107
- package/dist/flags/flag_utils.js.map +1 -1
- package/dist/flags/type_utils.d.ts +12 -11
- package/dist/httpAuth.cjs +16 -20
- package/dist/httpAuth.cjs.map +1 -1
- package/dist/httpAuth.d.ts +10 -7
- package/dist/httpAuth.js +16 -19
- package/dist/httpAuth.js.map +1 -1
- package/dist/index.cjs +176 -179
- package/dist/index.d.ts +58 -20
- package/dist/index.js +37 -34
- package/dist/json.cjs +10 -8
- package/dist/json.cjs.map +1 -1
- package/dist/json.d.ts +18 -18
- package/dist/json.js +8 -6
- package/dist/json.js.map +1 -1
- package/dist/navigation.cjs +3 -2
- package/dist/navigation.cjs.map +1 -1
- package/dist/navigation.d.ts +18 -21
- package/dist/navigation.js +3 -1
- package/dist/navigation.js.map +1 -1
- package/dist/plid.cjs +16 -20
- package/dist/plid.cjs.map +1 -1
- package/dist/plid.d.ts +11 -7
- package/dist/plid.js +15 -18
- package/dist/plid.js.map +1 -1
- package/dist/pool/entry.d.ts +11 -11
- package/dist/pool/index.d.ts +3 -4
- package/dist/pool/query.cjs +21 -43
- package/dist/pool/query.cjs.map +1 -1
- package/dist/pool/query.d.ts +25 -20
- package/dist/pool/query.js +20 -40
- package/dist/pool/query.js.map +1 -1
- package/dist/pool/spec.cjs +40 -47
- package/dist/pool/spec.cjs.map +1 -1
- package/dist/pool/spec.d.ts +33 -31
- package/dist/pool/spec.js +40 -45
- package/dist/pool/spec.js.map +1 -1
- package/dist/ref.cjs +51 -71
- package/dist/ref.cjs.map +1 -1
- package/dist/ref.d.ts +36 -33
- package/dist/ref.js +50 -69
- package/dist/ref.js.map +1 -1
- package/dist/utag.d.ts +18 -14
- package/dist/util.cjs +8 -7
- package/dist/util.cjs.map +1 -1
- package/dist/util.d.ts +5 -2
- package/dist/util.js +8 -6
- package/dist/util.js.map +1 -1
- package/dist/value_or_error.cjs +7 -3
- package/dist/value_or_error.cjs.map +1 -1
- package/dist/value_or_error.d.ts +9 -6
- package/dist/value_or_error.js +7 -2
- package/dist/value_or_error.js.map +1 -1
- package/package.json +6 -6
- package/src/flags/block_flags.ts +2 -1
- package/src/flags/flag_utils.ts +0 -22
- package/dist/author_marker.d.ts.map +0 -1
- package/dist/base32_encode.d.ts +0 -8
- package/dist/base32_encode.d.ts.map +0 -1
- package/dist/base64.d.ts.map +0 -1
- package/dist/block_state.d.ts.map +0 -1
- package/dist/bmodel/block_config.d.ts.map +0 -1
- package/dist/bmodel/code.d.ts.map +0 -1
- package/dist/bmodel/container.d.ts.map +0 -1
- package/dist/bmodel/index.d.ts.map +0 -1
- package/dist/bmodel/normalization.d.ts.map +0 -1
- package/dist/bmodel/types.d.ts.map +0 -1
- package/dist/branding.d.ts.map +0 -1
- package/dist/common_types.d.ts.map +0 -1
- package/dist/driver_kit.d.ts.map +0 -1
- package/dist/drivers/ChunkedStreamReader.d.ts.map +0 -1
- package/dist/drivers/blob.d.ts.map +0 -1
- package/dist/drivers/index.d.ts.map +0 -1
- package/dist/drivers/interfaces.d.ts.map +0 -1
- package/dist/drivers/log.d.ts.map +0 -1
- package/dist/drivers/ls.d.ts.map +0 -1
- package/dist/drivers/pframe/column_filter.d.ts.map +0 -1
- package/dist/drivers/pframe/data_info.d.ts.map +0 -1
- package/dist/drivers/pframe/data_types.d.ts.map +0 -1
- package/dist/drivers/pframe/driver.d.ts.map +0 -1
- package/dist/drivers/pframe/filter_spec.d.ts.map +0 -1
- package/dist/drivers/pframe/find_columns.d.ts.map +0 -1
- package/dist/drivers/pframe/index.d.ts.map +0 -1
- package/dist/drivers/pframe/linker_columns.d.ts.map +0 -1
- package/dist/drivers/pframe/pframe.d.ts.map +0 -1
- package/dist/drivers/pframe/query/index.d.ts.map +0 -1
- package/dist/drivers/pframe/query/query_common.d.ts.map +0 -1
- package/dist/drivers/pframe/query/query_data.d.ts.map +0 -1
- package/dist/drivers/pframe/query/query_spec.d.ts.map +0 -1
- package/dist/drivers/pframe/query/utils.d.ts.map +0 -1
- package/dist/drivers/pframe/spec/anchored.d.ts.map +0 -1
- package/dist/drivers/pframe/spec/filtered_column.d.ts.map +0 -1
- package/dist/drivers/pframe/spec/ids.d.ts.map +0 -1
- package/dist/drivers/pframe/spec/index.d.ts.map +0 -1
- package/dist/drivers/pframe/spec/native_id.d.ts.map +0 -1
- package/dist/drivers/pframe/spec/selectors.d.ts.map +0 -1
- package/dist/drivers/pframe/spec/spec.d.ts.map +0 -1
- package/dist/drivers/pframe/table.d.ts.map +0 -1
- package/dist/drivers/pframe/table_calculate.d.ts.map +0 -1
- package/dist/drivers/pframe/table_common.d.ts.map +0 -1
- package/dist/drivers/pframe/type_util.d.ts +0 -5
- package/dist/drivers/pframe/type_util.d.ts.map +0 -1
- package/dist/drivers/pframe/unique_values.d.ts.map +0 -1
- package/dist/drivers/upload.d.ts.map +0 -1
- package/dist/drivers/urls.d.ts.map +0 -1
- package/dist/errors.d.ts.map +0 -1
- package/dist/flags/block_flags.d.ts.map +0 -1
- package/dist/flags/flag_utils.d.ts.map +0 -1
- package/dist/flags/index.d.ts +0 -4
- package/dist/flags/index.d.ts.map +0 -1
- package/dist/flags/type_utils.d.ts.map +0 -1
- package/dist/httpAuth.d.ts.map +0 -1
- package/dist/index.cjs.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/json.d.ts.map +0 -1
- package/dist/navigation.d.ts.map +0 -1
- package/dist/plid.d.ts.map +0 -1
- package/dist/pool/entry.d.ts.map +0 -1
- package/dist/pool/index.d.ts.map +0 -1
- package/dist/pool/query.d.ts.map +0 -1
- package/dist/pool/spec.d.ts.map +0 -1
- package/dist/ref.d.ts.map +0 -1
- package/dist/utag.d.ts.map +0 -1
- package/dist/util.d.ts.map +0 -1
- package/dist/value_or_error.d.ts.map +0 -1
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
//#region src/drivers/pframe/data_info.d.ts
|
|
1
2
|
/**
|
|
2
3
|
* Represents a JavaScript representation of a value in a PColumn. Can be null, a number, or a string.
|
|
3
4
|
* These are the primitive types that can be stored directly in PColumns.
|
|
@@ -5,117 +6,89 @@
|
|
|
5
6
|
* Note: Actual columns can hold more value types, which are converted to these JavaScript types
|
|
6
7
|
* once they enter the JavaScript runtime.
|
|
7
8
|
*/
|
|
8
|
-
|
|
9
|
+
type PColumnValue = null | number | string;
|
|
9
10
|
/**
|
|
10
11
|
* Represents a key for a PColumn value.
|
|
11
12
|
* Can be an array of strings or numbers.
|
|
12
13
|
*/
|
|
13
|
-
|
|
14
|
+
type PColumnKey = (number | string)[];
|
|
14
15
|
/**
|
|
15
16
|
* Represents a single entry in a PColumn's data structure.
|
|
16
17
|
* Contains a key and a value.
|
|
17
18
|
*/
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
/** Value / blob at the given key */
|
|
22
|
-
value: T;
|
|
19
|
+
type PColumnDataEntry<T> = {
|
|
20
|
+
/** Key for the value */key: PColumnKey; /** Value / blob at the given key */
|
|
21
|
+
value: T;
|
|
23
22
|
};
|
|
24
23
|
/**
|
|
25
24
|
* Represents column data stored as a simple JSON structure.
|
|
26
25
|
* Used for small datasets that can be efficiently stored directly in memory.
|
|
27
26
|
*/
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
*/
|
|
37
|
-
data: Record<string, PColumnValue>;
|
|
27
|
+
type JsonDataInfo = {
|
|
28
|
+
/** Identifier for this data format ('Json') */type: "Json"; /** Number of axes that make up the complete key (tuple length) */
|
|
29
|
+
keyLength: number;
|
|
30
|
+
/**
|
|
31
|
+
* Key-value pairs where keys are stringified tuples of axis values
|
|
32
|
+
* and values are the column values for those coordinates
|
|
33
|
+
*/
|
|
34
|
+
data: Record<string, PColumnValue>;
|
|
38
35
|
};
|
|
39
36
|
/**
|
|
40
37
|
* Represents column data partitioned across multiple JSON blobs.
|
|
41
38
|
* Used for larger datasets that need to be split into manageable chunks.
|
|
42
39
|
*/
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
partitionKeyLength: number;
|
|
48
|
-
/** Map of stringified partition keys to blob references */
|
|
49
|
-
parts: Record<string, Blob>;
|
|
40
|
+
type JsonPartitionedDataInfo<Blob> = {
|
|
41
|
+
/** Identifier for this data format ('JsonPartitioned') */type: "JsonPartitioned"; /** Number of leading axes used for partitioning */
|
|
42
|
+
partitionKeyLength: number; /** Map of stringified partition keys to blob references */
|
|
43
|
+
parts: Record<string, Blob>;
|
|
50
44
|
};
|
|
51
45
|
/**
|
|
52
46
|
* Represents a binary format chunk containing index and values as separate blobs.
|
|
53
47
|
* Used for efficient storage and retrieval of column data in binary format.
|
|
54
48
|
*/
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
/** Binary blob containing the actual values */
|
|
59
|
-
values: Blob;
|
|
49
|
+
type BinaryChunk<Blob> = {
|
|
50
|
+
/** Binary blob containing structured index information */index: Blob; /** Binary blob containing the actual values */
|
|
51
|
+
values: Blob;
|
|
60
52
|
};
|
|
61
53
|
/**
|
|
62
54
|
* Represents column data partitioned across multiple binary chunks.
|
|
63
55
|
* Optimized for efficient storage and retrieval of large datasets.
|
|
64
56
|
*/
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
partitionKeyLength: number;
|
|
70
|
-
/** Map of stringified partition keys to binary chunks */
|
|
71
|
-
parts: Record<string, BinaryChunk<Blob>>;
|
|
57
|
+
type BinaryPartitionedDataInfo<Blob> = {
|
|
58
|
+
/** Identifier for this data format ('BinaryPartitioned') */type: "BinaryPartitioned"; /** Number of leading axes used for partitioning */
|
|
59
|
+
partitionKeyLength: number; /** Map of stringified partition keys to binary chunks */
|
|
60
|
+
parts: Record<string, BinaryChunk<Blob>>;
|
|
72
61
|
};
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
/** Field name in the Parquet file */
|
|
77
|
-
id: string;
|
|
62
|
+
type ParquetChunkMappingAxis = {
|
|
63
|
+
/** Data type (matches PColumn axis types) */type: "Int" | "Long" | "String"; /** Field name in the Parquet file */
|
|
64
|
+
id: string;
|
|
78
65
|
};
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
/** Field name in the Parquet file */
|
|
83
|
-
id: string;
|
|
66
|
+
type ParquetChunkMappingColumn = {
|
|
67
|
+
/** Data type (matches PColumn value type) */type: "Int" | "Long" | "Float" | "Double" | "String"; /** Field name in the Parquet file */
|
|
68
|
+
id: string;
|
|
84
69
|
};
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
/** Column mapping */
|
|
89
|
-
column: ParquetChunkMappingColumn;
|
|
70
|
+
type ParquetChunkMapping = {
|
|
71
|
+
/** Axes mappings - Parquet file is sorted by these fields in this order */axes: ParquetChunkMappingAxis[]; /** Column mapping */
|
|
72
|
+
column: ParquetChunkMappingColumn;
|
|
90
73
|
};
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
/** Byte
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
axes: number[];
|
|
98
|
-
/** Byte size for the data column */
|
|
99
|
-
column: number;
|
|
100
|
-
};
|
|
74
|
+
type ParquetChunkStats = {
|
|
75
|
+
/** Number of rows in the chunk */numberOfRows: number; /** Byte size information for storage optimization and query planning */
|
|
76
|
+
size: {
|
|
77
|
+
/** Byte sizes for each axis column in the same order as axes mapping */axes: number[]; /** Byte size for the data column */
|
|
78
|
+
column: number;
|
|
79
|
+
};
|
|
101
80
|
};
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
/** Pre-computed statistics for optimization without blob download */
|
|
106
|
-
stats: Partial<ParquetChunkStats>;
|
|
81
|
+
type ParquetChunkMetadata = {
|
|
82
|
+
/** Content hash calculated for the specific axes and data this chunk represents */dataDigest: string; /** Pre-computed statistics for optimization without blob download */
|
|
83
|
+
stats: Partial<ParquetChunkStats>;
|
|
107
84
|
};
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
data: Blob;
|
|
85
|
+
type ParquetChunk<Blob> = {
|
|
86
|
+
/** Parquet file (PTable) containing column data */data: Blob;
|
|
111
87
|
} & ParquetChunkMapping & Partial<ParquetChunkMetadata>;
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
partitionKeyLength: number;
|
|
117
|
-
/** Map of stringified partition keys to parquet files */
|
|
118
|
-
parts: Record<string, Blob>;
|
|
88
|
+
type ParquetPartitionedDataInfo<Blob> = {
|
|
89
|
+
/** Identifier for this data format ('ParquetPartitioned') */type: "ParquetPartitioned"; /** Number of leading axes used for partitioning */
|
|
90
|
+
partitionKeyLength: number; /** Map of stringified partition keys to parquet files */
|
|
91
|
+
parts: Record<string, Blob>;
|
|
119
92
|
};
|
|
120
93
|
/**
|
|
121
94
|
* Union type representing all possible data storage formats for PColumn data.
|
|
@@ -123,14 +96,14 @@ export type ParquetPartitionedDataInfo<Blob> = {
|
|
|
123
96
|
*
|
|
124
97
|
* @template Blob - Type parameter representing the storage reference type (could be ResourceInfo, PFrameBlobId, etc.)
|
|
125
98
|
*/
|
|
126
|
-
|
|
99
|
+
type DataInfo<Blob> = JsonDataInfo | JsonPartitionedDataInfo<Blob> | BinaryPartitionedDataInfo<Blob> | ParquetPartitionedDataInfo<Blob>;
|
|
127
100
|
/**
|
|
128
101
|
* Type guard function that checks if the given value is a valid DataInfo.
|
|
129
102
|
*
|
|
130
103
|
* @param value - The value to check
|
|
131
104
|
* @returns True if the value is a valid DataInfo, false otherwise
|
|
132
105
|
*/
|
|
133
|
-
|
|
106
|
+
declare function isDataInfo<Blob>(value: unknown): value is DataInfo<Blob>;
|
|
134
107
|
/**
|
|
135
108
|
* Maps blob references in a DataInfo object from one type to another using a mapping function.
|
|
136
109
|
*
|
|
@@ -140,75 +113,75 @@ export declare function isDataInfo<Blob>(value: unknown): value is DataInfo<Blob
|
|
|
140
113
|
* @param mapFn - Function to transform blobs from type B1 to type B2
|
|
141
114
|
* @returns A new DataInfo object with transformed blob references
|
|
142
115
|
*/
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
116
|
+
declare function mapDataInfo<B1, B2>(dataInfo: ParquetPartitionedDataInfo<B1>, mapFn: (blob: B1) => B2): ParquetPartitionedDataInfo<B2>;
|
|
117
|
+
declare function mapDataInfo<B1, B2>(dataInfo: Exclude<DataInfo<B1>, ParquetPartitionedDataInfo<B1>>, mapFn: (blob: B1) => B2): Exclude<DataInfo<B2>, ParquetPartitionedDataInfo<B2>>;
|
|
118
|
+
declare function mapDataInfo<B1, B2>(dataInfo: DataInfo<B1>, mapFn: (blob: B1) => B2): DataInfo<B2>;
|
|
146
119
|
/**
|
|
147
120
|
* @param dataInfo - The source DataInfo object
|
|
148
121
|
* @param cb - Callback, function that have access to every blob to visit them all
|
|
149
122
|
* @returns Nothing
|
|
150
123
|
*/
|
|
151
|
-
|
|
124
|
+
declare function visitDataInfo<B>(dataInfo: DataInfo<B>, cb: (blob: B) => void): void;
|
|
152
125
|
/**
|
|
153
126
|
* Represents a single key-value entry in a column's explicit data structure.
|
|
154
127
|
* Used when directly instantiating PColumns with explicit data.
|
|
155
128
|
*/
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
129
|
+
type PColumnValuesEntry = {
|
|
130
|
+
key: PColumnKey;
|
|
131
|
+
val: PColumnValue;
|
|
159
132
|
};
|
|
160
133
|
/**
|
|
161
134
|
* Array of key-value entries representing explicit column data.
|
|
162
135
|
* Used for lightweight explicit instantiation of PColumns.
|
|
163
136
|
*/
|
|
164
|
-
|
|
137
|
+
type PColumnValues = PColumnValuesEntry[];
|
|
165
138
|
/**
|
|
166
139
|
* Entry-based representation of JsonDataInfo
|
|
167
140
|
*/
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
141
|
+
interface JsonDataInfoEntries {
|
|
142
|
+
type: "Json";
|
|
143
|
+
keyLength: number;
|
|
144
|
+
data: PColumnDataEntry<PColumnValue>[];
|
|
172
145
|
}
|
|
173
146
|
/**
|
|
174
147
|
* Entry-based representation of JsonPartitionedDataInfo
|
|
175
148
|
*/
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
149
|
+
interface JsonPartitionedDataInfoEntries<Blob> {
|
|
150
|
+
type: "JsonPartitioned";
|
|
151
|
+
partitionKeyLength: number;
|
|
152
|
+
parts: PColumnDataEntry<Blob>[];
|
|
180
153
|
}
|
|
181
154
|
/**
|
|
182
155
|
* Entry-based representation of BinaryPartitionedDataInfo
|
|
183
156
|
*/
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
157
|
+
interface BinaryPartitionedDataInfoEntries<Blob> {
|
|
158
|
+
type: "BinaryPartitioned";
|
|
159
|
+
partitionKeyLength: number;
|
|
160
|
+
parts: PColumnDataEntry<BinaryChunk<Blob>>[];
|
|
188
161
|
}
|
|
189
162
|
/**
|
|
190
163
|
* Entry-based representation of ParquetPartitionedDataInfo
|
|
191
164
|
*/
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
165
|
+
interface ParquetPartitionedDataInfoEntries<Blob> {
|
|
166
|
+
type: "ParquetPartitioned";
|
|
167
|
+
partitionKeyLength: number;
|
|
168
|
+
parts: PColumnDataEntry<Blob>[];
|
|
196
169
|
}
|
|
197
170
|
/**
|
|
198
171
|
* Union type representing all possible entry-based partitioned data storage formats
|
|
199
172
|
*/
|
|
200
|
-
|
|
173
|
+
type PartitionedDataInfoEntries<Blob> = JsonPartitionedDataInfoEntries<Blob> | BinaryPartitionedDataInfoEntries<Blob> | ParquetPartitionedDataInfoEntries<Blob>;
|
|
201
174
|
/**
|
|
202
175
|
* Union type representing all possible entry-based data storage formats
|
|
203
176
|
*/
|
|
204
|
-
|
|
177
|
+
type DataInfoEntries<Blob> = JsonDataInfoEntries | PartitionedDataInfoEntries<Blob>;
|
|
205
178
|
/**
|
|
206
179
|
* Type guard function that checks if the given value is a valid DataInfoEntries.
|
|
207
180
|
*
|
|
208
181
|
* @param value - The value to check
|
|
209
182
|
* @returns True if the value is a valid DataInfoEntries, false otherwise
|
|
210
183
|
*/
|
|
211
|
-
|
|
184
|
+
declare function isDataInfoEntries<Blob>(value: unknown): value is DataInfoEntries<Blob>;
|
|
212
185
|
/**
|
|
213
186
|
* Type guard function that checks if the given value is a valid PartitionedDataInfoEntries.
|
|
214
187
|
*
|
|
@@ -216,21 +189,21 @@ export declare function isDataInfoEntries<Blob>(value: unknown): value is DataIn
|
|
|
216
189
|
* @param value - The value to check
|
|
217
190
|
* @returns True if the value is a valid PartitionedDataInfoEntries, false otherwise
|
|
218
191
|
*/
|
|
219
|
-
|
|
192
|
+
declare function isPartitionedDataInfoEntries<Blob>(value: unknown): value is PartitionedDataInfoEntries<Blob>;
|
|
220
193
|
/**
|
|
221
194
|
* Converts DataInfo to DataInfoEntries
|
|
222
195
|
*
|
|
223
196
|
* @param dataInfo - The record-based DataInfo object
|
|
224
197
|
* @returns The equivalent entry-based DataInfoEntries object
|
|
225
198
|
*/
|
|
226
|
-
|
|
199
|
+
declare function dataInfoToEntries<Blob>(dataInfo: DataInfo<Blob>): DataInfoEntries<Blob>;
|
|
227
200
|
/**
|
|
228
201
|
* Converts DataInfoEntries to DataInfo
|
|
229
202
|
*
|
|
230
203
|
* @param dataInfoEntries - The entry-based DataInfoEntries object
|
|
231
204
|
* @returns The equivalent record-based DataInfo object
|
|
232
205
|
*/
|
|
233
|
-
|
|
206
|
+
declare function entriesToDataInfo<Blob>(dataInfoEntries: DataInfoEntries<Blob>): DataInfo<Blob>;
|
|
234
207
|
/**
|
|
235
208
|
* Maps blob references in a DataInfoEntries object from one type to another using a mapping function.
|
|
236
209
|
*
|
|
@@ -240,5 +213,7 @@ export declare function entriesToDataInfo<Blob>(dataInfoEntries: DataInfoEntries
|
|
|
240
213
|
* @param mapFn - Function to transform blobs from type B1 to type B2
|
|
241
214
|
* @returns A new DataInfoEntries object with transformed blob references
|
|
242
215
|
*/
|
|
243
|
-
|
|
216
|
+
declare function mapDataInfoEntries<B1, B2>(dataInfoEntries: DataInfoEntries<B1>, mapFn: (blob: B1) => B2): DataInfoEntries<B2>;
|
|
217
|
+
//#endregion
|
|
218
|
+
export { BinaryChunk, BinaryPartitionedDataInfo, BinaryPartitionedDataInfoEntries, DataInfo, DataInfoEntries, JsonDataInfo, JsonDataInfoEntries, JsonPartitionedDataInfo, JsonPartitionedDataInfoEntries, PColumnDataEntry, PColumnKey, PColumnValue, PColumnValues, PColumnValuesEntry, ParquetChunk, ParquetChunkMapping, ParquetChunkMappingAxis, ParquetChunkMappingColumn, ParquetChunkMetadata, ParquetChunkStats, ParquetPartitionedDataInfo, ParquetPartitionedDataInfoEntries, PartitionedDataInfoEntries, dataInfoToEntries, entriesToDataInfo, isDataInfo, isDataInfoEntries, isPartitionedDataInfoEntries, mapDataInfo, mapDataInfoEntries, visitDataInfo };
|
|
244
219
|
//# sourceMappingURL=data_info.d.ts.map
|