Maps SDK for C++ 1.0.0
Loading...
Searching...
No Matches
gem::vrp::Departure Class Reference

Defines a departure of an optimization or route. More...

Inheritance diagram for gem::vrp::Departure:
Collaboration diagram for gem::vrp::Departure:

Public Member Functions

 Departure ()=default
 Default constructor.
 Departure (const MiscLocation &depot)
 Constructs a Departure object initialized with depot information.
 Departure (const Departure &)=default
 Default copy constructor.
 Departure (Departure &&) noexcept=default
 Default move constructor.
Departureoperator= (const Departure &)=default
 Default copy assignment operator.
Departureoperator= (Departure &&) noexcept=default
 Default move assignment operator.
bool operator== (Departure const &departure) const
 Compares two Departure objects for equality.
bool operator!= (Departure const &departure) const
 Compares two Departure objects for equality.
const LargeInteger getDepotId () const noexcept
 Retrieves the depot ID associated with this departure.
DeparturesetDepotId (LargeInteger depotId) noexcept
 Sets the depot ID for this departure.
const StringRef getAlias () const noexcept
 Retrieves the alias of this departure.
DeparturesetAlias (const String &alias) noexcept
 Sets the alias for this departure.
const CoordinatesRef getCoordinates () const noexcept
 Retrieves the coordinates of the departure point.
CoordinatesRef getCoordinates ()
 Provides direct access to modify the coordinates of the departure point.
DeparturesetCoordinates (const Coordinates &coords) noexcept
 Sets the coordinates of the departure point.
const CoordinatesRef getMatchedCoordinates () const noexcept
 Retrieves the matched coordinates of the departure point.
const AddressInfoRef getAddress () const noexcept
 Retrieves the address associated with the departure point.
DeparturesetAddress (const AddressInfo &address) noexcept
 Sets the address for the departure point.
unsigned int getNumberOfPackages () const noexcept
 Retrieves the number of packages that must be delivered from this departure point.
float getWeight () const noexcept
 Retrieves the total weight of goods that must be delivered from this departure point.
float getCube () const noexcept
 Retrieves the cubic volume of goods that must be delivered from this departure point.
const TimeRef getDepartureTime () const noexcept
 Retrieves the scheduled departure time from this point.
unsigned int getTimeToNext () const noexcept
 Retrieves the estimated time to the next order from this departure point.
float getDistanceToNext () const noexcept
 Retrieves the distance to the next order from this departure point.

Detailed Description

Defines a departure of an optimization or route.

Implements share-read / copy-on-write Api object over IDeparture.

Constructor & Destructor Documentation

◆ Departure() [1/4]

gem::vrp::Departure::Departure ( )
default

Default constructor.

Initializes a new instance of the Departure class without setting any properties.

◆ Departure() [2/4]

gem::vrp::Departure::Departure ( const MiscLocation & depot)
inline

Constructs a Departure object initialized with depot information.

Parameters
depotA MiscLocation object containing the initial values for the departure's ID, alias, coordinates, and address.

◆ Departure() [3/4]

gem::vrp::Departure::Departure ( const Departure & )
default

Default copy constructor.

Creates a copy of an existing Departure object.

◆ Departure() [4/4]

gem::vrp::Departure::Departure ( Departure && )
defaultnoexcept

Default move constructor.

Moves an existing Departure object into a new instance.

Member Function Documentation

◆ getAddress()

const AddressInfoRef gem::vrp::Departure::getAddress ( ) const
inlinenoexcept

Retrieves the address associated with the departure point.

This address provides a human-readable location for the departure point, complementing the coordinates.

Returns
A constant reference to the AddressInfo object representing the departure address.

◆ getAlias()

const StringRef gem::vrp::Departure::getAlias ( ) const
inlinenoexcept

Retrieves the alias of this departure.

Returns
The alias as a StringRef.

◆ getCoordinates() [1/2]

CoordinatesRef gem::vrp::Departure::getCoordinates ( )
inline

Provides direct access to modify the coordinates of the departure point.

This allows for setting or updating the geographical location from which the vehicle departs.

Returns
A reference to the Coordinates object for modification.

◆ getCoordinates() [2/2]

const CoordinatesRef gem::vrp::Departure::getCoordinates ( ) const
inlinenoexcept

