NeTrainSim 0.1.1 beta
The Open-Source Network Trains Simulator
 
Loading...
Searching...
No Matches
netlink.h File Reference

This file contains the declaration of the NetLink class. More...

#include <string>
#include <iostream>
#include <map>
#include "../util/vector.h"
#include <memory>

Go to the source code of this file.

Classes

class  NetLink
 The NetLink class represents a network link in a simulation. More...
 

Functions

ostream & operator<< (ostream &ostr, const NetLink &link)
 Overloaded ostream operator for printing the NetLink object.
 

Detailed Description

This file contains the declaration of the NetLink class.

The NetLink class represents a network link in a simulation. It stores information about the link, such as its ID, starting and ending nodes, length, speed, grade, etc. The NetLink class is used in conjunction with other classes, such as NetNode and Train, to simulate train movement on a network. It also includes static variables and methods to keep track of the number of links in the simulator. The NetLink class is intended to be used as part of a network simulation system. It is designed to work with other classes and data structures in the simulation. The NetLink class can be used in a C++ application. Note: The implementation of some methods is not provided in this declaration file. They should be implemented separately in a corresponding source file.

Author
Ahmed Aredah
Version
0.1
Date
6/7/2023

Function Documentation

◆ operator<<()

ostream & operator<< ( ostream &  ostr,
const NetLink link 
)

Overloaded ostream operator for printing the NetLink object.

Parameters
ostrThe output stream object.
linkThe NetLink object to be printed.
Returns
The output stream object.