OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 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 | 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 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 | 82 |
83 void stop(); | 83 void stop(); |
84 | 84 |
85 // EventTarget | 85 // EventTarget |
86 virtual const AtomicString& interfaceName() const OVERRIDE; | 86 virtual const AtomicString& interfaceName() const OVERRIDE; |
87 virtual ExecutionContext* executionContext() const OVERRIDE; | 87 virtual ExecutionContext* executionContext() const OVERRIDE; |
88 | 88 |
89 private: | 89 private: |
90 RTCDataChannel(ExecutionContext*, PassOwnPtr<blink::WebRTCDataChannelHandler
>); | 90 RTCDataChannel(ExecutionContext*, PassOwnPtr<blink::WebRTCDataChannelHandler
>); |
91 | 91 |
92 void scheduleDispatchEvent(PassRefPtr<Event>); | 92 void scheduleDispatchEvent(PassRefPtrWillBeRawPtr<Event>); |
93 void scheduledEventTimerFired(Timer<RTCDataChannel>*); | 93 void scheduledEventTimerFired(Timer<RTCDataChannel>*); |
94 | 94 |
95 ExecutionContext* m_executionContext; | 95 ExecutionContext* m_executionContext; |
96 | 96 |
97 // blink::WebRTCDataChannelHandlerClient | 97 // blink::WebRTCDataChannelHandlerClient |
98 virtual void didChangeReadyState(blink::WebRTCDataChannelHandlerClient::Read
yState) OVERRIDE; | 98 virtual void didChangeReadyState(blink::WebRTCDataChannelHandlerClient::Read
yState) OVERRIDE; |
99 virtual void didReceiveStringData(const blink::WebString&) OVERRIDE; | 99 virtual void didReceiveStringData(const blink::WebString&) OVERRIDE; |
100 virtual void didReceiveRawData(const char*, size_t) OVERRIDE; | 100 virtual void didReceiveRawData(const char*, size_t) OVERRIDE; |
101 virtual void didDetectError() OVERRIDE; | 101 virtual void didDetectError() OVERRIDE; |
102 | 102 |
103 OwnPtr<blink::WebRTCDataChannelHandler> m_handler; | 103 OwnPtr<blink::WebRTCDataChannelHandler> m_handler; |
104 | 104 |
105 bool m_stopped; | 105 bool m_stopped; |
106 | 106 |
107 blink::WebRTCDataChannelHandlerClient::ReadyState m_readyState; | 107 blink::WebRTCDataChannelHandlerClient::ReadyState m_readyState; |
108 | 108 |
109 enum BinaryType { | 109 enum BinaryType { |
110 BinaryTypeBlob, | 110 BinaryTypeBlob, |
111 BinaryTypeArrayBuffer | 111 BinaryTypeArrayBuffer |
112 }; | 112 }; |
113 BinaryType m_binaryType; | 113 BinaryType m_binaryType; |
114 | 114 |
115 Timer<RTCDataChannel> m_scheduledEventTimer; | 115 Timer<RTCDataChannel> m_scheduledEventTimer; |
116 Vector<RefPtr<Event> > m_scheduledEvents; | 116 WillBePersistentHeapVector<RefPtrWillBeMember<Event> > m_scheduledEvents; |
117 }; | 117 }; |
118 | 118 |
119 } // namespace WebCore | 119 } // namespace WebCore |
120 | 120 |
121 #endif // RTCDataChannel_h | 121 #endif // RTCDataChannel_h |
OLD | NEW |