24 #include "ns3/names.h"
36 static TypeId tid =
TypeId(
"ns3::EnergyHarvesterContainer")
38 .SetGroupName(
"Energy")
Holds a vector of ns3::EnergyHarvester pointers.
void Clear()
Removes all elements in the container.
std::vector< Ptr< EnergyHarvester > >::const_iterator Iterator
Const iterator for EnergyHarvester container.
~EnergyHarvesterContainer() override
Iterator End() const
Get an iterator which refers to the last EnergyHarvester pointer in the container.
void DoDispose() override
Destructor implementation.
Iterator Begin() const
Get an iterator which refers to the first EnergyHarvester pointer in the container.
void DoInitialize() override
Calls Object::Initialize () for all EnergySource objects.
Ptr< EnergyHarvester > Get(uint32_t i) const
Get the i-th Ptr<EnergyHarvester> stored in this container.
void Add(EnergyHarvesterContainer container)
EnergyHarvesterContainer()
Creates an empty EnergyHarvesterContainer.
uint32_t GetN() const
Get the number of Ptr<EnergyHarvester> stored in this container.
static TypeId GetTypeId()
Get the type ID.
std::vector< Ptr< EnergyHarvester > > m_harvesters
Harvester container.
A base class which provides memory management and object aggregation.
Smart pointer class similar to boost::intrusive_ptr.
a unique identifier for an interface.
TypeId SetParent(TypeId tid)
Set the parent TypeId.
#define NS_ASSERT(condition)
At runtime, in debugging builds, if this condition is not true, the program prints the source file,...
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by ",...
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
Every class exported by the ns3 library is enclosed in the ns3 namespace.