tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

nsIEHistoryEnumerator.h (900B)


      1 /* This Source Code Form is subject to the terms of the Mozilla Public
      2 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
      3 * You can obtain one at http://mozilla.org/MPL/2.0/. */
      4 
      5 #ifndef iehistoryenumerator___h___
      6 #define iehistoryenumerator___h___
      7 
      8 #include <urlhist.h>
      9 
     10 #include "nsCOMPtr.h"
     11 #include "nsIWritablePropertyBag2.h"
     12 #include "nsSimpleEnumerator.h"
     13 
     14 class nsIEHistoryEnumerator final : public nsSimpleEnumerator {
     15 public:
     16  NS_DECL_NSISIMPLEENUMERATOR
     17 
     18  nsIEHistoryEnumerator();
     19 
     20  const nsID& DefaultInterface() override {
     21    return NS_GET_IID(nsIWritablePropertyBag2);
     22  }
     23 
     24 private:
     25  ~nsIEHistoryEnumerator() override;
     26 
     27  /**
     28   * Initializes the history reader, if needed.
     29   */
     30  void EnsureInitialized();
     31 
     32  RefPtr<IUrlHistoryStg2> mIEHistory;
     33  RefPtr<IEnumSTATURL> mURLEnumerator;
     34 
     35  nsCOMPtr<nsIWritablePropertyBag2> mCachedNextEntry;
     36 };
     37 
     38 #endif