Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(251)

Side by Side Diff: third_party/WebKit/Source/core/dom/DocumentStatisticsCollector.h

Issue 1248643004: Test distillability without JavaScript (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@early
Patch Set: move tests, remove dbg msg Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef DocumentStatisticsCollector_h
6 #define DocumentStatisticsCollector_h
7
8 namespace WTF {
9 class String;
10 }
11
12 namespace blink {
13
14 class Document;
15
16 struct DocumentStatistics {
17 size_t nodeCount;
18 size_t elementCount;
19 size_t anchorElementCount;
20 size_t formElementCount;
21 size_t textContentLength;
22 size_t innerTextLength;
23 };
24
25 class DocumentStatisticsCollector {
26 public:
27 DocumentStatisticsCollector();
28
29 void setReadyToCollect() { m_readyToCollect = true; }
30 void collectStatistics(Document&);
31
32 private:
33 bool m_statisticsCollected : 1;
34 bool m_readyToCollect : 1;
35 };
36
37 }
38
39 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698