Page Speed Optimization Libraries
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | List of all members
net_instaweb::CombiningFilter::Combiner Class Reference
Inheritance diagram for net_instaweb::CombiningFilter::Combiner:

Public Member Functions

 Combiner (RewriteDriver *driver, RewriteFilter *filter)
OutputResourcePtr MakeOutput ()
bool Write (const ResourceVector &in, const OutputResourcePtr &out)
virtual bool WritePiece (int index, int num_pieces, const Resource *input, OutputResource *combination, Writer *writer, MessageHandler *handler)
void set_prefix (const GoogleString &prefix)
- Public Member Functions inherited from net_instaweb::ResourceCombiner
 ResourceCombiner (RewriteDriver *rewrite_driver, const StringPiece &extension, RewriteFilter *filter)
 Note: extension should not include the leading dot here.
void Reset ()
GoogleString UrlSafeId () const
int num_urls () const
 Returns the number of URLs that have been successfully added.
const ResourceVector & resources () const
GoogleString ResolvedBase () const
 Base common to all URLs. Always has a trailing slash.
TimedBool AddResourceNoFetch (const ResourcePtr &resource, MessageHandler *handler)

Additional Inherited Members

- Static Public Attributes inherited from net_instaweb::ResourceCombiner
static const int kUrlSlack = 100
- Protected Member Functions inherited from net_instaweb::ResourceCombiner
virtual void RemoveLastResource ()
OutputResourcePtr Combine (MessageHandler *handler)
virtual bool WriteCombination (const ResourceVector &combine_resources, const OutputResourcePtr &combination, MessageHandler *handler)
virtual void Clear ()
- Protected Attributes inherited from net_instaweb::ResourceCombiner
ServerContext *const server_context_
RewriteDriver *const rewrite_driver_

Member Function Documentation

virtual bool net_instaweb::CombiningFilter::Combiner::WritePiece ( int  index,
int  num_pieces,
const Resource input,
OutputResource combination,
Writer writer,
MessageHandler handler 

Override this to alter how pieces are processed when included inside a combination. Returns whether successful. The default implementation writes input->contents() to the writer without any alteration. 'index' is the position of this piece in the combination, while num_pieces is the total number of pieces.

Reimplemented from net_instaweb::ResourceCombiner.

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