removed useless getters

This commit is contained in:
Nicola Baldo
2011-03-29 17:33:07 +02:00
parent 5681257d46
commit d8b452dcef
4 changed files with 10 additions and 50 deletions

View File

@@ -144,15 +144,6 @@ LtePhy::SetDownlinkChannel (Ptr<SpectrumChannel> c)
m_downlinkSpectrumPhy->SetChannel (c);
}
Ptr<SpectrumChannel>
LtePhy::GetDownlinkChannel ()
{
NS_LOG_FUNCTION (this);
return m_downlinkSpectrumPhy->GetChannel ();
}
void
LtePhy::SetUplinkChannel (Ptr<SpectrumChannel> c)
{
@@ -160,15 +151,6 @@ LtePhy::SetUplinkChannel (Ptr<SpectrumChannel> c)
m_uplinkSpectrumPhy->SetChannel (c);
}
Ptr<SpectrumChannel>
LtePhy::GetUplinkChannel ()
{
NS_LOG_FUNCTION (this);
return m_uplinkSpectrumPhy->GetChannel ();
}
void
LtePhy::SetDownlinkSubChannels (std::vector<int> mask )
{

View File

@@ -100,24 +100,12 @@ public:
*/
void SetDownlinkChannel (Ptr<SpectrumChannel> c);
/**
* Get the downlink channel
* \return a Ptr to the downlink SpectrumChannel
*/
Ptr<SpectrumChannel> GetDownlinkChannel ();
/**
* Set the uplink channel
* \param c the uplink channel
*/
void SetUplinkChannel (Ptr<SpectrumChannel> c);
/**
* Get the uplink channel
* \return a Ptr to the uplink SpectrumChannel
*/
Ptr<SpectrumChannel> GetUplinkChannel ();
/**
* \brief set a list of sub channel to use in the downlink.
* A sub channel is composed by a couple of resource bloks (180KHz x 1 ms)

View File

@@ -39,11 +39,7 @@ namespace ns3 {
NS_OBJECT_ENSURE_REGISTERED (LteSpectrumPhy);
LteSpectrumPhy::LteSpectrumPhy ()
: m_mobility (0),
m_device (0),
m_channel (0),
m_txPsd (0),
m_state (IDLE)
: m_state (IDLE)
{
}
@@ -52,6 +48,14 @@ LteSpectrumPhy::~LteSpectrumPhy ()
{
}
void LteSpectrumPhy::DoDispose ()
{
m_channel->Dispose ();
m_channel = 0;
m_mobility = 0;
m_device = 0;
}
std::ostream& operator<< (std::ostream& os, LteSpectrumPhy::State s)
{
switch (s)
@@ -141,14 +145,6 @@ LteSpectrumPhy::SetChannel (Ptr<SpectrumChannel> c)
m_channel = c;
}
Ptr<SpectrumChannel>
LteSpectrumPhy::GetChannel (void)
{
return m_channel;
}
Ptr<const SpectrumModel>
LteSpectrumPhy::GetRxSpectrumModel () const
{

View File

@@ -61,6 +61,7 @@ public:
// inherited from Object
static TypeId GetTypeId (void);
virtual void DoDispose ();
// inherited from SpectrumPhy
void SetChannel (Ptr<SpectrumChannel> c);
@@ -72,13 +73,6 @@ public:
void StartRx (Ptr<PacketBurst> pb, Ptr <const SpectrumValue> rxPsd, SpectrumType st, Time duration);
/**
* \brief Get the channel where the physical layer is attached
* \return a pointer to the channel
*/
Ptr<SpectrumChannel> GetChannel (void);
/**
* Get the SpectrumType used by this PHY
*