dom/network/interfaces/nsINetworkStatsServiceProxy.idl

Thu, 22 Jan 2015 13:21:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 22 Jan 2015 13:21:57 +0100
branch
TOR_BUG_9701
changeset 15
b8a032363ba2
permissions
-rw-r--r--

Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6

michael@0 1 /* This Source Code Form is subject to the terms of the Mozilla Public
michael@0 2 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
michael@0 3 * You can obtain one at http://mozilla.org/MPL/2.0/. */
michael@0 4
michael@0 5 #include "nsISupports.idl"
michael@0 6
michael@0 7 interface nsINetworkInterface;
michael@0 8
michael@0 9 [scriptable, function, uuid(5f821529-1d80-4ab5-a933-4e1b3585b6bc)]
michael@0 10 interface nsINetworkStatsServiceProxyCallback : nsISupports
michael@0 11 {
michael@0 12 /*
michael@0 13 * @param aResult callback result with boolean value
michael@0 14 * @param aMessage message
michael@0 15 */
michael@0 16 void notify(in boolean aResult, in jsval aMessage);
michael@0 17 };
michael@0 18
michael@0 19 [scriptable, uuid(705c01d6-8574-464c-8ec9-ac1522a45546)]
michael@0 20 interface nsINetworkStatsServiceProxy : nsISupports
michael@0 21 {
michael@0 22 /*
michael@0 23 * An interface used to record per-app traffic data.
michael@0 24 * @param aAppId app id
michael@0 25 * @param aNetworkInterface network
michael@0 26 * @param aTimeStamp time stamp
michael@0 27 * @param aRxBytes received data amount
michael@0 28 * @param aTxBytes transmitted data amount
michael@0 29 * @param aIsAccumulative is stats accumulative
michael@0 30 * @param aCallback an optional callback
michael@0 31 */
michael@0 32 void saveAppStats(in unsigned long aAppId,
michael@0 33 in nsINetworkInterface aNetwork,
michael@0 34 in unsigned long long aTimeStamp,
michael@0 35 in unsigned long long aRxBytes,
michael@0 36 in unsigned long long aTxBytes,
michael@0 37 in boolean aIsAccumulative,
michael@0 38 [optional] in nsINetworkStatsServiceProxyCallback aCallback);
michael@0 39
michael@0 40 /*
michael@0 41 * An interface used to record per-system service traffic data.
michael@0 42 * @param aServiceType system service type
michael@0 43 * @param aNetworkInterface network
michael@0 44 * @param aTimeStamp time stamp
michael@0 45 * @param aRxBytes received data amount
michael@0 46 * @param aTxBytes transmitted data amount
michael@0 47 * @param aIsAccumulative is stats accumulative
michael@0 48 * @param aCallback an optional callback
michael@0 49 */
michael@0 50 void saveServiceStats(in string aServiceType,
michael@0 51 in nsINetworkInterface aNetwork,
michael@0 52 in unsigned long long aTimeStamp,
michael@0 53 in unsigned long long aRxBytes,
michael@0 54 in unsigned long long aTxBytes,
michael@0 55 in boolean aIsAccumulative,
michael@0 56 [optional] in nsINetworkStatsServiceProxyCallback aCallback);
michael@0 57 };

mercurial