OLD | NEW |
1 /* | 1 /* |
2 * libjingle | 2 * libjingle |
3 * Copyright 2012 Google Inc. | 3 * Copyright 2012 Google Inc. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are met: | 6 * modification, are permitted provided that the following conditions are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright notice, | 8 * 1. Redistributions of source code must retain the above copyright notice, |
9 * this list of conditions and the following disclaimer. | 9 * this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright notice, | 10 * 2. Redistributions in binary form must reproduce the above copyright notice, |
(...skipping 119 matching lines...) Loading... |
130 class MetricsObserverInterface : public rtc::RefCountInterface { | 130 class MetricsObserverInterface : public rtc::RefCountInterface { |
131 public: | 131 public: |
132 | 132 |
133 // |type| is the type of the enum counter to be incremented. |counter| | 133 // |type| is the type of the enum counter to be incremented. |counter| |
134 // is the particular counter in that type. |counter_max| is the next sequence | 134 // is the particular counter in that type. |counter_max| is the next sequence |
135 // number after the highest counter. | 135 // number after the highest counter. |
136 virtual void IncrementEnumCounter(PeerConnectionEnumCounterType type, | 136 virtual void IncrementEnumCounter(PeerConnectionEnumCounterType type, |
137 int counter, | 137 int counter, |
138 int counter_max) {} | 138 int counter_max) {} |
139 | 139 |
| 140 // This is used to handle sparse counters like SSL cipher suites. |
| 141 // TODO(guoweis): Remove the implementation once the dependency's interface |
| 142 // definition is updated. |
| 143 virtual void IncrementSparseEnumCounter(PeerConnectionEnumCounterType type, |
| 144 int counter) { |
| 145 IncrementEnumCounter(type, counter, 0 /* Ignored */); |
| 146 } |
| 147 |
140 virtual void AddHistogramSample(PeerConnectionMetricsName type, | 148 virtual void AddHistogramSample(PeerConnectionMetricsName type, |
141 int value) = 0; | 149 int value) = 0; |
142 // TODO(jbauch): Make method abstract when it is implemented by Chromium. | |
143 virtual void AddHistogramSample(PeerConnectionMetricsName type, | |
144 const std::string& value) {} | |
145 | 150 |
146 protected: | 151 protected: |
147 virtual ~MetricsObserverInterface() {} | 152 virtual ~MetricsObserverInterface() {} |
148 }; | 153 }; |
149 | 154 |
150 typedef MetricsObserverInterface UMAObserver; | 155 typedef MetricsObserverInterface UMAObserver; |
151 | 156 |
152 class PeerConnectionInterface : public rtc::RefCountInterface { | 157 class PeerConnectionInterface : public rtc::RefCountInterface { |
153 public: | 158 public: |
154 // See http://dev.w3.org/2011/webrtc/editor/webrtc.html#state-definitions . | 159 // See http://dev.w3.org/2011/webrtc/editor/webrtc.html#state-definitions . |
(...skipping 477 matching lines...) Loading... |
632 CreatePeerConnectionFactory( | 637 CreatePeerConnectionFactory( |
633 rtc::Thread* worker_thread, | 638 rtc::Thread* worker_thread, |
634 rtc::Thread* signaling_thread, | 639 rtc::Thread* signaling_thread, |
635 AudioDeviceModule* default_adm, | 640 AudioDeviceModule* default_adm, |
636 cricket::WebRtcVideoEncoderFactory* encoder_factory, | 641 cricket::WebRtcVideoEncoderFactory* encoder_factory, |
637 cricket::WebRtcVideoDecoderFactory* decoder_factory); | 642 cricket::WebRtcVideoDecoderFactory* decoder_factory); |
638 | 643 |
639 } // namespace webrtc | 644 } // namespace webrtc |
640 | 645 |
641 #endif // TALK_APP_WEBRTC_PEERCONNECTIONINTERFACE_H_ | 646 #endif // TALK_APP_WEBRTC_PEERCONNECTIONINTERFACE_H_ |
OLD | NEW |