satellite-scheduling-object.cc
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2013 Magister Solutions Ltd
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: Jani Puttonen <jani.puttonen@magister.fi>
19  */
20 
22 
23 #include <ns3/log.h>
24 #include <ns3/mac48-address.h>
25 
26 NS_LOG_COMPONENT_DEFINE("SatSchedulingObject");
27 
28 namespace ns3
29 {
30 
32  : m_macAddress(),
33  m_bufferedBytes(0),
34  m_minTxOpportunity(0),
35  m_holDelay(Seconds(0.0)),
36  m_flowId()
37 {
38  NS_LOG_FUNCTION(this);
39  NS_ASSERT(false);
40 
44 }
45 
47  uint32_t bytes,
48  uint32_t minTxOpportunity,
49  Time holDelay,
50  uint8_t flowId)
51  : m_macAddress(addr),
52  m_bufferedBytes(bytes),
53  m_minTxOpportunity(minTxOpportunity),
54  m_holDelay(holDelay),
55  m_flowId(flowId)
56 {
57  NS_LOG_FUNCTION(this << addr << bytes << holDelay << (uint32_t)flowId);
58 }
59 
61 {
62 }
63 
64 Mac48Address
66 {
67  NS_LOG_FUNCTION(this);
68  return m_macAddress;
69 }
70 
71 uint32_t
73 {
74  NS_LOG_FUNCTION(this);
75  return m_bufferedBytes;
76 }
77 
78 uint32_t
80 {
81  NS_LOG_FUNCTION(this);
82  return m_minTxOpportunity;
83 }
84 
85 uint8_t
87 {
88  NS_LOG_FUNCTION(this);
89  return m_flowId;
90 }
91 
92 Time
94 {
95  NS_LOG_FUNCTION(this);
96  return m_holDelay;
97 }
98 
99 } // namespace ns3
uint32_t GetBufferedBytes() const
Get buffered bytes of this object.
uint32_t GetMinTxOpportunityInBytes() const
Get minimum Tx opportunity in bytes.
SatSchedulingObject()
Default constructor.
virtual ~SatSchedulingObject()
Destructor.
uint8_t GetFlowId() const
Get the flow identifier of the scheduling object.
Time GetHolDelay() const
Get HOL delay of the object.
Mac48Address GetMacAddress() const
Get the MAC address of this object.
SatArqSequenceNumber is handling the sequence numbers for the ARQ process.