url_request_data_job.h revision 72a454cd3513ac24fbdd0e0cb9ad70b86a99b801
1// Copyright (c) 2010 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 NET_URL_REQUEST_URL_REQUEST_DATA_JOB_H_ 6#define NET_URL_REQUEST_URL_REQUEST_DATA_JOB_H_ 7#pragma once 8 9#include <string> 10 11#include "net/url_request/url_request.h" 12#include "net/url_request/url_request_simple_job.h" 13 14namespace net { 15 16class URLRequest; 17 18class URLRequestDataJob : public URLRequestSimpleJob { 19 public: 20 explicit URLRequestDataJob(URLRequest* request); 21 22 static URLRequest::ProtocolFactory Factory; 23 24 // URLRequestSimpleJob 25 virtual bool GetData(std::string* mime_type, 26 std::string* charset, 27 std::string* data) const; 28 29 private: 30 ~URLRequestDataJob(); 31 32 DISALLOW_COPY_AND_ASSIGN(URLRequestDataJob); 33}; 34 35} // namespace net 36 37#endif // NET_URL_REQUEST_URL_REQUEST_DATA_JOB_H_ 38