Stateless reader for the [2D_*] mesh sections of a SWMM .inp (inline or via [2D_MESH_FILE]), the counterpart of InpMeshWriter.
More...
#include <mesh/inpmeshreader.h>
Static Public Member Functions | |
| static InpMeshReadResult | read (const QString &inpPath) |
| Read inline/native-sidecar mesh data and resolve edge/infiltration overlays into owned values. | |
Stateless reader for the [2D_*] mesh sections of a SWMM .inp (inline or via [2D_MESH_FILE]), the counterpart of InpMeshWriter.
Its single static member holds no state between calls. Values are returned in authored units with no SI conversion or reprojection.
|
staticnodiscard |
Read inline/native-sidecar mesh data and resolve edge/infiltration overlays into owned values.
| [in] | inpPath | Borrowed SWMM input pathname, unchanged; QFile reads whole UTF-8 text read only. Relative FILE references resolve against its directory; native [2D_*] sidecar grammar is expected, not SMS cards even when both extensions are .2dm. |
Look up the 2D mesh associated with inpPath.
A nonempty external mesh reference selects that sidecar exclusively; unreadable references are errors and readable references without complete geometry return no mesh. Inline mesh data is selected only when there is no nonempty reference.
Missing mesh data is not an error — hasMesh stays false and errorMsg is empty so callers can treat the absence as "no 2D layer to add". errorMsg is only populated when a malformed section or a broken external reference prevents parsing what was clearly intended to be a mesh.