IssuingTransactionFlightDataLeg.fromJson constructor
IssuingTransactionFlightDataLeg.fromJson(
- Object? json
Implementation
factory IssuingTransactionFlightDataLeg.fromJson(Object? json) {
final map = (json as Map).cast<String, Object?>();
return IssuingTransactionFlightDataLeg(
arrivalAirportCode: map['arrival_airport_code'] == null
? null
: (map['arrival_airport_code'] as String),
carrier: map['carrier'] == null ? null : (map['carrier'] as String),
departureAirportCode: map['departure_airport_code'] == null
? null
: (map['departure_airport_code'] as String),
flightNumber: map['flight_number'] == null
? null
: (map['flight_number'] as String),
serviceClass: map['service_class'] == null
? null
: (map['service_class'] as String),
stopoverAllowed: map['stopover_allowed'] == null
? null
: (map['stopover_allowed'] as bool),
);
}