Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(229)

Side by Side Diff: chrome/browser/local_discovery/gcd_registration_ticket_request.h

Issue 307353008: GCD registration ticket creation flow (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/local_discovery/gcd_registration_ticket_request.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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.
4
5 #ifndef CHROME_BROWSER_LOCAL_DISCOVERY_GCD_REGISTRATION_TICKET_REQUEST_H_
6 #define CHROME_BROWSER_LOCAL_DISCOVERY_GCD_REGISTRATION_TICKET_REQUEST_H_
7
8 #include <string>
9
10 #include "base/callback.h"
11 #include "base/values.h"
12 #include "chrome/browser/local_discovery/gcd_api_flow.h"
13
14 namespace local_discovery {
15
16 class GCDRegistrationTicketRequest : public GCDApiFlowRequest {
17 public:
18 // |ticket_id| contains the registration ticket ID, or an empty string in case
19 // of an error.
20 typedef base::Callback<void(const std::string& ticket_id)> ResponseCallback;
21
22 explicit GCDRegistrationTicketRequest(const ResponseCallback& callback);
23 virtual ~GCDRegistrationTicketRequest();
24
25 // GCDApiFlow::Request implementation.
26 virtual void GetUploadData(std::string* upload_type,
27 std::string* upload_data) OVERRIDE;
28 virtual net::URLFetcher::RequestType GetRequestType() OVERRIDE;
29 virtual void OnGCDAPIFlowError(GCDApiFlow::Status status) OVERRIDE;
30 virtual void OnGCDAPIFlowComplete(
31 const base::DictionaryValue& value) OVERRIDE;
32 virtual GURL GetURL() OVERRIDE;
33
34 private:
35 ResponseCallback callback_;
36 };
37
38 } // namespace local_discovery
39
40 #endif // CHROME_BROWSER_LOCAL_DISCOVERY_GCD_REGISTRATION_TICKET_REQUEST_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/local_discovery/gcd_registration_ticket_request.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698