mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
60 lines
2.2 KiB
Plaintext
60 lines
2.2 KiB
Plaintext
/* 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 nsINetworkInterface;
|
|
|
|
[scriptable, function, uuid(5f821529-1d80-4ab5-a933-4e1b3585b6bc)]
|
|
interface nsINetworkStatsServiceProxyCallback : nsISupports
|
|
{
|
|
/*
|
|
* @param aResult callback result with boolean value
|
|
* @param aMessage message
|
|
*/
|
|
void notify(in boolean aResult, in jsval aMessage);
|
|
};
|
|
|
|
[scriptable, uuid(98fd8f69-784e-4626-aa59-56d6436a3c24)]
|
|
interface nsINetworkStatsServiceProxy : nsISupports
|
|
{
|
|
/*
|
|
* An interface used to record per-app traffic data.
|
|
* @param aAppId app id
|
|
* @param aIsInBrowser true if the iframe element is mozbrowser
|
|
* @param aNetworkInterface network
|
|
* @param aTimeStamp time stamp
|
|
* @param aRxBytes received data amount
|
|
* @param aTxBytes transmitted data amount
|
|
* @param aIsAccumulative is stats accumulative
|
|
* @param aCallback an optional callback
|
|
*/
|
|
void saveAppStats(in unsigned long aAppId,
|
|
in boolean aIsInBrowser,
|
|
in nsINetworkInterface aNetwork,
|
|
in unsigned long long aTimeStamp,
|
|
in unsigned long long aRxBytes,
|
|
in unsigned long long aTxBytes,
|
|
in boolean aIsAccumulative,
|
|
[optional] in nsINetworkStatsServiceProxyCallback aCallback);
|
|
|
|
/*
|
|
* An interface used to record per-system service traffic data.
|
|
* @param aServiceType system service type
|
|
* @param aNetworkInterface network
|
|
* @param aTimeStamp time stamp
|
|
* @param aRxBytes received data amount
|
|
* @param aTxBytes transmitted data amount
|
|
* @param aIsAccumulative is stats accumulative
|
|
* @param aCallback an optional callback
|
|
*/
|
|
void saveServiceStats(in string aServiceType,
|
|
in nsINetworkInterface aNetwork,
|
|
in unsigned long long aTimeStamp,
|
|
in unsigned long long aRxBytes,
|
|
in unsigned long long aTxBytes,
|
|
in boolean aIsAccumulative,
|
|
[optional] in nsINetworkStatsServiceProxyCallback aCallback);
|
|
};
|