Table of content
3.7. PassengerBookingService

Schema Entities
Service Interfaces

Microservices
3.7.1 Passenger
Entity Name: Passenger
Data Schema: AirportLogistics
Master Service: PassengerBookingService

Microservices
Entity Properties
Pseudo code snippet
final Passenger passenger = (Passenger) this.callMicroservice(ServiceNames.PASSENGER_BOOKING_SERVICE + "/passenger/" + id, Passenger.class);
if (passenger != null) {
final Country nationality1 = (Country) this.callMicroservice(ServiceNames.COUNTRY_SERVICE + "/country/" + passenger.getNationality().getId(), Country.class);
if (nationality1 != null) {
}
}
return passenger;
3.7.2 PassengerBooking
Entity Name: PassengerBooking
Data Schema: AirportLogistics
Master Service: PassengerBookingService

Microservices
Entity Properties
Pseudo code snippet
final PassengerBooking passengerbooking = (PassengerBooking) this.callMicroservice(ServiceNames.PASSENGER_BOOKING_SERVICE + "/passengerbooking/" + id, PassengerBooking.class);
if (passengerbooking != null) {
final Seat seat1 = (Seat) this.callMicroservice(ServiceNames.PASSENGER_BOOKING_SERVICE + "/seat/" + passengerbooking.getSeat().getId(), Seat.class);
if (seat1 != null) {
final Airplane airplane2 = (Airplane) this.callMicroservice(ServiceNames.AIRPLANE_SERVICE + "/airplane/" + seat1.getAirplane().getId(), Airplane.class);
if (airplane2 != null) {
final Airline airline3 = (Airline) this.callMicroservice(ServiceNames.AIRPLANE_SERVICE + "/airline/" + airplane2.getAirline().getId(), Airline.class);
if (airline3 != null) {
}
final AirplaneType airplanetype4 = (AirplaneType) this.callMicroservice(ServiceNames.AIRPLANE_SERVICE + "/airplanetype/" + airplane2.getAirplaneType().getId(), AirplaneType.class);
if (airplanetype4 != null) {
final AirplaneProducer airplaneproducer5 = (AirplaneProducer) this.callMicroservice(ServiceNames.AIRPLANE_SERVICE + "/airplaneproducer/" + airplanetype4.getAirplaneProducer().getId(), AirplaneProducer.class);
if (airplaneproducer5 != null) {
}
}
}
final SeatCategory seatcategory6 = (SeatCategory) this.callMicroservice(ServiceNames.PASSENGER_BOOKING_SERVICE + "/seatcategory/" + seat1.getSeatCategory().getId(), SeatCategory.class);
if (seatcategory6 != null) {
}
}
final Flight flight7 = (Flight) this.callMicroservice(ServiceNames.AIRPORT_SERVICE + "/flight/" + passengerbooking.getFlight().getId(), Flight.class);
if (flight7 != null) {
final Gate departuregate8 = (Gate) this.callMicroservice(ServiceNames.AIRPORT_SERVICE + "/gate/" + flight7.getDepartureGate().getId(), Gate.class);
if (departuregate8 != null) {
final Terminal terminal9 = (Terminal) this.callMicroservice(ServiceNames.AIRPORT_SERVICE + "/terminal/" + departuregate8.getTerminal().getId(), Terminal.class);
if (terminal9 != null) {
final Airport airport10 = (Airport) this.callMicroservice(ServiceNames.AIRPORT_SERVICE + "/airport/" + terminal9.getAirport().getId(), Airport.class);
if (airport10 != null) {
final City city11 = (City) this.callMicroservice(ServiceNames.COUNTRY_SERVICE + "/city/" + airport10.getCity().getId(), City.class);
if (city11 != null) {
final Country country12 = (Country) this.callMicroservice(ServiceNames.COUNTRY_SERVICE + "/country/" + city11.getCountry().getId(), Country.class);
if (country12 != null) {
}
}
}
}
}
final Airplane airplane13 = (Airplane) this.callMicroservice(ServiceNames.AIRPLANE_SERVICE + "/airplane/" + flight7.getAirplane().getId(), Airplane.class);
if (airplane13 != null) {
final Airline airline14 = (Airline) this.callMicroservice(ServiceNames.AIRPLANE_SERVICE + "/airline/" + airplane13.getAirline().getId(), Airline.class);
if (airline14 != null) {
}
final AirplaneType airplanetype15 = (AirplaneType) this.callMicroservice(ServiceNames.AIRPLANE_SERVICE + "/airplanetype/" + airplane13.getAirplaneType().getId(), AirplaneType.class);
if (airplanetype15 != null) {
final AirplaneProducer airplaneproducer16 = (AirplaneProducer) this.callMicroservice(ServiceNames.AIRPLANE_SERVICE + "/airplaneproducer/" + airplanetype15.getAirplaneProducer().getId(), AirplaneProducer.class);
if (airplaneproducer16 != null) {
}
}
}
final FlightRoute flightroute17 = (FlightRoute) this.callMicroservice(ServiceNames.AIRPORT_SERVICE + "/flightroute/" + flight7.getFlightRoute().getId(), FlightRoute.class);
if (flightroute17 != null) {
final Airport destination18 = (Airport) this.callMicroservice(ServiceNames.AIRPORT_SERVICE + "/airport/" + flightroute17.getDestination().getId(), Airport.class);
if (destination18 != null) {
final City city19 = (City) this.callMicroservice(ServiceNames.COUNTRY_SERVICE + "/city/" + destination18.getCity().getId(), City.class);
if (city19 != null) {
final Country country20 = (Country) this.callMicroservice(ServiceNames.COUNTRY_SERVICE + "/country/" + city19.getCountry().getId(), Country.class);
if (country20 != null) {
}
}
}
final Airport source21 = (Airport) this.callMicroservice(ServiceNames.AIRPORT_SERVICE + "/airport/" + flightroute17.getSource().getId(), Airport.class);
if (source21 != null) {
final City city22 = (City) this.callMicroservice(ServiceNames.COUNTRY_SERVICE + "/city/" + source21.getCity().getId(), City.class);
if (city22 != null) {
final Country country23 = (Country) this.callMicroservice(ServiceNames.COUNTRY_SERVICE + "/country/" + city22.getCountry().getId(), Country.class);
if (country23 != null) {
}
}
}
}
final Gate arrivalgate24 = (Gate) this.callMicroservice(ServiceNames.AIRPORT_SERVICE + "/gate/" + flight7.getArrivalGate().getId(), Gate.class);
if (arrivalgate24 != null) {
final Terminal terminal25 = (Terminal) this.callMicroservice(ServiceNames.AIRPORT_SERVICE + "/terminal/" + arrivalgate24.getTerminal().getId(), Terminal.class);
if (terminal25 != null) {
final Airport airport26 = (Airport) this.callMicroservice(ServiceNames.AIRPORT_SERVICE + "/airport/" + terminal25.getAirport().getId(), Airport.class);
if (airport26 != null) {
final City city27 = (City) this.callMicroservice(ServiceNames.COUNTRY_SERVICE + "/city/" + airport26.getCity().getId(), City.class);
if (city27 != null) {
final Country country28 = (Country) this.callMicroservice(ServiceNames.COUNTRY_SERVICE + "/country/" + city27.getCountry().getId(), Country.class);
if (country28 != null) {
}
}
}
}
}
}
final Passenger passenger29 = (Passenger) this.callMicroservice(ServiceNames.PASSENGER_BOOKING_SERVICE + "/passenger/" + passengerbooking.getPassenger().getId(), Passenger.class);
if (passenger29 != null) {
final Country nationality30 = (Country) this.callMicroservice(ServiceNames.COUNTRY_SERVICE + "/country/" + passenger29.getNationality().getId(), Country.class);
if (nationality30 != null) {
}
}
}
return passengerbooking;
3.7.3 Seat
Entity Name: Seat
Data Schema: AirportLogistics
Master Service: PassengerBookingService

