| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 63 return candidates_.size(); | 63 return candidates_.size(); |
| 64 } | 64 } |
| 65 virtual bool HasCandidate(const IceCandidateInterface* candidate) const; | 65 virtual bool HasCandidate(const IceCandidateInterface* candidate) const; |
| 66 // Adds and takes ownership of the JsepIceCandidate. | 66 // Adds and takes ownership of the JsepIceCandidate. |
| 67 virtual void add(JsepIceCandidate* candidate) { | 67 virtual void add(JsepIceCandidate* candidate) { |
| 68 candidates_.push_back(candidate); | 68 candidates_.push_back(candidate); |
| 69 } | 69 } |
| 70 virtual const IceCandidateInterface* at(size_t index) const { | 70 virtual const IceCandidateInterface* at(size_t index) const { |
| 71 return candidates_[index]; | 71 return candidates_[index]; |
| 72 } | 72 } |
| 73 // Removes the candidate that has a matching address and protocol. |
| 74 // Returns the number of candidates that were removed. |
| 75 size_t remove(const cricket::Candidate& candidate); |
| 73 | 76 |
| 74 private: | 77 private: |
| 75 std::vector<JsepIceCandidate*> candidates_; | 78 std::vector<JsepIceCandidate*> candidates_; |
| 76 | 79 |
| 77 RTC_DISALLOW_COPY_AND_ASSIGN(JsepCandidateCollection); | 80 RTC_DISALLOW_COPY_AND_ASSIGN(JsepCandidateCollection); |
| 78 }; | 81 }; |
| 79 | 82 |
| 80 } // namespace webrtc | 83 } // namespace webrtc |
| 81 | 84 |
| 82 #endif // WEBRTC_API_JSEPICECANDIDATE_H_ | 85 #endif // WEBRTC_API_JSEPICECANDIDATE_H_ |
| OLD | NEW |