src/wifi/model/wifi-information-element.h
author Tom Henderson <tomh@tomh.org>
Mon, 28 Sep 2015 20:27:25 -0700
changeset 11676 05ea1489e509
parent 11628 243b71de25a0
permissions -rw-r--r--
bug 2184: Integer overflow in MacLow
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
     1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
     2
/*
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
     3
 * Copyright (c) 2010 Dean Armstrong
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
     4
 *
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
     5
 * This program is free software; you can redistribute it and/or modify
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
     6
 * it under the terms of the GNU General Public License version 2 as
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
     7
 * published by the Free Software Foundation;
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
     8
 *
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
     9
 * This program is distributed in the hope that it will be useful,
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    10
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    11
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    12
 * GNU General Public License for more details.
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    13
 *
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    14
 * You should have received a copy of the GNU General Public License
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    15
 * along with this program; if not, write to the Free Software
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    16
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    17
 *
11450
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
    18
 * Author: Dean Armstrong <deanarm@gmail.com>
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    19
 */
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    20
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    21
#ifndef WIFI_INFORMATION_ELEMENT_H
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    22
#define WIFI_INFORMATION_ELEMENT_H
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    23
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    24
#include "ns3/header.h"
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    25
#include "ns3/simple-ref-count.h"
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    26
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    27
namespace ns3 {
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    28
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    29
/**
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    30
 * This type is used to represent an Information Element ID. An
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    31
 * enumeration would be tidier, but doesn't provide for the
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    32
 * inheritance that is currently preferable to cleanly support
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    33
 * pre-standard modules such as mesh. Maybe there is a nice way of
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    34
 * doing this with a class.
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    35
 *
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    36
 * Until such time as a better way of implementing this is dreamt up
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    37
 * and applied, developers will need to be careful to avoid
6445
43d91786d268 simple doxygen fixes
Josh Pelkey <jpelkey@gatech.edu>
parents: 6389
diff changeset
    38
 * duplication of IE IDs in the defines below (and in files which
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    39
 * declare "subclasses" of WifiInformationElement). Sorry.
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    40
 */
6379
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    41
typedef uint8_t WifiInformationElementId;
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    42
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    43
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    44
/**
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    45
 * Here we have definition of all Information Element IDs in IEEE
6379
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    46
 * 802.11-2007. See the comments for WifiInformationElementId - this could
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    47
 * probably be done in a considerably tidier manner.
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    48
 */
6379
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    49
#define IE_SSID                                ((WifiInformationElementId)0)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    50
#define IE_SUPPORTED_RATES                     ((WifiInformationElementId)1)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    51
#define IE_FH_PARAMETER_SET                    ((WifiInformationElementId)2)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    52
#define IE_DS_PARAMETER_SET                    ((WifiInformationElementId)3)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    53
#define IE_CF_PARAMETER_SET                    ((WifiInformationElementId)4)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    54
#define IE_TIM                                 ((WifiInformationElementId)5)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    55
#define IE_IBSS_PARAMETER_SET                  ((WifiInformationElementId)6)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    56
#define IE_COUNTRY                             ((WifiInformationElementId)7)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    57
#define IE_HOPPING_PATTERN_PARAMETERS          ((WifiInformationElementId)8)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    58
#define IE_HOPPING_PATTERN_TABLE               ((WifiInformationElementId)9)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    59
#define IE_REQUEST                             ((WifiInformationElementId)10)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    60
#define IE_BSS_LOAD                            ((WifiInformationElementId)11)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    61
#define IE_EDCA_PARAMETER_SET                  ((WifiInformationElementId)12)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    62
#define IE_TSPEC                               ((WifiInformationElementId)13)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    63
#define IE_TCLAS                               ((WifiInformationElementId)14)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    64
#define IE_SCHEDULE                            ((WifiInformationElementId)15)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    65
#define IE_CHALLENGE_TEXT                      ((WifiInformationElementId)16)
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    66
// 17 to 31 are reserved in 802.11-2007
6379
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    67
#define IE_POWER_CONSTRAINT                    ((WifiInformationElementId)32)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    68
#define IE_POWER_CAPABILITY                    ((WifiInformationElementId)33)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    69
#define IE_TPC_REQUEST                         ((WifiInformationElementId)34)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    70
#define IE_TPC_REPORT                          ((WifiInformationElementId)35)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    71
#define IE_SUPPORTED_CHANNELS                  ((WifiInformationElementId)36)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    72
#define IE_CHANNEL_SWITCH_ANNOUNCEMENT         ((WifiInformationElementId)37)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    73
#define IE_MEASUREMENT_REQUEST                 ((WifiInformationElementId)38)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    74
#define IE_MEASUREMENT_REPORT                  ((WifiInformationElementId)39)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    75
#define IE_QUIET                               ((WifiInformationElementId)40)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    76
#define IE_IBSS_DFS                            ((WifiInformationElementId)41)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    77
#define IE_ERP_INFORMATION                     ((WifiInformationElementId)42)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    78
#define IE_TS_DELAY                            ((WifiInformationElementId)43)
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    79
#define IE_TCLAS_PROCESSING                    ((WifiInformationElementId)44)
10139
17a71cd49da3 partial 802.11n support
Ghada Badawy <gbadawy@gmail.com>
parents: 7139
diff changeset
    80
#define IE_HT_CAPABILITIES                     ((WifiInformationElementId)45)
6379
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    81
#define IE_QOS_CAPABILITY                      ((WifiInformationElementId)46)
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    82
// 47 is reserved in 802.11-2007
6379
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    83
#define IE_RSN                                 ((WifiInformationElementId)48)
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    84
// 49 is reserved in 802.11-2007
6379
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    85
#define IE_EXTENDED_SUPPORTED_RATES            ((WifiInformationElementId)50)
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    86
// 51 to 126 are reserved in 802.11-2007
6379
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    87
#define IE_EXTENDED_CAPABILITIES               ((WifiInformationElementId)127)
11628
243b71de25a0 add support for IEEE 802.11ac
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11587
diff changeset
    88
// 128 to 190 are reserved in 802.11-2007
243b71de25a0 add support for IEEE 802.11ac
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11587
diff changeset
    89
#define IE_VHT_CAPABILITIES                    ((WifiInformationElementId)191)
6379
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
    90
#define IE_VENDOR_SPECIFIC                     ((WifiInformationElementId)221)
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
    91
// 222 to 255 are reserved in 802.11-2007
11587
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
    92
#define IE11S_LINK_METRIC_REPORT               ((WifiInformationElementId)115)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
    93
#define IE11S_CONGESTION_NOTIFICATION          ((WifiInformationElementId)116)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
    94
#define IE11S_SUPP_MBSS_REG_CLASSES_CHANNELS   ((WifiInformationElementId)23)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
    95
#define IE11S_MESH_CHANNEL_SWITCH_ANNOUNCEMENT ((WifiInformationElementId)24)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
    96
#define IE11S_MESH_TIM                         ((WifiInformationElementId)25)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
    97
#define IE11S_AWAKE_WINDOW                     ((WifiInformationElementId)119)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
    98
#define IE11S_BEACON_TIMING                    ((WifiInformationElementId)120)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
    99
#define IE11S_MCCAOP_SETUP_REQUEST             ((WifiInformationElementId)121)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   100
#define IE11S_MCCAOP_SETUP_REPLY               ((WifiInformationElementId)122)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   101
#define IE11S_MCCAOP_ADVERTISEMENT             ((WifiInformationElementId)123)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   102
#define IE11S_MCCAOP_RESERVATION_TEARDOWN      ((WifiInformationElementId)31)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   103
#define IE11S_PORTAL_ANNOUNCEMENT              ((WifiInformationElementId)32)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   104
#define IE11S_PROXY_UPDATE                     ((WifiInformationElementId)137)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   105
#define IE11S_PROXY_UPDATE_CONFIRMATION        ((WifiInformationElementId)138)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   106
#define IE11S_ABBREVIATED_HANDSHAKE            ((WifiInformationElementId)39)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   107
/* begin of open80211s-compatible IDs */
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   108
#define IE11S_MESH_CONFIGURATION               ((WifiInformationElementId)113)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   109
#define IE11S_MESH_ID                          ((WifiInformationElementId)114)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   110
#define IE11S_PEERING_MANAGEMENT               ((WifiInformationElementId)117)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   111
/* end of open80211s-compatible IDs */
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   112
#define IE11S_RANN                             ((WifiInformationElementId)126)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   113
/* begin of open80211s-compatible IDs */
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   114
#define IE11S_PREQ                             ((WifiInformationElementId)130)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   115
#define IE11S_PREP                             ((WifiInformationElementId)131)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   116
#define IE11S_PERR                             ((WifiInformationElementId)132)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   117
/* end of open80211s-compatible IDs */
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   118
#define IE11S_MESH_PEERING_PROTOCOL_VERSION    ((WifiInformationElementId)74)
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   119
38e93ba5afa5 move definition of Wifi information element IDs from mesh to wifi module; implement more fully the WifiInformationElementVector header class
Tom Henderson <tomh@tomh.org>
parents: 11450
diff changeset
   120
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   121
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   122
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   123
/**
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   124
 * \brief Information element, as defined in 802.11-2007 standard
7139
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   125
 * \ingroup wifi
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   126
 *
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   127
 * The IEEE 802.11 standard includes the notion of Information
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   128
 * Elements, which are encodings of management information to be
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   129
 * communicated between STAs in the payload of various frames of type
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   130
 * Management. Information Elements (IEs) have a common format, each
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   131
 * starting with a single octet - the Element ID, which indicates the
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   132
 * specific type of IE (a type to represent the options here is
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   133
 * defined as WifiInformationElementId). The next octet is a length field and
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   134
 * encodes the number of octets in the third and final field, which is
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   135
 * the IE Information field.
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   136
 *
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   137
 * The class ns3::WifiInformationElement provides a base for classes
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   138
 * which represent specific Information Elements. This class defines
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   139
 * pure virtual methods for serialisation
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   140
 * (ns3::WifiInformationElement::SerializeInformationField) and
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   141
 * deserialisation
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   142
 * (ns3::WifiInformationElement::DeserializeInformationField) of IEs, from
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   143
 * or to data members or other objects that simulation objects use to
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   144
 * maintain the relevant state.
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   145
 *
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   146
 * This class also provides an implementation of the equality
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   147
 * operator, which operates by comparing the serialised versions of
79dd02ed46ec doxygen wifi module grouping all wifi classes
Nicola Baldo <nbaldo@cttc.es>
parents: 6852
diff changeset
   148
 * the two WifiInformationElement objects concerned.
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   149
 *
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   150
 * Elements are defined to have a common general format consisting of
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   151
 * a 1 octet Element ID field, a 1 octet length field, and a
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   152
 * variable-length element-specific information field. Each element is
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   153
 * assigned a unique Element ID as defined in this standard. The
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   154
 * Length field specifies the number of octets in the Information
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   155
 * field.
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   156
 *
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   157
 * This class is pure virtual and acts as base for classes which know
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   158
 * how to serialize specific IEs.
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   159
 */
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   160
class WifiInformationElement : public SimpleRefCount<WifiInformationElement>
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   161
{
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   162
public:
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   163
  virtual ~WifiInformationElement ();
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   164
  /**
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   165
   * Serialize entire IE including Element ID and length fields
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   166
   *
11450
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   167
   * \param i an iterator which points to where the IE should be written.
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   168
   *
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   169
   * \return an iterator
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   170
   */
6389
6e83ec53ba0a Bug 881: Add missing rename of SerializeIE to Serialize.
Dean Armstrong <deanarm@gmail.com>
parents: 6382
diff changeset
   171
  Buffer::Iterator Serialize (Buffer::Iterator i) const;
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   172
  /**
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   173
   * Deserialize entire IE, which must be present. The iterator
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   174
   * passed in must be pointing at the Element ID (i.e., the very
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   175
   * first octet) of the correct type of information element,
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   176
   * otherwise this method will generate a fatal error.
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   177
   *
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   178
   * \param i an iterator which points to where the IE should be read.
11450
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   179
   *
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   180
   * \return an iterator
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   181
   */
6382
9e5768e48981 Bug 881: WifiInformationElement method renaming
Dean Armstrong <deanarm@gmail.com>
parents: 6380
diff changeset
   182
  Buffer::Iterator Deserialize (Buffer::Iterator i);
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   183
  /**
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   184
   * Deserialize entire IE if it is present. The iterator passed in
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   185
   * must be pointing at the Element ID of an information element. If
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   186
   * the Element ID is not the one that the given class is interested
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   187
   * in then it will return the same iterator.
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   188
   *
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   189
   * \param i an iterator which points to where the IE should be read.
11450
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   190
   *
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   191
   * \return an iterator
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   192
   */
6382
9e5768e48981 Bug 881: WifiInformationElement method renaming
Dean Armstrong <deanarm@gmail.com>
parents: 6380
diff changeset
   193
  Buffer::Iterator DeserializeIfPresent (Buffer::Iterator i);
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   194
  /**
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   195
   * Get the size of the serialized IE including Element ID and
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   196
   * length fields.
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   197
   *
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   198
   * \return the size of the serialized IE
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   199
   */
6380
650233cda60e Bug 881: Bring Wi-Fi IE serdes intelligence into WifiInformationElement object
Dean Armstrong <deanarm@gmail.com>
parents: 6379
diff changeset
   200
  uint16_t GetSerializedSize () const;
650233cda60e Bug 881: Bring Wi-Fi IE serdes intelligence into WifiInformationElement object
Dean Armstrong <deanarm@gmail.com>
parents: 6379
diff changeset
   201
11002
80e12ddf6d72 [Doxygen] Remove trivial and/or misused groupings
Peter D. Barnes, Jr. <barnes26@llnl.gov>
parents: 10483
diff changeset
   202
  // Each subclass must implement these pure virtual functions:
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   203
  /// Own unique Element ID
6379
f1031f074dbd Bug 881: Change WifiElementId to WifiInformationElementId
Dean Armstrong <deanarm@gmail.com>
parents: 6378
diff changeset
   204
  virtual WifiInformationElementId ElementId () const = 0;
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   205
  /**
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   206
   * Length of serialized information (i.e., the length of the body
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   207
   * of the IE, not including the Element ID and length octets. This
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   208
   * is the value that will appear in the second octet of the entire
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   209
   * IE - the length field)
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   210
   *
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   211
   * \return the length of serialized information
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   212
   */
6382
9e5768e48981 Bug 881: WifiInformationElement method renaming
Dean Armstrong <deanarm@gmail.com>
parents: 6380
diff changeset
   213
  virtual uint8_t GetInformationFieldSize () const = 0;
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   214
  /**
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   215
   * Serialize information (i.e., the body of the IE, not including
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   216
   * the Element ID and length octets)
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   217
   *
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   218
   * \param start an iterator which points to where the information should
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   219
   *        be written.
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   220
   */
6382
9e5768e48981 Bug 881: WifiInformationElement method renaming
Dean Armstrong <deanarm@gmail.com>
parents: 6380
diff changeset
   221
  virtual void SerializeInformationField (Buffer::Iterator start) const = 0;
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   222
  /**
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   223
   * Deserialize information (i.e., the body of the IE, not including
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   224
   * the Element ID and length octets)
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   225
   *
11450
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   226
   * \param start an iterator which points to where the information should be written.
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   227
   * \param length
11450
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   228
   *
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   229
   * \return the number of bytes read
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   230
   */
6382
9e5768e48981 Bug 881: WifiInformationElement method renaming
Dean Armstrong <deanarm@gmail.com>
parents: 6380
diff changeset
   231
  virtual uint8_t DeserializeInformationField (Buffer::Iterator start,
9e5768e48981 Bug 881: WifiInformationElement method renaming
Dean Armstrong <deanarm@gmail.com>
parents: 6380
diff changeset
   232
                                               uint8_t length) = 0;
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   233
11450
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   234
  // In addition, a subclass may optionally override the following...
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   235
  /**
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   236
   * Generate human-readable form of IE
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   237
   *
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   238
   * \param os output stream
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   239
   */
6380
650233cda60e Bug 881: Bring Wi-Fi IE serdes intelligence into WifiInformationElement object
Dean Armstrong <deanarm@gmail.com>
parents: 6379
diff changeset
   240
  virtual void Print (std::ostream &os) const;
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   241
  /**
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   242
   * Compare information elements using Element ID
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   243
   *
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   244
   * \param a another information element to compare with
11450
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   245
   *
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   246
   * \return true if the Element ID is less than the other IE Element ID,
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   247
   *         false otherwise
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   248
   */
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   249
  virtual bool operator< (WifiInformationElement const & a) const;
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   250
  /**
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   251
   * Compare two IEs for equality by ID & Length, and then through
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   252
   * memcmp of serialised version
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   253
   *
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   254
   * \param a another information element to compare with
11450
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   255
   *
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   256
   * \return true if the two IEs are equal,
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   257
   *         false otherwise
10483
e3a02ed14587 [doxygen] wifi module
Daniel Lertpratchya <nikkipui@gmail.com>
parents: 10139
diff changeset
   258
   */
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   259
  virtual bool operator== (WifiInformationElement const & a) const;
11002
80e12ddf6d72 [Doxygen] Remove trivial and/or misused groupings
Peter D. Barnes, Jr. <barnes26@llnl.gov>
parents: 10483
diff changeset
   260
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   261
};
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   262
11450
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   263
} //namespace ns3
9f4ae69f12b7 cleanup wifi module
Sébastien Deronne <sebastien.deronne@gmail.com>
parents: 11002
diff changeset
   264
6378
57485ed01268 Bug 881: Extract WifiInformationElement(Vector) core to wifi module
Dean Armstrong <deanarm@gmail.com>
parents:
diff changeset
   265
#endif /* WIFI_INFORMATION_ELEMENT_H */