A Discrete-Event Network Simulator
API
lte-ccm-rrc-sap.h
Go to the documentation of this file.
1/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */
2/*
3 * Copyright (c) 2015 Danilo Abrignani
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: Danilo Abrignani <danilo.abrignani@unibo.it>
19 *
20 */
21
22#ifndef LTE_CCM_RRC_SAP_H
23#define LTE_CCM_RRC_SAP_H
24
25#include <ns3/lte-rrc-sap.h>
26#include <ns3/eps-bearer.h>
27#include <ns3/lte-enb-cmac-sap.h>
28#include <ns3/lte-mac-sap.h>
29#include <map>
30
31
32namespace ns3 {
33 class LteUeCmacSapProvider;
34 class UeManager;
35 class LteEnbCmacSapProvider;
36 class LteMacSapUser;
37 class LteRrcSap;
38
47{
48
50friend class UeManager;
52friend class LteMacSapUser;
53
54public:
55
56 virtual ~LteCcmRrcSapProvider ();
57
59 struct LcsConfig
60 {
64 };
65
77 virtual void ReportUeMeas (uint16_t rnti, LteRrcSap::MeasResults measResults) = 0;
78
84 virtual void AddUe (uint16_t rnti, uint8_t state) = 0;
85
92 virtual void AddLc (LteEnbCmacSapProvider::LcInfo lcInfo, LteMacSapUser* msu) = 0;
93
99 virtual void RemoveUe (uint16_t rnti) = 0;
100
119 virtual std::vector<LteCcmRrcSapProvider::LcsConfig> SetupDataRadioBearer (EpsBearer bearer, uint8_t bearerId, uint16_t rnti, uint8_t lcid, uint8_t lcGroup, LteMacSapUser *msu) = 0;
120
130 virtual std::vector<uint8_t> ReleaseDataRadioBearer (uint16_t rnti, uint8_t lcid) = 0;
131
140
141}; // end of class LteCcmRrcSapProvider
142
143
152{
154 friend class LteEnbRrc;
155public:
156 virtual ~LteCcmRrcSapUser ();
157
175
189 virtual void TriggerComponentCarrier (uint16_t rnti, uint16_t targetCellId) = 0;
190
196 virtual void AddLcs (std::vector<LteEnbRrcSapProvider::LogicalChannelConfig> lcConfig) = 0;
197
204 virtual void ReleaseLcs (uint16_t rnti, uint8_t lcid) = 0;
205
212 virtual Ptr<UeManager> GetUeManager (uint16_t rnti) = 0;
213
219 virtual void SetNumberOfComponentCarriers (uint16_t noOfComponentCarriers) = 0;
220
221}; // end of class LteCcmRrcSapUser
222
224template <class C>
226{
227public:
234
235 // inherited from LteCcmRrcSapProvider
236 virtual void ReportUeMeas (uint16_t rnti, LteRrcSap::MeasResults measResults);
237 virtual void AddUe (uint16_t rnti, uint8_t state);
238 virtual void AddLc (LteEnbCmacSapProvider::LcInfo lcInfo, LteMacSapUser* msu);
239 virtual void RemoveUe (uint16_t rnti);
240 virtual std::vector<LteCcmRrcSapProvider::LcsConfig> SetupDataRadioBearer (EpsBearer bearer, uint8_t bearerId, uint16_t rnti, uint8_t lcid, uint8_t lcGroup, LteMacSapUser *msu);
241 virtual std::vector<uint8_t> ReleaseDataRadioBearer (uint16_t rnti, uint8_t lcid);
243
244private:
246};
247
248template <class C>
250 : m_owner (owner)
251{
252}
253
254template <class C>
256{
257 m_owner->DoReportUeMeas (rnti, measResults);
258}
259
260template <class C>
261void MemberLteCcmRrcSapProvider<C>::AddUe (uint16_t rnti, uint8_t state)
262{
263 m_owner->DoAddUe (rnti, state);
264}
265
266template <class C>
268{
269 m_owner->DoAddLc (lcInfo, msu);
270}
271
272template <class C>
274{
275 m_owner->DoRemoveUe (rnti);
276}
277
278template <class C>
279std::vector<LteCcmRrcSapProvider::LcsConfig> MemberLteCcmRrcSapProvider<C>::SetupDataRadioBearer (EpsBearer bearer, uint8_t bearerId, uint16_t rnti, uint8_t lcid, uint8_t lcGroup, LteMacSapUser *msu)
280{
281 return m_owner->DoSetupDataRadioBearer (bearer, bearerId, rnti, lcid, lcGroup, msu);
282}
283
284template <class C>
285std::vector<uint8_t> MemberLteCcmRrcSapProvider<C>::ReleaseDataRadioBearer (uint16_t rnti, uint8_t lcid)
286{
287 return m_owner->DoReleaseDataRadioBearer (rnti, lcid);
288}
289
290template <class C>
292{
293 return m_owner->DoConfigureSignalBearer (lcInfo, rlcMacSapUser);
294}
295
296
298template <class C>
300{
301public:
307 MemberLteCcmRrcSapUser (C* owner);
308
309 // inherited from LteCcmRrcSapUser
310 virtual void AddLcs (std::vector<LteEnbRrcSapProvider::LogicalChannelConfig> lcConfig);
311 virtual void ReleaseLcs (uint16_t rnti, uint8_t lcid);
313 virtual void TriggerComponentCarrier (uint16_t rnti, uint16_t targetCellId);
314 virtual Ptr<UeManager> GetUeManager (uint16_t rnti);
315 virtual void SetNumberOfComponentCarriers (uint16_t noOfComponentCarriers);
316
317private:
319};
320
321template <class C>
323 : m_owner (owner)
324{
325}
326
327template <class C>
328void MemberLteCcmRrcSapUser<C>::AddLcs (std::vector<LteEnbRrcSapProvider::LogicalChannelConfig> lcConfig)
329{
330 NS_FATAL_ERROR ("Function should not be called because it is not implemented.");
331 //m_owner->DoAddLcs (lcConfig);
332}
333
334template <class C>
335void MemberLteCcmRrcSapUser<C>::ReleaseLcs (uint16_t rnti, uint8_t lcid)
336{
337 NS_FATAL_ERROR ("Function should not be called because it is not implemented.");
338 //m_owner->DoReleaseLcs (rnti, lcid);
339
340}
341
342template <class C>
343uint8_t
345{
346 return m_owner->DoAddUeMeasReportConfigForComponentCarrier (reportConfig);
347}
348
349
350template <class C>
351void
352MemberLteCcmRrcSapUser<C>::TriggerComponentCarrier (uint16_t rnti, uint16_t targetCellId)
353{
354 NS_FATAL_ERROR ("Function should not be called because it is not implemented.");
355}
356
357template <class C>
360{
361 return m_owner->GetUeManager (rnti);
362}
363
364template <class C>
365void
367{
368 return m_owner->DoSetNumberOfComponentCarriers (noOfComponentCarriers);
369}
370
371} // end of namespace ns3
372
373
374#endif /* LTE_CCM_RRC_SAP_H */
375
This class contains the specification of EPS Bearers.
Definition: eps-bearer.h:92
Service Access Point (SAP) offered by the Component Carrier Manager (CCM) instance to the eNodeB RRC ...
virtual void ReportUeMeas(uint16_t rnti, LteRrcSap::MeasResults measResults)=0
Reports UE measurements to the component carrier manager.
virtual std::vector< LteCcmRrcSapProvider::LcsConfig > SetupDataRadioBearer(EpsBearer bearer, uint8_t bearerId, uint16_t rnti, uint8_t lcid, uint8_t lcGroup, LteMacSapUser *msu)=0
Add a new Bearer for the Ue in the LteEnbComponentCarrierManager.
virtual void AddUe(uint16_t rnti, uint8_t state)=0
Add a new UE in the LteEnbComponentCarrierManager.
virtual LteMacSapUser * ConfigureSignalBearer(LteEnbCmacSapProvider::LcInfo lcInfo, LteMacSapUser *rlcMacSapUser)=0
Add the Signal Bearer for a specific Ue in LteEnbComponenCarrierManager.
virtual void AddLc(LteEnbCmacSapProvider::LcInfo lcInfo, LteMacSapUser *msu)=0
Add a new logical channel.
virtual void RemoveUe(uint16_t rnti)=0
Remove an existing UE.
virtual std::vector< uint8_t > ReleaseDataRadioBearer(uint16_t rnti, uint8_t lcid)=0
Release an existing Data Radio Bearer for a Ue in the LteEnbComponentCarrierManager.
Service Access Point (SAP) offered by the eNodeB RRC instance to the component carrier manager (CCM) ...
virtual uint8_t AddUeMeasReportConfigForComponentCarrier(LteRrcSap::ReportConfigEutra reportConfig)=0
Request a certain reporting configuration to be fulfilled by the UEs attached to the eNodeB entity.
virtual Ptr< UeManager > GetUeManager(uint16_t rnti)=0
Get UE manager by RNTI.
virtual void ReleaseLcs(uint16_t rnti, uint8_t lcid)=0
remove an existing LC
virtual void SetNumberOfComponentCarriers(uint16_t noOfComponentCarriers)=0
Set the number of component carriers.
virtual void AddLcs(std::vector< LteEnbRrcSapProvider::LogicalChannelConfig > lcConfig)=0
add a new Logical Channel (LC)
virtual void TriggerComponentCarrier(uint16_t rnti, uint16_t targetCellId)=0
Instruct the eNodeB RRC entity to prepare a component carrier.
The LTE Radio Resource Control entity at the eNB.
Definition: lte-enb-rrc.h:634
Service Access Point (SAP) offered by the MAC to the RLC See Femto Forum MAC Scheduler Interface Spec...
Definition: lte-mac-sap.h:96
MemberLteCcmRrcSapProvider class.
virtual void RemoveUe(uint16_t rnti)
Remove an existing UE.
virtual std::vector< LteCcmRrcSapProvider::LcsConfig > SetupDataRadioBearer(EpsBearer bearer, uint8_t bearerId, uint16_t rnti, uint8_t lcid, uint8_t lcGroup, LteMacSapUser *msu)
Add a new Bearer for the Ue in the LteEnbComponentCarrierManager.
virtual void AddLc(LteEnbCmacSapProvider::LcInfo lcInfo, LteMacSapUser *msu)
Add a new logical channel.
MemberLteCcmRrcSapProvider(C *owner)
Constructor.
virtual LteMacSapUser * ConfigureSignalBearer(LteEnbCmacSapProvider::LcInfo lcInfo, LteMacSapUser *rlcMacSapUser)
Add the Signal Bearer for a specific Ue in LteEnbComponenCarrierManager.
virtual void AddUe(uint16_t rnti, uint8_t state)
Add a new UE in the LteEnbComponentCarrierManager.
virtual void ReportUeMeas(uint16_t rnti, LteRrcSap::MeasResults measResults)
Reports UE measurements to the component carrier manager.
virtual std::vector< uint8_t > ReleaseDataRadioBearer(uint16_t rnti, uint8_t lcid)
Release an existing Data Radio Bearer for a Ue in the LteEnbComponentCarrierManager.
MemberLteCcmRrcSapUser class.
virtual void AddLcs(std::vector< LteEnbRrcSapProvider::LogicalChannelConfig > lcConfig)
add a new Logical Channel (LC)
virtual void TriggerComponentCarrier(uint16_t rnti, uint16_t targetCellId)
Instruct the eNodeB RRC entity to prepare a component carrier.
virtual void ReleaseLcs(uint16_t rnti, uint8_t lcid)
remove an existing LC
virtual Ptr< UeManager > GetUeManager(uint16_t rnti)
Get UE manager by RNTI.
virtual uint8_t AddUeMeasReportConfigForComponentCarrier(LteRrcSap::ReportConfigEutra reportConfig)
Request a certain reporting configuration to be fulfilled by the UEs attached to the eNodeB entity.
C * m_owner
the owner class
MemberLteCcmRrcSapUser(C *owner)
Constructor.
virtual void SetNumberOfComponentCarriers(uint16_t noOfComponentCarriers)
Set the number of component carriers.
Smart pointer class similar to boost::intrusive_ptr.
Definition: ptr.h:74
Manages all the radio bearer information possessed by the ENB RRC for a single UE.
Definition: lte-enb-rrc.h:75
#define NS_FATAL_ERROR(msg)
Report a fatal error with a message and terminate.
Definition: fatal-error.h:165
Every class exported by the ns3 library is enclosed in the ns3 namespace.
uint16_t componentCarrierId
component carrier ID
LteEnbCmacSapProvider::LcInfo lc
LC info.
Logical Channel information to be passed to CmacSapProvider::ConfigureLc.
MeasResults structure.
Definition: lte-rrc-sap.h:680
Specifies criteria for triggering of an E-UTRA measurement reporting event.
Definition: lte-rrc-sap.h:362