OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007 Apple 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 | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 10 matching lines...) Expand all Loading... |
21 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 21 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
23 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 23 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
24 */ | 24 */ |
25 | 25 |
26 #ifndef SubstituteData_h | 26 #ifndef SubstituteData_h |
27 #define SubstituteData_h | 27 #define SubstituteData_h |
28 | 28 |
29 #include "platform/SharedBuffer.h" | 29 #include "platform/SharedBuffer.h" |
30 #include "platform/weborigin/KURL.h" | 30 #include "platform/weborigin/KURL.h" |
| 31 #include "wtf/Allocator.h" |
31 #include "wtf/PassRefPtr.h" | 32 #include "wtf/PassRefPtr.h" |
32 #include "wtf/RefPtr.h" | 33 #include "wtf/RefPtr.h" |
33 | 34 |
34 namespace blink { | 35 namespace blink { |
35 | 36 |
36 enum SubstituteDataLoadPolicy { | 37 enum SubstituteDataLoadPolicy { |
37 LoadNormally, | 38 LoadNormally, |
38 ForceSynchronousLoad | 39 ForceSynchronousLoad |
39 }; | 40 }; |
40 | 41 |
41 class SubstituteData { | 42 class SubstituteData { |
| 43 DISALLOW_ALLOCATION(); |
42 public: | 44 public: |
43 SubstituteData() | 45 SubstituteData() |
44 : m_substituteDataLoadPolicy(LoadNormally) | 46 : m_substituteDataLoadPolicy(LoadNormally) |
45 { | 47 { |
46 } | 48 } |
47 | 49 |
48 SubstituteData(PassRefPtr<SharedBuffer> content, const AtomicString& mimeTyp
e, const AtomicString& textEncoding, const KURL& failingURL, SubstituteDataLoadP
olicy substituteDataLoadPolicy = LoadNormally) | 50 SubstituteData(PassRefPtr<SharedBuffer> content, const AtomicString& mimeTyp
e, const AtomicString& textEncoding, const KURL& failingURL, SubstituteDataLoadP
olicy substituteDataLoadPolicy = LoadNormally) |
49 : m_content(content) | 51 : m_content(content) |
50 , m_mimeType(mimeType) | 52 , m_mimeType(mimeType) |
51 , m_textEncoding(textEncoding) | 53 , m_textEncoding(textEncoding) |
(...skipping 15 matching lines...) Expand all Loading... |
67 AtomicString m_mimeType; | 69 AtomicString m_mimeType; |
68 AtomicString m_textEncoding; | 70 AtomicString m_textEncoding; |
69 KURL m_failingURL; | 71 KURL m_failingURL; |
70 SubstituteDataLoadPolicy m_substituteDataLoadPolicy; | 72 SubstituteDataLoadPolicy m_substituteDataLoadPolicy; |
71 }; | 73 }; |
72 | 74 |
73 } | 75 } |
74 | 76 |
75 #endif // SubstituteData_h | 77 #endif // SubstituteData_h |
76 | 78 |
OLD | NEW |