Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1083)

Unified Diff: webrtc/sdk/objc/Framework/Classes/RTCRtpSender.mm

Issue 1917193008: Adding getParameters/setParameters APIs to RtpReceiver. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: objc compile errors Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/sdk/objc/Framework/Classes/RTCRtpSender.mm
diff --git a/webrtc/sdk/objc/Framework/Classes/RTCRtpSender.mm b/webrtc/sdk/objc/Framework/Classes/RTCRtpSender.mm
index 3d413dc16013d6eb902bf42f692e556b25840d22..9ecf0ae5ae91876fcb852ed82a73ffad8a3d8878 100644
--- a/webrtc/sdk/objc/Framework/Classes/RTCRtpSender.mm
+++ b/webrtc/sdk/objc/Framework/Classes/RTCRtpSender.mm
@@ -21,16 +21,6 @@
rtc::scoped_refptr<webrtc::RtpSenderInterface> _nativeRtpSender;
}
-- (instancetype)initWithNativeRtpSender:
- (rtc::scoped_refptr<webrtc::RtpSenderInterface>)nativeRtpSender {
- NSParameterAssert(nativeRtpSender);
- if (self = [super init]) {
- _nativeRtpSender = nativeRtpSender;
- RTCLogInfo(@"RTCRtpSender(%p): created sender: %@", self, self.description);
- }
- return self;
-}
-
- (NSString *)senderId {
return [NSString stringForStdString:_nativeRtpSender->id()];
}
@@ -67,4 +57,38 @@
self.senderId];
}
+- (BOOL)isEqual:(id)object {
+ if (self == object) {
+ return YES;
+ }
+ if (object == nil) {
+ return NO;
+ }
+ if (![object isMemberOfClass:[self class]]) {
+ return NO;
+ }
+ RTCRtpSender *sender = (RTCRtpSender *)object;
+ return _nativeRtpSender == sender.nativeRtpSender;
+}
+
+- (NSUInteger)hash {
+ return (NSUInteger)_nativeRtpSender.get();
+}
+
+#pragma mark - Private
+
+- (rtc::scoped_refptr<webrtc::RtpSenderInterface>)nativeRtpSender {
+ return _nativeRtpSender;
+}
+
+- (instancetype)initWithNativeRtpSender:
+ (rtc::scoped_refptr<webrtc::RtpSenderInterface>)nativeRtpSender {
+ NSParameterAssert(nativeRtpSender);
+ if (self = [super init]) {
+ _nativeRtpSender = nativeRtpSender;
+ RTCLogInfo(@"RTCRtpSender(%p): created sender: %@", self, self.description);
+ }
+ return self;
+}
+
@end
« no previous file with comments | « webrtc/sdk/objc/Framework/Classes/RTCRtpReceiver+Private.h ('k') | webrtc/sdk/objc/Framework/Classes/RTCRtpSender+Private.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698