Faker C++
Loading...
Searching...
No Matches
airline.h
Go to the documentation of this file.
1#pragma once
2
3#include <string>
4#include <string_view>
5
6#include "faker-cxx/export.h"
7
9{
19FAKER_CXX_EXPORT std::string_view aircraftType();
20
21struct FAKER_CXX_EXPORT Airplane
22{
23 std::string_view name;
24 std::string_view iataTypeCode;
25};
26
36FAKER_CXX_EXPORT Airplane airplane();
37
38struct FAKER_CXX_EXPORT AirlineInfo
39{
40 std::string_view name;
41 std::string_view iataCode;
42};
43
53FAKER_CXX_EXPORT AirlineInfo airline();
54
55struct FAKER_CXX_EXPORT Airport
56{
57 std::string_view name;
58 std::string_view iataCode;
59};
60
70FAKER_CXX_EXPORT Airport airport();
71
72enum class AircraftType
73{
77};
78
90FAKER_CXX_EXPORT std::string seat(AircraftType aircraftType);
91
102FAKER_CXX_EXPORT std::string recordLocator(bool allowNumerics = false);
103
119FAKER_CXX_EXPORT std::string flightNumber(bool addLeadingZeros = false, unsigned int length = 4);
120
121struct FAKER_CXX_EXPORT Range
122{
123 unsigned int min;
124 unsigned int max;
125};
126
142FAKER_CXX_EXPORT std::string flightNumberByRange(bool addLeadingZeros = false, Range length = {1, 4});
143}
Definition airline.h:9
FAKER_CXX_EXPORT Airplane airplane()
Get a random airplane.
FAKER_CXX_EXPORT std::string_view aircraftType()
Get a random aircraft type.
FAKER_CXX_EXPORT Airport airport()
Get a random airport.
FAKER_CXX_EXPORT std::string recordLocator(bool allowNumerics=false)
Get a random record location.
AircraftType
Definition airline.h:73
FAKER_CXX_EXPORT std::string flightNumberByRange(bool addLeadingZeros=false, Range length={1, 4})
Get a random flight number from given length.
FAKER_CXX_EXPORT std::string seat(AircraftType aircraftType)
Get a random seat by aircraft type.
FAKER_CXX_EXPORT AirlineInfo airline()
Get a random airline.
FAKER_CXX_EXPORT std::string flightNumber(bool addLeadingZeros=false, unsigned int length=4)
Get a random flight number from given length.
Definition airline.h:39
std::string_view name
Definition airline.h:40
std::string_view iataCode
Definition airline.h:41
Definition airline.h:22
std::string_view name
Definition airline.h:23
std::string_view iataTypeCode
Definition airline.h:24
Definition airline.h:56
std::string_view iataCode
Definition airline.h:58
std::string_view name
Definition airline.h:57
Definition airline.h:122
unsigned int min
Definition airline.h:123
unsigned int max
Definition airline.h:124