A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
ul-job.cc
Go to the documentation of this file.
1/*
2 * Copyright (c)
3 *
4 * SPDX-License-Identifier: GPL-2.0-only
5 *
6 * Author: Juliana Freitag Borin, Flavio Kubota and Nelson L.
7 * S. da Fonseca - wimaxgroup@lrc.ic.unicamp.br
8 */
9
10#include "ul-job.h"
11
12#include <stdint.h>
13
14namespace ns3
15{
16
18 : m_deadline(Seconds(0)),
19 m_size(0)
20{
21}
22
24{
25}
26
29{
30 return m_ssRecord;
31}
32
33void
35{
36 m_ssRecord = ssRecord;
37}
38
41{
42 return m_schedulingType;
43}
44
45void
47{
48 m_schedulingType = schedulingType;
49}
50
53{
54 return m_type;
55}
56
57void
59{
60 m_type = type;
61}
62
65{
66 return m_serviceFlow;
67}
68
69void
71{
72 m_serviceFlow = serviceFlow;
73}
74
75Time
77{
78 return m_releaseTime;
79}
80
81void
83{
84 m_releaseTime = releaseTime;
85}
86
87Time
89{
90 return m_period;
91}
92
93void
95{
96 m_period = period;
97}
98
99Time
101{
102 return m_deadline;
103}
104
105void
107{
108 m_deadline = deadline;
109}
110
113{
114 return m_size;
115}
116
117void
119{
120 m_size = size;
121}
122
123/**
124 * \brief equality operator
125 * \param a first ULJob
126 * \param b second ULJob
127 * \returns true if equal
128 */
129bool
130operator==(const UlJob& a, const UlJob& b)
131{
132 return a.GetServiceFlow() == b.GetServiceFlow() && a.GetSsRecord() == b.GetSsRecord();
133}
134
138
139int
141{
142 return m_priority;
143}
144
145void
147{
148 m_priority = priority;
149}
150
153{
154 return m_job;
155}
156
157void
159{
160 m_job = job;
161}
162
163} // namespace ns3
void SetUlJob(Ptr< UlJob > job)
Set UL job.
Definition ul-job.cc:158
Ptr< UlJob > GetUlJob() const
Get UL job function.
Definition ul-job.cc:152
void SetPriority(int priority)
Set priority.
Definition ul-job.cc:146
int GetPriority() const
Get priority.
Definition ul-job.cc:140
PriorityUlJob()
this class implements an auxiliary struct to compute the priority of the rtPS and nrtPS in the interm...
Definition ul-job.cc:135
Ptr< UlJob > m_job
the job
Definition ul-job.h:188
int m_priority
the priority
Definition ul-job.h:187
Smart pointer class similar to boost::intrusive_ptr.
This class is used by the base station to store some information related to subscriber station in the...
Definition ss-record.h:35
This class implements service flows as described by the IEEE-802.16 standard.
SchedulingType
section 11.13.11 Service flow scheduling type, page 701
Simulation virtual time values and global simulation resolution.
Definition nstime.h:94
this class implements a structure to compute the priority of service flows
Definition ul-job.h:39
void SetSize(uint32_t size)
Set size.
Definition ul-job.cc:118
SSRecord * GetSsRecord() const
Get SS record.
Definition ul-job.cc:28
void SetServiceFlow(ServiceFlow *serviceFlow)
Set service flow.
Definition ul-job.cc:70
void SetSsRecord(SSRecord *ssRecord)
Set SS record.
Definition ul-job.cc:34
ServiceFlow * m_serviceFlow
service flow
Definition ul-job.h:150
ServiceFlow::SchedulingType GetSchedulingType() const
Get scheduling type.
Definition ul-job.cc:40
ReqType m_type
Type of request, DATA or Unicast req slots.
Definition ul-job.h:149
SSRecord * m_ssRecord
Pointer to SSRecord.
Definition ul-job.h:147
uint32_t m_size
Number of minislots requested.
Definition ul-job.h:144
void SetReleaseTime(Time releaseTime)
Set release time.
Definition ul-job.cc:82
Time GetReleaseTime() const
Get release time.
Definition ul-job.cc:76
Time m_deadline
Request should be satisfied by this time.
Definition ul-job.h:143
void SetSchedulingType(ServiceFlow::SchedulingType schedulingType)
Set scheduling type.
Definition ul-job.cc:46
uint32_t GetSize() const
Get size.
Definition ul-job.cc:112
void SetType(ReqType type)
Set type.
Definition ul-job.cc:58
void SetPeriod(Time period)
Set period.
Definition ul-job.cc:94
Time m_releaseTime
The time after which the job can be processed.
Definition ul-job.h:141
Time GetDeadline() const
Get deadline.
Definition ul-job.cc:100
Time GetPeriod() const
Get period.
Definition ul-job.cc:88
ServiceFlow * GetServiceFlow() const
Get service flow.
Definition ul-job.cc:64
ReqType GetType() const
Get type.
Definition ul-job.cc:52
ServiceFlow::SchedulingType m_schedulingType
Scheduling type of flow.
Definition ul-job.h:145
~UlJob() override
Definition ul-job.cc:23
Time m_period
For periodic jobs.
Definition ul-job.h:142
void SetDeadline(Time deadline)
Set deadline.
Definition ul-job.cc:106
Time Seconds(double value)
Construct a Time in the indicated unit.
Definition nstime.h:1308
Every class exported by the ns3 library is enclosed in the ns3 namespace.
bool operator==(const EventId &a, const EventId &b)
Definition event-id.h:155
ReqType
Request type enumeration.
Definition ul-job.h:29