[B5] IFC-Export nach Rust: ifc_export.rs schreibt die STEP-Datei
TS (exportIfc.ts) sammelt nur noch Bauteile und Geometrie als flachen Puffer, Rust (src-tauri/fileio/src/ifc_export.rs, Format-Modul pkgFileIo) baut Entitäten, GUIDs, Typen mit Materialschichten, Psets, Beziehungen, Räume, Georeferenz und die \X2\/\X4\-Kodierung. TS-STEP-Erzeugung gelöscht; ifcGuid/ifcString sind Fassaden. exportIfcSpf bleibt synchron, verlangt aber das geladene Format-Modul (Dialog und CLI laden per loadFileio, Tests per fileioWasm.setup). Golden-Vergleich gegen die TS-Fassung (45 Exporte): zeichengleich bis auf Zeitstempel. Rust-Tests: Zahlen/Strings/GUIDs, Wohlgeformtheit, Fehlerpfade ohne Panic. Claude-Session: https://claude.ai/code/session_01NTYBZBvLYCtugMJoKXaB67
This commit is contained in:
10 files changed
+2117
-717
No files matched your search
@@ -22,6 +22,7 @@ import { distinctImportLayers, planImportCategories } from "../io/dxfToDrawings"
|
||||
import type { ImportDecision } from "../ui/ImportDialog";
|
||||
import { exportScheduleCsv } from "../export/exportSchedule";
|
||||
import { exportIfcSpf } from "../export/exportIfc";
|
||||
import { loadFileio } from "../engine/fileioWasm";
|
||||
import { exportProjectStep } from "../export/exportStep";
|
||||
import { exportObj, exportStl } from "../export/exportMesh";
|
||||
import type { ExportSaveFormat } from "../ui/ExportSaveDialog";
|
||||
@@ -503,7 +504,10 @@ export function useProjectFileActions(
|
||||
downloadTextFile("" + exportScheduleCsv(project), filename, "text/csv;charset=utf-8;");
|
||||
break;
|
||||
case "ifc":
|
||||
downloadTextFile(exportIfcSpf(project), filename);
|
||||
// IFC schreibt Rust (Format-Modul pkgFileIo, wird beim ersten Export nachgeladen).
|
||||
void loadFileio()
|
||||
.then(() => downloadTextFile(exportIfcSpf(project), filename))
|
||||
.catch((e) => notify(`${t("ifc.export.failed")}: ${e instanceof Error ? e.message : String(e)}`, "error"));
|
||||
break;
|
||||
case "obj":
|
||||
downloadTextFile(exportObj(project), filename);
|
||||
|
||||
Reference in new issue
Block a user