gecko-dev/netwerk/ipc/DocumentChannelChild.h
Stefan Hindli fb36126f61 Backed out 15 changesets (bug 1607984) for causing very frequent reftest faiures CLOSED TREE
Backed out changeset 5497c90b03de (bug 1607984)
Backed out changeset 71dffa590c10 (bug 1607984)
Backed out changeset fdacabac2c54 (bug 1607984)
Backed out changeset 5f9fe17e46b8 (bug 1607984)
Backed out changeset 8f9058eb821d (bug 1607984)
Backed out changeset 025af7792f2a (bug 1607984)
Backed out changeset c7edd070b2f3 (bug 1607984)
Backed out changeset 8e7c95d322e8 (bug 1607984)
Backed out changeset e51f6b7a745c (bug 1607984)
Backed out changeset 979d99eb12d1 (bug 1607984)
Backed out changeset f554d4ce6718 (bug 1607984)
Backed out changeset fe84e5c64b4e (bug 1607984)
Backed out changeset 05d2032060db (bug 1607984)
Backed out changeset 07ce7b11fee9 (bug 1607984)
Backed out changeset 718d89be09d2 (bug 1607984)
2020-04-15 18:33:24 +03:00

65 lines
2.2 KiB
C++

/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim: set sw=2 ts=8 et tw=80 : */
/* 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/. */
#ifndef mozilla_net_DocumentChannelChild_h
#define mozilla_net_DocumentChannelChild_h
#include "mozilla/net/PDocumentChannelChild.h"
#include "mozilla/net/DocumentChannel.h"
#include "nsIAsyncVerifyRedirectCallback.h"
#include "mozilla/dom/nsCSPContext.h"
namespace mozilla {
namespace net {
/**
* DocumentChannelChild is an implementation of DocumentChannel for nsDocShells
* in the content process, that uses PDocumentChannel to serialize everything
* across IPDL to the parent process.
*/
class DocumentChannelChild final : public DocumentChannel,
public nsIAsyncVerifyRedirectCallback,
public PDocumentChannelChild {
public:
DocumentChannelChild(nsDocShellLoadState* aLoadState,
class LoadInfo* aLoadInfo, nsLoadFlags aLoadFlags,
uint32_t aCacheKey);
NS_DECL_ISUPPORTS_INHERITED
NS_DECL_NSIASYNCVERIFYREDIRECTCALLBACK
NS_IMETHOD AsyncOpen(nsIStreamListener* aListener) override;
NS_IMETHOD Cancel(nsresult aStatusCode) override;
mozilla::ipc::IPCResult RecvFailedAsyncOpen(const nsresult& aStatusCode);
mozilla::ipc::IPCResult RecvDisconnectChildListeners(
const nsresult& aStatus, const nsresult& aLoadGroupStatus);
mozilla::ipc::IPCResult RecvDeleteSelf();
mozilla::ipc::IPCResult RecvRedirectToRealChannel(
RedirectToRealChannelArgs&& aArgs,
nsTArray<Endpoint<extensions::PStreamFilterParent>>&& aEndpoints,
RedirectToRealChannelResolver&& aResolve);
private:
void ShutdownListeners(nsresult aStatusCode);
~DocumentChannelChild();
nsCOMPtr<nsIChannel> mRedirectChannel;
RedirectToRealChannelResolver mRedirectResolver;
nsTArray<Endpoint<extensions::PStreamFilterParent>> mStreamFilterEndpoints;
};
} // namespace net
} // namespace mozilla
#endif // mozilla_net_DocumentChannelChild_h