Airline pilots take turns using the bathroom nearest the cockpit during a flight. There are no bathrooms installed in the cockpit. For airplanes with a single pilot, diapers, catheters, or collection devices are used if they are unable to land to use the airport bathroom.