| Index: chrome/browser/predictors/predictor_database_service.h
|
| diff --git a/chrome/browser/predictors/predictor_database_service.h b/chrome/browser/predictors/predictor_database_service.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..1061e4980c2c32f27027f807d2d4724b7443707c
|
| --- /dev/null
|
| +++ b/chrome/browser/predictors/predictor_database_service.h
|
| @@ -0,0 +1,40 @@
|
| +// Copyright (c) 2012 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_PREDICTORS_PREDICTOR_DATABASE_SERVICE_H_
|
| +#define CHROME_BROWSER_PREDICTORS_PREDICTOR_DATABASE_SERVICE_H_
|
| +
|
| +#include "base/memory/ref_counted.h"
|
| +#include "chrome/browser/predictors/predictor_database.h"
|
| +#include "chrome/browser/profiles/profile_keyed_service.h"
|
| +
|
| +class Profile;
|
| +
|
| +namespace predictors {
|
| +
|
| +// Maintains per-profile information about PredictorDatabase.
|
| +class PredictorDatabaseService: public ProfileKeyedService {
|
| + public:
|
| + explicit PredictorDatabaseService(Profile* profile);
|
| + virtual ~PredictorDatabaseService();
|
| +
|
| + scoped_refptr<PredictorDatabase> GetDatabase() const {
|
| + return db_;
|
| + }
|
| +
|
| + private:
|
| + // ProfileKeyedService
|
| + virtual void Shutdown() OVERRIDE;
|
| +
|
| + // A pointer to the profile which this service refers to.
|
| + Profile* profile_;
|
| +
|
| + scoped_refptr<PredictorDatabase> db_;
|
| +
|
| + DISALLOW_COPY_AND_ASSIGN(PredictorDatabaseService);
|
| +};
|
| +
|
| +} // namespace predictors
|
| +
|
| +#endif // CHROME_BROWSER_PREDICTORS_PREDICTOR_DATABASE_SERVICE_H_
|
|
|