Add deletion functionality to the background services context.

This will delete all the logged events for the background service.

The upstream CL this is based on adds the ability to clear user data
across all registrations.

This CL also exposes a `ShouldLogEvent` function for clients to know
whether they should create an event proto or not.

Bug: 927726
Change-Id: I68f5419251ee29ecc130d0df712da556109e2860
Reviewed-on: https://chromium-review.googlesource.com/c/1470703
Commit-Queue: Rayan Kanso <rayankans@chromium.org>
Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
Cr-Commit-Position: refs/heads/master@{#633694}
3 files changed