Back to index

lightning-sunbird  0.9+nobinonly
Public Member Functions | Private Attributes
nsHttpPushBackWriter Class Reference
Inheritance diagram for nsHttpPushBackWriter:
Inheritance graph
Collaboration diagram for nsHttpPushBackWriter:
Collaboration graph

List of all members.

Public Member Functions

 nsHttpPushBackWriter (const char *buf, PRUint32 bufLen)
virtual ~nsHttpPushBackWriter ()
nsresult OnWriteSegment (char *buf, PRUint32 count, PRUint32 *countWritten)

Private Attributes

const char * mBuf
PRUint32 mBufLen

Detailed Description

Definition at line 62 of file nsHttpPipeline.cpp.

Constructor & Destructor Documentation

nsHttpPushBackWriter::nsHttpPushBackWriter ( const char *  buf,
PRUint32  bufLen 
) [inline]

Definition at line 65 of file nsHttpPipeline.cpp.

        : mBuf(buf)
        , mBufLen(bufLen)
        { }
virtual nsHttpPushBackWriter::~nsHttpPushBackWriter ( ) [inline, virtual]

Definition at line 69 of file nsHttpPipeline.cpp.


Member Function Documentation

nsresult nsHttpPushBackWriter::OnWriteSegment ( char *  buf,
PRUint32  count,
PRUint32 countWritten 
) [inline, virtual]

Implements nsAHttpSegmentWriter.

Definition at line 71 of file nsHttpPipeline.cpp.

        if (mBufLen == 0)
            return NS_BASE_STREAM_CLOSED;

        if (count > mBufLen)
            count = mBufLen;

        memcpy(buf, mBuf, count);

        mBuf += count;
        mBufLen -= count;
        *countWritten = count;
        return NS_OK;

Here is the call graph for this function:

Member Data Documentation

Definition at line 88 of file nsHttpPipeline.cpp.

Definition at line 89 of file nsHttpPipeline.cpp.

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