LLPacketRing Class Reference

#include <llpacketring.h>

Collaboration diagram for LLPacketRing:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 LLPacketRing ()
 ~LLPacketRing ()
void free ()
void dropPackets (U32)
void setDropPercentage (F32 percent_to_drop)
void setUseInThrottle (const BOOL use_throttle)
void setUseOutThrottle (const BOOL use_throttle)
void setInBandwidth (const F32 bps)
void setOutBandwidth (const F32 bps)
S32 receivePacket (S32 socket, char *datap)
S32 receiveFromRing (S32 socket, char *datap)
BOOL sendPacket (int h_socket, char *send_buffer, S32 buf_size, LLHost host)
LLHost getLastSender ()
S32 getAndResetActualInBits ()
S32 getAndResetActualOutBits ()

Protected Attributes

BOOL mUseInThrottle
BOOL mUseOutThrottle
LLThrottle mInThrottle
LLThrottle mOutThrottle
S32 mActualBitsIn
S32 mActualBitsOut
S32 mMaxBufferLength
S32 mInBufferLength
S32 mOutBufferLength
F32 mDropPercentage
U32 mPacketsToDrop
std::queue< LLPacketBuffer * > mReceiveQueue
std::queue< LLPacketBuffer * > mSendQueue
LLHost mLastSender


Detailed Description

Definition at line 44 of file llpacketring.h.


Constructor & Destructor Documentation

LLPacketRing::LLPacketRing (  ) 

Definition at line 44 of file llpacketring.cpp.

LLPacketRing::~LLPacketRing (  ) 

Definition at line 60 of file llpacketring.cpp.

References free().

Here is the call graph for this function:


Member Function Documentation

void LLPacketRing::free ( void   ) 

Definition at line 66 of file llpacketring.cpp.

References mReceiveQueue, and mSendQueue.

Referenced by ~LLPacketRing().

Here is the caller graph for this function:

void LLPacketRing::dropPackets ( U32  num_to_drop  ) 

Definition at line 86 of file llpacketring.cpp.

References mPacketsToDrop.

Referenced by drop_packet().

Here is the caller graph for this function:

void LLPacketRing::setDropPercentage ( F32  percent_to_drop  ) 

Definition at line 92 of file llpacketring.cpp.

References mDropPercentage.

Referenced by idle_startup().

Here is the caller graph for this function:

void LLPacketRing::setUseInThrottle ( const BOOL  use_throttle  ) 

Definition at line 97 of file llpacketring.cpp.

References mUseInThrottle.

Referenced by idle_startup().

Here is the caller graph for this function:

void LLPacketRing::setUseOutThrottle ( const BOOL  use_throttle  ) 

Definition at line 102 of file llpacketring.cpp.

References mUseOutThrottle.

Referenced by idle_startup().

Here is the caller graph for this function:

void LLPacketRing::setInBandwidth ( const F32  bps  ) 

Definition at line 107 of file llpacketring.cpp.

References mInThrottle, and LLThrottle::setRate().

Referenced by idle_startup().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLPacketRing::setOutBandwidth ( const F32  bps  ) 

Definition at line 112 of file llpacketring.cpp.

References mOutThrottle, and LLThrottle::setRate().

Referenced by idle_startup().

Here is the call graph for this function:

Here is the caller graph for this function:

S32 LLPacketRing::receivePacket ( S32  socket,
char *  datap 
)

Definition at line 153 of file llpacketring.cpp.

References FALSE, get_sender(), LLPacketBuffer::getSize(), ll_frand(), llendl, llwarns, mActualBitsIn, mDropPercentage, mInBufferLength, mLastSender, mMaxBufferLength, mPacketsToDrop, mReceiveQueue, mUseInThrottle, NULL, receive_packet(), receiveFromRing(), and S32.

Referenced by LLMessageSystem::checkMessages().

Here is the call graph for this function:

Here is the caller graph for this function:

S32 LLPacketRing::receiveFromRing ( S32  socket,
char *  datap 
)

Definition at line 117 of file llpacketring.cpp.

References LLThrottle::checkOverflow(), LLPacketBuffer::getData(), LLPacketBuffer::getHost(), LLPacketBuffer::getSize(), mInBufferLength, mInThrottle, mLastSender, mReceiveQueue, NULL, S32, and LLThrottle::throttleOverflow().

Referenced by receivePacket().

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL LLPacketRing::sendPacket ( int  h_socket,
char *  send_buffer,
S32  buf_size,
LLHost  host 
)

LLHost LLPacketRing::getLastSender (  )  [inline]

Definition at line 91 of file llpacketring.h.

References mLastSender.

Referenced by LLMessageSystem::checkMessages(), and LLMessageSystem::dumpPacketToLog().

Here is the caller graph for this function:

S32 LLPacketRing::getAndResetActualInBits (  )  [inline]

Definition at line 65 of file llpacketring.h.

References mActualBitsIn, and S32.

Referenced by LLWorld::updateNetStats().

Here is the caller graph for this function:

S32 LLPacketRing::getAndResetActualOutBits (  )  [inline]

Definition at line 66 of file llpacketring.h.

References mActualBitsOut, and S32.

Referenced by LLWorld::updateNetStats().

Here is the caller graph for this function:


Member Data Documentation

Definition at line 68 of file llpacketring.h.

Referenced by receivePacket(), and setUseInThrottle().

Definition at line 69 of file llpacketring.h.

Referenced by sendPacket(), and setUseOutThrottle().

Definition at line 72 of file llpacketring.h.

Referenced by receiveFromRing(), and setInBandwidth().

Definition at line 73 of file llpacketring.h.

Referenced by sendPacket(), and setOutBandwidth().

Definition at line 75 of file llpacketring.h.

Referenced by getAndResetActualInBits(), and receivePacket().

Definition at line 76 of file llpacketring.h.

Referenced by getAndResetActualOutBits(), and sendPacket().

Definition at line 77 of file llpacketring.h.

Referenced by receivePacket(), and sendPacket().

Definition at line 78 of file llpacketring.h.

Referenced by receiveFromRing(), and receivePacket().

Definition at line 79 of file llpacketring.h.

Referenced by sendPacket().

Definition at line 81 of file llpacketring.h.

Referenced by receivePacket(), and setDropPercentage().

Definition at line 82 of file llpacketring.h.

Referenced by dropPackets(), and receivePacket().

std::queue<LLPacketBuffer *> LLPacketRing::mReceiveQueue [protected]

Definition at line 84 of file llpacketring.h.

Referenced by free(), receiveFromRing(), and receivePacket().

std::queue<LLPacketBuffer *> LLPacketRing::mSendQueue [protected]

Definition at line 85 of file llpacketring.h.

Referenced by free(), and sendPacket().

Definition at line 87 of file llpacketring.h.

Referenced by getLastSender(), receiveFromRing(), and receivePacket().


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

Generated on Fri May 16 08:55:09 2008 for SecondLife by  doxygen 1.5.5