A Discrete-Event Network Simulator
API
epc-enb-s1-sap.h
Go to the documentation of this file.
1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2012 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC)
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: Nicola Baldo <nbaldo@cttc.es>
19  */
20 
21 #ifndef EPC_ENB_S1_SAP_H
22 #define EPC_ENB_S1_SAP_H
23 
24 #include <list>
25 #include <stdint.h>
26 #include <ns3/eps-bearer.h>
27 #include <ns3/ipv4-address.h>
28 
29 namespace ns3 {
30 
31 
40 {
41 public:
42  virtual ~EpcEnbS1SapProvider ();
43 
50  virtual void InitialUeMessage (uint64_t imsi, uint16_t rnti) = 0;
51 
58  virtual void DoSendReleaseIndication (uint64_t imsi, uint16_t rnti, uint8_t bearerId) = 0;
59 
62  {
63  uint8_t epsBearerId;
64  uint32_t teid;
65  };
66 
69  {
70  uint16_t rnti;
71  uint16_t cellId;
72  uint32_t mmeUeS1Id;
73  std::list<BearerToBeSwitched> bearersToBeSwitched;
74  };
75 
81  virtual void PathSwitchRequest (PathSwitchRequestParameters params) = 0;
82 
83 
91  virtual void UeContextRelease (uint16_t rnti) = 0;
92 
93 };
94 
95 
96 
105 {
106 public:
107  virtual ~EpcEnbS1SapUser ();
108 
114  {
115  uint16_t rnti;
119  uint8_t bearerId;
120  uint32_t gtpTeid;
122  };
123 
130 
131 
134  {
135  uint16_t rnti;
136  };
137 
144 
145 };
146 
147 
148 
149 
155 template <class C>
157 {
158 public:
164  MemberEpcEnbS1SapProvider (C* owner);
165 
166  // inherited from EpcEnbS1SapProvider
167  virtual void InitialUeMessage (uint64_t imsi, uint16_t rnti);
168  virtual void DoSendReleaseIndication (uint64_t imsi, uint16_t rnti, uint8_t bearerId);
169 
170  virtual void PathSwitchRequest (PathSwitchRequestParameters params);
171  virtual void UeContextRelease (uint16_t rnti);
172 
173 private:
175  C* m_owner;
176 };
177 
178 template <class C>
180  : m_owner (owner)
181 {
182 }
183 
184 template <class C>
186 {
187 }
188 
189 
190 template <class C>
191 void MemberEpcEnbS1SapProvider<C>::InitialUeMessage (uint64_t imsi, uint16_t rnti)
192 {
193  m_owner->DoInitialUeMessage (imsi, rnti);
194 }
195 
196 template <class C>
197 void MemberEpcEnbS1SapProvider<C>::DoSendReleaseIndication (uint64_t imsi, uint16_t rnti, uint8_t bearerId)
198 {
199  m_owner->DoReleaseIndication (imsi, rnti, bearerId);
200 }
201 
202 template <class C>
204 {
205  m_owner->DoPathSwitchRequest (params);
206 }
207 
208 template <class C>
210 {
211  m_owner->DoUeContextRelease (rnti);
212 }
213 
219 template <class C>
221 {
222 public:
228  MemberEpcEnbS1SapUser (C* owner);
229 
230  // inherited from EpcEnbS1SapUser
233 
234 private:
236  C* m_owner;
237 };
238 
239 template <class C>
241  : m_owner (owner)
242 {
243 }
244 
245 template <class C>
247 {
248 }
249 
250 template <class C>
252 {
253  m_owner->DoDataRadioBearerSetupRequest (params);
254 }
255 
256 template <class C>
258 {
259  m_owner->DoPathSwitchRequestAcknowledge (params);
260 }
261 
262 } // namespace ns3
263 
264 #endif // EPC_ENB_S1_SAP_H
Ipv4Address transportLayerAddress
IP Address of the SGW, see 36.423 9.2.1.
Parameters passed to DataRadioBearerSetupRequest ()
Template for the implementation of the EpcEnbS1SapUser as a member of an owner class of type C to whi...
This class implements the Service Access Point (SAP) between the LteEnbRrc and the EpcEnbApplication...
virtual void PathSwitchRequest(PathSwitchRequestParameters params)=0
Path Switch Request.
virtual void UeContextRelease(uint16_t rnti)
release UE context at the S1 Application of the source eNB after reception of the UE CONTEXT RELEASE ...
uint32_t mmeUeS1Id
mmeUeS1Id in practice, we use the IMSI
This class implements the Service Access Point (SAP) between the LteEnbRrc and the EpcEnbApplication...
virtual void DataRadioBearerSetupRequest(DataRadioBearerSetupRequestParameters params)=0
request the setup of a DataRadioBearer
uint16_t rnti
the RNTI identifying the UE for which the DataRadioBearer is to be created
std::list< BearerToBeSwitched > bearersToBeSwitched
list of bearers to be switched
EpsBearer bearer
the characteristics of the bearer to be set up
This class contains the specification of EPS Bearers.
Definition: eps-bearer.h:71
virtual void UeContextRelease(uint16_t rnti)=0
release UE context at the S1 Application of the source eNB after reception of the UE CONTEXT RELEASE ...
virtual void DoSendReleaseIndication(uint64_t imsi, uint16_t rnti, uint8_t bearerId)
Triggers epc-enb-application to send ERAB Release Indication message towards MME. ...
uint32_t gtpTeid
S1-bearer GTP tunnel endpoint identifier, see 36.423 9.2.1.
virtual void InitialUeMessage(uint64_t imsi, uint16_t rnti)
PathSwitchRequestParameters structure.
BearerToBeSwitched structure.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
virtual void DataRadioBearerSetupRequest(DataRadioBearerSetupRequestParameters params)
request the setup of a DataRadioBearer
Template for the implementation of the EpcEnbS1SapProvider as a member of an owner class of type C to...
PathSwitchRequestAcknowledgeParameters structure.
virtual void PathSwitchRequest(PathSwitchRequestParameters params)
Path Switch Request.
virtual void DoSendReleaseIndication(uint64_t imsi, uint16_t rnti, uint8_t bearerId)=0
Triggers epc-enb-application to send ERAB Release Indication message towards MME. ...
virtual void InitialUeMessage(uint64_t imsi, uint16_t rnti)=0
Ipv4 addresses are stored in host order in this class.
Definition: ipv4-address.h:40
virtual void PathSwitchRequestAcknowledge(PathSwitchRequestAcknowledgeParameters params)=0
request a path switch acknowledge
virtual void PathSwitchRequestAcknowledge(PathSwitchRequestAcknowledgeParameters params)
request a path switch acknowledge