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

Side by Side Diff: chrome/browser/extensions/api/feedback_private/blob_reader.h

Issue 17111003: Implement the feedbackPrivate API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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
OLDNEW
(Empty)
1 // Copyright (c) 2013 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_EXTENSIONS_API_FEEDBACK_PRIVATE_BLOB_READER_H_
6 #define CHROME_BROWSER_EXTENSIONS_API_FEEDBACK_PRIVATE_BLOB_READER_H_
7
8 #include <string>
9
10 #include "base/callback.h"
11 #include "base/memory/scoped_ptr.h"
12 #include "googleurl/src/gurl.h"
13 #include "net/base/io_buffer.h"
14 #include "net/url_request/url_fetcher_delegate.h"
15 #include "net/url_request/url_request.h"
16
17 class Profile;
18 namespace net {
19 class URLFetcher;
20 }
21
22 class BlobReader : public net::URLFetcherDelegate {
23 public:
24 typedef base::Callback<void(scoped_ptr<std::string> blob_data)>
25 BlobReadCallback;
26
27 BlobReader(Profile* profile,
28 const GURL& blob_url,
29 BlobReadCallback callback);
30 virtual ~BlobReader();
31
32 void Start();
33
34 private:
35 // Overridden from net::URLFetcherDelegate.
36 virtual void OnURLFetchComplete(const net::URLFetcher* source) OVERRIDE;
37
38 BlobReadCallback callback_;
39 net::URLFetcher* fetcher_;
40
41 DISALLOW_COPY_AND_ASSIGN(BlobReader);
42 };
43
44 #endif // CHROME_BROWSER_EXTENSIONS_API_FEEDBACK_PRIVATE_BLOB_READER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698