netwerk/protocol/wyciwyg/WyciwygChannelParent.h

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/netwerk/protocol/wyciwyg/WyciwygChannelParent.h	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,65 @@
     1.4 +/* This Source Code Form is subject to the terms of the Mozilla Public
     1.5 + * License, v. 2.0. If a copy of the MPL was not distributed with this
     1.6 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
     1.7 +
     1.8 +#ifndef mozilla_net_WyciwygChannelParent_h
     1.9 +#define mozilla_net_WyciwygChannelParent_h
    1.10 +
    1.11 +#include "mozilla/net/PWyciwygChannelParent.h"
    1.12 +#include "mozilla/net/NeckoCommon.h"
    1.13 +#include "nsIStreamListener.h"
    1.14 +
    1.15 +#include "nsIWyciwygChannel.h"
    1.16 +#include "nsIInterfaceRequestor.h"
    1.17 +#include "nsILoadContext.h"
    1.18 +
    1.19 +namespace mozilla {
    1.20 +namespace dom {
    1.21 +  class PBrowserParent;
    1.22 +}
    1.23 +
    1.24 +namespace net {
    1.25 +
    1.26 +class WyciwygChannelParent : public PWyciwygChannelParent
    1.27 +                           , public nsIStreamListener
    1.28 +                           , public nsIInterfaceRequestor
    1.29 +{
    1.30 +public:
    1.31 +  NS_DECL_ISUPPORTS
    1.32 +  NS_DECL_NSIREQUESTOBSERVER
    1.33 +  NS_DECL_NSISTREAMLISTENER
    1.34 +  NS_DECL_NSIINTERFACEREQUESTOR
    1.35 +
    1.36 +  WyciwygChannelParent();
    1.37 +  virtual ~WyciwygChannelParent();
    1.38 +
    1.39 +protected:
    1.40 +  virtual bool RecvInit(const URIParams& uri) MOZ_OVERRIDE;
    1.41 +  virtual bool RecvAsyncOpen(const URIParams& original,
    1.42 +                             const uint32_t& loadFlags,
    1.43 +                             const IPC::SerializedLoadContext& loadContext,
    1.44 +                             PBrowserParent* parent) MOZ_OVERRIDE;
    1.45 +  virtual bool RecvWriteToCacheEntry(const nsString& data) MOZ_OVERRIDE;
    1.46 +  virtual bool RecvCloseCacheEntry(const nsresult& reason) MOZ_OVERRIDE;
    1.47 +  virtual bool RecvSetCharsetAndSource(const int32_t& source,
    1.48 +                                       const nsCString& charset) MOZ_OVERRIDE;
    1.49 +  virtual bool RecvSetSecurityInfo(const nsCString& securityInfo) MOZ_OVERRIDE;
    1.50 +  virtual bool RecvCancel(const nsresult& statusCode) MOZ_OVERRIDE;
    1.51 +  virtual bool RecvAppData(const IPC::SerializedLoadContext& loadContext,
    1.52 +                           PBrowserParent* parent) MOZ_OVERRIDE;
    1.53 +
    1.54 +  virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE;
    1.55 +
    1.56 +  bool SetupAppData(const IPC::SerializedLoadContext& loadContext,
    1.57 +                    PBrowserParent* aParent);
    1.58 +
    1.59 +  nsCOMPtr<nsIWyciwygChannel> mChannel;
    1.60 +  bool mIPCClosed;
    1.61 +  bool mReceivedAppData;
    1.62 +  nsCOMPtr<nsILoadContext> mLoadContext;
    1.63 +};
    1.64 +
    1.65 +} // namespace net
    1.66 +} // namespace mozilla
    1.67 +
    1.68 +#endif // mozilla_net_WyciwygChannelParent_h

mercurial