@ifc-lite/query 1.0.0 → 1.1.1
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/duckdb-integration.d.ts.map +1 -0
- package/dist/duckdb-integration.js.map +1 -0
- package/dist/entity-node.d.ts.map +1 -0
- package/dist/entity-node.js.map +1 -0
- package/dist/entity-query.d.ts.map +1 -0
- package/dist/entity-query.js.map +1 -0
- package/dist/entity-table.d.ts.map +1 -0
- package/dist/entity-table.js.map +1 -0
- package/dist/fluent-api.d.ts.map +1 -0
- package/dist/fluent-api.js.map +1 -0
- package/dist/ifc-query.d.ts.map +1 -0
- package/dist/ifc-query.js.map +1 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js.map +1 -0
- package/dist/property-table.d.ts.map +1 -0
- package/dist/property-table.js.map +1 -0
- package/dist/query-result-entity.d.ts.map +1 -0
- package/dist/query-result-entity.js.map +1 -0
- package/package.json +5 -5
- package/dist/parser/src/classification-extractor.d.ts +0 -73
- package/dist/parser/src/classification-extractor.d.ts.map +0 -1
- package/dist/parser/src/classification-extractor.js +0 -218
- package/dist/parser/src/classification-extractor.js.map +0 -1
- package/dist/parser/src/columnar-parser.d.ts +0 -43
- package/dist/parser/src/columnar-parser.d.ts.map +0 -1
- package/dist/parser/src/columnar-parser.js +0 -226
- package/dist/parser/src/columnar-parser.js.map +0 -1
- package/dist/parser/src/entity-extractor.d.ts +0 -15
- package/dist/parser/src/entity-extractor.d.ts.map +0 -1
- package/dist/parser/src/entity-extractor.js +0 -144
- package/dist/parser/src/entity-extractor.js.map +0 -1
- package/dist/parser/src/entity-index.d.ts +0 -11
- package/dist/parser/src/entity-index.d.ts.map +0 -1
- package/dist/parser/src/entity-index.js +0 -24
- package/dist/parser/src/entity-index.js.map +0 -1
- package/dist/parser/src/generated/entities.d.ts +0 -6198
- package/dist/parser/src/generated/entities.d.ts.map +0 -1
- package/dist/parser/src/generated/entities.js +0 -5
- package/dist/parser/src/generated/entities.js.map +0 -1
- package/dist/parser/src/generated/enums.d.ts +0 -2260
- package/dist/parser/src/generated/enums.d.ts.map +0 -1
- package/dist/parser/src/generated/enums.js +0 -2470
- package/dist/parser/src/generated/enums.js.map +0 -1
- package/dist/parser/src/generated/schema-registry.d.ts +0 -50
- package/dist/parser/src/generated/schema-registry.d.ts.map +0 -1
- package/dist/parser/src/generated/schema-registry.js +0 -60518
- package/dist/parser/src/generated/schema-registry.js.map +0 -1
- package/dist/parser/src/georef-extractor.d.ts +0 -60
- package/dist/parser/src/georef-extractor.d.ts.map +0 -1
- package/dist/parser/src/georef-extractor.js +0 -200
- package/dist/parser/src/georef-extractor.js.map +0 -1
- package/dist/parser/src/ifc-schema.d.ts +0 -13
- package/dist/parser/src/ifc-schema.d.ts.map +0 -1
- package/dist/parser/src/ifc-schema.js +0 -203
- package/dist/parser/src/ifc-schema.js.map +0 -1
- package/dist/parser/src/index.d.ts +0 -43
- package/dist/parser/src/index.d.ts.map +0 -1
- package/dist/parser/src/index.js +0 -150
- package/dist/parser/src/index.js.map +0 -1
- package/dist/parser/src/material-extractor.d.ts +0 -97
- package/dist/parser/src/material-extractor.d.ts.map +0 -1
- package/dist/parser/src/material-extractor.js +0 -283
- package/dist/parser/src/material-extractor.js.map +0 -1
- package/dist/parser/src/property-extractor.d.ts +0 -23
- package/dist/parser/src/property-extractor.d.ts.map +0 -1
- package/dist/parser/src/property-extractor.js +0 -102
- package/dist/parser/src/property-extractor.js.map +0 -1
- package/dist/parser/src/quantity-extractor.d.ts +0 -64
- package/dist/parser/src/quantity-extractor.d.ts.map +0 -1
- package/dist/parser/src/quantity-extractor.js +0 -202
- package/dist/parser/src/quantity-extractor.js.map +0 -1
- package/dist/parser/src/relationship-extractor.d.ts +0 -18
- package/dist/parser/src/relationship-extractor.d.ts.map +0 -1
- package/dist/parser/src/relationship-extractor.js +0 -91
- package/dist/parser/src/relationship-extractor.js.map +0 -1
- package/dist/parser/src/spatial-hierarchy-builder.d.ts +0 -21
- package/dist/parser/src/spatial-hierarchy-builder.d.ts.map +0 -1
- package/dist/parser/src/spatial-hierarchy-builder.js +0 -201
- package/dist/parser/src/spatial-hierarchy-builder.js.map +0 -1
- package/dist/parser/src/style-extractor.d.ts +0 -83
- package/dist/parser/src/style-extractor.d.ts.map +0 -1
- package/dist/parser/src/style-extractor.js +0 -327
- package/dist/parser/src/style-extractor.js.map +0 -1
- package/dist/parser/src/tokenizer.d.ts +0 -26
- package/dist/parser/src/tokenizer.d.ts.map +0 -1
- package/dist/parser/src/tokenizer.js +0 -181
- package/dist/parser/src/tokenizer.js.map +0 -1
- package/dist/parser/src/types.d.ts +0 -42
- package/dist/parser/src/types.d.ts.map +0 -1
- package/dist/parser/src/types.js +0 -5
- package/dist/parser/src/types.js.map +0 -1
- package/dist/query/src/duckdb-integration.d.ts.map +0 -1
- package/dist/query/src/duckdb-integration.js.map +0 -1
- package/dist/query/src/entity-node.d.ts.map +0 -1
- package/dist/query/src/entity-node.js.map +0 -1
- package/dist/query/src/entity-query.d.ts.map +0 -1
- package/dist/query/src/entity-query.js.map +0 -1
- package/dist/query/src/entity-table.d.ts.map +0 -1
- package/dist/query/src/entity-table.js.map +0 -1
- package/dist/query/src/fluent-api.d.ts.map +0 -1
- package/dist/query/src/fluent-api.js.map +0 -1
- package/dist/query/src/ifc-query.d.ts.map +0 -1
- package/dist/query/src/ifc-query.js.map +0 -1
- package/dist/query/src/index.d.ts.map +0 -1
- package/dist/query/src/index.js.map +0 -1
- package/dist/query/src/property-table.d.ts.map +0 -1
- package/dist/query/src/property-table.js.map +0 -1
- package/dist/query/src/query-result-entity.d.ts.map +0 -1
- package/dist/query/src/query-result-entity.js.map +0 -1
- /package/dist/{query/src/duckdb-integration.d.ts → duckdb-integration.d.ts} +0 -0
- /package/dist/{query/src/duckdb-integration.js → duckdb-integration.js} +0 -0
- /package/dist/{query/src/entity-node.d.ts → entity-node.d.ts} +0 -0
- /package/dist/{query/src/entity-node.js → entity-node.js} +0 -0
- /package/dist/{query/src/entity-query.d.ts → entity-query.d.ts} +0 -0
- /package/dist/{query/src/entity-query.js → entity-query.js} +0 -0
- /package/dist/{query/src/entity-table.d.ts → entity-table.d.ts} +0 -0
- /package/dist/{query/src/entity-table.js → entity-table.js} +0 -0
- /package/dist/{query/src/fluent-api.d.ts → fluent-api.d.ts} +0 -0
- /package/dist/{query/src/fluent-api.js → fluent-api.js} +0 -0
- /package/dist/{query/src/ifc-query.d.ts → ifc-query.d.ts} +0 -0
- /package/dist/{query/src/ifc-query.js → ifc-query.js} +0 -0
- /package/dist/{query/src/index.d.ts → index.d.ts} +0 -0
- /package/dist/{query/src/index.js → index.js} +0 -0
- /package/dist/{query/src/property-table.d.ts → property-table.d.ts} +0 -0
- /package/dist/{query/src/property-table.js → property-table.js} +0 -0
- /package/dist/{query/src/query-result-entity.d.ts → query-result-entity.d.ts} +0 -0
- /package/dist/{query/src/query-result-entity.js → query-result-entity.js} +0 -0
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Georeferencing Extractor
|
|
3
|
-
*
|
|
4
|
-
* Extracts IFC georeferencing information for coordinate system transformations.
|
|
5
|
-
*
|
|
6
|
-
* IFC georeferencing concepts:
|
|
7
|
-
* - IfcMapConversion: Transformation from local engineering CRS to map CRS
|
|
8
|
-
* - IfcProjectedCRS: Target coordinate reference system (e.g., UTM, State Plane)
|
|
9
|
-
* - IfcGeometricRepresentationContext: Context with coordinate system info
|
|
10
|
-
*
|
|
11
|
-
* This enables:
|
|
12
|
-
* - Converting IFC coordinates to real-world coordinates (lat/lon or projected)
|
|
13
|
-
* - Integration with GIS systems
|
|
14
|
-
* - Multi-model coordination (ensuring models align in real-world space)
|
|
15
|
-
*/
|
|
16
|
-
import type { IfcEntity } from './entity-extractor';
|
|
17
|
-
export interface MapConversion {
|
|
18
|
-
id: number;
|
|
19
|
-
sourceCRS: number;
|
|
20
|
-
targetCRS: number;
|
|
21
|
-
eastings: number;
|
|
22
|
-
northings: number;
|
|
23
|
-
orthogonalHeight: number;
|
|
24
|
-
xAxisAbscissa?: number;
|
|
25
|
-
xAxisOrdinate?: number;
|
|
26
|
-
scale?: number;
|
|
27
|
-
}
|
|
28
|
-
export interface ProjectedCRS {
|
|
29
|
-
id: number;
|
|
30
|
-
name: string;
|
|
31
|
-
description?: string;
|
|
32
|
-
geodeticDatum?: string;
|
|
33
|
-
verticalDatum?: string;
|
|
34
|
-
mapProjection?: string;
|
|
35
|
-
mapZone?: string;
|
|
36
|
-
mapUnit?: string;
|
|
37
|
-
}
|
|
38
|
-
export interface GeoreferenceInfo {
|
|
39
|
-
hasGeoreference: boolean;
|
|
40
|
-
mapConversion?: MapConversion;
|
|
41
|
-
projectedCRS?: ProjectedCRS;
|
|
42
|
-
transformMatrix?: number[];
|
|
43
|
-
}
|
|
44
|
-
/**
|
|
45
|
-
* Extract georeferencing information from IFC entities
|
|
46
|
-
*/
|
|
47
|
-
export declare function extractGeoreferencing(entities: Map<number, IfcEntity>, entitiesByType: Map<string, number[]>): GeoreferenceInfo;
|
|
48
|
-
/**
|
|
49
|
-
* Transform a point from local to world coordinates
|
|
50
|
-
*/
|
|
51
|
-
export declare function transformToWorld(localPoint: [number, number, number], georef: GeoreferenceInfo): [number, number, number] | null;
|
|
52
|
-
/**
|
|
53
|
-
* Transform a point from world to local coordinates
|
|
54
|
-
*/
|
|
55
|
-
export declare function transformToLocal(worldPoint: [number, number, number], georef: GeoreferenceInfo): [number, number, number] | null;
|
|
56
|
-
/**
|
|
57
|
-
* Get coordinate system description
|
|
58
|
-
*/
|
|
59
|
-
export declare function getCoordinateSystemDescription(georef: GeoreferenceInfo): string;
|
|
60
|
-
//# sourceMappingURL=georef-extractor.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"georef-extractor.d.ts","sourceRoot":"","sources":["../../../../parser/src/georef-extractor.ts"],"names":[],"mappings":"AAIA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,EAAE,SAAS,E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AC9B,UAAU,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,EACpC,MAAM,EAAE,gBAAgB,GACvB,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,GAAG,IAAI,CA2BjC;AAED;;GAEG;AACH,wBAAgB,8BAA8B,CAAC,MAAM,EAAE,gBAAgB,GAAG,MAAM,CAuB/E"}
|
|
@@ -1,200 +0,0 @@
|
|
|
1
|
-
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
2
|
-
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
3
|
-
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
|
4
|
-
/**
|
|
5
|
-
* Extract georeferencing information from IFC entities
|
|
6
|
-
*/
|
|
7
|
-
export function extractGeoreferencing(entities, entitiesByType) {
|
|
8
|
-
const info = {
|
|
9
|
-
hasGeoreference: false,
|
|
10
|
-
};
|
|
11
|
-
// Extract IfcMapConversion
|
|
12
|
-
const mapConversionIds = entitiesByType.get('IfcMapConversion') || [];
|
|
13
|
-
if (mapConversionIds.length > 0) {
|
|
14
|
-
const entity = entities.get(mapConversionIds[0]);
|
|
15
|
-
if (entity) {
|
|
16
|
-
info.mapConversion = extractMapConversion(entity);
|
|
17
|
-
info.hasGeoreference = true;
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
// Extract IfcProjectedCRS
|
|
21
|
-
const projectedCRSIds = entitiesByType.get('IfcProjectedCRS') || [];
|
|
22
|
-
if (projectedCRSIds.length > 0) {
|
|
23
|
-
const entity = entities.get(projectedCRSIds[0]);
|
|
24
|
-
if (entity) {
|
|
25
|
-
info.projectedCRS = extractProjectedCRS(entity);
|
|
26
|
-
info.hasGeoreference = true;
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
// Compute transformation matrix if we have map conversion
|
|
30
|
-
if (info.mapConversion) {
|
|
31
|
-
info.transformMatrix = computeTransformMatrix(info.mapConversion);
|
|
32
|
-
}
|
|
33
|
-
return info;
|
|
34
|
-
}
|
|
35
|
-
function extractMapConversion(entity) {
|
|
36
|
-
// IfcMapConversion attributes (IFC4):
|
|
37
|
-
// [0] SourceCRS (IfcCoordinateReferenceSystem)
|
|
38
|
-
// [1] TargetCRS (IfcCoordinateReferenceSystem)
|
|
39
|
-
// [2] Eastings (IfcLengthMeasure)
|
|
40
|
-
// [3] Northings (IfcLengthMeasure)
|
|
41
|
-
// [4] OrthogonalHeight (IfcLengthMeasure)
|
|
42
|
-
// [5] XAxisAbscissa (OPTIONAL IfcReal)
|
|
43
|
-
// [6] XAxisOrdinate (OPTIONAL IfcReal)
|
|
44
|
-
// [7] Scale (OPTIONAL IfcReal)
|
|
45
|
-
return {
|
|
46
|
-
id: entity.id,
|
|
47
|
-
sourceCRS: getReference(entity.attributes[0]) || 0,
|
|
48
|
-
targetCRS: getReference(entity.attributes[1]) || 0,
|
|
49
|
-
eastings: getNumber(entity.attributes[2]) || 0,
|
|
50
|
-
northings: getNumber(entity.attributes[3]) || 0,
|
|
51
|
-
orthogonalHeight: getNumber(entity.attributes[4]) || 0,
|
|
52
|
-
xAxisAbscissa: getNumber(entity.attributes[5]),
|
|
53
|
-
xAxisOrdinate: getNumber(entity.attributes[6]),
|
|
54
|
-
scale: getNumber(entity.attributes[7]),
|
|
55
|
-
};
|
|
56
|
-
}
|
|
57
|
-
function extractProjectedCRS(entity) {
|
|
58
|
-
// IfcProjectedCRS attributes (IFC4):
|
|
59
|
-
// [0] Name (IfcLabel)
|
|
60
|
-
// [1] Description (OPTIONAL IfcText)
|
|
61
|
-
// [2] GeodeticDatum (OPTIONAL IfcIdentifier)
|
|
62
|
-
// [3] VerticalDatum (OPTIONAL IfcIdentifier)
|
|
63
|
-
// [4] MapProjection (OPTIONAL IfcIdentifier)
|
|
64
|
-
// [5] MapZone (OPTIONAL IfcIdentifier)
|
|
65
|
-
// [6] MapUnit (OPTIONAL IfcNamedUnit)
|
|
66
|
-
// Parse MapUnit if it's a reference
|
|
67
|
-
let mapUnit;
|
|
68
|
-
const mapUnitRef = getReference(entity.attributes[6]);
|
|
69
|
-
if (mapUnitRef) {
|
|
70
|
-
// Would need to resolve the IfcNamedUnit entity
|
|
71
|
-
mapUnit = 'METRE'; // Default assumption
|
|
72
|
-
}
|
|
73
|
-
return {
|
|
74
|
-
id: entity.id,
|
|
75
|
-
name: getString(entity.attributes[0]) || '',
|
|
76
|
-
description: getString(entity.attributes[1]),
|
|
77
|
-
geodeticDatum: getString(entity.attributes[2]),
|
|
78
|
-
verticalDatum: getString(entity.attributes[3]),
|
|
79
|
-
mapProjection: getString(entity.attributes[4]),
|
|
80
|
-
mapZone: getString(entity.attributes[5]),
|
|
81
|
-
mapUnit,
|
|
82
|
-
};
|
|
83
|
-
}
|
|
84
|
-
/**
|
|
85
|
-
* Compute 4x4 transformation matrix from local to world coordinates
|
|
86
|
-
*/
|
|
87
|
-
function computeTransformMatrix(mapConversion) {
|
|
88
|
-
const { eastings, northings, orthogonalHeight, xAxisAbscissa, xAxisOrdinate, scale } = mapConversion;
|
|
89
|
-
// Default scale to 1.0 if not specified
|
|
90
|
-
const s = scale || 1.0;
|
|
91
|
-
// Compute rotation angle from X-axis direction
|
|
92
|
-
let angle = 0;
|
|
93
|
-
if (xAxisAbscissa !== undefined && xAxisOrdinate !== undefined) {
|
|
94
|
-
angle = Math.atan2(xAxisOrdinate, xAxisAbscissa);
|
|
95
|
-
}
|
|
96
|
-
const cos = Math.cos(angle);
|
|
97
|
-
const sin = Math.sin(angle);
|
|
98
|
-
// Build 4x4 transformation matrix:
|
|
99
|
-
// [scale*cos -scale*sin 0 eastings ]
|
|
100
|
-
// [scale*sin scale*cos 0 northings ]
|
|
101
|
-
// [0 0 1 height ]
|
|
102
|
-
// [0 0 0 1 ]
|
|
103
|
-
return [
|
|
104
|
-
s * cos, s * sin, 0, 0,
|
|
105
|
-
-s * sin, s * cos, 0, 0,
|
|
106
|
-
0, 0, 1, 0,
|
|
107
|
-
eastings, northings, orthogonalHeight, 1,
|
|
108
|
-
];
|
|
109
|
-
}
|
|
110
|
-
/**
|
|
111
|
-
* Transform a point from local to world coordinates
|
|
112
|
-
*/
|
|
113
|
-
export function transformToWorld(localPoint, georef) {
|
|
114
|
-
if (!georef.transformMatrix) {
|
|
115
|
-
return null;
|
|
116
|
-
}
|
|
117
|
-
const [x, y, z] = localPoint;
|
|
118
|
-
const m = georef.transformMatrix;
|
|
119
|
-
// Apply transformation: [x', y', z', 1] = [x, y, z, 1] * M
|
|
120
|
-
const xWorld = m[0] * x + m[4] * y + m[8] * z + m[12];
|
|
121
|
-
const yWorld = m[1] * x + m[5] * y + m[9] * z + m[13];
|
|
122
|
-
const zWorld = m[2] * x + m[6] * y + m[10] * z + m[14];
|
|
123
|
-
return [xWorld, yWorld, zWorld];
|
|
124
|
-
}
|
|
125
|
-
/**
|
|
126
|
-
* Transform a point from world to local coordinates
|
|
127
|
-
*/
|
|
128
|
-
export function transformToLocal(worldPoint, georef) {
|
|
129
|
-
if (!georef.transformMatrix) {
|
|
130
|
-
return null;
|
|
131
|
-
}
|
|
132
|
-
// Compute inverse transformation
|
|
133
|
-
const m = georef.transformMatrix;
|
|
134
|
-
const [xWorld, yWorld, zWorld] = worldPoint;
|
|
135
|
-
// Extract rotation and scale
|
|
136
|
-
const scale = georef.mapConversion?.scale || 1.0;
|
|
137
|
-
const angle = Math.atan2(m[1], m[0]);
|
|
138
|
-
const cos = Math.cos(-angle);
|
|
139
|
-
const sin = Math.sin(-angle);
|
|
140
|
-
const invScale = 1.0 / scale;
|
|
141
|
-
// Apply inverse translation
|
|
142
|
-
const xTrans = xWorld - m[12];
|
|
143
|
-
const yTrans = yWorld - m[13];
|
|
144
|
-
const zTrans = zWorld - m[14];
|
|
145
|
-
// Apply inverse rotation and scale
|
|
146
|
-
const x = invScale * (cos * xTrans - sin * yTrans);
|
|
147
|
-
const y = invScale * (sin * xTrans + cos * yTrans);
|
|
148
|
-
const z = zTrans;
|
|
149
|
-
return [x, y, z];
|
|
150
|
-
}
|
|
151
|
-
/**
|
|
152
|
-
* Get coordinate system description
|
|
153
|
-
*/
|
|
154
|
-
export function getCoordinateSystemDescription(georef) {
|
|
155
|
-
if (!georef.hasGeoreference) {
|
|
156
|
-
return 'Local Engineering Coordinates';
|
|
157
|
-
}
|
|
158
|
-
const parts = [];
|
|
159
|
-
if (georef.projectedCRS) {
|
|
160
|
-
parts.push(georef.projectedCRS.name);
|
|
161
|
-
if (georef.projectedCRS.mapProjection) {
|
|
162
|
-
parts.push(`(${georef.projectedCRS.mapProjection})`);
|
|
163
|
-
}
|
|
164
|
-
if (georef.projectedCRS.geodeticDatum) {
|
|
165
|
-
parts.push(`Datum: ${georef.projectedCRS.geodeticDatum}`);
|
|
166
|
-
}
|
|
167
|
-
}
|
|
168
|
-
if (georef.mapConversion) {
|
|
169
|
-
const { eastings, northings, orthogonalHeight } = georef.mapConversion;
|
|
170
|
-
parts.push(`Origin: (${eastings.toFixed(2)}, ${northings.toFixed(2)}, ${orthogonalHeight.toFixed(2)})`);
|
|
171
|
-
}
|
|
172
|
-
return parts.join(' ');
|
|
173
|
-
}
|
|
174
|
-
// Helper functions
|
|
175
|
-
function getString(value) {
|
|
176
|
-
if (value === null || value === undefined)
|
|
177
|
-
return undefined;
|
|
178
|
-
if (typeof value === 'string')
|
|
179
|
-
return value;
|
|
180
|
-
return String(value);
|
|
181
|
-
}
|
|
182
|
-
function getNumber(value) {
|
|
183
|
-
if (value === null || value === undefined)
|
|
184
|
-
return undefined;
|
|
185
|
-
if (typeof value === 'number')
|
|
186
|
-
return value;
|
|
187
|
-
const num = parseFloat(value);
|
|
188
|
-
return isNaN(num) ? undefined : num;
|
|
189
|
-
}
|
|
190
|
-
function getReference(value) {
|
|
191
|
-
if (value === null || value === undefined)
|
|
192
|
-
return undefined;
|
|
193
|
-
if (typeof value === 'number')
|
|
194
|
-
return value;
|
|
195
|
-
if (typeof value === 'string' && value.startsWith('#')) {
|
|
196
|
-
return parseInt(value.substring(1));
|
|
197
|
-
}
|
|
198
|
-
return undefined;
|
|
199
|
-
}
|
|
200
|
-
//# sourceMappingURL=georef-extractor.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"georef-extractor.js","sourceRoot":"","sources":["../../../../parser/src/georef-extractor.ts"],"names":[],"mappings":"AAAA;;+DAE+D;AAmD/D;;GAEG;AACH,MAAM,UAAU,qBAAqB,CACnC,QAAgC,EAChC,cAAqC;IAErC,MAAM,IAAI,GAAqB;QAC7B,eAAe,EAAE,KAAK;KACvB,CAAC;IAEF,2BAA2B;IAC3B,MAAM,gBAAgB,GAAG,cAAc,CAAC,GAAG,CAAC,kBAAkB,CAAC,IAAI,EAAE,CAAC;IACtE,IAAI,gBAAgB,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QAChC,MAAM,MAAM,GAAG,QAAQ,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC,CAAC,CAAC,CAAC;QACjD,IAAI,MAAM,EAAE,CAAC;YACX,IAAI,CAAC,aAAa,GAAG,oBAAoB,CAAC,MAAM,CAAC,CAAC;YAClD,IAAI,CAAC,eAAe,GAAG,IAAI,CAAC;QAC9B,CAAC;IACH,CAAC;IAED,0BAA0B;IAC1B,MAAM,eAAe,GAAG,cAAc,CAAC,GAAG,CAAC,iBAAiB,CAAC,IAAI,EAAE,CAAC;IACpE,IAAI,eAAe,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QAC/B,MAAM,MAAM,GAAG,QAAQ,CAAC,GAAG,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,CAAC;QAChD,IAAI,MAAM,EAAE,CAAC;YACX,IAAI,CAAC,YAAY,GAAG,mBAAmB,CAAC,MAAM,CAAC,CAAC;YAChD,IAAI,CAAC,eAAe,GAAG,IAAI,CAAC;QAC9B,CAAC;IACH,CAAC;IAED,0DAA0D;IAC1D,IAAI,IAAI,CAAC,aAAa,EAAE,CAAC;QACvB,IAAI,CAAC,eAAe,GAAG,sBAAsB,CAAC,IAAI,CAAC,aA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,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,SAAS;QAAE,OAAO,SAAS,CAAC;IAC5D,IAAI,OAAO,KAAK,KAAK,QAAQ;QAAE,OAAO,KAAK,CAAC;IAC5C,MAAM,GAAG,GAAG,UAAU,CAAC,KAAK,CAAC,CAAC;IAC9B,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,GAAG,CAAC;AACtC,CAAC;AAED,SAAS,YAAY,CAAC,KAAU;IAC9B,IAAI,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,SAAS;QAAE,OAAO,SAAS,CAAC;IAC5D,IAAI,OAAO,KAAK,KAAK,QAAQ;QAAE,OAAO,KAAK,CAAC;IAC5C,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;QACvD,OAAO,QAAQ,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;IACtC,CAAC;IACD,OAAO,SAAS,CAAC;AACnB,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Get all attributes for an IFC entity type by walking the inheritance chain
|
|
3
|
-
*/
|
|
4
|
-
export declare function getAttributeNames(type: string): string[];
|
|
5
|
-
/**
|
|
6
|
-
* Check if a type is known in the schema
|
|
7
|
-
*/
|
|
8
|
-
export declare function isKnownType(type: string): boolean;
|
|
9
|
-
/**
|
|
10
|
-
* Get attribute name at a specific index for a type
|
|
11
|
-
*/
|
|
12
|
-
export declare function getAttributeNameAt(type: string, index: number): string | null;
|
|
13
|
-
//# sourceMappingURL=ifc-schema.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ifc-schema.d.ts","sourceRoot":"","sources":["../../../../parser/src/ifc-schema.ts"],"names":[],"mappings":"AAmMA;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,EAAE,CAsBxD;AAED;;GAEG;AACH,wBAAgB,WAAW,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAGjD;AAED;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAG7E"}
|
|
@@ -1,203 +0,0 @@
|
|
|
1
|
-
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
2
|
-
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
3
|
-
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
|
4
|
-
/**
|
|
5
|
-
* IFC Schema Registry
|
|
6
|
-
*
|
|
7
|
-
* Defines IFC entity type inheritance hierarchy and attributes.
|
|
8
|
-
* Follows the IFC specification inheritance structure.
|
|
9
|
-
*/
|
|
10
|
-
/**
|
|
11
|
-
* Type inheritance map: child -> parent
|
|
12
|
-
*/
|
|
13
|
-
const INHERITANCE_MAP = new Map([
|
|
14
|
-
// Root level
|
|
15
|
-
['IfcRoot', ''],
|
|
16
|
-
// Object definition hierarchy
|
|
17
|
-
['IfcObjectDefinition', 'IfcRoot'],
|
|
18
|
-
['IfcObject', 'IfcObjectDefinition'],
|
|
19
|
-
['IfcProduct', 'IfcObject'],
|
|
20
|
-
['IfcElement', 'IfcProduct'],
|
|
21
|
-
['IfcBuildingElement', 'IfcElement'],
|
|
22
|
-
// Spatial structure
|
|
23
|
-
['IfcSpatialElement', 'IfcProduct'],
|
|
24
|
-
['IfcSpatialStructureElement', 'IfcSpatialElement'],
|
|
25
|
-
['IfcProject', 'IfcSpatialStructureElement'],
|
|
26
|
-
['IfcSite', 'IfcSpatialStructureElement'],
|
|
27
|
-
['IfcBuilding', 'IfcSpatialStructureElement'],
|
|
28
|
-
['IfcBuildingStorey', 'IfcSpatialStructureElement'],
|
|
29
|
-
['IfcSpace', 'IfcSpatialElement'],
|
|
30
|
-
// Building elements
|
|
31
|
-
['IfcWall', 'IfcBuildingElement'],
|
|
32
|
-
['IfcWallStandardCase', 'IfcWall'],
|
|
33
|
-
['IfcSlab', 'IfcBuildingElement'],
|
|
34
|
-
['IfcBeam', 'IfcBuildingElement'],
|
|
35
|
-
['IfcColumn', 'IfcBuildingElement'],
|
|
36
|
-
['IfcRoof', 'IfcBuildingElement'],
|
|
37
|
-
['IfcStair', 'IfcBuildingElement'],
|
|
38
|
-
['IfcRamp', 'IfcBuildingElement'],
|
|
39
|
-
['IfcRailing', 'IfcBuildingElement'],
|
|
40
|
-
['IfcFooting', 'IfcBuildingElement'],
|
|
41
|
-
['IfcBuildingElementProxy', 'IfcBuildingElement'],
|
|
42
|
-
['IfcFurnishingElement', 'IfcElement'],
|
|
43
|
-
// Openings and fillings
|
|
44
|
-
['IfcOpeningElement', 'IfcElement'],
|
|
45
|
-
['IfcWindow', 'IfcBuildingElement'],
|
|
46
|
-
['IfcDoor', 'IfcBuildingElement'],
|
|
47
|
-
// MEP
|
|
48
|
-
['IfcDistributionElement', 'IfcElement'],
|
|
49
|
-
['IfcFlowSegment', 'IfcDistributionElement'],
|
|
50
|
-
['IfcFlowTerminal', 'IfcDistributionElement'],
|
|
51
|
-
// Relationships
|
|
52
|
-
['IfcRelationship', 'IfcRoot'],
|
|
53
|
-
['IfcRelDefines', 'IfcRelationship'],
|
|
54
|
-
['IfcRelDefinesByProperties', 'IfcRelDefines'],
|
|
55
|
-
['IfcRelDefinesByType', 'IfcRelDefines'],
|
|
56
|
-
['IfcRelConnects', 'IfcRelationship'],
|
|
57
|
-
['IfcRelVoidsElement', 'IfcRelConnects'],
|
|
58
|
-
['IfcRelFillsElement', 'IfcRelConnects'],
|
|
59
|
-
['IfcRelContainedInSpatialStructure', 'IfcRelConnects'],
|
|
60
|
-
['IfcRelAggregates', 'IfcRelConnects'],
|
|
61
|
-
['IfcRelAssociates', 'IfcRelationship'],
|
|
62
|
-
['IfcRelAssociatesMaterial', 'IfcRelAssociates'],
|
|
63
|
-
// Property sets
|
|
64
|
-
['IfcPropertyDefinition', 'IfcRoot'],
|
|
65
|
-
['IfcPropertySet', 'IfcPropertyDefinition'],
|
|
66
|
-
['IfcProperty', 'IfcRoot'],
|
|
67
|
-
['IfcPropertySingleValue', 'IfcProperty'],
|
|
68
|
-
// Geometry and placement
|
|
69
|
-
['IfcPlacement', 'IfcGeometricRepresentationItem'],
|
|
70
|
-
['IfcLocalPlacement', 'IfcPlacement'],
|
|
71
|
-
['IfcOwnerHistory', 'IfcRoot'],
|
|
72
|
-
]);
|
|
73
|
-
/**
|
|
74
|
-
* Attributes defined at each entity type level (only attributes added at this level)
|
|
75
|
-
*/
|
|
76
|
-
const TYPE_ATTRIBUTES = new Map([
|
|
77
|
-
// IfcRoot (base)
|
|
78
|
-
['IfcRoot', ['GlobalId', 'OwnerHistory', 'Name', 'Description']],
|
|
79
|
-
// IfcObjectDefinition (no new attributes, but needed for inheritance walk)
|
|
80
|
-
['IfcObjectDefinition', []],
|
|
81
|
-
// IfcObject
|
|
82
|
-
['IfcObject', ['ObjectType']],
|
|
83
|
-
// IfcProduct
|
|
84
|
-
['IfcProduct', ['ObjectPlacement', 'Representation']],
|
|
85
|
-
// IfcElement
|
|
86
|
-
['IfcElement', ['Tag']],
|
|
87
|
-
// IfcBuildingElement (no new attributes, but needed for inheritance walk)
|
|
88
|
-
['IfcBuildingElement', []],
|
|
89
|
-
// Spatial structure
|
|
90
|
-
['IfcProject', []],
|
|
91
|
-
['IfcSite', []],
|
|
92
|
-
['IfcBuilding', []],
|
|
93
|
-
['IfcBuildingStorey', []],
|
|
94
|
-
['IfcSpace', []],
|
|
95
|
-
// Building elements
|
|
96
|
-
['IfcWall', ['PredefinedType']],
|
|
97
|
-
['IfcWallStandardCase', []],
|
|
98
|
-
['IfcSlab', ['PredefinedType']],
|
|
99
|
-
['IfcBeam', ['PredefinedType']],
|
|
100
|
-
['IfcColumn', ['PredefinedType']],
|
|
101
|
-
['IfcRoof', ['PredefinedType']],
|
|
102
|
-
['IfcStair', ['PredefinedType']],
|
|
103
|
-
['IfcRamp', ['PredefinedType']],
|
|
104
|
-
['IfcRailing', ['PredefinedType']],
|
|
105
|
-
['IfcFooting', ['PredefinedType']],
|
|
106
|
-
['IfcBuildingElementProxy', ['PredefinedType']],
|
|
107
|
-
['IfcFurnishingElement', ['PredefinedType']],
|
|
108
|
-
// Openings and fillings
|
|
109
|
-
['IfcOpeningElement', ['PredefinedType']],
|
|
110
|
-
['IfcWindow', ['OverallHeight', 'OverallWidth', 'PredefinedType', 'PartitioningType', 'UserDefinedPartitioningType']],
|
|
111
|
-
['IfcDoor', ['OverallHeight', 'OverallWidth', 'PredefinedType', 'OperationType', 'UserDefinedOperationType']],
|
|
112
|
-
// MEP
|
|
113
|
-
['IfcDistributionElement', ['PredefinedType']],
|
|
114
|
-
['IfcFlowSegment', []],
|
|
115
|
-
['IfcFlowTerminal', []],
|
|
116
|
-
// Relationships
|
|
117
|
-
['IfcRelationship', []],
|
|
118
|
-
['IfcRelDefines', []],
|
|
119
|
-
['IfcRelDefinesByProperties', []], // Attributes handled specially in relationship-extractor
|
|
120
|
-
['IfcRelDefinesByType', []],
|
|
121
|
-
['IfcRelConnects', []],
|
|
122
|
-
['IfcRelVoidsElement', []],
|
|
123
|
-
['IfcRelFillsElement', []],
|
|
124
|
-
['IfcRelContainedInSpatialStructure', []],
|
|
125
|
-
['IfcRelAggregates', []],
|
|
126
|
-
['IfcRelAssociates', []],
|
|
127
|
-
['IfcRelAssociatesMaterial', []],
|
|
128
|
-
// Property sets
|
|
129
|
-
['IfcPropertyDefinition', []],
|
|
130
|
-
['IfcPropertySet', ['HasProperties']],
|
|
131
|
-
['IfcProperty', ['Name']],
|
|
132
|
-
['IfcPropertySingleValue', ['NominalValue', 'Unit']],
|
|
133
|
-
// Geometry and placement
|
|
134
|
-
['IfcPlacement', ['PlacementLocation']],
|
|
135
|
-
['IfcLocalPlacement', ['PlacementRelTo', 'RelativePlacement']],
|
|
136
|
-
['IfcOwnerHistory', ['OwningUser', 'OwningApplication', 'State', 'ChangeAction', 'LastModifiedDate', 'LastModifyingUser', 'LastModifyingApplication', 'CreationDate']],
|
|
137
|
-
]);
|
|
138
|
-
/**
|
|
139
|
-
* Get the parent type for a given IFC entity type
|
|
140
|
-
*/
|
|
141
|
-
function getParentType(type) {
|
|
142
|
-
const normalized = normalizeTypeName(type);
|
|
143
|
-
const parent = INHERITANCE_MAP.get(normalized);
|
|
144
|
-
return parent && parent !== '' ? parent : null;
|
|
145
|
-
}
|
|
146
|
-
/**
|
|
147
|
-
* Normalize type name (handle case variations)
|
|
148
|
-
* Converts: IFCWINDOW -> IfcWindow, IfcWindow -> IfcWindow, ifcwindow -> IfcWindow
|
|
149
|
-
*/
|
|
150
|
-
function normalizeTypeName(type) {
|
|
151
|
-
// If already in correct format (starts with "Ifc"), return as-is
|
|
152
|
-
if (type.startsWith('Ifc')) {
|
|
153
|
-
return type;
|
|
154
|
-
}
|
|
155
|
-
// Convert uppercase or mixed case to PascalCase
|
|
156
|
-
const upper = type.toUpperCase();
|
|
157
|
-
if (upper.startsWith('IFC')) {
|
|
158
|
-
// IFCWINDOW -> IfcWindow
|
|
159
|
-
// IFCWALLSTANDARDCASE -> IfcWallStandardCase
|
|
160
|
-
const rest = type.slice(3); // Remove "IFC" or "Ifc"
|
|
161
|
-
// Convert rest to PascalCase (capitalize first letter, lowercase rest)
|
|
162
|
-
const pascalRest = rest.charAt(0).toUpperCase() + rest.slice(1).toLowerCase();
|
|
163
|
-
return 'Ifc' + pascalRest;
|
|
164
|
-
}
|
|
165
|
-
// If doesn't start with IFC, assume it's already normalized or return as-is
|
|
166
|
-
return type;
|
|
167
|
-
}
|
|
168
|
-
/**
|
|
169
|
-
* Get all attributes for an IFC entity type by walking the inheritance chain
|
|
170
|
-
*/
|
|
171
|
-
export function getAttributeNames(type) {
|
|
172
|
-
const normalized = normalizeTypeName(type);
|
|
173
|
-
const attributes = [];
|
|
174
|
-
const visited = new Set();
|
|
175
|
-
let currentType = normalized;
|
|
176
|
-
// Walk up the inheritance chain
|
|
177
|
-
while (currentType && !visited.has(currentType)) {
|
|
178
|
-
visited.add(currentType);
|
|
179
|
-
const typeAttrs = TYPE_ATTRIBUTES.get(currentType);
|
|
180
|
-
if (typeAttrs) {
|
|
181
|
-
// Prepend attributes (parent attributes come first)
|
|
182
|
-
attributes.unshift(...typeAttrs);
|
|
183
|
-
}
|
|
184
|
-
currentType = getParentType(currentType);
|
|
185
|
-
}
|
|
186
|
-
// If no attributes found, return empty array (will fallback to indexed)
|
|
187
|
-
return attributes;
|
|
188
|
-
}
|
|
189
|
-
/**
|
|
190
|
-
* Check if a type is known in the schema
|
|
191
|
-
*/
|
|
192
|
-
export function isKnownType(type) {
|
|
193
|
-
const normalized = normalizeTypeName(type);
|
|
194
|
-
return INHERITANCE_MAP.has(normalized) || TYPE_ATTRIBUTES.has(normalized);
|
|
195
|
-
}
|
|
196
|
-
/**
|
|
197
|
-
* Get attribute name at a specific index for a type
|
|
198
|
-
*/
|
|
199
|
-
export function getAttributeNameAt(type, index) {
|
|
200
|
-
const attributes = getAttributeNames(type);
|
|
201
|
-
return attributes[index] || null;
|
|
202
|
-
}
|
|
203
|
-
//# sourceMappingURL=ifc-schema.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ifc-schema.js","sourceRoot":"","sources":["../../../../parser/src/ifc-schema.ts"],"names":[],"mappings":"AAAA;;+DAE+D;AAE/D;;;;;GAKG;AAEH;;GAEG;AACH,MAAM,eAAe,GAAwB,IAAI,GAAG,CAAC;IACjD,aAAa;IACb,CAAC,SAAS,EAAE,EAAE,CAAC;IAEf,8BAA8B;IAC9B,CAAC,qBAAqB,EAAE,SAAS,CAAC;IAClC,CAAC,WAAW,EAAE,qBAAqB,CAAC;IACpC,CAAC,YAAY,EAAE,WAAW,CAAC;IAC3B,CAAC,YAAY,EAAE,YAAY,CAAC;IAC5B,CAAC,oBAAoB,EAAE,YAAY,CAAC;IAEpC,oBAAoB;IACpB,CAAC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,OAAO,eAAe,CAAC,GAAG,CAAC,UAAU,CAAC,IAAI,eAAe,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC;AAC9E,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,kBAAkB,CAAC,IAAY,EAAE,KAAa;IAC1D,MAAM,UAAU,GAAG,iBAAiB,CAAC,IAAI,CAAC,CAAC;IAC3C,OAAO,UAAU,CAAC,KAAK,CAAC,IAAI,IAAI,CAAC;AACrC,CAAC"}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @ifc-lite/parser - Main parser interface
|
|
3
|
-
*/
|
|
4
|
-
export { StepTokenizer } from './tokenizer.js';
|
|
5
|
-
export { EntityIndexBuilder } from './entity-index.js';
|
|
6
|
-
export { EntityExtractor } from './entity-extractor.js';
|
|
7
|
-
export { PropertyExtractor } from './property-extractor.js';
|
|
8
|
-
export { QuantityExtractor } from './quantity-extractor.js';
|
|
9
|
-
export { RelationshipExtractor } from './relationship-extractor.js';
|
|
10
|
-
export { StyleExtractor } from './style-extractor.js';
|
|
11
|
-
export { SpatialHierarchyBuilder } from './spatial-hierarchy-builder.js';
|
|
12
|
-
export { ColumnarParser, type IfcDataStore } from './columnar-parser.js';
|
|
13
|
-
export { extractMaterials, getMaterialForElement, getMaterialNameForElement, type MaterialsData, type Material, type MaterialLayer, type MaterialLayerSet } from './material-extractor.js';
|
|
14
|
-
export { extractGeoreferencing, transformToWorld, transformToLocal, getCoordinateSystemDescription, type GeoreferenceInfo, type MapConversion, type ProjectedCRS } from './georef-extractor.js';
|
|
15
|
-
export { extractClassifications, getClassificationsForElement, getClassificationCodeForElement, getClassificationPath, groupElementsByClassification, type ClassificationsData, type Classification, type ClassificationReference } from './classification-extractor.js';
|
|
16
|
-
export { SCHEMA_REGISTRY, getEntityMetadata, getAllAttributesForEntity, getInheritanceChainForEntity, isKnownEntity } from './generated/schema-registry.js';
|
|
17
|
-
export type * from './generated/entities.js';
|
|
18
|
-
export * from './generated/enums.js';
|
|
19
|
-
export * from './types.js';
|
|
20
|
-
export * from './style-extractor.js';
|
|
21
|
-
export { getAttributeNames, getAttributeNameAt, isKnownType } from './ifc-schema.js';
|
|
22
|
-
import type { ParseResult } from './types.js';
|
|
23
|
-
import { type IfcDataStore } from './columnar-parser.js';
|
|
24
|
-
export interface ParseOptions {
|
|
25
|
-
onProgress?: (progress: {
|
|
26
|
-
phase: string;
|
|
27
|
-
percent: number;
|
|
28
|
-
}) => void;
|
|
29
|
-
}
|
|
30
|
-
/**
|
|
31
|
-
* Main parser class
|
|
32
|
-
*/
|
|
33
|
-
export declare class IfcParser {
|
|
34
|
-
/**
|
|
35
|
-
* Parse IFC file into structured data
|
|
36
|
-
*/
|
|
37
|
-
parse(buffer: ArrayBuffer, options?: ParseOptions): Promise<ParseResult>;
|
|
38
|
-
/**
|
|
39
|
-
* Parse IFC file into columnar data store (new format)
|
|
40
|
-
*/
|
|
41
|
-
parseColumnar(buffer: ArrayBuffer, options?: ParseOptions): Promise<IfcDataStore>;
|
|
42
|
-
}
|
|
43
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../parser/src/index.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAC/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AACvD,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAC5D,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAC5D,OAAO,EAAE,qBAAqB,EAAE,MAAM,6BAA6B,CAAC;AACpE,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,uBAAuB,EAAE,MAAM,gCAAgC,CAAC;AACzE,OAAO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