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

Side by Side Diff: third_party/WebKit/public/platform/WebURLLoaderClient.h

Issue 2835123005: Send the decoded size when response completed and stop summing in ResourceLoader::DidReceiveData() (Closed)
Patch Set: Created 3 years, 7 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 virtual void DidReceiveTransferSizeUpdate(int transfer_size_diff) {} 86 virtual void DidReceiveTransferSizeUpdate(int transfer_size_diff) {}
87 87
88 // Called when a chunk of renderer-generated metadata is received from the 88 // Called when a chunk of renderer-generated metadata is received from the
89 // cache. 89 // cache.
90 virtual void DidReceiveCachedMetadata(const char* data, int data_length) {} 90 virtual void DidReceiveCachedMetadata(const char* data, int data_length) {}
91 91
92 // Called when the load completes successfully. 92 // Called when the load completes successfully.
93 // |totalEncodedDataLength| may be equal to kUnknownEncodedDataLength. 93 // |totalEncodedDataLength| may be equal to kUnknownEncodedDataLength.
94 virtual void DidFinishLoading(double finish_time, 94 virtual void DidFinishLoading(double finish_time,
95 int64_t total_encoded_data_length, 95 int64_t total_encoded_data_length,
96 int64_t total_encoded_body_length) {} 96 int64_t total_encoded_body_length,
97 int64_t total_decoded_body_length) {}
97 98
98 // Called when the load completes with an error. 99 // Called when the load completes with an error.
99 // |totalEncodedDataLength| may be equal to kUnknownEncodedDataLength. 100 // |totalEncodedDataLength| may be equal to kUnknownEncodedDataLength.
100 virtual void DidFail(const WebURLError&, 101 virtual void DidFail(const WebURLError&,
101 int64_t total_encoded_data_length, 102 int64_t total_encoded_data_length,
102 int64_t total_encoded_body_length) {} 103 int64_t total_encoded_body_length,
104 int64_t total_decoded_body_length) {}
103 105
104 // Value passed to didFinishLoading when total encoded data length isn't 106 // Value passed to didFinishLoading when total encoded data length isn't
105 // known. 107 // known.
106 static const int64_t kUnknownEncodedDataLength = -1; 108 static const int64_t kUnknownEncodedDataLength = -1;
107 109
108 protected: 110 protected:
109 virtual ~WebURLLoaderClient() {} 111 virtual ~WebURLLoaderClient() {}
110 }; 112 };
111 113
112 } // namespace blink 114 } // namespace blink
113 115
114 #endif 116 #endif
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/tests/sim/SimRequest.cpp ('k') | third_party/WebKit/public/platform/WebURLLoaderTestDelegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698