Microservices
Entity Properties
Pseudo code snippet
final Seat seat = (Seat) this.callMicroservice(ServiceNames.PASSENGER_BOOKING_SERVICE + "/seat/" + id, Seat.class);
if (seat != null) {
final Airplane airplane1 = (Airplane) this.callMicroservice(ServiceNames.AIRPLANE_SERVICE + "/airplane/" + seat.getAirplane().getId(), Airplane.class);
if (airplane1 != null) {
final Airline airline2 = (Airline) this.callMicroservice(ServiceNames.AIRPLANE_SERVICE + "/airline/" + airplane1.getAirline().getId(), Airline.class);
if (airline2 != null) {
}
final AirplaneType airplanetype3 = (AirplaneType) this.callMicroservice(ServiceNames.AIRPLANE_SERVICE + "/airplanetype/" + airplane1.getAirplaneType().getId(), AirplaneType.class);
if (airplanetype3 != null) {
final AirplaneProducer airplaneproducer4 = (AirplaneProducer) this.callMicroservice(ServiceNames.AIRPLANE_SERVICE + "/airplaneproducer/" + airplanetype3.getAirplaneProducer().getId(), AirplaneProducer.class);
if (airplaneproducer4 != null) {
}
}
}
final SeatCategory seatcategory5 = (SeatCategory) this.callMicroservice(ServiceNames.PASSENGER_BOOKING_SERVICE + "/seatcategory/" + seat.getSeatCategory().getId(), SeatCategory.class);
if (seatcategory5 != null) {
}
}
return seat;
3.7.4 SeatCategory
Entity Name: SeatCategory
Data Schema: AirportLogistics
Master Service: PassengerBookingService

Microservices
Entity Properties
Pseudo code snippet
final SeatCategory seatcategory = (SeatCategory) this.callMicroservice(ServiceNames.PASSENGER_BOOKING_SERVICE + "/seatcategory/" + id, SeatCategory.class);
if (seatcategory != null) {
}
return seatcategory;
Table of content