Page Speed Optimization Libraries  1.12.34.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Classes | Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
net_instaweb::NestedFilter Class Reference

#include "rewrite_context_test_base.h"

Inheritance diagram for net_instaweb::NestedFilter:
net_instaweb::RewriteFilter net_instaweb::CommonFilter net_instaweb::EmptyHtmlFilter net_instaweb::HtmlFilter

Classes

class  Context
 
class  NestedSlot
 

Public Member Functions

 NestedFilter (RewriteDriver *driver, SimpleTextFilter *upper_filter, UpperCaseRewriter *upper_rewriter, bool expected_nested_result)
 
int num_top_rewrites () const
 Stats.
 
int num_sub_rewrites () const
 
void ClearStats ()
 
void set_chain (bool x)
 Set this to true to create a chain of nested rewrites on the same slot.
 
bool expected_nested_rewrite_result () const
 
void set_expected_nested_rewrite_result (bool x)
 
void set_check_nested_rewrite_result (bool x)
 
- Public Member Functions inherited from net_instaweb::RewriteFilter
 RewriteFilter (RewriteDriver *driver)
 
virtual void DetermineEnabled (GoogleString *disabled_reason)
 
virtual bool CanModifyUrls ()
 
virtual const UrlSegmentEncoderencoder () const
 
virtual bool ComputeOnTheFly () const
 
virtual RewriteContextMakeNestedRewriteContext (RewriteContext *parent, const ResourceSlotPtr &slot)
 
virtual void EncodeUserAgentIntoResourceContext (ResourceContext *context) const
 
virtual const
RewriteOptions::Filter
RelatedFilters (int *num_filters) const
 
virtual const StringPieceVector * RelatedOptions () const
 
- Public Member Functions inherited from net_instaweb::CommonFilter
 CommonFilter (RewriteDriver *driver)
 
const GoogleUrlbase_url () const
 Getters. More...
 
const GoogleUrldecoded_base_url () const
 
RewriteDriverdriver () const
 
HtmlElementnoscript_element () const
 
void InsertNodeAtBodyEnd (HtmlNode *data)
 
virtual void StartDocument ()
 Note: Don't overload these methods, overload the implementers instead!
 
virtual void StartElement (HtmlElement *element)
 
virtual void EndElement (HtmlElement *element)
 
virtual void Characters (HtmlCharactersNode *characters)
 
ResourcePtr CreateInputResource (StringPiece input_url, bool *is_authorized)
 
ResourcePtr CreateInputResourceOrInsertDebugComment (StringPiece input_url, HtmlElement *element)
 
void ResolveUrl (StringPiece input_url, GoogleUrl *out_url)
 
bool BaseUrlIsValid () const
 
bool DebugMode () const
 
bool CanAddPagespeedOnloadToImage (const HtmlElement &)
 
virtual void LogFilterModifiedContent ()
 
virtual
RewriteDriver::InlineAuthorizationPolicy 
AllowUnauthorizedDomain () const
 
virtual bool IntendedForInlining () const
 
void AddJsToElement (StringPiece js, HtmlElement *script)
 
- Public Member Functions inherited from net_instaweb::EmptyHtmlFilter
virtual void EndDocument ()
 
virtual void Cdata (HtmlCdataNode *cdata)
 Called for CDATA blocks (e.g. <![CDATA[foobar]]>)
 
virtual void Comment (HtmlCommentNode *comment)
 Called for HTML comments that aren't IE directives (e.g. ).
 
virtual void IEDirective (HtmlIEDirectiveNode *directive)
 
virtual void Directive (HtmlDirectiveNode *directive)
 Called for HTML directives (e.g. <!doctype foobar>).
 
virtual void Flush ()
 
ScriptUsage GetScriptUsage () const override
 
- Public Member Functions inherited from net_instaweb::HtmlFilter
virtual void RenderDone ()
 
bool is_enabled () const
 
void set_is_enabled (bool is_enabled)
 

Static Public Attributes

static const bool kExpectNestedRewritesSucceed = true
 For use with NestedFilter constructor.
 
static const bool kExpectNestedRewritesFail = false
 
static const char kFilterId []
 
- Static Public Attributes inherited from net_instaweb::CommonFilter
static const char kCreateResourceFailedDebugMsg []
 Debug message to be inserted when resource creation fails.
 

Protected Member Functions

virtual RewriteContextMakeRewriteContext ()
 
virtual void StartElementImpl (HtmlElement *element)
 
SimpleTextFilterupper_filter ()
 
virtual const char * id () const
 
virtual const char * Name () const
 The name of this filter – used for logging and debugging.
 
virtual void StartDocumentImpl ()
 
virtual void EndElementImpl (HtmlElement *element)
 
- Protected Member Functions inherited from net_instaweb::RewriteFilter
virtual const char * LoggingId ()
 This class logs using id().
 
- Protected Member Functions inherited from net_instaweb::CommonFilter
ServerContextserver_context () const
 
const RewriteOptionsrewrite_options ()
 

Additional Inherited Members

- Public Types inherited from net_instaweb::HtmlFilter
enum  ScriptUsage { kWillInjectScripts, kMayInjectScripts, kNeverInjectsScripts }
 Describes a filter's relationship with scripts. More...
 
- Static Public Member Functions inherited from net_instaweb::RewriteFilter
static StringPiece GetCharsetForScript (const Resource *script, const StringPiece attribute_charset, const StringPiece enclosing_charset)
 
static GoogleString GetCharsetForStylesheet (const Resource *stylesheet, const StringPiece attribute_charset, const StringPiece enclosing_charset)
 
- Static Public Member Functions inherited from net_instaweb::CommonFilter
static bool ExtractMetaTagDetails (const HtmlElement &element, const ResponseHeaders *headers, GoogleString *content, GoogleString *mime_type, GoogleString *charset)
 

Detailed Description

Filter that contains nested resources that must themselves be rewritten.

Member Function Documentation

virtual RewriteContext* net_instaweb::NestedFilter::MakeRewriteContext ( )
inlineprotectedvirtual

Generates a RewriteContext appropriate for this filter. Default implementation returns NULL. This must be overridden by filters. This is used to implement Fetch.

Reimplemented from net_instaweb::RewriteFilter.

virtual void net_instaweb::NestedFilter::StartDocumentImpl ( )
inlineprotectedvirtual

Overload these implementer methods: Intentionally left abstract so that implementers don't forget to change the name from Blah to BlahImpl.

Implements net_instaweb::CommonFilter.


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