19 #ifndef NET_INSTAWEB_REWRITER_PUBLIC_DEDUP_INLINED_IMAGES_FILTER_H_
20 #define NET_INSTAWEB_REWRITER_PUBLIC_DEDUP_INLINED_IMAGES_FILTER_H_
30 namespace net_instaweb {
59 virtual void StartElementImpl(
HtmlElement* element);
63 virtual const char*
Name()
const {
return "DedupInlinedImages"; }
67 bool IsDedupCandidate(
HtmlElement* element, StringPiece* src_iff_true);
70 bool script_inserted_;
71 StringStringMap hash_to_id_map_;
75 Variable* num_dedup_inlined_images_candidates_found_;
77 Variable* num_dedup_inlined_images_candidates_replaced_;
virtual void DetermineEnabled(GoogleString *disabled_reason)
Definition: common_filter.h:47
Definition: statistics.h:43
Base class for implementations of monitoring statistics.
Definition: statistics.h:342
static const char kDiiInitializer[]
public for the test harness only.
Definition: dedup_inlined_images_filter.h:45
Definition: html_element.h:42
static const char kCandidatesFound[]
Statistics' names.
Definition: dedup_inlined_images_filter.h:48
static void InitStats(Statistics *statistics)
May be called multiple times, if there are multiple statistics objects.
std::string GoogleString
PAGESPEED_KERNEL_BASE_STRING_H_.
Definition: string.h:24
ScriptUsage GetScriptUsage() const override
Definition: dedup_inlined_images_filter.h:64
static const char kCandidatesReplaced[]
No. of those replaced with JS.
Definition: dedup_inlined_images_filter.h:49
ScriptUsage
Describes a filter's relationship with scripts.
Definition: html_filter.h:38
static const unsigned int kMinimumImageCutoff
Dont dedup if smaller.
Definition: dedup_inlined_images_filter.h:43
Definition: rewrite_driver.h:100
virtual void EndDocument()
virtual void StartDocumentImpl()
Definition: html_filter.h:43
virtual const char * Name() const
The name of this filter – used for logging and debugging.
Definition: dedup_inlined_images_filter.h:63
Definition: dedup_inlined_images_filter.h:41