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

Side by Side Diff: components/translate/core/browser/translate_ranker.h

Issue 2930433004: Send UMA recording state to TranslateRanker. (Closed)
Patch Set: Enable Logging in tests that use Flushing. Created 3 years, 6 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
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_RANKER_H_ 5 #ifndef COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_RANKER_H_
6 #define COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_RANKER_H_ 6 #define COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_RANKER_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 // |translate_event.decision_overrides()|. If override is disabled, 53 // |translate_event.decision_overrides()|. If override is disabled,
54 // returns false and finalize and record |translate_event| with 54 // returns false and finalize and record |translate_event| with
55 // |event_type| as |translate_event.event_type()|. |event_type| 55 // |event_type| as |translate_event.event_type()|. |event_type|
56 // must be one of the values defined by 56 // must be one of the values defined by
57 // metrics::TranslateEventProto::EventType. 57 // metrics::TranslateEventProto::EventType.
58 virtual bool ShouldOverrideDecision( 58 virtual bool ShouldOverrideDecision(
59 int event_type, 59 int event_type,
60 const GURL& url, 60 const GURL& url,
61 metrics::TranslateEventProto* translate_event) = 0; 61 metrics::TranslateEventProto* translate_event) = 0;
62 62
63 // Override the default enabled/disabled state of translate event logging.
64 virtual void EnableLogging(bool enable_logging) = 0;
65
63 private: 66 private:
64 DISALLOW_COPY_AND_ASSIGN(TranslateRanker); 67 DISALLOW_COPY_AND_ASSIGN(TranslateRanker);
65 }; 68 };
66 69
67 } // namespace translate 70 } // namespace translate
68 71
69 #endif // COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_RANKER_H_ 72 #endif // COMPONENTS_TRANSLATE_CORE_BROWSER_TRANSLATE_RANKER_H_
OLDNEW
« no previous file with comments | « components/translate/core/browser/mock_translate_ranker.h ('k') | components/translate/core/browser/translate_ranker_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698