Page Speed Optimization Libraries  1.8.31.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Protected Member Functions
net_instaweb::StringAsyncFetch Class Reference

#include "async_fetch.h"

Inheritance diagram for net_instaweb::StringAsyncFetch:
net_instaweb::AsyncFetch net_instaweb::ExpectStringAsyncFetch net_instaweb::FetcherTest::CheckCallback

List of all members.

Public Member Functions

 StringAsyncFetch (const RequestContextPtr &request_ctx)
 StringAsyncFetch (const RequestContextPtr &request_ctx, GoogleString *buffer)
virtual bool HandleWrite (const StringPiece &content, MessageHandler *handler)
virtual bool HandleFlush (MessageHandler *handler)
virtual void HandleHeadersComplete ()
virtual void HandleDone (bool success)
bool success () const
bool done () const
const GoogleString & buffer () const
virtual void Reset ()

Protected Member Functions

void set_success (bool success)
void set_done (bool done)

Detailed Description

Class to represent an Async fetch that collects the response-data into a string, which can be accessed via buffer() and cleared via Reset().

Todo:
TODO(jmarantz): move StringAsyncFetch into its own file.

Member Function Documentation

virtual void net_instaweb::StringAsyncFetch::Reset ( ) [inline, virtual]

Resets the 'headers_complete_' flag.

Todo:
TODO(jmarantz): should this also clear the response headers?

Reimplemented from net_instaweb::AsyncFetch.

void net_instaweb::StringAsyncFetch::set_success ( bool  success) [inline, protected]

For subclasses that need to use complex logic to set success_ and done_. Most subclasses should not need these.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines