OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2011, 2012 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 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
167 | 167 |
168 Document* m_document; | 168 Document* m_document; |
169 WebSocketChannelClient* m_client; | 169 WebSocketChannelClient* m_client; |
170 OwnPtr<WebSocketHandshake> m_handshake; | 170 OwnPtr<WebSocketHandshake> m_handshake; |
171 RefPtr<SocketStreamHandle> m_handle; | 171 RefPtr<SocketStreamHandle> m_handle; |
172 Vector<char> m_buffer; | 172 Vector<char> m_buffer; |
173 | 173 |
174 Timer<MainThreadWebSocketChannel> m_resumeTimer; | 174 Timer<MainThreadWebSocketChannel> m_resumeTimer; |
175 bool m_suspended; | 175 bool m_suspended; |
176 bool m_closing; | 176 bool m_closing; |
| 177 bool m_didFailOfClientAlreadyRun; |
177 bool m_receivedClosingHandshake; | 178 bool m_receivedClosingHandshake; |
178 Timer<MainThreadWebSocketChannel> m_closingTimer; | 179 Timer<MainThreadWebSocketChannel> m_closingTimer; |
179 bool m_closed; | 180 bool m_closed; |
180 bool m_shouldDiscardReceivedData; | 181 bool m_shouldDiscardReceivedData; |
181 unsigned long m_unhandledBufferedAmount; | 182 unsigned long m_unhandledBufferedAmount; |
182 | 183 |
183 unsigned long m_identifier; // m_identifier == 0 means that we could not obt
ain a valid identifier. | 184 unsigned long m_identifier; // m_identifier == 0 means that we could not obt
ain a valid identifier. |
184 | 185 |
185 // Private members only for hybi-10 protocol. | 186 // Private members only for hybi-10 protocol. |
186 bool m_hasContinuousFrame; | 187 bool m_hasContinuousFrame; |
187 WebSocketFrame::OpCode m_continuousFrameOpCode; | 188 WebSocketFrame::OpCode m_continuousFrameOpCode; |
188 Vector<char> m_continuousFrameData; | 189 Vector<char> m_continuousFrameData; |
189 unsigned short m_closeEventCode; | 190 unsigned short m_closeEventCode; |
190 String m_closeEventReason; | 191 String m_closeEventReason; |
191 | 192 |
192 Deque<OwnPtr<QueuedFrame> > m_outgoingFrameQueue; | 193 Deque<OwnPtr<QueuedFrame> > m_outgoingFrameQueue; |
193 OutgoingFrameQueueStatus m_outgoingFrameQueueStatus; | 194 OutgoingFrameQueueStatus m_outgoingFrameQueueStatus; |
194 | 195 |
195 // FIXME: Load two or more Blobs simultaneously for better performance. | 196 // FIXME: Load two or more Blobs simultaneously for better performance. |
196 OwnPtr<FileReaderLoader> m_blobLoader; | 197 OwnPtr<FileReaderLoader> m_blobLoader; |
197 BlobLoaderStatus m_blobLoaderStatus; | 198 BlobLoaderStatus m_blobLoaderStatus; |
198 | 199 |
199 WebSocketDeflateFramer m_deflateFramer; | 200 WebSocketDeflateFramer m_deflateFramer; |
200 }; | 201 }; |
201 | 202 |
202 } // namespace WebCore | 203 } // namespace WebCore |
203 | 204 |
204 #endif // MainThreadWebSocketChannel_h | 205 #endif // MainThreadWebSocketChannel_h |
OLD | NEW |