1 // Copyright 2014 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 WebPushClient_h
6 #define WebPushClient_h
8 #include "public/platform/WebCallbacks.h"
9 #include "public/platform/WebPushError.h"
10 #include "public/platform/WebPushPermissionStatus.h"
14 class WebServiceWorkerProvider;
15 struct WebPushRegistration;
17 typedef WebCallbacks<WebPushRegistration, WebPushError> WebPushRegistrationCallbacks;
18 typedef WebCallbacks<WebPushPermissionStatus, void> WebPushPermissionStatusCallback;
22 virtual ~WebPushClient() { }
24 // Ownership of the WebPushRegistrationCallbacks is transferred to the
25 // client. Ownership of the WebServiceWorkerProvider is not transferred.
26 virtual void registerPushMessaging(WebPushRegistrationCallbacks*, WebServiceWorkerProvider*) { }
28 // Ownership of the WebPushPermissionStatusCallback is transferred to the
29 // client. Ownership of the WebServiceWorkerProvider is not transferred.
30 virtual void getPermissionStatus(WebPushPermissionStatusCallback*, WebServiceWorkerProvider*) { }
35 #endif // WebPushClient_h