NewNet::Object Class Reference

Base class for objects. More...

#include <nnobject.h>

Inheritance diagram for NewNet::Object:

NewNet::Buffer NewNet::Event< T > NewNet::Event< T >::Callback NewNet::Event< ClientType * > NewNet::FactorySocket< ServerType, ClientType > NewNet::FactorySocket< NewNet::TcpServerSocket, ClientType > NewNet::FactorySocket< NewNet::UnixServerSocket, ClientType > NewNet::RateLimiter NewNet::Reactor NewNet::Socket List of all members.

Public Member Functions

 Object ()
 Constructor.
 Object (const Object &)
 Copy constructor.
virtual ~Object ()
 Destructor.
GuardObjectguardObject ()
 Reference to the guard object.
RefCounterrefCounter ()
 Reference to the reference counter.

Detailed Description

This provides a base class for NewNet objects. It provides a reference counter and a guard object for detecting deletion of the object.

Definition at line 39 of file nnobject.h.


Constructor & Destructor Documentation

NewNet::Object::Object (  )  [inline]

This constructs a new object. Note that you don't have to call this. It's an empty method.

Definition at line 45 of file nnobject.h.

NewNet::Object::Object ( const Object  )  [inline]

Ensures that the reference count of the copied object is 0 and that the guard object is empty.

Definition at line 52 of file nnobject.h.

virtual NewNet::Object::~Object (  )  [inline, virtual]

When an object is destroyed, the guard object will be emitted so the registered callbacks get called.

Definition at line 59 of file nnobject.h.

References NewNet::RefCounter::count().


Member Function Documentation

GuardObject& NewNet::Object::guardObject (  )  [inline]

This returns a reference to the object's guard object so you can hook in your own callbacks if you want to.

Definition at line 75 of file nnobject.h.

RefCounter& NewNet::Object::refCounter (  )  [inline]

This returns a reference to the object's reference counter so you can manipulate it if you want to.

Definition at line 83 of file nnobject.h.

Referenced by NewNet::Event< T >::Callback::disconnect().


The documentation for this class was generated from the following file:
Generated on Sun Jan 7 14:00:01 2007 for NewNet by  doxygen 1.5.1