![]() |
OpenSWMM Engine
6.0.0-alpha.1
Data-oriented, plugin-extensible SWMM Engine (6.0.0-alpha.1)
|
Internal shared helpers for C API impl files. More...
#include "SWMMEngine.hpp"#include "../../../include/openswmm/engine/openswmm_engine.h"#include <cstring>#include <algorithm>Go to the source code of this file.
Macros | |
| #define | CHECK_HANDLE(e) do { if (!(e)) return SWMM_ERR_BADHANDLE; } while(0) |
| #define | CHECK_INDEX(cond) do { if (!(cond)) return SWMM_ERR_BADINDEX; } while(0) |
| #define | CHECK_GEOMETRY(ctx) |
| Geometry/topology setters: only BUILDING or OPENED. | |
| #define | CHECK_INITIAL_COND(ctx) |
| Initial-condition setters: BUILDING, OPENED, or INITIALIZED. | |
| #define | CHECK_RUNNING(ctx) |
| Runtime forcing / state override: only RUNNING. | |
| #define | CHECK_READABLE(ctx) |
| Read-only access: any state where data exists (not CREATED, CLOSED, or ERROR) | |
Internal shared helpers for C API impl files.
NOT installed — used only by openswmm_*_impl.cpp files. Provides the opaque-handle cast and common guard macros.
| #define CHECK_GEOMETRY | ( | ctx | ) |
Geometry/topology setters: only BUILDING or OPENED.
| #define CHECK_HANDLE | ( | e | ) | do { if (!(e)) return SWMM_ERR_BADHANDLE; } while(0) |
| #define CHECK_INDEX | ( | cond | ) | do { if (!(cond)) return SWMM_ERR_BADINDEX; } while(0) |
| #define CHECK_INITIAL_COND | ( | ctx | ) |
Initial-condition setters: BUILDING, OPENED, or INITIALIZED.
| #define CHECK_READABLE | ( | ctx | ) |
Read-only access: any state where data exists (not CREATED, CLOSED, or ERROR)
| #define CHECK_RUNNING | ( | ctx | ) |
Runtime forcing / state override: only RUNNING.