Crashpad

Public Member Functions | List of all members
crashpad::DatabaseSizePruneCondition Class Referencefinal

A PruneCondition that deletes older reports to keep the total Crashpad database size under the specified limit. More...

`#include "client/prune_crash_reports.h"`

Inheritance diagram for crashpad::DatabaseSizePruneCondition:

## Public Member Functions
| DatabaseSizePruneCondition (size_t max_size_in_kb)
| Creates a PruneCondition that will keep newer reports, until the sum of the size of all reports is not smaller than max_size_in_kb. After the limit is reached, older reports will be pruned. More...
bool | ShouldPruneReport (const CrashReportDatabase::Report &report) override
| Evaluates a crash report for deletion. More...

## Additional Inherited Members
Static Public Member Functions inherited from crashpad::PruneCondition
static std::unique_ptr< PruneCondition > | GetDefault ()
| Returns a sensible default condition for removing obsolete crash reports. More...

## Detailed Description

A PruneCondition that deletes older reports to keep the total Crashpad database size under the specified limit.

## Constructor & Destructor Documentation

## ◆ DatabaseSizePruneCondition()

crashpad::DatabaseSizePruneCondition::DatabaseSizePruneCondition | ( | size_t | max_size_in_kb | ) |
| explicit

Creates a PruneCondition that will keep newer reports, until the sum of the size of all reports is not smaller than max_size_in_kb. After the limit is reached, older reports will be pruned.

Parameters

  [in] | max_size_in_kb | The maximum number of kilobytes that all crash reports should consume.

## Member Function Documentation

## ◆ ShouldPruneReport()

bool crashpad::DatabaseSizePruneCondition::ShouldPruneReport | ( | const CrashReportDatabase::Report & | report | ) |
| override virtual

Evaluates a crash report for deletion.

Parameters

  [in] | report | The crash report to evaluate.

Returns
  `true` if the crash report should be deleted, `false` if it should be kept.

Implements crashpad::PruneCondition.

The documentation for this class was generated from the following files:

- client/prune_crash_reports.h
- client/prune_crash_reports.cc