A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Documentation ▼
Installation
Manual
Models
Contributing
Wiki
Development ▼
API Docs
Issue Tracker
Merge Requests
API
Loading...
Searching...
No Matches
wimax-channel.h
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2007,2008 INRIA
3
*
4
* SPDX-License-Identifier: GPL-2.0-only
5
*
6
* Author: Jahanzeb Farooq <jahanzeb.farooq@sophia.inria.fr>
7
*/
8
9
#ifndef WIMAX_CHANNEL_H
10
#define WIMAX_CHANNEL_H
11
12
#include "
wimax-connection.h
"
13
14
#include "ns3/channel.h"
15
#include "ns3/log.h"
16
17
#include <list>
18
19
namespace
ns3
20
{
21
22
class
WimaxPhy;
23
class
Packet;
24
class
Position;
25
class
PacketBurst;
26
27
/**
28
* \ingroup wimax
29
* The channel object to attach Wimax NetDevices
30
*/
31
class
WimaxChannel
:
public
Channel
32
{
33
public
:
34
/**
35
* \brief Get the type ID.
36
* \return the object TypeId
37
*/
38
static
TypeId
GetTypeId
();
39
WimaxChannel
();
40
~WimaxChannel
()
override
;
41
/**
42
* \brief attach the channel to a physical layer of a device
43
* \param phy the physical layer to which the channel will be attached
44
*/
45
void
Attach
(
Ptr<WimaxPhy>
phy);
46
/**
47
* \return the number of attached devices
48
*/
49
std::size_t
GetNDevices
()
const override
;
50
/**
51
* \param i the ith device
52
* \return the ith attached device
53
*/
54
Ptr<NetDevice>
GetDevice
(std::size_t i)
const override
;
55
56
/**
57
* Assign a fixed random variable stream number to the random variables
58
* used by this model. Return the number of streams (possibly zero) that
59
* have been assigned.
60
*
61
* \param stream first stream index to use
62
* \return the number of stream indices assigned by this model
63
*/
64
virtual
int64_t
AssignStreams
(int64_t stream) = 0;
65
66
private
:
67
/**
68
* Attach a phy to the channel
69
* \param phy the phy object to attach
70
*/
71
virtual
void
DoAttach
(
Ptr<WimaxPhy>
phy) = 0;
72
73
/**
74
* Get number of devices on the channel
75
* \returns the number of devices
76
*/
77
virtual
std::size_t
DoGetNDevices
()
const
= 0;
78
/**
79
* Get device corresponding to index
80
* \param i the device index
81
* \returns the device
82
*/
83
virtual
Ptr<NetDevice>
DoGetDevice
(std::size_t i)
const
= 0;
84
};
85
86
}
// namespace ns3
87
88
#endif
/* WIMAX_CHANNEL_H */
ns3::Channel
Abstract Channel Base Class.
Definition
channel.h:34
ns3::Ptr
Smart pointer class similar to boost::intrusive_ptr.
Definition
mpi-test-fixtures.h:37
ns3::TypeId
a unique identifier for an interface.
Definition
type-id.h:48
ns3::WimaxChannel
The channel object to attach Wimax NetDevices.
Definition
wimax-channel.h:32
ns3::WimaxChannel::WimaxChannel
WimaxChannel()
Definition
wimax-channel.cc:30
ns3::WimaxChannel::GetNDevices
std::size_t GetNDevices() const override
Definition
wimax-channel.cc:45
ns3::WimaxChannel::GetTypeId
static TypeId GetTypeId()
Get the type ID.
Definition
wimax-channel.cc:24
ns3::WimaxChannel::DoGetNDevices
virtual std::size_t DoGetNDevices() const =0
Get number of devices on the channel.
ns3::WimaxChannel::AssignStreams
virtual int64_t AssignStreams(int64_t stream)=0
Assign a fixed random variable stream number to the random variables used by this model.
ns3::WimaxChannel::Attach
void Attach(Ptr< WimaxPhy > phy)
attach the channel to a physical layer of a device
Definition
wimax-channel.cc:39
ns3::WimaxChannel::~WimaxChannel
~WimaxChannel() override
Definition
wimax-channel.cc:34
ns3::WimaxChannel::DoAttach
virtual void DoAttach(Ptr< WimaxPhy > phy)=0
Attach a phy to the channel.
ns3::WimaxChannel::DoGetDevice
virtual Ptr< NetDevice > DoGetDevice(std::size_t i) const =0
Get device corresponding to index.
ns3::WimaxChannel::GetDevice
Ptr< NetDevice > GetDevice(std::size_t i) const override
Definition
wimax-channel.cc:51
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
wimax-connection.h
src
wimax
model
wimax-channel.h
Generated on Fri Nov 8 2024 13:59:09 for ns-3 by
1.11.0