| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 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 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 148 bool wasClean, | 148 bool wasClean, |
| 149 unsigned short code, | 149 unsigned short code, |
| 150 const String& reason) override; | 150 const String& reason) override; |
| 151 void didReceiveFlowControl(WebSocketHandle*, int64_t quota) override; | 151 void didReceiveFlowControl(WebSocketHandle*, int64_t quota) override; |
| 152 void didStartClosingHandshake(WebSocketHandle*) override; | 152 void didStartClosingHandshake(WebSocketHandle*) override; |
| 153 | 153 |
| 154 // Methods for BlobLoader. | 154 // Methods for BlobLoader. |
| 155 void didFinishLoadingBlob(DOMArrayBuffer*); | 155 void didFinishLoadingBlob(DOMArrayBuffer*); |
| 156 void didFailLoadingBlob(FileError::ErrorCode); | 156 void didFailLoadingBlob(FileError::ErrorCode); |
| 157 | 157 |
| 158 // This method is run asynchronously after a successful connect() to allow for |
| 159 // additional filtering policy to be applied to this connection. |
| 160 void maybeFilterConnection(); |
| 161 |
| 158 // m_handle is a handle of the connection. | 162 // m_handle is a handle of the connection. |
| 159 // m_handle == 0 means this channel is closed. | 163 // m_handle == 0 means this channel is closed. |
| 160 std::unique_ptr<WebSocketHandle> m_handle; | 164 std::unique_ptr<WebSocketHandle> m_handle; |
| 161 | 165 |
| 162 // m_client can be deleted while this channel is alive, but this class | 166 // m_client can be deleted while this channel is alive, but this class |
| 163 // expects that disconnect() is called before the deletion. | 167 // expects that disconnect() is called before the deletion. |
| 164 Member<WebSocketChannelClient> m_client; | 168 Member<WebSocketChannelClient> m_client; |
| 165 KURL m_url; | 169 KURL m_url; |
| 166 // m_identifier > 0 means calling scriptContextExecution() returns a Document. | 170 // m_identifier > 0 means calling scriptContextExecution() returns a Document. |
| 167 unsigned long m_identifier; | 171 unsigned long m_identifier; |
| (...skipping 13 matching lines...) Expand all Loading... |
| 181 RefPtr<WebSocketHandshakeRequest> m_handshakeRequest; | 185 RefPtr<WebSocketHandshakeRequest> m_handshakeRequest; |
| 182 | 186 |
| 183 static const uint64_t receivedDataSizeForFlowControlHighWaterMark = 1 << 15; | 187 static const uint64_t receivedDataSizeForFlowControlHighWaterMark = 1 << 15; |
| 184 }; | 188 }; |
| 185 | 189 |
| 186 std::ostream& operator<<(std::ostream&, const DocumentWebSocketChannel*); | 190 std::ostream& operator<<(std::ostream&, const DocumentWebSocketChannel*); |
| 187 | 191 |
| 188 } // namespace blink | 192 } // namespace blink |
| 189 | 193 |
| 190 #endif // DocumentWebSocketChannel_h | 194 #endif // DocumentWebSocketChannel_h |
| OLD | NEW |