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
bs-uplink-scheduler.cc
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
#include "
bs-uplink-scheduler.h
"
10
11
#include "
bandwidth-manager.h
"
12
#include "
bs-link-manager.h
"
13
#include "
bs-net-device.h
"
14
#include "
burst-profile-manager.h
"
15
#include "
cid.h
"
16
#include "
service-flow-record.h
"
17
#include "
service-flow.h
"
18
#include "
ss-manager.h
"
19
#include "
ss-record.h
"
20
21
#include "ns3/log.h"
22
#include "ns3/simulator.h"
23
#include "ns3/uinteger.h"
24
25
namespace
ns3
26
{
27
28
NS_LOG_COMPONENT_DEFINE
(
"UplinkScheduler"
);
29
30
NS_OBJECT_ENSURE_REGISTERED
(
UplinkScheduler
);
31
32
UplinkScheduler::UplinkScheduler
()
33
:
m_bs
(nullptr),
34
m_timeStampIrInterval
(),
35
m_nrIrOppsAllocated
(0),
36
m_isIrIntrvlAllocated
(false),
37
m_isInvIrIntrvlAllocated
(false),
38
m_dcdTimeStamp
(
Simulator
::
Now
()),
39
m_ucdTimeStamp
(
Simulator
::
Now
())
40
{
41
}
42
43
UplinkScheduler::UplinkScheduler
(
Ptr<BaseStationNetDevice>
bs)
44
:
m_bs
(bs),
45
m_timeStampIrInterval
(),
46
m_nrIrOppsAllocated
(0),
47
m_isIrIntrvlAllocated
(false),
48
m_isInvIrIntrvlAllocated
(false),
49
m_dcdTimeStamp
(
Simulator
::
Now
()),
50
m_ucdTimeStamp
(
Simulator
::
Now
())
51
{
52
}
53
54
UplinkScheduler::~UplinkScheduler
()
55
{
56
m_bs
=
nullptr
;
57
m_uplinkAllocations
.clear();
58
}
59
60
void
61
UplinkScheduler::InitOnce
()
62
{
63
}
64
65
TypeId
66
UplinkScheduler::GetTypeId
()
67
{
68
static
TypeId
tid =
TypeId
(
"ns3::UplinkScheduler"
).
SetParent
<
Object
>().SetGroupName(
"Wimax"
);
69
return
tid;
70
}
71
72
uint8_t
73
UplinkScheduler::GetNrIrOppsAllocated
()
const
74
{
75
return
m_nrIrOppsAllocated
;
76
}
77
78
void
79
UplinkScheduler::SetNrIrOppsAllocated
(uint8_t nrIrOppsAllocated)
80
{
81
m_nrIrOppsAllocated
= nrIrOppsAllocated;
82
}
83
84
bool
85
UplinkScheduler::GetIsIrIntrvlAllocated
()
const
86
{
87
return
m_isIrIntrvlAllocated
;
88
}
89
90
void
91
UplinkScheduler::SetIsIrIntrvlAllocated
(
bool
isIrIntrvlAllocated)
92
{
93
m_isIrIntrvlAllocated
= isIrIntrvlAllocated;
94
}
95
96
bool
97
UplinkScheduler::GetIsInvIrIntrvlAllocated
()
const
98
{
99
return
m_isInvIrIntrvlAllocated
;
100
}
101
102
void
103
UplinkScheduler::SetIsInvIrIntrvlAllocated
(
bool
isInvIrIntrvlAllocated)
104
{
105
m_isInvIrIntrvlAllocated
= isInvIrIntrvlAllocated;
106
}
107
108
Time
109
UplinkScheduler::GetDcdTimeStamp
()
const
110
{
111
return
m_dcdTimeStamp
;
112
}
113
114
void
115
UplinkScheduler::SetDcdTimeStamp
(
Time
dcdTimeStamp)
116
{
117
m_dcdTimeStamp
= dcdTimeStamp;
118
}
119
120
Time
121
UplinkScheduler::GetUcdTimeStamp
()
const
122
{
123
return
m_ucdTimeStamp
;
124
}
125
126
void
127
UplinkScheduler::SetUcdTimeStamp
(
Time
ucdTimeStamp)
128
{
129
m_ucdTimeStamp
= ucdTimeStamp;
130
}
131
132
std::list<OfdmUlMapIe>
133
UplinkScheduler::GetUplinkAllocations
()
const
134
{
135
return
m_uplinkAllocations
;
136
}
137
138
Time
139
UplinkScheduler::GetTimeStampIrInterval
()
140
{
141
return
m_timeStampIrInterval
;
142
}
143
144
void
145
UplinkScheduler::SetTimeStampIrInterval
(
Time
timeStampIrInterval)
146
{
147
m_timeStampIrInterval
= timeStampIrInterval;
148
}
149
150
Ptr<BaseStationNetDevice>
151
UplinkScheduler::GetBs
()
152
{
153
return
m_bs
;
154
}
155
156
void
157
UplinkScheduler::SetBs
(
Ptr<BaseStationNetDevice>
bs)
158
{
159
m_bs
= bs;
160
}
161
}
// namespace ns3
bandwidth-manager.h
bs-link-manager.h
bs-net-device.h
bs-uplink-scheduler.h
burst-profile-manager.h
cid.h
ns3::Object::Object
Object()
Constructor.
Definition
object.cc:96
ns3::Ptr
Smart pointer class similar to boost::intrusive_ptr.
Definition
ptr.h:66
ns3::Simulator
Control the scheduling of simulation events.
Definition
simulator.h:57
ns3::Time
Simulation virtual time values and global simulation resolution.
Definition
nstime.h:94
ns3::TypeId
a unique identifier for an interface.
Definition
type-id.h:49
ns3::TypeId::SetParent
TypeId SetParent(TypeId tid)
Set the parent TypeId.
Definition
type-id.cc:1001
ns3::UplinkScheduler
Virtual class for uplink scheduler.
Definition
bs-uplink-scheduler.h:34
ns3::UplinkScheduler::SetUcdTimeStamp
virtual void SetUcdTimeStamp(Time ucdTimeStamp)
Set UCD timestamp.
Definition
bs-uplink-scheduler.cc:127
ns3::UplinkScheduler::SetDcdTimeStamp
virtual void SetDcdTimeStamp(Time dcdTimeStamp)
Set DCD timestamp.
Definition
bs-uplink-scheduler.cc:115
ns3::UplinkScheduler::SetNrIrOppsAllocated
virtual void SetNrIrOppsAllocated(uint8_t nrIrOppsAllocated)
Set the number of IR opps allocated.
Definition
bs-uplink-scheduler.cc:79
ns3::UplinkScheduler::GetUplinkAllocations
virtual std::list< OfdmUlMapIe > GetUplinkAllocations() const
Definition
bs-uplink-scheduler.cc:133
ns3::UplinkScheduler::GetIsIrIntrvlAllocated
virtual bool GetIsIrIntrvlAllocated() const
Definition
bs-uplink-scheduler.cc:85
ns3::UplinkScheduler::SetBs
virtual void SetBs(Ptr< BaseStationNetDevice > bs)
Set base station device.
Definition
bs-uplink-scheduler.cc:157
ns3::UplinkScheduler::~UplinkScheduler
~UplinkScheduler() override
Definition
bs-uplink-scheduler.cc:54
ns3::UplinkScheduler::m_ucdTimeStamp
Time m_ucdTimeStamp
UCD timestamp.
Definition
bs-uplink-scheduler.h:233
ns3::UplinkScheduler::SetIsIrIntrvlAllocated
virtual void SetIsIrIntrvlAllocated(bool isIrIntrvlAllocated)
Set if the IR interval is allocated.
Definition
bs-uplink-scheduler.cc:91
ns3::UplinkScheduler::m_uplinkAllocations
std::list< OfdmUlMapIe > m_uplinkAllocations
uplink allocations
Definition
bs-uplink-scheduler.h:227
ns3::UplinkScheduler::GetNrIrOppsAllocated
virtual uint8_t GetNrIrOppsAllocated() const
Definition
bs-uplink-scheduler.cc:73
ns3::UplinkScheduler::m_timeStampIrInterval
Time m_timeStampIrInterval
timestamp IR interval
Definition
bs-uplink-scheduler.h:228
ns3::UplinkScheduler::m_dcdTimeStamp
Time m_dcdTimeStamp
DCD timestamp.
Definition
bs-uplink-scheduler.h:232
ns3::UplinkScheduler::GetIsInvIrIntrvlAllocated
virtual bool GetIsInvIrIntrvlAllocated() const
Definition
bs-uplink-scheduler.cc:97
ns3::UplinkScheduler::SetIsInvIrIntrvlAllocated
virtual void SetIsInvIrIntrvlAllocated(bool isInvIrIntrvlAllocated)
Set if the Inv IR interval is allocated.
Definition
bs-uplink-scheduler.cc:103
ns3::UplinkScheduler::InitOnce
virtual void InitOnce()=0
one time initialization function
Definition
bs-uplink-scheduler.cc:61
ns3::UplinkScheduler::m_isIrIntrvlAllocated
bool m_isIrIntrvlAllocated
is IR interval allocated
Definition
bs-uplink-scheduler.h:230
ns3::UplinkScheduler::GetTypeId
static TypeId GetTypeId()
Get the type ID.
Definition
bs-uplink-scheduler.cc:66
ns3::UplinkScheduler::m_nrIrOppsAllocated
uint8_t m_nrIrOppsAllocated
number IR opps allocated
Definition
bs-uplink-scheduler.h:229
ns3::UplinkScheduler::GetTimeStampIrInterval
virtual Time GetTimeStampIrInterval()
Definition
bs-uplink-scheduler.cc:139
ns3::UplinkScheduler::m_bs
Ptr< BaseStationNetDevice > m_bs
the base station
Definition
bs-uplink-scheduler.h:226
ns3::UplinkScheduler::GetDcdTimeStamp
virtual Time GetDcdTimeStamp() const
Definition
bs-uplink-scheduler.cc:109
ns3::UplinkScheduler::SetTimeStampIrInterval
virtual void SetTimeStampIrInterval(Time timeStampIrInterval)
Set timestamp IR interval.
Definition
bs-uplink-scheduler.cc:145
ns3::UplinkScheduler::GetBs
virtual Ptr< BaseStationNetDevice > GetBs()
Definition
bs-uplink-scheduler.cc:151
ns3::UplinkScheduler::GetUcdTimeStamp
virtual Time GetUcdTimeStamp() const
Definition
bs-uplink-scheduler.cc:121
ns3::UplinkScheduler::UplinkScheduler
UplinkScheduler()
Definition
bs-uplink-scheduler.cc:32
ns3::UplinkScheduler::m_isInvIrIntrvlAllocated
bool m_isInvIrIntrvlAllocated
is Inv IR interval allocated
Definition
bs-uplink-scheduler.h:231
NS_LOG_COMPONENT_DEFINE
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
Definition
log.h:191
NS_OBJECT_ENSURE_REGISTERED
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
Definition
object-base.h:35
ns3::Now
Time Now()
create an ns3::Time instance which contains the current simulation time.
Definition
simulator.cc:294
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
service-flow-record.h
service-flow.h
ss-manager.h
ss-record.h
src
wimax
model
bs-uplink-scheduler.cc
Generated on Wed Jun 11 2025 13:15:42 for ns-3 by
1.13.2