michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: #ifndef mozilla_net_WyciwygChannelParent_h michael@0: #define mozilla_net_WyciwygChannelParent_h michael@0: michael@0: #include "mozilla/net/PWyciwygChannelParent.h" michael@0: #include "mozilla/net/NeckoCommon.h" michael@0: #include "nsIStreamListener.h" michael@0: michael@0: #include "nsIWyciwygChannel.h" michael@0: #include "nsIInterfaceRequestor.h" michael@0: #include "nsILoadContext.h" michael@0: michael@0: namespace mozilla { michael@0: namespace dom { michael@0: class PBrowserParent; michael@0: } michael@0: michael@0: namespace net { michael@0: michael@0: class WyciwygChannelParent : public PWyciwygChannelParent michael@0: , public nsIStreamListener michael@0: , public nsIInterfaceRequestor michael@0: { michael@0: public: michael@0: NS_DECL_ISUPPORTS michael@0: NS_DECL_NSIREQUESTOBSERVER michael@0: NS_DECL_NSISTREAMLISTENER michael@0: NS_DECL_NSIINTERFACEREQUESTOR michael@0: michael@0: WyciwygChannelParent(); michael@0: virtual ~WyciwygChannelParent(); michael@0: michael@0: protected: michael@0: virtual bool RecvInit(const URIParams& uri) MOZ_OVERRIDE; michael@0: virtual bool RecvAsyncOpen(const URIParams& original, michael@0: const uint32_t& loadFlags, michael@0: const IPC::SerializedLoadContext& loadContext, michael@0: PBrowserParent* parent) MOZ_OVERRIDE; michael@0: virtual bool RecvWriteToCacheEntry(const nsString& data) MOZ_OVERRIDE; michael@0: virtual bool RecvCloseCacheEntry(const nsresult& reason) MOZ_OVERRIDE; michael@0: virtual bool RecvSetCharsetAndSource(const int32_t& source, michael@0: const nsCString& charset) MOZ_OVERRIDE; michael@0: virtual bool RecvSetSecurityInfo(const nsCString& securityInfo) MOZ_OVERRIDE; michael@0: virtual bool RecvCancel(const nsresult& statusCode) MOZ_OVERRIDE; michael@0: virtual bool RecvAppData(const IPC::SerializedLoadContext& loadContext, michael@0: PBrowserParent* parent) MOZ_OVERRIDE; michael@0: michael@0: virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; michael@0: michael@0: bool SetupAppData(const IPC::SerializedLoadContext& loadContext, michael@0: PBrowserParent* aParent); michael@0: michael@0: nsCOMPtr mChannel; michael@0: bool mIPCClosed; michael@0: bool mReceivedAppData; michael@0: nsCOMPtr mLoadContext; michael@0: }; michael@0: michael@0: } // namespace net michael@0: } // namespace mozilla michael@0: michael@0: #endif // mozilla_net_WyciwygChannelParent_h