A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Portuguese
Docs ▼
Wiki
Manual
Models
Develop ▼
API
Bugs
API
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
bs-scheduler-simple.h
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2007,2008 INRIA
4
*
5
* This program is free software; you can redistribute it and/or modify
6
* it under the terms of the GNU General Public License version 2 as
7
* published by the Free Software Foundation;
8
*
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
13
*
14
* You should have received a copy of the GNU General Public License
15
* along with this program; if not, write to the Free Software
16
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17
*
18
* Author: Jahanzeb Farooq <jahanzeb.farooq@sophia.inria.fr>
19
*/
20
21
/* BS outbound scheduler as per in Section 6.3.5.1 */
22
23
#ifndef BS_SCHEDULER_SIMPLE_H
24
#define BS_SCHEDULER_SIMPLE_H
25
26
#include <list>
27
#include "ns3/packet.h"
28
#include "
wimax-phy.h
"
29
#include "ns3/packet-burst.h"
30
#include "
dl-mac-messages.h
"
31
#include "
bs-scheduler.h
"
32
33
namespace
ns3
{
34
35
class
BaseStationNetDevice;
36
class
GenericMacHeader;
37
class
WimaxConnection;
38
class
Cid;
39
43
class
BSSchedulerSimple
:
public
BSScheduler
44
{
45
public
:
46
BSSchedulerSimple
();
47
BSSchedulerSimple
(
Ptr<BaseStationNetDevice>
bs);
48
~BSSchedulerSimple
(
void
);
49
50
static
TypeId
GetTypeId
(
void
);
51
52
/*
53
* \brief This function returns all the downlink bursts scheduled for the next
54
* downlink sub-frame
55
* \returns all the downlink bursts scheduled for the next downlink sub-frame
56
*/
57
std::list<std::pair<OfdmDlMapIe*, Ptr<PacketBurst> > >*
58
GetDownlinkBursts
(
void
)
const
;
59
/*
60
* \brief This function adds a downlink burst to the list of downlink bursts
61
* scheduled for the next downlink sub-frame
62
* \param connection a pointer to connection in wich the burst will be sent
63
* \param diuc downlink iuc
64
* \param modulationType the modulation type of the burst
65
* \param burst the downlink burst to add to the downlink sub frame
66
*/
67
void
AddDownlinkBurst
(
Ptr<const WimaxConnection>
connection, uint8_t diuc,
68
WimaxPhy::ModulationType
modulationType,
Ptr<PacketBurst>
burst);
69
70
/*
71
* \brief the scheduling function for the downlink subframe.
72
*/
73
void
Schedule
(
void
);
74
/*
75
* \brief Selects a connection from the list of connections having packets to be sent .
76
* \param connection will point to a connection that have packets to be sent
77
* \returns false if no connection has packets to be sent, true otherwise
78
*/
79
bool
SelectConnection
(
Ptr<WimaxConnection>
&connection);
80
/*
81
* \brief Creates a downlink UGS burst
82
* \param serviceFlow the service flow of the burst
83
* \param modulationType the modulation type to be used for the burst
84
* \param availableSymbols maximum number of OFDM symbols to be used by the burst
85
* \returns a Burst (list of packets)
86
*/
87
Ptr<PacketBurst>
CreateUgsBurst
(
ServiceFlow
*serviceFlow,
88
WimaxPhy::ModulationType
modulationType, uint32_t availableSymbols);
89
90
private
:
91
std::list<std::pair<OfdmDlMapIe*, Ptr<PacketBurst> > > *
m_downlinkBursts
;
92
};
93
94
}
// namespace ns3
95
96
#endif
/* BS_SCHEDULER_SIMPLE_H */
ns3::Ptr
Smart pointer class similar to boost::intrusive_ptr.
Definition:
ptr.h:73
ns3::BSSchedulerSimple::CreateUgsBurst
Ptr< PacketBurst > CreateUgsBurst(ServiceFlow *serviceFlow, WimaxPhy::ModulationType modulationType, uint32_t availableSymbols)
Definition:
bs-scheduler-simple.cc:325
ns3::BSSchedulerSimple::SelectConnection
bool SelectConnection(Ptr< WimaxConnection > &connection)
Definition:
bs-scheduler-simple.cc:217
dl-mac-messages.h
ns3::BSSchedulerSimple::GetDownlinkBursts
std::list< std::pair< OfdmDlMapIe *, Ptr< PacketBurst > > > * GetDownlinkBursts(void) const
Definition:
bs-scheduler-simple.cc:80
ns3::BSSchedulerSimple::Schedule
void Schedule(void)
Definition:
bs-scheduler-simple.cc:106
ns3::BSSchedulerSimple::m_downlinkBursts
std::list< std::pair< OfdmDlMapIe *, Ptr< PacketBurst > > > * m_downlinkBursts
Definition:
bs-scheduler-simple.h:91
ns3::WimaxPhy::ModulationType
ModulationType
Definition:
wimax-phy.h:48
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::ServiceFlow
This class implements service flows as described by the IEEE-802.16 standard.
Definition:
service-flow.h:39
bs-scheduler.h
ns3::BSSchedulerSimple::AddDownlinkBurst
void AddDownlinkBurst(Ptr< const WimaxConnection > connection, uint8_t diuc, WimaxPhy::ModulationType modulationType, Ptr< PacketBurst > burst)
Definition:
bs-scheduler-simple.cc:85
ns3::BSSchedulerSimple::~BSSchedulerSimple
~BSSchedulerSimple(void)
Definition:
bs-scheduler-simple.cc:64
ns3::BSSchedulerSimple::BSSchedulerSimple
BSSchedulerSimple()
Definition:
bs-scheduler-simple.cc:50
ns3::BSScheduler
Definition:
bs-scheduler.h:43
wimax-phy.h
ns3::BSSchedulerSimple::GetTypeId
static TypeId GetTypeId(void)
Definition:
bs-scheduler-simple.cc:44
ns3::TypeId
a unique identifier for an interface.
Definition:
type-id.h:51
ns3::BSSchedulerSimple
Introspection did not find any typical Config paths.
Definition:
bs-scheduler-simple.h:43
src
wimax
model
bs-scheduler-simple.h
Generated on Thu Feb 5 2015 18:33:58 for ns-3 by
1.8.9.1