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
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
uan-header-common.h
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2009 University of Washington
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: Leonard Tracy <lentracy@gmail.com>
19
*/
20
21
#ifndef UAN_HEADER_COMMON_H
22
#define UAN_HEADER_COMMON_H
23
24
#include "ns3/header.h"
25
#include "ns3/nstime.h"
26
#include "ns3/simulator.h"
27
#include "
uan-address.h
"
28
29
namespace
ns3 {
30
37
class
UanHeaderCommon
:
public
Header
38
{
39
public
:
40
UanHeaderCommon
();
47
UanHeaderCommon
(
const
UanAddress
src,
const
UanAddress
dest, uint8_t type);
48
virtual
~UanHeaderCommon
();
49
50
static
TypeId
GetTypeId
(
void
);
51
55
void
SetDest
(
UanAddress
dest);
59
void
SetSrc
(
UanAddress
src);
63
void
SetType
(uint8_t type);
64
68
UanAddress
GetDest
(
void
)
const
;
72
UanAddress
GetSrc
(
void
)
const
;
76
uint8_t
GetType
(
void
)
const
;
77
78
79
80
// Inherrited methods
81
virtual
uint32_t
GetSerializedSize
(
void
)
const
;
82
virtual
void
Serialize
(
Buffer::Iterator
start
)
const
;
83
virtual
uint32_t
Deserialize
(
Buffer::Iterator
start);
84
virtual
void
Print
(std::ostream &os)
const
;
85
virtual
TypeId
GetInstanceTypeId
(
void
)
const
;
86
private
:
87
UanAddress
m_dest
;
88
UanAddress
m_src
;
89
uint8_t
m_type
;
90
91
92
};
93
94
}
95
96
#endif
/* UAN_HEADER_COMMON_H */
src
uan
model
uan-header-common.h
Generated on Tue Nov 13 2012 10:32:23 for ns-3 by
1.8.1.2