1 // Copyright 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 GOOGLE_APIS_GCM_ENGINE_GCM_UNREGISTRATION_REQUEST_HANDLER_H_
6 #define GOOGLE_APIS_GCM_ENGINE_GCM_UNREGISTRATION_REQUEST_HANDLER_H_
8 #include "google_apis/gcm/engine/unregistration_request.h"
12 // Used to revoke the registration ID when unregister is called or the
13 // application has been uninstalled.
14 class GCM_EXPORT GCMUnregistrationRequestHandler
:
15 public UnregistrationRequest::CustomRequestHandler
{
17 GCMUnregistrationRequestHandler(const std::string
& app_id
);
18 ~GCMUnregistrationRequestHandler() override
;
20 // UnregistrationRequest::CustomRequestHandler overrides:
21 void BuildRequestBody(std::string
* body
) override
;
22 UnregistrationRequest::Status
ParseResponse(
23 const net::URLFetcher
* source
) override
;
24 void ReportUMAs(UnregistrationRequest::Status status
,
26 base::TimeDelta complete_time
) override
;
31 DISALLOW_COPY_AND_ASSIGN(GCMUnregistrationRequestHandler
);
36 #endif // GOOGLE_APIS_GCM_ENGINE_GCM_UNREGISTRATION_REQUEST_HANDLER_H_