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

Side by Side Diff: chrome/renderer/safe_browsing/phishing_term_feature_extractor.cc

Issue 18252003: Replace third_party/icu/public with third_party/icu/source (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: roll ICU to 211851 Created 7 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/renderer/safe_browsing/phishing_term_feature_extractor.h" 5 #include "chrome/renderer/safe_browsing/phishing_term_feature_extractor.h"
6 6
7 #include <list> 7 #include <list>
8 #include <map> 8 #include <map>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
11 #include "base/compiler_specific.h" 11 #include "base/compiler_specific.h"
12 #include "base/i18n/case_conversion.h" 12 #include "base/i18n/case_conversion.h"
13 #include "base/logging.h" 13 #include "base/logging.h"
14 #include "base/message_loop.h" 14 #include "base/message_loop.h"
15 #include "base/metrics/histogram.h" 15 #include "base/metrics/histogram.h"
16 #include "base/strings/utf_string_conversions.h" 16 #include "base/strings/utf_string_conversions.h"
17 #include "base/time/time.h" 17 #include "base/time/time.h"
18 #include "chrome/renderer/safe_browsing/feature_extractor_clock.h" 18 #include "chrome/renderer/safe_browsing/feature_extractor_clock.h"
19 #include "chrome/renderer/safe_browsing/features.h" 19 #include "chrome/renderer/safe_browsing/features.h"
20 #include "chrome/renderer/safe_browsing/murmurhash3_util.h" 20 #include "chrome/renderer/safe_browsing/murmurhash3_util.h"
21 #include "crypto/sha2.h" 21 #include "crypto/sha2.h"
22 #include "third_party/icu/public/common/unicode/ubrk.h" 22 #include "third_party/icu/source/common/unicode/ubrk.h"
23 #include "ui/base/l10n/l10n_util.h" 23 #include "ui/base/l10n/l10n_util.h"
24 24
25 namespace safe_browsing { 25 namespace safe_browsing {
26 26
27 // This time should be short enough that it doesn't noticeably disrupt the 27 // This time should be short enough that it doesn't noticeably disrupt the
28 // user's interaction with the page. 28 // user's interaction with the page.
29 const int PhishingTermFeatureExtractor::kMaxTimePerChunkMs = 10; 29 const int PhishingTermFeatureExtractor::kMaxTimePerChunkMs = 10;
30 30
31 // Experimenting shows that we get a reasonable gain in performance by 31 // Experimenting shows that we get a reasonable gain in performance by
32 // increasing this up to around 10, but there's not much benefit in 32 // increasing this up to around 10, but there's not much benefit in
(...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after
301 301
302 void PhishingTermFeatureExtractor::Clear() { 302 void PhishingTermFeatureExtractor::Clear() {
303 page_text_ = NULL; 303 page_text_ = NULL;
304 features_ = NULL; 304 features_ = NULL;
305 done_callback_.Reset(); 305 done_callback_.Reset();
306 state_.reset(NULL); 306 state_.reset(NULL);
307 negative_word_cache_.Clear(); 307 negative_word_cache_.Clear();
308 } 308 }
309 309
310 } // namespace safe_browsing 310 } // namespace safe_browsing
OLDNEW
« no previous file with comments | « chrome/renderer/pepper/ppb_pdf_impl.cc ('k') | chrome/renderer/spellchecker/spellcheck_worditerator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698