crash_keys_android.h 996 B

12345678910111213141516171819202122232425262728293031
  1. // Copyright 2018 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. #ifndef COMPONENTS_CRASH_ANDROID_CRASH_KEYS_ANDROID_H_
  5. #define COMPONENTS_CRASH_ANDROID_CRASH_KEYS_ANDROID_H_
  6. #include <string>
  7. // See CrashKeys.java for how to add a new crash key.
  8. // A Java counterpart will be generated for this enum.
  9. // GENERATED_JAVA_ENUM_PACKAGE: org.chromium.components.crash
  10. enum class CrashKeyIndex {
  11. LOADED_DYNAMIC_MODULE = 0,
  12. ACTIVE_DYNAMIC_MODULE,
  13. APPLICATION_STATUS,
  14. INSTALLED_MODULES,
  15. EMULATED_MODULES,
  16. DYNAMIC_MODULE_DEX_NAME,
  17. PARTNER_CUSTOMIZATION_CONFIG,
  18. FIRST_RUN,
  19. NUM_ENTRIES
  20. };
  21. // These methods are only exposed for testing -- normal usage should be from
  22. // Java.
  23. void SetAndroidCrashKey(CrashKeyIndex index, const std::string& value);
  24. void ClearAndroidCrashKey(CrashKeyIndex index);
  25. void FlushAndroidCrashKeys();
  26. #endif // COMPONENTS_CRASH_ANDROID_CRASH_KEYS_ANDROID_H_