= __Application_Name__ Protobuf Documentation :toc: == Booking.proto === Booking Represents the booking of a vehicle. Vehicles are some cool shit. But drive carefully! |=========================================== |*Field* |*Type* |*Label* |*Description* |vehicle_id | <> | |ID of booked vehicle. |customer_id | <> | |Customer that booked the vehicle. |status | <> | |Status of the booking. |confirmation_sent | <> | |Has booking confirmation been sent? |payment_received | <> | |Has payment been received? |color_preference | <> | |Color preference of the customer. |=========================================== === BookingStatus Represents the status of a vehicle booking. |=========================================== |*Field* |*Type* |*Label* |*Description* |id | <> | |Unique booking status ID. |description | <> | |Booking status description. E.g. "Active". |=========================================== === BookingStatusID Represents the booking status ID. |=========================================== |*Field* |*Type* |*Label* |*Description* |id | <> | |Unique booking status ID. |=========================================== === EmptyBookingMessage An empty message for testing == Customer.proto === Address Represents a mail address. |=========================================== |*Field* |*Type* |*Label* |*Description* |address_line_1 | <> |required |First address line. |address_line_2 | <> |optional |Second address line. |address_line_3 | <> |optional |Second address line. |town | <> |required |Address town. |county | <> |optional |Address county, if applicable. |country | <> |required |Address country. |=========================================== === Customer Represents a customer. |=========================================== |*Field* |*Type* |*Label* |*Description* |id | <> |required |Unique customer ID. |first_name | <> |required |Customer first name. |last_name | <> |required |Customer last name. |details | <> |optional |Customer details. |email_address | <> |optional |Customer e-mail address. |phone_number | <> |repeated |Customer phone numbers, primary first. |mail_addresses | <> |repeated |Customer mail addresses, primary first. |=========================================== == Vehicle.proto === Manufacturer Represents a manufacturer of cars. |=========================================== |*Field* |*Type* |*Label* |*Description* |id | <> |required |The unique manufacturer ID. |code | <> |required |A manufacturer code, e.g. "DKL4P". |details | <> |optional |Manufacturer details (minimum orders et.c.). |category | <> |optional |Manufacturer category. |=========================================== === Model Represents a vehicle model. |=========================================== |*Field* |*Type* |*Label* |*Description* |id | <> |required |The unique model ID. |model_code | <> |required |The car model code, e.g. "PZ003". |model_name | <> |required |The car model name, e.g. "Z3". |daily_hire_rate_dollars | <> |required |Dollars per day. |daily_hire_rate_cents | <> |required |Cents per day. |=========================================== === Vehicle Represents a vehicle that can be hired. |=========================================== |*Field* |*Type* |*Label* |*Description* |id | <> |required |Unique vehicle ID. |model | <> |required |Vehicle model. |reg_number | <> |required |Vehicle registration number. |mileage | <> |optional |Current vehicle mileage, if known. |category | <> |optional |Vehicle category. |daily_hire_rate_dollars | <> |optional |Dollars per day. |daily_hire_rate_cents | <> |optional |Cents per day. |=========================================== === Vehicle.Category Represents a vehicle category. E.g. "Sedan" or "Truck". |=========================================== |*Field* |*Type* |*Label* |*Description* |code | <> |required |Category code. E.g. "S". |description | <> |required |Category name. E.g. "Sedan". |=========================================== [[Manufacturer.Category]] === Manufacturer.Category Manufacturer category. A manufacturer may be either inhouse or external. |===================================== |*Name* |*Number* |*Description* |CATEGORY_INHOUSE |0 |The manufacturer is inhouse. |CATEGORY_EXTERNAL |1 |The manufacturer is external. |===================================== == Scalar Value Types |============================================================== |*.proto Type* |*Notes* |*C++ Type* |*Java Type* |*Python Type* |[[double]] (((double))) double | |double |double |float |[[float]] (((float))) float | |float |float |float |[[int32]] (((int32))) int32 |Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. |int32 |int |int |[[int64]] (((int64))) int64 |Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. |int64 |long |int/long |[[uint32]] (((uint32))) uint32 |Uses variable-length encoding. |uint32 |int |int/long |[[uint64]] (((uint64))) uint64 |Uses variable-length encoding. |uint64 |long |int/long |[[sint32]] (((sint32))) sint32 |Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. |int32 |int |int |[[sint64]] (((sint64))) sint64 |Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. |int64 |long |int/long |[[fixed32]] (((fixed32))) fixed32 |Always four bytes. More efficient than uint32 if values are often greater than 2^28. |uint32 |int |int |[[fixed64]] (((fixed64))) fixed64 |Always eight bytes. More efficient than uint64 if values are often greater than 2^56. |uint64 |long |int/long |[[sfixed32]] (((sfixed32))) sfixed32 |Always four bytes. |int32 |int |int |[[sfixed64]] (((sfixed64))) sfixed64 |Always eight bytes. |int64 |long |int/long |[[bool]] (((bool))) bool | |bool |boolean |boolean |[[string]] (((string))) string |A string must always contain UTF-8 encoded or 7-bit ASCII text. |string |String |str/unicode |[[bytes]] (((bytes))) bytes |May contain any arbitrary sequence of bytes. |string |ByteString |str |==============================================================