| OLD | NEW |
| (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 CHROME_BROWSER_SAFE_BROWSING_INCIDENT_REPORTING_TRACKED_PREFERENCE_INCID
ENT_H_ |
| 6 #define CHROME_BROWSER_SAFE_BROWSING_INCIDENT_REPORTING_TRACKED_PREFERENCE_INCID
ENT_H_ |
| 7 |
| 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "chrome/browser/safe_browsing/incident_reporting/incident.h" |
| 10 |
| 11 namespace safe_browsing { |
| 12 |
| 13 class ClientIncidentReport_IncidentData_TrackedPreferenceIncident; |
| 14 |
| 15 // An incident representing a tracked preference that has been modified or |
| 16 // cleared. |
| 17 class TrackedPreferenceIncident : public Incident { |
| 18 public: |
| 19 explicit TrackedPreferenceIncident( |
| 20 scoped_ptr<ClientIncidentReport_IncidentData_TrackedPreferenceIncident> |
| 21 tracked_preference); |
| 22 ~TrackedPreferenceIncident() override; |
| 23 |
| 24 // Incident: |
| 25 |
| 26 // Returns IncidentType::TRACKED_PREFERENCE. |
| 27 IncidentType GetType() const override; |
| 28 |
| 29 // Returns the preference path. |
| 30 std::string GetKey() const override; |
| 31 |
| 32 // Returns a digest computed over the payload. |
| 33 uint32_t ComputeDigest() const override; |
| 34 |
| 35 scoped_ptr<ClientIncidentReport_IncidentData> TakePayload() override; |
| 36 |
| 37 private: |
| 38 DISALLOW_COPY_AND_ASSIGN(TrackedPreferenceIncident); |
| 39 }; |
| 40 |
| 41 } // namespace safe_browsing |
| 42 |
| 43 #endif // CHROME_BROWSER_SAFE_BROWSING_INCIDENT_REPORTING_TRACKED_PREFERENCE_IN
CIDENT_H_ |
| OLD | NEW |