Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Compound Members | File Members

CBuf Class Reference

#include <tcpapp.h>

Collaboration diagram for CBuf:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 CBuf (AppData *c, int nbytes)
 ~CBuf ()
AppDatadata ()
int size ()
int bytes ()

Protected Attributes

AppDatadata_
int size_
int nbytes_
CBufnext_

Friends

class CBufList

Constructor & Destructor Documentation

CBuf::CBuf AppData c,
int  nbytes
 

Definition at line 32 of file tcpapp.cc.

References data_, nbytes_, next_, AppData::size(), and size_.

00033 {
00034         nbytes_ = nbytes;
00035         size_ = c->size();
00036         if (size_ > 0) 
00037                 data_ = c;
00038         else 
00039                 data_ = NULL;
00040         next_ = NULL;
00041 }

Here is the call graph for this function:

CBuf::~CBuf  )  [inline]
 

Definition at line 34 of file tcpapp.h.

References data_.

00034                 {
00035                 if (data_ != NULL)
00036                         delete data_;
00037         }


Member Function Documentation

int CBuf::bytes  )  [inline]
 

Definition at line 40 of file tcpapp.h.

References nbytes_.

Referenced by TcpApp::recv().

00040 { return nbytes_; }

AppData* CBuf::data  )  [inline]
 

Definition at line 38 of file tcpapp.h.

References data_.

Referenced by TcpApp::recv().

00038 { return data_; }

int CBuf::size  )  [inline]
 

Definition at line 39 of file tcpapp.h.

References size_.

Referenced by TcpApp::recv().

00039 { return size_; }


Friends And Related Function Documentation

friend class CBufList [friend]
 

Definition at line 48 of file tcpapp.h.


Member Data Documentation

AppData* CBuf::data_ [protected]
 

Definition at line 49 of file tcpapp.h.

Referenced by CBuf(), data(), and ~CBuf().

int CBuf::nbytes_ [protected]
 

Definition at line 51 of file tcpapp.h.

Referenced by bytes(), and CBuf().

CBuf* CBuf::next_ [protected]
 

Definition at line 52 of file tcpapp.h.

Referenced by CBuf(), CBufList::detach(), CBufList::insert(), and CBufList::~CBufList().

int CBuf::size_ [protected]
 

Definition at line 50 of file tcpapp.h.

Referenced by CBuf(), and size().


The documentation for this class was generated from the following files:
Generated on Tue Apr 20 12:35:34 2004 for NS2.26SourcesOriginal by doxygen 1.3.3