| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 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 | 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_SAFE_JSON_JSON_SANITIZER_H_ | 5 #ifndef COMPONENTS_SAFE_JSON_JSON_SANITIZER_H_ |
| 6 #define COMPONENTS_SAFE_JSON_JSON_SANITIZER_H_ | 6 #define COMPONENTS_SAFE_JSON_JSON_SANITIZER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/callback_forward.h" | 10 #include "base/callback_forward.h" |
| 11 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
| 12 #include "base/macros.h" | 12 #include "base/macros.h" |
| 13 #include "base/memory/scoped_ptr.h" | |
| 14 #include "build/build_config.h" | 13 #include "build/build_config.h" |
| 15 | 14 |
| 16 #if defined(OS_ANDROID) | 15 #if defined(OS_ANDROID) |
| 17 #include <jni.h> | 16 #include <jni.h> |
| 18 #endif | 17 #endif |
| 19 | 18 |
| 20 namespace safe_json { | 19 namespace safe_json { |
| 21 | 20 |
| 22 // Sanitizes and normalizes JSON by parsing it in a safe environment and | 21 // Sanitizes and normalizes JSON by parsing it in a safe environment and |
| 23 // re-serializing it. Parsing the sanitized JSON should result in a value | 22 // re-serializing it. Parsing the sanitized JSON should result in a value |
| (...skipping 21 matching lines...) Expand all Loading... |
| 45 JsonSanitizer() {} | 44 JsonSanitizer() {} |
| 46 ~JsonSanitizer() {} | 45 ~JsonSanitizer() {} |
| 47 | 46 |
| 48 private: | 47 private: |
| 49 DISALLOW_COPY_AND_ASSIGN(JsonSanitizer); | 48 DISALLOW_COPY_AND_ASSIGN(JsonSanitizer); |
| 50 }; | 49 }; |
| 51 | 50 |
| 52 } // namespace safe_json | 51 } // namespace safe_json |
| 53 | 52 |
| 54 #endif // COMPONENTS_SAFE_JSON_JSON_SANITIZER_H_ | 53 #endif // COMPONENTS_SAFE_JSON_JSON_SANITIZER_H_ |
| OLD | NEW |