gecko-dev/toolkit/components/antitracking/nsITrackingDBService.idl
2019-05-31 15:13:33 +00:00

25 lines
1.0 KiB
Plaintext

/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "nsISupports.idl"
interface nsIPrincipal;
interface nsIAsyncInputStream;
[scriptable, uuid(650934db-1939-4424-be26-6ffb0375424d)]
interface nsITrackingDBService : nsISupports
{
/**
* Record entries from a content blocking log in the tracking database.
* This function is typically called at the end of the document lifecycle,
* since calling it multiple times results in multiple new entries.
*
* @param aFirstPartyPrincipal the principal of the first party that was
* loaded in the document that the content blocking log belongs to
* @param aInputStream the content blocking log as an input stream that outputs a JSON string
*/
void recordContentBlockingLog(in nsIPrincipal aFirstPartyPrincipal, in nsIAsyncInputStream aInputStream);
};