| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 // An object to record and send user feedback to spelling service. The spelling | 5 // An object to record and send user feedback to spelling service. The spelling |
| 6 // service uses the feedback to improve its suggestions. | 6 // service uses the feedback to improve its suggestions. |
| 7 // | 7 // |
| 8 // Assigns uint32_t hash identifiers to spelling suggestions from spelling | 8 // Assigns uint32_t hash identifiers to spelling suggestions from spelling |
| 9 // service and stores these suggestions. Records user's actions on these | 9 // service and stores these suggestions. Records user's actions on these |
| 10 // suggestions. Periodically sends batches of user feedback to the spelling | 10 // suggestions. Periodically sends batches of user feedback to the spelling |
| 11 // service. | 11 // service. |
| 12 | 12 |
| 13 #ifndef CHROME_BROWSER_SPELLCHECKER_FEEDBACK_SENDER_H_ | 13 #ifndef CHROME_BROWSER_SPELLCHECKER_FEEDBACK_SENDER_H_ |
| 14 #define CHROME_BROWSER_SPELLCHECKER_FEEDBACK_SENDER_H_ | 14 #define CHROME_BROWSER_SPELLCHECKER_FEEDBACK_SENDER_H_ |
| 15 | 15 |
| 16 #include <stddef.h> | 16 #include <stddef.h> |
| 17 #include <stdint.h> | 17 #include <stdint.h> |
| 18 | 18 |
| 19 #include <array> | 19 #include <array> |
| 20 #include <climits> | 20 #include <climits> |
| 21 #include <map> | 21 #include <map> |
| 22 #include <set> | 22 #include <set> |
| 23 #include <vector> | 23 #include <vector> |
| 24 | 24 |
| 25 #include "base/macros.h" | 25 #include "base/macros.h" |
| 26 #include "base/memory/scoped_vector.h" | 26 #include "base/memory/scoped_vector.h" |
| 27 #include "base/memory/weak_ptr.h" | 27 #include "base/memory/weak_ptr.h" |
| 28 #include "base/timer/timer.h" | 28 #include "base/timer/timer.h" |
| 29 #include "chrome/browser/spellchecker/feedback.h" | 29 #include "components/spellcheck/browser/feedback.h" |
| 30 #include "chrome/browser/spellchecker/misspelling.h" | 30 #include "components/spellcheck/browser/misspelling.h" |
| 31 #include "net/url_request/url_fetcher_delegate.h" | 31 #include "net/url_request/url_fetcher_delegate.h" |
| 32 #include "url/gurl.h" | 32 #include "url/gurl.h" |
| 33 | 33 |
| 34 class SpellCheckMarker; | 34 class SpellCheckMarker; |
| 35 struct SpellCheckResult; | 35 struct SpellCheckResult; |
| 36 | 36 |
| 37 namespace net { | 37 namespace net { |
| 38 class URLFetcher; | 38 class URLFetcher; |
| 39 class URLRequestContextGetter; | 39 class URLRequestContextGetter; |
| 40 } | 40 } |
| (...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 187 // If a sender is destroyed before it finishes, then sending feedback will be | 187 // If a sender is destroyed before it finishes, then sending feedback will be |
| 188 // canceled. | 188 // canceled. |
| 189 ScopedVector<net::URLFetcher> senders_; | 189 ScopedVector<net::URLFetcher> senders_; |
| 190 | 190 |
| 191 DISALLOW_COPY_AND_ASSIGN(FeedbackSender); | 191 DISALLOW_COPY_AND_ASSIGN(FeedbackSender); |
| 192 }; | 192 }; |
| 193 | 193 |
| 194 } // namespace spellcheck | 194 } // namespace spellcheck |
| 195 | 195 |
| 196 #endif // CHROME_BROWSER_SPELLCHECKER_FEEDBACK_SENDER_H_ | 196 #endif // CHROME_BROWSER_SPELLCHECKER_FEEDBACK_SENDER_H_ |
| OLD | NEW |