OLD | NEW |
1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ | 1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ |
2 /* | 2 /* |
3 * Copyright (c) 2011 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC) | 3 * Copyright (c) 2011 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC) |
4 * | 4 * |
5 * This program is free software; you can redistribute it and/or modify | 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 | 6 * it under the terms of the GNU General Public License version 2 as |
7 * published by the Free Software Foundation; | 7 * published by the Free Software Foundation; |
8 * | 8 * |
9 * This program is distributed in the hope that it will be useful, | 9 * This program is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 29 matching lines...) Expand all Loading... |
40 public: | 40 public: |
41 | 41 |
42 /** | 42 /** |
43 * \brief Constructor | 43 * \brief Constructor |
44 * | 44 * |
45 * Creates a null header | 45 * Creates a null header |
46 */ | 46 */ |
47 LtePdcpHeader (); | 47 LtePdcpHeader (); |
48 ~LtePdcpHeader (); | 48 ~LtePdcpHeader (); |
49 | 49 |
| 50 /** |
| 51 * \brief Set DC bit |
| 52 * |
| 53 * \param dcBit DC bit to set |
| 54 */ |
50 void SetDcBit (uint8_t dcBit); | 55 void SetDcBit (uint8_t dcBit); |
| 56 /** |
| 57 * \brief Set sequence number |
| 58 * |
| 59 * \param sequenceNumber sequence number |
| 60 */ |
51 void SetSequenceNumber (uint16_t sequenceNumber); | 61 void SetSequenceNumber (uint16_t sequenceNumber); |
52 | 62 |
| 63 /** |
| 64 * \brief Get DC bit |
| 65 * |
| 66 * \returns DC bit |
| 67 */ |
53 uint8_t GetDcBit () const; | 68 uint8_t GetDcBit () const; |
| 69 /** |
| 70 * \brief Get sequence number |
| 71 * |
| 72 * \returns sequence number |
| 73 */ |
54 uint16_t GetSequenceNumber () const; | 74 uint16_t GetSequenceNumber () const; |
55 | 75 |
56 typedef enum { | 76 /// DcBit_t typedef |
| 77 enum { |
57 CONTROL_PDU = 0, | 78 CONTROL_PDU = 0, |
58 DATA_PDU = 1 | 79 DATA_PDU = 1 |
59 } DcBit_t; | 80 } DcBit_t; ///< DcBit_t typedef |
60 | 81 |
| 82 /** |
| 83 * \brief Get the type ID. |
| 84 * \return the object TypeId |
| 85 */ |
61 static TypeId GetTypeId (void); | 86 static TypeId GetTypeId (void); |
62 virtual TypeId GetInstanceTypeId (void) const; | 87 virtual TypeId GetInstanceTypeId (void) const; |
63 virtual void Print (std::ostream &os) const; | 88 virtual void Print (std::ostream &os) const; |
64 virtual uint32_t GetSerializedSize (void) const; | 89 virtual uint32_t GetSerializedSize (void) const; |
65 virtual void Serialize (Buffer::Iterator start) const; | 90 virtual void Serialize (Buffer::Iterator start) const; |
66 virtual uint32_t Deserialize (Buffer::Iterator start); | 91 virtual uint32_t Deserialize (Buffer::Iterator start); |
67 | 92 |
68 private: | 93 private: |
69 uint8_t m_dcBit; | 94 uint8_t m_dcBit; ///< the DC bit |
70 uint16_t m_sequenceNumber; | 95 uint16_t m_sequenceNumber; ///< the sequence number |
71 | 96 |
72 }; | 97 }; |
73 | 98 |
74 } // namespace ns3 | 99 } // namespace ns3 |
75 | 100 |
76 #endif // LTE_PDCP_HEADER_H | 101 #endif // LTE_PDCP_HEADER_H |
OLD | NEW |