#include <plc-outlet.h>
Public Member Functions | |
PLC_Outlet (Ptr< PLC_Node > node, Ptr< PLC_Impedance > impedance=0) | |
Constructor. | |
void | RegisterBackboneBranch (Ptr< PLC_BackboneBranch > bb_branch) |
void | SetImpedance (Ptr< PLC_Impedance > impedance, bool updateImmediately=true) |
Ptr< PLC_Impedance > | GetImpedance (void) |
bool | IsTimeVariant (void) |
Ptr< PLC_Node > | GetNode (void) |
void | SetRxInterface (Ptr< PLC_RxInterface > interface) |
Ptr< PLC_RxInterface > | GetRxInterface (void) |
void | Lock (void) const |
void | Unlock (void) const |
Static Public Member Functions | |
static TypeId | GetTypeId (void) |
Class representing an outlet in the PLC network. An outlet has to be bound to a PLC_Node and an impedance can be assigned to it. The main purpose of PLC_Outlet is to define network nodes that may sporadically change their shunt impedance while the simulation is running. If this happens all affected cached equivalent impedances, edge transfer units and channel transfer functions are set out of date resulting in a recomputation of these values when needed the next time.
ns3::PLC_Outlet::PLC_Outlet | ( | Ptr< PLC_Node > | node, |
Ptr< PLC_Impedance > | impedance = 0 |
||
) |
Constructor.
node | PLC_Node the outlet is connected to |
impedance | PLC_Impedance to connect with the outlet |
Ptr< PLC_Impedance > ns3::PLC_Outlet::GetImpedance | ( | void | ) |
Ptr<PLC_Node> ns3::PLC_Outlet::GetNode | ( | void | ) | [inline] |
Ptr< PLC_RxInterface > ns3::PLC_Outlet::GetRxInterface | ( | void | ) |
bool ns3::PLC_Outlet::IsTimeVariant | ( | void | ) |
void ns3::PLC_Outlet::Lock | ( | void | ) | const [inline] |
Mutex lock and unlock
void ns3::PLC_Outlet::RegisterBackboneBranch | ( | Ptr< PLC_BackboneBranch > | bb_branch | ) |
Register a PLC_BackboneBranch which is affected by an impedance change of this outlet. This is done by the depth first search algorithm within PLC_ChannelTransferImpl::DiscoverOutlets
bb_branch | Affected PLC_BackboneBranch |
void ns3::PLC_Outlet::SetImpedance | ( | Ptr< PLC_Impedance > | impedance, |
bool | updateImmediately = true |
||
) |
Change the shunt impedance of the outlet and set all affected values of the PLC network out of date.
impedance | New shunt impedance |
updateImmediately | If true all channels and currently active receive PSDs will be recalculated |
void ns3::PLC_Outlet::SetRxInterface | ( | Ptr< PLC_RxInterface > | interface | ) |
Notify the outlet that it has an RX interface on top. This is necessary to set out of date all backbone paths leading to this node.