| Index: base/metrics/crash_sample_chromeos.h
|
| diff --git a/base/metrics/crash_sample_chromeos.h b/base/metrics/crash_sample_chromeos.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..f177f8e9c481806d05650109bb5252c3fa3a1ec8
|
| --- /dev/null
|
| +++ b/base/metrics/crash_sample_chromeos.h
|
| @@ -0,0 +1,30 @@
|
| +// Copyright (c) 2014 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef BASE_METRICS_CHROMEOS_CRASH_SAMPLE_CHROMEOS_H
|
| +#define BASE_METRICS_CHROMEOS_CRASH_SAMPLE_CHROMEOS_H
|
| +
|
| +#include <string>
|
| +
|
| +#include "base/base_export.h"
|
| +#include "base/compiler_specific.h"
|
| +#include "base/metrics/metric_sample_chromeos.h"
|
| +
|
| +namespace base {
|
| +// Represents a crash event described by a simple name.
|
| +class BASE_EXPORT CrashSample : public MetricSample {
|
| + public:
|
| + explicit CrashSample(const std::string& crashname);
|
| + virtual ~CrashSample();
|
| + // Produce a serialized version of the crash.
|
| + // Format: crash\0|name_|\0
|
| + virtual string ToString() const OVERRIDE;
|
| +
|
| + // static
|
| + // Return a CrashSample object representing the serialized crash if possible.
|
| + // If the deserialization fails, returns NULL.
|
| + static CrashSample* ReadCrash(const std::string& crash_serialized);
|
| +};
|
| +} // namespace base
|
| +#endif // BASE_METRICS_CHROMEOS_CRASH_SAMPLE_CHROMEOS_H
|
|
|