OLD | NEW |
1 /* | 1 /* |
2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) | 2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) |
3 Copyright (C) 2001 Dirk Mueller <mueller@kde.org> | 3 Copyright (C) 2001 Dirk Mueller <mueller@kde.org> |
4 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) | 4 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) |
5 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All | 5 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All |
6 rights reserved. | 6 rights reserved. |
7 | 7 |
8 This library is free software; you can redistribute it and/or | 8 This library is free software; you can redistribute it and/or |
9 modify it under the terms of the GNU Library General Public | 9 modify it under the terms of the GNU Library General Public |
10 License as published by the Free Software Foundation; either | 10 License as published by the Free Software Foundation; either |
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
220 | 220 |
221 // This may return nullptr when the resource isn't cacheable. | 221 // This may return nullptr when the resource isn't cacheable. |
222 CachedMetadataHandler* cacheHandler(); | 222 CachedMetadataHandler* cacheHandler(); |
223 | 223 |
224 AtomicString httpContentType() const; | 224 AtomicString httpContentType() const; |
225 | 225 |
226 bool wasCanceled() const { return m_error.isCancellation(); } | 226 bool wasCanceled() const { return m_error.isCancellation(); } |
227 bool errorOccurred() const { | 227 bool errorOccurred() const { |
228 return m_status == LoadError || m_status == DecodeError; | 228 return m_status == LoadError || m_status == DecodeError; |
229 } | 229 } |
230 bool loadFailedOrCanceled() { return !m_error.isNull(); } | 230 bool loadFailedOrCanceled() const { return !m_error.isNull(); } |
231 | 231 |
232 DataBufferingPolicy getDataBufferingPolicy() const { | 232 DataBufferingPolicy getDataBufferingPolicy() const { |
233 return m_options.dataBufferingPolicy; | 233 return m_options.dataBufferingPolicy; |
234 } | 234 } |
235 void setDataBufferingPolicy(DataBufferingPolicy); | 235 void setDataBufferingPolicy(DataBufferingPolicy); |
236 | 236 |
237 // The isPreloaded() flag is using a counter in order to make sure that even | 237 // The isPreloaded() flag is using a counter in order to make sure that even |
238 // when multiple ResourceFetchers are preloading the resource, it will remain | 238 // when multiple ResourceFetchers are preloading the resource, it will remain |
239 // marked as preloaded until *all* of them have used it. | 239 // marked as preloaded until *all* of them have used it. |
240 bool isUnusedPreload() const { | 240 bool isUnusedPreload() const { |
(...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
465 }; | 465 }; |
466 | 466 |
467 #define DEFINE_RESOURCE_TYPE_CASTS(typeName) \ | 467 #define DEFINE_RESOURCE_TYPE_CASTS(typeName) \ |
468 DEFINE_TYPE_CASTS(typeName##Resource, Resource, resource, \ | 468 DEFINE_TYPE_CASTS(typeName##Resource, Resource, resource, \ |
469 resource->getType() == Resource::typeName, \ | 469 resource->getType() == Resource::typeName, \ |
470 resource.getType() == Resource::typeName); | 470 resource.getType() == Resource::typeName); |
471 | 471 |
472 } // namespace blink | 472 } // namespace blink |
473 | 473 |
474 #endif | 474 #endif |
OLD | NEW |