Public Member Functions

atscppapi::transformations::GzipDeflateTransformation Class Reference

A TransformationPlugin to easily add gzip deflate to your TransformationPlugin chain. More...

#include <GzipDeflateTransformation.h>

Inherits atscppapi::TransformationPlugin.

Collaboration diagram for atscppapi::transformations::GzipDeflateTransformation:
Collaboration graph
[legend]

Public Member Functions

 GzipDeflateTransformation (Transaction &transaction, TransformationPlugin::Type type)
 A full example of how to use GzipDeflateTransformation and GzipInflateTransformation is available in examples/gzip_tranformation/.
void consume (const std::string &data)
 Any TransformationPlugin must implement consume(), this method will take content from the transformation chain and gzip compress it.
void handleInputComplete ()
 Any TransformationPlugin must implement handleInputComplete(), this method will finalize the gzip compression and flush any remaining data and the epilouge.
virtual ~GzipDeflateTransformation ()

Detailed Description

A TransformationPlugin to easily add gzip deflate to your TransformationPlugin chain.

The GzipDeflateTransformation is a helper transformation that can be used to easily compress content. For a full example of GzipDeflateTransformation and GzipInflateTransformation see examples/gzip_transformation/.

Note:
GzipDeflateTransformation DOES NOT set Content-Encoding headers, it is the users responsibility to set any applicable headers.
See also:
GzipInflateTransformation

Definition at line 53 of file GzipDeflateTransformation.h.


Constructor & Destructor Documentation

atscppapi::transformations::GzipDeflateTransformation::GzipDeflateTransformation ( Transaction transaction,
TransformationPlugin::Type  type 
)

A full example of how to use GzipDeflateTransformation and GzipInflateTransformation is available in examples/gzip_tranformation/.

Parameters:
transaction As with any TransformationPlugin you must pass in the transaction
type because the GzipDeflateTransformation can be used with both requests and responses you must specify the Type.
See also:
TransformationPlugin::Type
virtual atscppapi::transformations::GzipDeflateTransformation::~GzipDeflateTransformation (  )  [virtual]

Member Function Documentation

void atscppapi::transformations::GzipDeflateTransformation::consume ( const std::string &  data  )  [virtual]

Any TransformationPlugin must implement consume(), this method will take content from the transformation chain and gzip compress it.

Parameters:
data the input data to compress

Implements atscppapi::TransformationPlugin.

void atscppapi::transformations::GzipDeflateTransformation::handleInputComplete (  )  [virtual]

Any TransformationPlugin must implement handleInputComplete(), this method will finalize the gzip compression and flush any remaining data and the epilouge.

Implements atscppapi::TransformationPlugin.


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