A Discrete-Event Network Simulator
API
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
ns3::OutputStreamWrapper Class Reference

#include <output-stream-wrapper.h>

+ Inheritance diagram for ns3::OutputStreamWrapper:
+ Collaboration diagram for ns3::OutputStreamWrapper:

Public Member Functions

 OutputStreamWrapper (std::string filename, std::ios::openmode filemode)
 
 OutputStreamWrapper (std::ostream *os)
 
 ~OutputStreamWrapper ()
 
std::ostream * GetStream (void)
 Return a pointer to an ostream previously set in the wrapper. More...
 
- Public Member Functions inherited from ns3::SimpleRefCount< OutputStreamWrapper >
 SimpleRefCount ()
 Constructor. More...
 
 SimpleRefCount (const SimpleRefCount &o)
 Copy constructor. More...
 
uint32_t GetReferenceCount (void) const
 Get the reference count of the object. More...
 
SimpleRefCountoperator= (const SimpleRefCount &o)
 Assignment. More...
 
void Ref (void) const
 Increment the reference count. More...
 
void Unref (void) const
 Decrement the reference count. More...
 

Private Attributes

bool m_destroyable
 
std::ostream * m_ostream
 

Additional Inherited Members

- Static Public Member Functions inherited from ns3::SimpleRefCount< OutputStreamWrapper >
static void Cleanup (void)
 Noop. More...
 

Detailed Description

Definition at line 70 of file output-stream-wrapper.h.

Constructor & Destructor Documentation

ns3::OutputStreamWrapper::OutputStreamWrapper ( std::string  filename,
std::ios::openmode  filemode 
)

Definition at line 29 of file output-stream-wrapper.cc.

References m_ostream, NS_ABORT_MSG_UNLESS, NS_LOG_FUNCTION, and ns3::FatalImpl::RegisterStream().

+ Here is the call graph for this function:

ns3::OutputStreamWrapper::OutputStreamWrapper ( std::ostream *  os)

Definition at line 41 of file output-stream-wrapper.cc.

References m_ostream, NS_ABORT_MSG_UNLESS, NS_LOG_FUNCTION, and ns3::FatalImpl::RegisterStream().

+ Here is the call graph for this function:

ns3::OutputStreamWrapper::~OutputStreamWrapper ( )

Definition at line 49 of file output-stream-wrapper.cc.

References m_destroyable, m_ostream, NS_LOG_FUNCTION, and ns3::FatalImpl::UnregisterStream().

+ Here is the call graph for this function:

Member Function Documentation

std::ostream * ns3::OutputStreamWrapper::GetStream ( void  )

Return a pointer to an ostream previously set in the wrapper.

See also
SetStream
Returns
a pointer to the encapsulated std::ostream

Definition at line 58 of file output-stream-wrapper.cc.

References m_ostream, and NS_LOG_FUNCTION.

Referenced by ns3::AsciiPhyReceiveSinkWithContext(), ns3::AsciiPhyReceiveSinkWithoutContext(), ns3::AsciiPhyTransmitSinkWithContext(), ns3::AsciiPhyTransmitSinkWithoutContext(), ns3::WimaxHelper::AsciiRxEvent(), ns3::WimaxHelper::AsciiTxEvent(), ns3::MobilityHelper::CourseChanged(), CwndChange(), CwndTracer(), Ns3TcpLossTestCase::CwndTracer(), ns3::AsciiTraceHelper::DefaultDequeueSinkWithContext(), ns3::AsciiTraceHelper::DefaultDequeueSinkWithoutContext(), ns3::AsciiTraceHelper::DefaultDropSinkWithContext(), ns3::AsciiTraceHelper::DefaultDropSinkWithoutContext(), ns3::AsciiTraceHelper::DefaultEnqueueSinkWithContext(), ns3::AsciiTraceHelper::DefaultEnqueueSinkWithoutContext(), ns3::AsciiTraceHelper::DefaultReceiveSinkWithContext(), ns3::AsciiTraceHelper::DefaultReceiveSinkWithoutContext(), Ns3TcpStateTestCase::DoRun(), Ns3TcpLossTestCase::DoRun(), ns3::Ipv4L3ProtocolDropSinkWithContext(), ns3::Ipv4L3ProtocolDropSinkWithoutContext(), ns3::Ipv4L3ProtocolRxSinkWithContext(), ns3::Ipv4L3ProtocolRxSinkWithoutContext(), ns3::Ipv4L3ProtocolTxSinkWithContext(), ns3::Ipv4L3ProtocolTxSinkWithoutContext(), ns3::Ipv6L3ProtocolDropSinkWithContext(), ns3::Ipv6L3ProtocolDropSinkWithoutContext(), ns3::Ipv6L3ProtocolRxSinkWithContext(), ns3::Ipv6L3ProtocolRxSinkWithoutContext(), ns3::Ipv6L3ProtocolTxSinkWithContext(), ns3::Ipv6L3ProtocolTxSinkWithoutContext(), ns3::aodv::RoutingTableEntry::Print(), ns3::dsdv::RoutingTableEntry::Print(), ns3::aodv::RoutingTable::Print(), ns3::dsdv::RoutingTable::Print(), ns3::dsdv::RoutingProtocol::PrintRoutingTable(), ns3::aodv::RoutingProtocol::PrintRoutingTable(), ns3::Ipv4StaticRouting::PrintRoutingTable(), ns3::Ipv4ListRouting::PrintRoutingTable(), ns3::Ipv4GlobalRouting::PrintRoutingTable(), ns3::Ipv6ListRouting::PrintRoutingTable(), ns3::Ipv4NixVectorRouting::PrintRoutingTable(), ns3::olsr::RoutingProtocol::PrintRoutingTable(), ns3::Ipv6StaticRouting::PrintRoutingTable(), SsThreshTracer(), and ns3::WriteAveragePowerSpectralDensityReport().

+ Here is the caller graph for this function:

Member Data Documentation

bool ns3::OutputStreamWrapper::m_destroyable
private

Definition at line 88 of file output-stream-wrapper.h.

Referenced by ~OutputStreamWrapper().

std::ostream* ns3::OutputStreamWrapper::m_ostream
private

Definition at line 87 of file output-stream-wrapper.h.

Referenced by GetStream(), OutputStreamWrapper(), and ~OutputStreamWrapper().


The documentation for this class was generated from the following files: