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
lte-rlc-sap.h
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2011 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC)
3
*
4
* SPDX-License-Identifier: GPL-2.0-only
5
*
6
* Author: Manuel Requena <manuel.requena@cttc.es>
7
*/
8
9
#ifndef LTE_RLC_SAP_H
10
#define LTE_RLC_SAP_H
11
12
#include "ns3/packet.h"
13
14
namespace
ns3
15
{
16
17
/**
18
* Service Access Point (SAP) offered by the UM-RLC and AM-RLC entities to the PDCP entity
19
* See 3GPP 36.322 Radio Link Control (RLC) protocol specification
20
*
21
* This is the RLC SAP Provider
22
* (i.e. the part of the SAP that contains the RLC methods called by the PDCP)
23
*/
24
class
LteRlcSapProvider
25
{
26
public
:
27
virtual
~LteRlcSapProvider
();
28
29
/**
30
* Parameters for LteRlcSapProvider::TransmitPdcpPdu
31
*/
32
struct
TransmitPdcpPduParameters
33
{
34
Ptr<Packet>
pdcpPdu
;
/**< the PDCP PDU */
35
uint16_t
rnti
;
/**< the C-RNTI identifying the UE */
36
uint8_t
lcid
;
/**< the logical channel id corresponding to the sending RLC instance */
37
};
38
39
/**
40
* Send a PDCP PDU to the RLC for transmission
41
* This method is to be called
42
* when upper PDCP entity has a PDCP PDU ready to send
43
* \param params the TransmitPdcpPduParameters
44
*/
45
virtual
void
TransmitPdcpPdu
(
TransmitPdcpPduParameters
params) = 0;
46
};
47
48
/**
49
* Service Access Point (SAP) offered by the UM-RLC and AM-RLC entities to the PDCP entity
50
* See 3GPP 36.322 Radio Link Control (RLC) protocol specification
51
*
52
* This is the RLC SAP User
53
* (i.e. the part of the SAP that contains the PDCP methods called by the RLC)
54
*/
55
class
LteRlcSapUser
56
{
57
public
:
58
virtual
~LteRlcSapUser
();
59
60
/**
61
* Called by the RLC entity to notify the PDCP entity of the reception of a new PDCP PDU
62
*
63
* \param p the PDCP PDU
64
*/
65
virtual
void
ReceivePdcpPdu
(
Ptr<Packet>
p) = 0;
66
};
67
68
/// LteRlcSpecificLteRlcSapProvider
69
template
<
class
C>
70
class
LteRlcSpecificLteRlcSapProvider
:
public
LteRlcSapProvider
71
{
72
public
:
73
/**
74
* Constructor
75
*
76
* \param rlc the RLC
77
*/
78
LteRlcSpecificLteRlcSapProvider
(C* rlc);
79
80
// Delete default constructor to avoid misuse
81
LteRlcSpecificLteRlcSapProvider
() =
delete
;
82
83
/**
84
* Interface implemented from LteRlcSapProvider
85
* \param params the TransmitPdcpPduParameters
86
*/
87
void
TransmitPdcpPdu
(
TransmitPdcpPduParameters
params)
override
;
88
89
private
:
90
C*
m_rlc
;
///< the RLC
91
};
92
93
template
<
class
C>
94
LteRlcSpecificLteRlcSapProvider<C>::LteRlcSpecificLteRlcSapProvider
(C* rlc)
95
: m_rlc(rlc)
96
{
97
}
98
99
template
<
class
C>
100
void
101
LteRlcSpecificLteRlcSapProvider<C>::TransmitPdcpPdu
(
TransmitPdcpPduParameters
params)
102
{
103
m_rlc->DoTransmitPdcpPdu(params.pdcpPdu);
104
}
105
106
/// LteRlcSpecificLteRlcSapUser class
107
template
<
class
C>
108
class
LteRlcSpecificLteRlcSapUser
:
public
LteRlcSapUser
109
{
110
public
:
111
/**
112
* Constructor
113
*
114
* \param pdcp the PDCP
115
*/
116
LteRlcSpecificLteRlcSapUser
(C* pdcp);
117
118
// Delete default constructor to avoid misuse
119
LteRlcSpecificLteRlcSapUser
() =
delete
;
120
121
// Interface implemented from LteRlcSapUser
122
void
ReceivePdcpPdu
(
Ptr<Packet>
p)
override
;
123
124
private
:
125
C*
m_pdcp
;
///< the PDCP
126
};
127
128
template
<
class
C>
129
LteRlcSpecificLteRlcSapUser<C>::LteRlcSpecificLteRlcSapUser
(C* pdcp)
130
: m_pdcp(pdcp)
131
{
132
}
133
134
template
<
class
C>
135
void
136
LteRlcSpecificLteRlcSapUser<C>::ReceivePdcpPdu
(
Ptr<Packet>
p)
137
{
138
m_pdcp->DoReceivePdcpPdu(p);
139
}
140
141
}
// namespace ns3
142
143
#endif
// LTE_RLC_SAP_H
ns3::LteRlcSapProvider
Service Access Point (SAP) offered by the UM-RLC and AM-RLC entities to the PDCP entity See 3GPP 36....
Definition
lte-rlc-sap.h:25
ns3::LteRlcSapProvider::~LteRlcSapProvider
virtual ~LteRlcSapProvider()
Definition
lte-rlc-sap.cc:14
ns3::LteRlcSapProvider::TransmitPdcpPdu
virtual void TransmitPdcpPdu(TransmitPdcpPduParameters params)=0
Send a PDCP PDU to the RLC for transmission This method is to be called when upper PDCP entity has a ...
ns3::LteRlcSapUser
Service Access Point (SAP) offered by the UM-RLC and AM-RLC entities to the PDCP entity See 3GPP 36....
Definition
lte-rlc-sap.h:56
ns3::LteRlcSapUser::~LteRlcSapUser
virtual ~LteRlcSapUser()
Definition
lte-rlc-sap.cc:18
ns3::LteRlcSapUser::ReceivePdcpPdu
virtual void ReceivePdcpPdu(Ptr< Packet > p)=0
Called by the RLC entity to notify the PDCP entity of the reception of a new PDCP PDU.
ns3::LteRlcSpecificLteRlcSapProvider
LteRlcSpecificLteRlcSapProvider.
Definition
lte-rlc-sap.h:71
ns3::LteRlcSpecificLteRlcSapProvider::LteRlcSpecificLteRlcSapProvider
LteRlcSpecificLteRlcSapProvider()=delete
ns3::LteRlcSpecificLteRlcSapProvider::TransmitPdcpPdu
void TransmitPdcpPdu(TransmitPdcpPduParameters params) override
Interface implemented from LteRlcSapProvider.
Definition
lte-rlc-sap.h:101
ns3::LteRlcSpecificLteRlcSapProvider::m_rlc
C * m_rlc
the RLC
Definition
lte-rlc-sap.h:90
ns3::LteRlcSpecificLteRlcSapUser
LteRlcSpecificLteRlcSapUser class.
Definition
lte-rlc-sap.h:109
ns3::LteRlcSpecificLteRlcSapUser::m_pdcp
C * m_pdcp
the PDCP
Definition
lte-rlc-sap.h:125
ns3::LteRlcSpecificLteRlcSapUser::ReceivePdcpPdu
void ReceivePdcpPdu(Ptr< Packet > p) override
Called by the RLC entity to notify the PDCP entity of the reception of a new PDCP PDU.
Definition
lte-rlc-sap.h:136
ns3::LteRlcSpecificLteRlcSapUser::LteRlcSpecificLteRlcSapUser
LteRlcSpecificLteRlcSapUser()=delete
ns3::Ptr
Smart pointer class similar to boost::intrusive_ptr.
Definition
mpi-test-fixtures.h:37
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::LteRlcSapProvider::TransmitPdcpPduParameters
Parameters for LteRlcSapProvider::TransmitPdcpPdu.
Definition
lte-rlc-sap.h:33
ns3::LteRlcSapProvider::TransmitPdcpPduParameters::lcid
uint8_t lcid
the logical channel id corresponding to the sending RLC instance
Definition
lte-rlc-sap.h:36
ns3::LteRlcSapProvider::TransmitPdcpPduParameters::pdcpPdu
Ptr< Packet > pdcpPdu
the PDCP PDU
Definition
lte-rlc-sap.h:34
ns3::LteRlcSapProvider::TransmitPdcpPduParameters::rnti
uint16_t rnti
the C-RNTI identifying the UE
Definition
lte-rlc-sap.h:35
src
lte
model
lte-rlc-sap.h
Generated on Fri Nov 8 2024 13:59:03 for ns-3 by
1.11.0