nsSHEntry.h (1869B)
1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 2 /* vim: set ts=8 sts=2 et sw=2 tw=80: */ 3 /* This Source Code Form is subject to the terms of the Mozilla Public 4 * License, v. 2.0. If a copy of the MPL was not distributed with this 5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 6 7 #ifndef nsSHEntry_h 8 #define nsSHEntry_h 9 10 #include "nsCOMArray.h" 11 #include "nsCOMPtr.h" 12 #include "nsISHEntry.h" 13 #include "nsString.h" 14 #include "nsWeakReference.h" 15 16 class nsSHEntryShared; 17 class nsIInputStream; 18 class nsIURI; 19 class nsIReferrerInfo; 20 21 class nsSHEntry : public nsISHEntry, public nsSupportsWeakReference { 22 public: 23 nsSHEntry(); 24 25 NS_DECL_ISUPPORTS 26 NS_DECL_NSISHENTRY 27 28 virtual void EvictDocumentViewer(); 29 30 static nsresult Startup(); 31 static void Shutdown(); 32 33 nsSHEntryShared* GetState() { return mShared; } 34 35 protected: 36 explicit nsSHEntry(const nsSHEntry& aOther); 37 virtual ~nsSHEntry(); 38 39 // We share the state in here with other SHEntries which correspond to the 40 // same document. 41 RefPtr<nsSHEntryShared> mShared; 42 43 // See nsSHEntry.idl for comments on these members. 44 nsCOMPtr<nsIURI> mURI; 45 nsCOMPtr<nsIURI> mOriginalURI; 46 nsCOMPtr<nsIURI> mResultPrincipalURI; 47 nsCOMPtr<nsIURI> mUnstrippedURI; 48 nsCOMPtr<nsIReferrerInfo> mReferrerInfo; 49 nsString mTitle; 50 nsString mName; 51 nsCOMPtr<nsIInputStream> mPostData; 52 uint32_t mLoadType; 53 uint32_t mID; 54 int32_t mScrollPositionX; 55 int32_t mScrollPositionY; 56 nsWeakPtr mParent; 57 nsCOMArray<nsISHEntry> mChildren; 58 nsCOMPtr<nsIStructuredCloneContainer> mStateData; 59 nsString mSrcdocData; 60 nsCOMPtr<nsIURI> mBaseURI; 61 bool mLoadReplace; 62 bool mURIWasModified; 63 bool mIsSrcdocEntry; 64 bool mScrollRestorationIsManual; 65 bool mLoadedInThisProcess; 66 bool mTransient; 67 bool mHasUserInteraction; 68 bool mHasUserActivation; 69 }; 70 71 #endif /* nsSHEntry_h */