| Index: chrome/browser/android/offline_pages/prerendering_offliner_factory.h
|
| diff --git a/chrome/browser/android/offline_pages/prerendering_offliner_factory.h b/chrome/browser/android/offline_pages/prerendering_offliner_factory.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..0e10afe1cb71535ecf22d1442ac0055ceed09c2d
|
| --- /dev/null
|
| +++ b/chrome/browser/android/offline_pages/prerendering_offliner_factory.h
|
| @@ -0,0 +1,44 @@
|
| +// Copyright 2016 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef CHROME_BROWSER_ANDROID_OFFLINE_PAGES_PRERENDERING_OFFLINER_FACTORY_H_
|
| +#define CHROME_BROWSER_ANDROID_OFFLINE_PAGES_PRERENDERING_OFFLINER_FACTORY_H_
|
| +
|
| +#include "base/macros.h"
|
| +#include "chrome/browser/android/offline_pages/prerendering_offliner.h"
|
| +#include "components/offline_pages/background/offliner.h"
|
| +#include "components/offline_pages/background/offliner_factory.h"
|
| +#include "content/public/browser/browser_context.h"
|
| +
|
| +namespace base {
|
| +template <typename T>
|
| +struct DefaultSingletonTraits;
|
| +} // namespace base
|
| +
|
| +namespace offline_pages {
|
| +
|
| +class OfflinerPolicy;
|
| +class PrerenderingOffliner;
|
| +
|
| +// A factory to create one unique OfflinePageModel.
|
| +class PrerenderingOfflinerFactory : public OfflinerFactory {
|
| + public:
|
| + PrerenderingOffliner* GetOffliner(const OfflinerPolicy* policy) override;
|
| +
|
| + explicit PrerenderingOfflinerFactory(content::BrowserContext* context);
|
| + ~PrerenderingOfflinerFactory() override;
|
| +
|
| + private:
|
| + // TODO: Do I still need a singleton?
|
| + friend struct base::DefaultSingletonTraits<PrerenderingOfflinerFactory>;
|
| +
|
| + DISALLOW_COPY_AND_ASSIGN(PrerenderingOfflinerFactory);
|
| +
|
| + PrerenderingOffliner* offliner_;
|
| + content::BrowserContext* context_;
|
| +};
|
| +
|
| +} // namespace offline_pages
|
| +
|
| +#endif // CHROME_BROWSER_ANDROID_OFFLINE_PAGES_PRERENDERING_OFFLINER_FACTORY_H_
|
|
|