gecko-dev/netwerk/ipc/PSocketProcess.ipdl

65 строки
2.6 KiB
Plaintext

/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* 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 protocol PDNSRequest;
include protocol PSocketProcessBridge;
include protocol PProfiler;
include protocol PWebrtcTCPSocket;
include MemoryReportTypes;
include PBrowserOrId;
include PrefsTypes;
using mozilla::dom::NativeThreadId from "mozilla/dom/TabMessageUtils.h";
using mozilla::Telemetry::HistogramAccumulation from "mozilla/TelemetryComms.h";
using mozilla::Telemetry::KeyedHistogramAccumulation from "mozilla/TelemetryComms.h";
using mozilla::Telemetry::ScalarAction from "mozilla/TelemetryComms.h";
using mozilla::Telemetry::KeyedScalarAction from "mozilla/TelemetryComms.h";
using mozilla::Telemetry::ChildEventData from "mozilla/TelemetryComms.h";
using mozilla::Telemetry::DiscardedData from "mozilla/TelemetryComms.h";
using base::ProcessId from "base/process.h";
using mozilla::OriginAttributes from "mozilla/ipc/BackgroundUtils.h";
namespace mozilla {
namespace net {
protocol PSocketProcess
{
manages PDNSRequest;
manages PWebrtcTCPSocket;
parent:
async InitCrashReporter(Shmem shmem, NativeThreadId threadId);
async AddMemoryReport(MemoryReport aReport);
async FinishMemoryReport(uint32_t aGeneration);
// Messages for sending telemetry to parent process.
async AccumulateChildHistograms(HistogramAccumulation[] accumulations);
async AccumulateChildKeyedHistograms(KeyedHistogramAccumulation[] accumulations);
async UpdateChildScalars(ScalarAction[] actions);
async UpdateChildKeyedScalars(KeyedScalarAction[] actions);
async RecordChildEvents(ChildEventData[] events);
async RecordDiscardedData(DiscardedData data);
/* tabId is only required for web-proxy support, which isn't always needed */
async PWebrtcTCPSocket(TabId? tabId);
async PDNSRequest(nsCString hostName, OriginAttributes originAttributes,
uint32_t flags);
child:
async PreferenceUpdate(Pref pref);
async RequestMemoryReport(uint32_t generation,
bool anonymize,
bool minimizeMemoryUsage,
FileDescriptor? DMDFile);
async SetOffline(bool offline);
async InitSocketProcessBridgeParent(ProcessId processId, Endpoint<PSocketProcessBridgeParent> endpoint);
async InitProfiler(Endpoint<PProfilerChild> aEndpoint);
// test-only
async SocketProcessTelemetryPing();
};
} // namespace net
} // namespace mozilla