OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/browser/loader/upload_data_stream_builder.h" | 5 #include "content/browser/loader/upload_data_stream_builder.h" |
6 | 6 |
7 #include <limits> | 7 #include <limits> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
104 DCHECK_EQ(0ul, element.offset()); | 104 DCHECK_EQ(0ul, element.offset()); |
105 scoped_ptr<storage::BlobDataHandle> handle = | 105 scoped_ptr<storage::BlobDataHandle> handle = |
106 blob_context->GetBlobDataFromUUID(element.blob_uuid()); | 106 blob_context->GetBlobDataFromUUID(element.blob_uuid()); |
107 storage::BlobDataHandle* handle_ptr = handle.get(); | 107 storage::BlobDataHandle* handle_ptr = handle.get(); |
108 element_readers.push_back(new storage::UploadBlobElementReader( | 108 element_readers.push_back(new storage::UploadBlobElementReader( |
109 handle_ptr->CreateReader(file_system_context, file_task_runner), | 109 handle_ptr->CreateReader(file_system_context, file_task_runner), |
110 handle.Pass())); | 110 handle.Pass())); |
111 break; | 111 break; |
112 } | 112 } |
113 case ResourceRequestBody::Element::TYPE_DISK_CACHE_ENTRY: | 113 case ResourceRequestBody::Element::TYPE_DISK_CACHE_ENTRY: |
| 114 case ResourceRequestBody::Element::TYPE_BYTES_DESCRIPTION: |
114 case ResourceRequestBody::Element::TYPE_UNKNOWN: | 115 case ResourceRequestBody::Element::TYPE_UNKNOWN: |
115 NOTREACHED(); | 116 NOTREACHED(); |
116 break; | 117 break; |
117 } | 118 } |
118 } | 119 } |
119 | 120 |
120 return make_scoped_ptr( | 121 return make_scoped_ptr( |
121 new net::ElementsUploadDataStream(element_readers.Pass(), | 122 new net::ElementsUploadDataStream(element_readers.Pass(), |
122 body->identifier())); | 123 body->identifier())); |
123 } | 124 } |
124 | 125 |
125 } // namespace content | 126 } // namespace content |
OLD | NEW |