OpenTTD Source 20260206-master-g4d4e37dbf1
DestinationID Struct Reference

Public Types

using BaseType = uint16_t

Public Member Functions

constexpr DestinationID (size_t index)
constexpr DestinationID (DepotID depot)
constexpr DestinationID (StationID station)
constexpr DepotID ToDepotID () const noexcept
constexpr StationID ToStationID () const noexcept
constexpr BaseType base () const noexcept
constexpr bool operator== (const DestinationID &destination) const
constexpr bool operator== (const StationID &station) const

Data Fields

BaseType value = 0

Detailed Description

Definition at line 21 of file order_type.h.

Member Typedef Documentation

◆ BaseType

using DestinationID::BaseType = uint16_t

Definition at line 22 of file order_type.h.

Constructor & Destructor Documentation

◆ DestinationID() [1/3]

DestinationID::DestinationID ( size_t index)
inlineconstexpr

Definition at line 26 of file order_type.h.

◆ DestinationID() [2/3]

DestinationID::DestinationID ( DepotID depot)
inlineconstexpr

Definition at line 27 of file order_type.h.

◆ DestinationID() [3/3]

DestinationID::DestinationID ( StationID station)
inlineconstexpr

Definition at line 28 of file order_type.h.

Member Function Documentation

◆ base()

BaseType DestinationID::base ( ) const
inlineconstexprnoexcept

Definition at line 32 of file order_type.h.

◆ operator==() [1/2]

bool DestinationID::operator== ( const DestinationID & destination) const
inlineconstexpr

Definition at line 34 of file order_type.h.

◆ operator==() [2/2]

bool DestinationID::operator== ( const StationID & station) const
inlineconstexpr

Definition at line 35 of file order_type.h.

◆ ToDepotID()

DepotID DestinationID::ToDepotID ( ) const
inlineconstexprnoexcept

Definition at line 30 of file order_type.h.

◆ ToStationID()

StationID DestinationID::ToStationID ( ) const
inlineconstexprnoexcept

Definition at line 31 of file order_type.h.

Field Documentation

◆ value

BaseType DestinationID::value = 0

Definition at line 23 of file order_type.h.


The documentation for this struct was generated from the following file: