resource_dispatcher_host_delegate.cc revision f8ee788a64d60abd8f2d742a5fdedde054ecd910
1// Copyright (c) 2012 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#include "content/public/browser/resource_dispatcher_host_delegate.h"
6
7#include "content/public/browser/stream_handle.h"
8
9namespace content {
10
11bool ResourceDispatcherHostDelegate::ShouldBeginRequest(
12    int child_id,
13    int route_id,
14    const std::string& method,
15    const GURL& url,
16    ResourceType::Type resource_type,
17    ResourceContext* resource_context) {
18  return true;
19}
20
21void ResourceDispatcherHostDelegate::RequestBeginning(
22    net::URLRequest* request,
23    ResourceContext* resource_context,
24    appcache::AppCacheService* appcache_service,
25    ResourceType::Type resource_type,
26    int child_id,
27    int route_id,
28    ScopedVector<ResourceThrottle>* throttles) {
29}
30
31void ResourceDispatcherHostDelegate::DownloadStarting(
32    net::URLRequest* request,
33    ResourceContext* resource_context,
34    int child_id,
35    int route_id,
36    int request_id,
37    bool is_content_initiated,
38    bool must_download,
39    ScopedVector<ResourceThrottle>* throttles) {
40}
41
42ResourceDispatcherHostLoginDelegate*
43    ResourceDispatcherHostDelegate::CreateLoginDelegate(
44        net::AuthChallengeInfo* auth_info,
45        net::URLRequest* request) {
46  return NULL;
47}
48
49bool ResourceDispatcherHostDelegate::HandleExternalProtocol(
50    const GURL& url,
51    int child_id,
52    int route_id,
53    bool initiated_by_user_gesture) {
54  return true;
55}
56
57bool ResourceDispatcherHostDelegate::ShouldForceDownloadResource(
58    const GURL& url,
59    const std::string& mime_type) {
60  return false;
61}
62
63bool ResourceDispatcherHostDelegate::ShouldInterceptResourceAsStream(
64    net::URLRequest* request,
65    const std::string& mime_type,
66    GURL* origin,
67    std::string* payload) {
68  return false;
69}
70
71void ResourceDispatcherHostDelegate::OnStreamCreated(
72    net::URLRequest* request,
73    scoped_ptr<content::StreamHandle> stream) {
74}
75
76void ResourceDispatcherHostDelegate::OnResponseStarted(
77    net::URLRequest* request,
78    ResourceContext* resource_context,
79    ResourceResponse* response,
80    IPC::Sender* sender) {
81}
82
83void ResourceDispatcherHostDelegate::OnRequestRedirected(
84    const GURL& redirect_url,
85    net::URLRequest* request,
86    ResourceContext* resource_context,
87    ResourceResponse* response) {
88}
89
90void ResourceDispatcherHostDelegate::RequestComplete(
91    net::URLRequest* url_request) {
92}
93
94ResourceDispatcherHostDelegate::ResourceDispatcherHostDelegate() {
95}
96
97ResourceDispatcherHostDelegate::~ResourceDispatcherHostDelegate() {
98}
99
100}  // namespace content
101