1 // Copyright (c) 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_SERVICES_GCM_INSTANCE_ID_INSTANCE_ID_PROFILE_SERVICE_H_
6 #define CHROME_BROWSER_SERVICES_GCM_INSTANCE_ID_INSTANCE_ID_PROFILE_SERVICE_H_
8 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h"
10 #include "components/keyed_service/core/keyed_service.h"
14 namespace instance_id
{
16 class InstanceIDDriver
;
18 // Providing Instance ID support, via InstanceIDDriver, to a profile.
19 class InstanceIDProfileService
: public KeyedService
{
21 // Returns whether InstanceID is enabled for |profile|.
22 static bool IsInstanceIDEnabled(Profile
* profile
);
24 explicit InstanceIDProfileService(Profile
* profile
);
25 ~InstanceIDProfileService() override
;
27 InstanceIDDriver
* driver() const { return driver_
.get(); }
30 scoped_ptr
<InstanceIDDriver
> driver_
;
32 DISALLOW_COPY_AND_ASSIGN(InstanceIDProfileService
);
35 } // namespace instance_id
37 #endif // CHROME_BROWSER_SERVICES_GCM_INSTANCE_ID_INSTANCE_ID_PROFILE_SERVICE_H_