src/helper/on-off-helper.cc
changeset 2965 4b28e9740e3b
parent 2890 172baa5960ff
child 3848 affd0834debc
equal deleted inserted replaced
2964:4e8cb1577144 2965:4b28e9740e3b
    25 namespace ns3 {
    25 namespace ns3 {
    26 
    26 
    27 OnOffHelper::OnOffHelper (std::string protocol, Address address)
    27 OnOffHelper::OnOffHelper (std::string protocol, Address address)
    28 {
    28 {
    29   m_factory.SetTypeId ("ns3::OnOffApplication");
    29   m_factory.SetTypeId ("ns3::OnOffApplication");
    30   m_factory.Set ("Protocol", String(protocol));
    30   m_factory.Set ("Protocol", StringValue (protocol));
    31   m_factory.Set ("Remote", address);
    31   m_factory.Set ("Remote", AddressValue (address));
    32 }
    32 }
    33 
    33 
    34 void 
    34 void 
    35 OnOffHelper::SetAttribute (std::string name, Attribute value)
    35 OnOffHelper::SetAttribute (std::string name, const AttributeValue &value)
    36 {
    36 {
    37   m_factory.Set (name, value);
    37   m_factory.Set (name, value);
    38 }
    38 }
    39 
    39 
    40 ApplicationContainer
    40 ApplicationContainer