Merges multiple TypeMappers instances into a single one whose tables are
the union of the delegates'. Earlier delegates take precedence on regex
conflicts because mapper lookup is first-match-wins and addAll keeps the
first inserted entry per key when merging into the buffer in order.
Firestore-specific type mappers. Currently covers cloud_firestore's
Timestamp only; future PG_/SQLITE_-style dialect families will live in
sibling classes (DartPostgresTypeMappers, DartSqliteTypeMappers, etc.) and
be composed alongside DartCoreTypeMappers at generation time.
Per-field opt-in mappers that emit json_serializable-style direct as
casts instead of the defensive letOrNull chain used by
DartCoreTypeMappers. Throws a TypeError on shape mismatch (caught by
the generated fromJsonOrNull try/catch and turned into a null model).
Broker-agnostic version of generateDartModelsGemeni. Pick the provider
at the CLI with --broker openai|anthropic|gemini. API keys come from
--api-key or, when absent, from the broker-specific env var via
EnvKeyResolver. The model id defaults to the first model the broker
lists for the resolved key, so common cases work with zero flags.
Reads a DBML file (one or many Table blocks, optional enum blocks and
trailing Ref: lines) and emits one annotated abstract Dart class per
Table plus one Dart enum per DBML enum — the inverse of
generateDbml.
Walks every Dart file under inputPath, extracts each
@GenerateDartModel annotation, and writes one DBML file describing the
schema as a single Table per model plus trailing Ref: lines for the
foreign keys captured in references:.
Resolves every Dart enum declared in or reachable from the given source
files into a dartName → variants map. Used by the DBML emitter to turn
@enum-tagged field types (UserRoleType@enum) into proper DBML
Enum "<name>" { ... } blocks plus enum(<name>) column types instead
of the silent text fallback.