Dynamical system model
Loading...
Searching...
No Matches
dsm::Itinerary Class Reference

The Itinerary class represents an itinerary in the network. More...

#include <Itinerary.hpp>

Public Member Functions

 Itinerary (Id id, Id destination)
 Construct a new Itinerary object.
 
 Itinerary (Id id, Id destination, SparseMatrix< bool > path)
 Construct a new Itinerary object.
 
void setDestination (Id destination)
 Set the itinerary's destination.
 
void setPath (SparseMatrix< bool > path)
 Set the itinerary's path.
 
Id id () const
 Get the itinerary's id.
 
Id destination () const
 Get the itinerary's destination.
 
const SparseMatrix< bool > & path () const
 Get the itinerary's path.
 

Detailed Description

The Itinerary class represents an itinerary in the network.

Template Parameters
IdThe type of the itinerary's id. It must be an unsigned integral type.

Constructor & Destructor Documentation

◆ Itinerary() [1/2]

dsm::Itinerary::Itinerary ( Id id,
Id destination )

Construct a new Itinerary object.

Parameters
destinationThe itinerary's destination

◆ Itinerary() [2/2]

dsm::Itinerary::Itinerary ( Id id,
Id destination,
SparseMatrix< bool > path )

Construct a new Itinerary object.

Parameters
destinationThe itinerary's destination
pathAn adjacency matrix made by a SparseMatrix representing the itinerary's path

Member Function Documentation

◆ destination()

Id dsm::Itinerary::destination ( ) const
inline

Get the itinerary's destination.

Returns
Id, The itinerary's destination

◆ id()

Id dsm::Itinerary::id ( ) const
inline

Get the itinerary's id.

Returns
Id, The itinerary's id

◆ path()

const SparseMatrix< bool > & dsm::Itinerary::path ( ) const
inline

Get the itinerary's path.

Returns
SparseMatrix<Id, bool>, An adjacency matrix made by a SparseMatrix representing the itinerary's path

◆ setDestination()

void dsm::Itinerary::setDestination ( Id destination)

Set the itinerary's destination.

Parameters
destinationThe itinerary's destination

◆ setPath()

void dsm::Itinerary::setPath ( SparseMatrix< bool > path)

Set the itinerary's path.

Parameters
pathAn adjacency matrix made by a SparseMatrix representing the itinerary's path
Exceptions
std::invalid_argument,ifthe itinerary's source or destination is not in the path's

The documentation for this class was generated from the following files: