OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * | 10 * |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 namespace blink { | 43 namespace blink { |
44 | 44 |
45 class ExecutionContext; | 45 class ExecutionContext; |
46 class Resource; | 46 class Resource; |
47 class FormData; | 47 class FormData; |
48 class ResourceResponse; | 48 class ResourceResponse; |
49 class SharedBuffer; | 49 class SharedBuffer; |
50 class TextResourceDecoder; | 50 class TextResourceDecoder; |
51 | 51 |
52 class XHRReplayData | 52 class XHRReplayData |
53 : public RefCounted<XHRReplayData> | 53 : public RefCountedWillBeGarbageCollectedFinalized<XHRReplayData> |
54 , public ContextLifecycleObserver { | 54 , public ContextLifecycleObserver { |
55 public: | 55 public: |
56 static PassRefPtr<XHRReplayData> create(ExecutionContext*, const AtomicStrin
g& method, const KURL&, bool async, PassRefPtr<FormData>, bool includeCredential
s); | 56 static PassRefPtrWillBeRawPtr<XHRReplayData> create(ExecutionContext*, const
AtomicString& method, const KURL&, bool async, PassRefPtr<FormData>, bool inclu
deCredentials); |
57 | 57 |
58 void addHeader(const AtomicString& key, const AtomicString& value); | 58 void addHeader(const AtomicString& key, const AtomicString& value); |
59 const AtomicString& method() const { return m_method; } | 59 const AtomicString& method() const { return m_method; } |
60 const KURL& url() const { return m_url; } | 60 const KURL& url() const { return m_url; } |
61 bool async() const { return m_async; } | 61 bool async() const { return m_async; } |
62 PassRefPtr<FormData> formData() const { return m_formData; } | 62 PassRefPtr<FormData> formData() const { return m_formData; } |
63 const HTTPHeaderMap& headers() const { return m_headers; } | 63 const HTTPHeaderMap& headers() const { return m_headers; } |
64 bool includeCredentials() const { return m_includeCredentials; } | 64 bool includeCredentials() const { return m_includeCredentials; } |
65 | 65 |
| 66 void trace(Visitor*) { } |
| 67 |
66 private: | 68 private: |
67 XHRReplayData(ExecutionContext*, const AtomicString& method, const KURL&, bo
ol async, PassRefPtr<FormData>, bool includeCredentials); | 69 XHRReplayData(ExecutionContext*, const AtomicString& method, const KURL&, bo
ol async, PassRefPtr<FormData>, bool includeCredentials); |
68 | 70 |
69 AtomicString m_method; | 71 AtomicString m_method; |
70 KURL m_url; | 72 KURL m_url; |
71 bool m_async; | 73 bool m_async; |
72 RefPtr<FormData> m_formData; | 74 RefPtr<FormData> m_formData; |
73 HTTPHeaderMap m_headers; | 75 HTTPHeaderMap m_headers; |
74 bool m_includeCredentials; | 76 bool m_includeCredentials; |
75 }; | 77 }; |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
127 bool hasData() const { return m_dataBuffer; } | 129 bool hasData() const { return m_dataBuffer; } |
128 size_t dataLength() const; | 130 size_t dataLength() const; |
129 void appendData(const char* data, size_t dataLength); | 131 void appendData(const char* data, size_t dataLength); |
130 size_t decodeDataToContent(); | 132 size_t decodeDataToContent(); |
131 | 133 |
132 String m_requestId; | 134 String m_requestId; |
133 String m_loaderId; | 135 String m_loaderId; |
134 String m_frameId; | 136 String m_frameId; |
135 KURL m_url; | 137 KURL m_url; |
136 String m_content; | 138 String m_content; |
137 RefPtr<XHRReplayData> m_xhrReplayData; | 139 RefPtrWillBePersistent<XHRReplayData> m_xhrReplayData; |
138 bool m_base64Encoded; | 140 bool m_base64Encoded; |
139 RefPtr<SharedBuffer> m_dataBuffer; | 141 RefPtr<SharedBuffer> m_dataBuffer; |
140 bool m_isContentEvicted; | 142 bool m_isContentEvicted; |
141 InspectorPageAgent::ResourceType m_type; | 143 InspectorPageAgent::ResourceType m_type; |
142 int m_httpStatusCode; | 144 int m_httpStatusCode; |
143 | 145 |
144 String m_textEncodingName; | 146 String m_textEncodingName; |
145 OwnPtr<TextResourceDecoder> m_decoder; | 147 OwnPtr<TextResourceDecoder> m_decoder; |
146 | 148 |
147 RefPtr<SharedBuffer> m_buffer; | 149 RefPtr<SharedBuffer> m_buffer; |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
182 ResourceDataMap m_requestIdToResourceDataMap; | 184 ResourceDataMap m_requestIdToResourceDataMap; |
183 size_t m_contentSize; | 185 size_t m_contentSize; |
184 size_t m_maximumResourcesContentSize; | 186 size_t m_maximumResourcesContentSize; |
185 size_t m_maximumSingleResourceContentSize; | 187 size_t m_maximumSingleResourceContentSize; |
186 }; | 188 }; |
187 | 189 |
188 } // namespace blink | 190 } // namespace blink |
189 | 191 |
190 | 192 |
191 #endif // !defined(NetworkResourcesData_h) | 193 #endif // !defined(NetworkResourcesData_h) |
OLD | NEW |