A Discrete-Event Network Simulator
API
epc-s11-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.cat>
19  */
20 
21 #ifndef EPC_S11_SAP_H
22 #define EPC_S11_SAP_H
23 
24 #include <ns3/address.h>
25 #include <ns3/ptr.h>
26 #include <ns3/object.h>
27 #include <ns3/eps-bearer.h>
28 #include <ns3/epc-tft.h>
29 #include <list>
30 
31 namespace ns3 {
32 
36 class EpcS11Sap
37 {
38 public:
39 
40  virtual ~EpcS11Sap ();
41 
45  struct GtpcMessage
46  {
47  uint32_t teid;
48  };
49 
54  struct Fteid
55  {
56  uint32_t teid;
58  };
59 
64  struct Uli
65  {
66  uint16_t gci;
67  };
68 
69 
70 };
71 
78 class EpcS11SapMme : public EpcS11Sap
79 {
80 public:
81 
87  {
88 
90  uint8_t epsBearerId;
93  };
94 
95 
100  {
101  std::list<BearerContextCreated> bearerContextsCreated;
102  };
103 
104 
111 
116  {
117  uint8_t epsBearerId;
118  };
119 
124  {
125  std::list<BearerContextRemoved> bearerContextsRemoved;
126  };
127 
133 
134 
135 
136 
141  {
143  enum Cause {
148  } cause;
149  };
150 
157 
158 };
159 
166 class EpcS11SapSgw : public EpcS11Sap
167 {
168 public:
169 
172  {
174  uint8_t epsBearerId;
177  };
178 
179 
184  {
185  uint64_t imsi;
187  std::list<BearerContextToBeCreated> bearerContextsToBeCreated;
188  };
189 
196 
199  {
200  uint8_t epsBearerId;
201  };
202 
207  {
208  std::list<BearerContextToBeRemoved> bearerContextsToBeRemoved;
209  };
210 
216 
219  {
220  uint8_t epsBearerId;
221  };
222 
227  {
228  std::list<BearerContextRemovedSgwPgw> bearerContextsRemoved;
229  };
230 
236 
241  {
243  };
244 
251 
252 };
253 
254 
255 
256 
257 
258 
259 
265 template <class C>
267 {
268 public:
274  MemberEpcS11SapMme (C* owner);
275 
276  // inherited from EpcS11SapMme
280 
281 private:
283  C* m_owner;
284 };
285 
291 template <class C>
293  : m_owner (owner)
294 {
295 }
296 
297 template <class C>
299 {
300 }
301 
302 template <class C>
304 {
305  m_owner->DoCreateSessionResponse (msg);
306 }
307 
308 template <class C>
310 {
311  m_owner->DoDeleteBearerRequest (msg);
312 }
313 
314 template <class C>
316 {
317  m_owner->DoModifyBearerResponse (msg);
318 }
319 
320 
321 
322 
323 
329 template <class C>
331 {
332 public:
338  MemberEpcS11SapSgw (C* owner);
339 
340  // inherited from EpcS11SapSgw
345 
346 private:
348  C* m_owner;
349 };
350 
356 template <class C>
358  : m_owner (owner)
359 {
360 }
361 
362 template <class C>
364 {
365 }
366 
367 template <class C>
369 {
370  m_owner->DoCreateSessionRequest (msg);
371 }
372 
373 template <class C>
375 {
376  m_owner->DoModifyBearerRequest (msg);
377 }
378 
379 template <class C>
381 {
382  m_owner->DoDeleteBearerCommand (msg);
383 }
384 
385 template <class C>
387 {
388  m_owner->DoDeleteBearerResponse (msg);
389 }
390 
391 
392 
393 
394 } //namespace ns3
395 
396 #endif /* EPC_S11_SAP_H */
397 
EpcS11Sap.
Definition: epc-s11-sap.h:37
virtual ~EpcS11Sap()
Definition: epc-s11-sap.cc:25
MME side of the S11 Service Access Point (SAP), provides the MME methods to be called when an S11 mes...
Definition: epc-s11-sap.h:79
virtual void DeleteBearerRequest(DeleteBearerRequestMessage msg)=0
As per 3GPP TS 29.274 Release 9 V9.3.0, a Delete Bearer Request message shall be sent on the S11 inte...
virtual void CreateSessionResponse(CreateSessionResponseMessage msg)=0
send a Create Session Response message
virtual void ModifyBearerResponse(ModifyBearerResponseMessage msg)=0
send a Modify Bearer Response message
SGW side of the S11 Service Access Point (SAP), provides the SGW methods to be called when an S11 mes...
Definition: epc-s11-sap.h:167
virtual void CreateSessionRequest(CreateSessionRequestMessage msg)=0
send a Create Session Request message
virtual void DeleteBearerResponse(DeleteBearerResponseMessage msg)=0
As per 3GPP TS 29.274 Release 9 V9.3.0, a Delete Bearer Command message shall be sent on the S11 inte...
virtual void ModifyBearerRequest(ModifyBearerRequestMessage msg)=0
send a Modify Bearer Request message
virtual void DeleteBearerCommand(DeleteBearerCommandMessage msg)=0
As per 3GPP TS 29.274 Release 9 V9.3.0, a Delete Bearer Command message shall be sent on the S11 inte...
This class contains the specification of EPS Bearers.
Definition: eps-bearer.h:92
Ipv4 addresses are stored in host order in this class.
Definition: ipv4-address.h:41
Template for the implementation of the EpcS11SapMme as a member of an owner class of type C to which ...
Definition: epc-s11-sap.h:267
virtual void CreateSessionResponse(CreateSessionResponseMessage msg)
send a Create Session Response message
Definition: epc-s11-sap.h:303
virtual void DeleteBearerRequest(DeleteBearerRequestMessage msg)
As per 3GPP TS 29.274 Release 9 V9.3.0, a Delete Bearer Request message shall be sent on the S11 inte...
Definition: epc-s11-sap.h:309
C * m_owner
owner class
Definition: epc-s11-sap.h:283
virtual void ModifyBearerResponse(ModifyBearerResponseMessage msg)
send a Modify Bearer Response message
Definition: epc-s11-sap.h:315
Template for the implementation of the EpcS11SapSgw as a member of an owner class of type C to which ...
Definition: epc-s11-sap.h:331
virtual void CreateSessionRequest(CreateSessionRequestMessage msg)
send a Create Session Request message
Definition: epc-s11-sap.h:368
virtual void DeleteBearerCommand(DeleteBearerCommandMessage msg)
As per 3GPP TS 29.274 Release 9 V9.3.0, a Delete Bearer Command message shall be sent on the S11 inte...
Definition: epc-s11-sap.h:380
C * m_owner
owner class
Definition: epc-s11-sap.h:348
virtual void DeleteBearerResponse(DeleteBearerResponseMessage msg)
As per 3GPP TS 29.274 Release 9 V9.3.0, a Delete Bearer Command message shall be sent on the S11 inte...
Definition: epc-s11-sap.h:386
virtual void ModifyBearerRequest(ModifyBearerRequestMessage msg)
send a Modify Bearer Request message
Definition: epc-s11-sap.h:374
Smart pointer class similar to boost::intrusive_ptr.
Definition: ptr.h:74
Every class exported by the ns3 library is enclosed in the ns3 namespace.
Fully-qualified TEID, see 3GPP TS 29.274 section 8.22.
Definition: epc-s11-sap.h:55
Ipv4Address address
IP address.
Definition: epc-s11-sap.h:57
uint32_t teid
TEID.
Definition: epc-s11-sap.h:56
TS 29.274 8.21 User Location Information (ULI)
Definition: epc-s11-sap.h:65
uint16_t gci
GCI.
Definition: epc-s11-sap.h:66
3GPP TS 29.274 version 8.3.1 Release 8 section 8.28
Definition: epc-s11-sap.h:87
EpcS11Sap::Fteid sgwFteid
EPC FTEID.
Definition: epc-s11-sap.h:89
Ptr< EpcTft > tft
traffic flow template
Definition: epc-s11-sap.h:92
Bearer Context Removed structure.
Definition: epc-s11-sap.h:116
Create Session Response message, see 3GPP TS 29.274 7.2.2.
Definition: epc-s11-sap.h:100
std::list< BearerContextCreated > bearerContextsCreated
bearer contexts created
Definition: epc-s11-sap.h:101
Delete Bearer Request message, see 3GPP TS 29.274 Release 9 V9.3.0 section 7.2.9.2.
Definition: epc-s11-sap.h:124
std::list< BearerContextRemoved > bearerContextsRemoved
list of bearer context removed
Definition: epc-s11-sap.h:125
Modify Bearer Response message, see 3GPP TS 29.274 7.2.7.
Definition: epc-s11-sap.h:141
enum ns3::EpcS11SapMme::ModifyBearerResponseMessage::Cause cause
the cause
BearerContextRemovedSgwPgw structure.
Definition: epc-s11-sap.h:219
BearerContextToBeCreated structure.
Definition: epc-s11-sap.h:172
EpsBearer bearerLevelQos
bearer QOS level
Definition: epc-s11-sap.h:175
Ptr< EpcTft > tft
traffic flow template
Definition: epc-s11-sap.h:176
BearerContextToBeCreated structure.
Definition: epc-s11-sap.h:199
Create Session Request message, see 3GPP TS 29.274 7.2.1.
Definition: epc-s11-sap.h:184
std::list< BearerContextToBeCreated > bearerContextsToBeCreated
list of bearer contexts to be created
Definition: epc-s11-sap.h:187
Delete Bearer Command message, see 3GPP TS 29.274 Release 9 V9.3.0 section 7.2.17....
Definition: epc-s11-sap.h:207
std::list< BearerContextToBeRemoved > bearerContextsToBeRemoved
list of bearer contexts to be removed
Definition: epc-s11-sap.h:208
Delete Bearer Response message, see 3GPP TS 29.274 Release 9 V9.3.0 section 7.2.10....
Definition: epc-s11-sap.h:227
std::list< BearerContextRemovedSgwPgw > bearerContextsRemoved
list of bearer contexts removed
Definition: epc-s11-sap.h:228
Modify Bearer Request message, see 3GPP TS 29.274 7.2.7.
Definition: epc-s11-sap.h:241