Phase A: generierter Dart-Client + DI-Foundation für Rust-Backend
OpenAPI-Generator-Setup: - tool/generate_api_client.sh: Direkter Aufruf der openapi-generator-cli.jar (Java-CLI statt Dart-build_runner-Integration — vermeidet die analyzer-/source_gen-Version-Hölle mit json_serializable) - tool/fetch_openapi_generator.sh: lädt die JAR (29 MB) nach (gitignored) - openapi/holzleitner.json: Snapshot der Backend-Spec für reproduzierbare Generation - packages/holzleitner_api/: generiertes Dart-Sub-Package (built_value + dio), per path-dep im Haupt-pubspec eingehängt Netzwerk-Layer (lib/data/network/): - BackendConfig: API- und Keycloak-Endpoints für Local-Dev (localhost wegen Keycloak-iss-Claim). - AuthTokenProvider-Schnittstelle. - DevPasswordGrantTokenProvider: Phase-A-Provider via Keycloak password-grant, Token-Caching mit Expiry-Check (Phase B ersetzt das durch flutter_appauth PKCE). - HolzleitnerAuthInterceptor: dynamischer Bearer-Inject pro Request. - HolzleitnerApiFactory: baut die generierte HolzleitnerApi-Klasse mit unserem Interceptor statt der vier Default-Auth-Interceptors. - network_locator.registerNetworking(): get_it-Setup, in main() vor runApp() aufgerufen. Clean-Arch-Scaffolding (lib/data/, lib/domain/): - Verzeichnisstruktur für Phase C+D angelegt (mapper/, repository/, entity/, repository/) — befüllt sich in den Folge-Phasen. Smoke-Test: - tool/smoke_test_api.dart ruft /health (ungeschützt) und /me/cars (mit Bearer) via generiertem Client — grün gegen lokales Backend.
This commit is contained in:
158
packages/holzleitner_api/lib/src/model/scan_event.g.dart
Normal file
158
packages/holzleitner_api/lib/src/model/scan_event.g.dart
Normal file
@ -0,0 +1,158 @@
|
||||
// GENERATED CODE - DO NOT MODIFY BY HAND
|
||||
|
||||
part of 'scan_event.dart';
|
||||
|
||||
// **************************************************************************
|
||||
// BuiltValueGenerator
|
||||
// **************************************************************************
|
||||
|
||||
class _$ScanEvent extends ScanEvent {
|
||||
@override
|
||||
final AuditAction action;
|
||||
@override
|
||||
final String? actorCarId;
|
||||
@override
|
||||
final String clientScanId;
|
||||
@override
|
||||
final DateTime clientScannedAt;
|
||||
@override
|
||||
final String deliveryItemId;
|
||||
@override
|
||||
final String? reason;
|
||||
|
||||
factory _$ScanEvent([void Function(ScanEventBuilder)? updates]) =>
|
||||
(ScanEventBuilder()..update(updates))._build();
|
||||
|
||||
_$ScanEvent._(
|
||||
{required this.action,
|
||||
this.actorCarId,
|
||||
required this.clientScanId,
|
||||
required this.clientScannedAt,
|
||||
required this.deliveryItemId,
|
||||
this.reason})
|
||||
: super._();
|
||||
@override
|
||||
ScanEvent rebuild(void Function(ScanEventBuilder) updates) =>
|
||||
(toBuilder()..update(updates)).build();
|
||||
|
||||
@override
|
||||
ScanEventBuilder toBuilder() => ScanEventBuilder()..replace(this);
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) {
|
||||
if (identical(other, this)) return true;
|
||||
return other is ScanEvent &&
|
||||
action == other.action &&
|
||||
actorCarId == other.actorCarId &&
|
||||
clientScanId == other.clientScanId &&
|
||||
clientScannedAt == other.clientScannedAt &&
|
||||
deliveryItemId == other.deliveryItemId &&
|
||||
reason == other.reason;
|
||||
}
|
||||
|
||||
@override
|
||||
int get hashCode {
|
||||
var _$hash = 0;
|
||||
_$hash = $jc(_$hash, action.hashCode);
|
||||
_$hash = $jc(_$hash, actorCarId.hashCode);
|
||||
_$hash = $jc(_$hash, clientScanId.hashCode);
|
||||
_$hash = $jc(_$hash, clientScannedAt.hashCode);
|
||||
_$hash = $jc(_$hash, deliveryItemId.hashCode);
|
||||
_$hash = $jc(_$hash, reason.hashCode);
|
||||
_$hash = $jf(_$hash);
|
||||
return _$hash;
|
||||
}
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return (newBuiltValueToStringHelper(r'ScanEvent')
|
||||
..add('action', action)
|
||||
..add('actorCarId', actorCarId)
|
||||
..add('clientScanId', clientScanId)
|
||||
..add('clientScannedAt', clientScannedAt)
|
||||
..add('deliveryItemId', deliveryItemId)
|
||||
..add('reason', reason))
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
|
||||
class ScanEventBuilder implements Builder<ScanEvent, ScanEventBuilder> {
|
||||
_$ScanEvent? _$v;
|
||||
|
||||
AuditAction? _action;
|
||||
AuditAction? get action => _$this._action;
|
||||
set action(AuditAction? action) => _$this._action = action;
|
||||
|
||||
String? _actorCarId;
|
||||
String? get actorCarId => _$this._actorCarId;
|
||||
set actorCarId(String? actorCarId) => _$this._actorCarId = actorCarId;
|
||||
|
||||
String? _clientScanId;
|
||||
String? get clientScanId => _$this._clientScanId;
|
||||
set clientScanId(String? clientScanId) => _$this._clientScanId = clientScanId;
|
||||
|
||||
DateTime? _clientScannedAt;
|
||||
DateTime? get clientScannedAt => _$this._clientScannedAt;
|
||||
set clientScannedAt(DateTime? clientScannedAt) =>
|
||||
_$this._clientScannedAt = clientScannedAt;
|
||||
|
||||
String? _deliveryItemId;
|
||||
String? get deliveryItemId => _$this._deliveryItemId;
|
||||
set deliveryItemId(String? deliveryItemId) =>
|
||||
_$this._deliveryItemId = deliveryItemId;
|
||||
|
||||
String? _reason;
|
||||
String? get reason => _$this._reason;
|
||||
set reason(String? reason) => _$this._reason = reason;
|
||||
|
||||
ScanEventBuilder() {
|
||||
ScanEvent._defaults(this);
|
||||
}
|
||||
|
||||
ScanEventBuilder get _$this {
|
||||
final $v = _$v;
|
||||
if ($v != null) {
|
||||
_action = $v.action;
|
||||
_actorCarId = $v.actorCarId;
|
||||
_clientScanId = $v.clientScanId;
|
||||
_clientScannedAt = $v.clientScannedAt;
|
||||
_deliveryItemId = $v.deliveryItemId;
|
||||
_reason = $v.reason;
|
||||
_$v = null;
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
@override
|
||||
void replace(ScanEvent other) {
|
||||
_$v = other as _$ScanEvent;
|
||||
}
|
||||
|
||||
@override
|
||||
void update(void Function(ScanEventBuilder)? updates) {
|
||||
if (updates != null) updates(this);
|
||||
}
|
||||
|
||||
@override
|
||||
ScanEvent build() => _build();
|
||||
|
||||
_$ScanEvent _build() {
|
||||
final _$result = _$v ??
|
||||
_$ScanEvent._(
|
||||
action: BuiltValueNullFieldError.checkNotNull(
|
||||
action, r'ScanEvent', 'action'),
|
||||
actorCarId: actorCarId,
|
||||
clientScanId: BuiltValueNullFieldError.checkNotNull(
|
||||
clientScanId, r'ScanEvent', 'clientScanId'),
|
||||
clientScannedAt: BuiltValueNullFieldError.checkNotNull(
|
||||
clientScannedAt, r'ScanEvent', 'clientScannedAt'),
|
||||
deliveryItemId: BuiltValueNullFieldError.checkNotNull(
|
||||
deliveryItemId, r'ScanEvent', 'deliveryItemId'),
|
||||
reason: reason,
|
||||
);
|
||||
replace(_$result);
|
||||
return _$result;
|
||||
}
|
||||
}
|
||||
|
||||
// ignore_for_file: deprecated_member_use_from_same_package,type=lint
|
||||
Reference in New Issue
Block a user