Retrieves the coordinates of the departure point.

These coordinates represent the geographical location from which the vehicle departs.

Returns
A constant reference to the Coordinates object representing the departure location.

◆ getCube()

float gem::vrp::Departure::getCube ( ) const
inlinenoexcept

Retrieves the cubic volume of goods that must be delivered from this departure point.

Returns
The cubic volume as a float, representing cubic meters or another unit of volume.

◆ getDepartureTime()

const TimeRef gem::vrp::Departure::getDepartureTime ( ) const
inlinenoexcept

Retrieves the scheduled departure time from this point.

This time indicates when the vehicle is expected to depart from the departure point.

Returns
A constant reference to the Time object representing the departure time.

◆ getDepotId()

const LargeInteger gem::vrp::Departure::getDepotId ( ) const
inlinenoexcept

Retrieves the depot ID associated with this departure.

Returns
The depot ID as a LargeInteger.

◆ getDistanceToNext()

float gem::vrp::Departure::getDistanceToNext ( ) const
inlinenoexcept

Retrieves the distance to the next order from this departure point.

This distance is used in routing and optimization calculations.

Returns
The distance to the next order as a float, in the unit set in the ConfigurationParameters.

◆ getMatchedCoordinates()

const CoordinatesRef gem::vrp::Departure::getMatchedCoordinates ( ) const
inlinenoexcept

Retrieves the matched coordinates of the departure point.

These coordinates represent the geographical matched location from which the vehicle departs.

Returns
A constant reference to the Coordinates object representing the departure location.

◆ getNumberOfPackages()

unsigned int gem::vrp::Departure::getNumberOfPackages ( ) const
inlinenoexcept

Retrieves the number of packages that must be delivered from this departure point.

Returns
The number of packages as an unsigned integer.

◆ getTimeToNext()

unsigned int gem::vrp::Departure::getTimeToNext ( ) const
inlinenoexcept

Retrieves the estimated time to the next order from this departure point.

This duration is used in planning to estimate arrival times at subsequent destinations.

Returns
The time to the next order as an unsigned integer, representing seconds.

◆ getWeight()

float gem::vrp::Departure::getWeight ( ) const
inlinenoexcept

Retrieves the total weight of goods that must be delivered from this departure point.

Returns
The total weight as a float, representing kilograms or another unit of weight.

◆ operator!=()

bool gem::vrp::Departure::operator!= ( Departure const & departure) const
inline

Compares two Departure objects for equality.

Parameters
departureAnother Departure object to compare against.
Returns
True if both Departure objects represent the same data, false otherwise.

◆ operator=() [1/2]

Departure & gem::vrp::Departure::operator= ( const Departure & )
default

Default copy assignment operator.

Replaces the contents of this object with a copy of another Departure object.

Returns
A reference to the current object.

◆ operator=() [2/2]

Departure & gem::vrp::Departure::operator= ( Departure && )
defaultnoexcept

Default move assignment operator.

Moves the contents of another Departure object into this one.

Returns
A reference to the current object.

◆ operator==()

bool gem::vrp::Departure::operator== ( Departure const & departure) const
inline

Compares two Departure objects for equality.

Parameters
departureAnother Departure object to compare against.
Returns
True if both Departure objects represent the same data, false otherwise.

◆ setAddress()

Departure & gem::vrp::Departure::setAddress ( const AddressInfo & address)
inlinenoexcept

Sets the address for the departure point.

Parameters
addressThe new address for the departure point.
Returns
A reference to this Departure object after the modification.

◆ setAlias()

Departure & gem::vrp::Departure::setAlias ( const String & alias)
inlinenoexcept

Sets the alias for this departure.

Parameters
aliasThe new alias as a String.
Returns
A reference to this Departure object after modification.

◆ setCoordinates()

Departure & gem::vrp::Departure::setCoordinates ( const Coordinates & coords)
inlinenoexcept

Sets the coordinates of the departure point.

Parameters
coordsThe new geographical coordinates for the departure point.
Returns
A reference to this Departure object after the modification.

◆ setDepotId()

Departure & gem::vrp::Departure::setDepotId ( LargeInteger depotId)
inlinenoexcept

Sets the depot ID for this departure.

Parameters
depotIdThe new depot ID as a LargeInteger.
Returns
A reference to this Departure object after modification.