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 * | 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
122 // WebRTCPeerConnectionHandlerClient | 122 // WebRTCPeerConnectionHandlerClient |
123 virtual void negotiationNeeded() OVERRIDE; | 123 virtual void negotiationNeeded() OVERRIDE; |
124 virtual void didGenerateICECandidate(const WebRTCICECandidate&) OVERRIDE; | 124 virtual void didGenerateICECandidate(const WebRTCICECandidate&) OVERRIDE; |
125 virtual void didChangeSignalingState(SignalingState) OVERRIDE; | 125 virtual void didChangeSignalingState(SignalingState) OVERRIDE; |
126 virtual void didChangeICEGatheringState(ICEGatheringState) OVERRIDE; | 126 virtual void didChangeICEGatheringState(ICEGatheringState) OVERRIDE; |
127 virtual void didChangeICEConnectionState(ICEConnectionState) OVERRIDE; | 127 virtual void didChangeICEConnectionState(ICEConnectionState) OVERRIDE; |
128 virtual void didAddRemoteStream(const WebMediaStream&) OVERRIDE; | 128 virtual void didAddRemoteStream(const WebMediaStream&) OVERRIDE; |
129 virtual void didRemoveRemoteStream(const WebMediaStream&) OVERRIDE; | 129 virtual void didRemoveRemoteStream(const WebMediaStream&) OVERRIDE; |
130 virtual void didAddRemoteDataChannel(WebRTCDataChannelHandler*) OVERRIDE; | 130 virtual void didAddRemoteDataChannel(WebRTCDataChannelHandler*) OVERRIDE; |
131 virtual void releasePeerConnectionHandler() OVERRIDE; | 131 virtual void releasePeerConnectionHandler() OVERRIDE; |
| 132 virtual void closePeerConnection() OVERRIDE; |
132 | 133 |
133 // EventTarget | 134 // EventTarget |
134 virtual const AtomicString& interfaceName() const OVERRIDE; | 135 virtual const AtomicString& interfaceName() const OVERRIDE; |
135 virtual ExecutionContext* executionContext() const OVERRIDE; | 136 virtual ExecutionContext* executionContext() const OVERRIDE; |
136 | 137 |
137 // ActiveDOMObject | 138 // ActiveDOMObject |
138 virtual void suspend() OVERRIDE; | 139 virtual void suspend() OVERRIDE; |
139 virtual void resume() OVERRIDE; | 140 virtual void resume() OVERRIDE; |
140 virtual void stop() OVERRIDE; | 141 virtual void stop() OVERRIDE; |
141 // We keep the this object alive until either stopped or closed. | 142 // We keep the this object alive until either stopped or closed. |
(...skipping 11 matching lines...) Expand all Loading... |
153 static PassRefPtr<RTCOfferOptions> parseOfferOptions(const Dictionary&, Exce
ptionState&); | 154 static PassRefPtr<RTCOfferOptions> parseOfferOptions(const Dictionary&, Exce
ptionState&); |
154 | 155 |
155 void scheduleDispatchEvent(PassRefPtrWillBeRawPtr<Event>); | 156 void scheduleDispatchEvent(PassRefPtrWillBeRawPtr<Event>); |
156 void dispatchScheduledEvent(); | 157 void dispatchScheduledEvent(); |
157 bool hasLocalStreamWithTrackId(const String& trackId); | 158 bool hasLocalStreamWithTrackId(const String& trackId); |
158 | 159 |
159 void changeSignalingState(WebRTCPeerConnectionHandlerClient::SignalingState)
; | 160 void changeSignalingState(WebRTCPeerConnectionHandlerClient::SignalingState)
; |
160 void changeIceGatheringState(WebRTCPeerConnectionHandlerClient::ICEGathering
State); | 161 void changeIceGatheringState(WebRTCPeerConnectionHandlerClient::ICEGathering
State); |
161 void changeIceConnectionState(WebRTCPeerConnectionHandlerClient::ICEConnecti
onState); | 162 void changeIceConnectionState(WebRTCPeerConnectionHandlerClient::ICEConnecti
onState); |
162 | 163 |
| 164 void closeInternal(); |
| 165 |
163 SignalingState m_signalingState; | 166 SignalingState m_signalingState; |
164 ICEGatheringState m_iceGatheringState; | 167 ICEGatheringState m_iceGatheringState; |
165 ICEConnectionState m_iceConnectionState; | 168 ICEConnectionState m_iceConnectionState; |
166 | 169 |
167 MediaStreamVector m_localStreams; | 170 MediaStreamVector m_localStreams; |
168 MediaStreamVector m_remoteStreams; | 171 MediaStreamVector m_remoteStreams; |
169 | 172 |
170 HeapVector<Member<RTCDataChannel> > m_dataChannels; | 173 HeapVector<Member<RTCDataChannel> > m_dataChannels; |
171 | 174 |
172 OwnPtr<WebRTCPeerConnectionHandler> m_peerHandler; | 175 OwnPtr<WebRTCPeerConnectionHandler> m_peerHandler; |
173 | 176 |
174 AsyncMethodRunner<RTCPeerConnection> m_dispatchScheduledEventRunner; | 177 AsyncMethodRunner<RTCPeerConnection> m_dispatchScheduledEventRunner; |
175 WillBeHeapVector<RefPtrWillBeMember<Event> > m_scheduledEvents; | 178 WillBeHeapVector<RefPtrWillBeMember<Event> > m_scheduledEvents; |
176 | 179 |
177 bool m_stopped; | 180 bool m_stopped; |
178 bool m_closed; | 181 bool m_closed; |
179 }; | 182 }; |
180 | 183 |
181 } // namespace blink | 184 } // namespace blink |
182 | 185 |
183 #endif // RTCPeerConnection_h | 186 #endif // RTCPeerConnection_h |
OLD | NEW |