├── README.md ├── WebRTCVideoChat.xcodeproj ├── project.pbxproj ├── project.xcworkspace │ └── contents.xcworkspacedata └── xcuserdata │ └── Kyle.xcuserdatad │ ├── xcdebugger │ └── Breakpoints_v2.xcbkptlist │ └── xcschemes │ ├── WebRTCVideoChat.xcscheme │ └── xcschememanagement.plist ├── WebRTCVideoChat ├── AppDelegate.swift ├── Assets.xcassets │ └── AppIcon.appiconset │ │ └── Contents.json ├── Base.lproj │ ├── LaunchScreen.storyboard │ └── Main.storyboard ├── Info.plist ├── PubNub.framework │ ├── Headers │ │ ├── NSURLSessionConfiguration+PNConfiguration.h │ │ ├── PNAES.h │ │ ├── PNAPICallBuilder.h │ │ ├── PNAPNSAPICallBuilder.h │ │ ├── PNAPNSAuditAPICallBuilder.h │ │ ├── PNAPNSEnabledChannelsResult.h │ │ ├── PNAPNSModificationAPICallBuilder.h │ │ ├── PNAcknowledgmentStatus.h │ │ ├── PNChannelClientStateResult.h │ │ ├── PNChannelGroupChannelsResult.h │ │ ├── PNChannelGroupClientStateResult.h │ │ ├── PNChannelGroupsResult.h │ │ ├── PNClientInformation.h │ │ ├── PNClientStateUpdateStatus.h │ │ ├── PNConfiguration.h │ │ ├── PNDefines.h │ │ ├── PNErrorCodes.h │ │ ├── PNErrorStatus.h │ │ ├── PNHistoryAPICallBuilder.h │ │ ├── PNHistoryResult.h │ │ ├── PNLLogger.h │ │ ├── PNObjectEventListener.h │ │ ├── PNPresenceAPICallBuilder.h │ │ ├── PNPresenceChannelGroupHereNowAPICallBuilder.h │ │ ├── PNPresenceChannelGroupHereNowResult.h │ │ ├── PNPresenceChannelHereNowAPICallBuilder.h │ │ ├── PNPresenceChannelHereNowResult.h │ │ ├── PNPresenceGlobalHereNowResult.h │ │ ├── PNPresenceHereNowAPICallBuilder.h │ │ ├── PNPresenceWhereNowAPICallBuilder.h │ │ ├── PNPresenceWhereNowResult.h │ │ ├── PNPublishAPICallBuilder.h │ │ ├── PNPublishSizeAPICallBuilder.h │ │ ├── PNPublishStatus.h │ │ ├── PNResult.h │ │ ├── PNServiceData.h │ │ ├── PNStateAPICallBuilder.h │ │ ├── PNStateAuditAPICallBuilder.h │ │ ├── PNStateModificationAPICallBuilder.h │ │ ├── PNStatus.h │ │ ├── PNStreamAPICallBuilder.h │ │ ├── PNStreamAuditAPICallBuilder.h │ │ ├── PNStreamModificationAPICallBuilder.h │ │ ├── PNStructures.h │ │ ├── PNSubscribeAPIBuilder.h │ │ ├── PNSubscribeChannelsOrGroupsAPIBuilder.h │ │ ├── PNSubscribeStatus.h │ │ ├── PNSubscriberResults.h │ │ ├── PNTimeAPICallBuilder.h │ │ ├── PNTimeResult.h │ │ ├── PNUnsubscribeAPICallBuilder.h │ │ ├── PNUnsubscribeChannelsOrGroupsAPICallBuilder.h │ │ ├── PubNub+APNS.h │ │ ├── PubNub+ChannelGroup.h │ │ ├── PubNub+Core.h │ │ ├── PubNub+History.h │ │ ├── PubNub+Presence.h │ │ ├── PubNub+Publish.h │ │ ├── PubNub+State.h │ │ ├── PubNub+Subscribe.h │ │ ├── PubNub+Time.h │ │ └── PubNub.h │ ├── Info.plist │ ├── Modules │ │ └── module.modulemap │ └── PubNub ├── Signaler.swift ├── ViewController.swift ├── WebRTC.framework │ ├── Headers │ │ ├── RTCAVFoundationVideoSource.h │ │ ├── RTCAudioSession.h │ │ ├── RTCAudioSessionConfiguration.h │ │ ├── RTCAudioSource.h │ │ ├── RTCAudioTrack.h │ │ ├── RTCCameraPreviewView.h │ │ ├── RTCCameraVideoCapturer.h │ │ ├── RTCConfiguration.h │ │ ├── RTCDataChannel.h │ │ ├── RTCDataChannelConfiguration.h │ │ ├── RTCDispatcher.h │ │ ├── RTCEAGLVideoView.h │ │ ├── RTCFieldTrials.h │ │ ├── RTCFileLogger.h │ │ ├── RTCIceCandidate.h │ │ ├── RTCIceServer.h │ │ ├── RTCIntervalRange.h │ │ ├── RTCLegacyStatsReport.h │ │ ├── RTCLogging.h │ │ ├── RTCMTLVideoView.h │ │ ├── RTCMacros.h │ │ ├── RTCMediaConstraints.h │ │ ├── RTCMediaSource.h │ │ ├── RTCMediaStream.h │ │ ├── RTCMediaStreamTrack.h │ │ ├── RTCMetrics.h │ │ ├── RTCMetricsSampleInfo.h │ │ ├── RTCPeerConnection.h │ │ ├── RTCPeerConnectionFactory.h │ │ ├── RTCRtpCodecParameters.h │ │ ├── RTCRtpEncodingParameters.h │ │ ├── RTCRtpParameters.h │ │ ├── RTCRtpReceiver.h │ │ ├── RTCRtpSender.h │ │ ├── RTCSSLAdapter.h │ │ ├── RTCSessionDescription.h │ │ ├── RTCTracing.h │ │ ├── RTCVideoCapturer.h │ │ ├── RTCVideoCodec.h │ │ ├── RTCVideoCodecFactory.h │ │ ├── RTCVideoCodecH264.h │ │ ├── RTCVideoFrame.h │ │ ├── RTCVideoFrameBuffer.h │ │ ├── RTCVideoRenderer.h │ │ ├── RTCVideoSource.h │ │ ├── RTCVideoTrack.h │ │ ├── RTCVideoViewShading.h │ │ ├── UIDevice+RTCDevice.h │ │ └── WebRTC.h │ ├── Info.plist │ ├── LICENSE.html │ ├── Modules │ │ └── module.modulemap │ └── WebRTC └── WebRTCClient.swift └── WebRTCVideoChatTests ├── Info.plist └── WebRTCVideoChatTests.swift /README.md: -------------------------------------------------------------------------------- 1 | # WebRTCVideoChat 2 | Example WebRTC video chat app, uses PubNub for signaling, insert your own PubNub keys 3 | -------------------------------------------------------------------------------- /WebRTCVideoChat.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /WebRTCVideoChat.xcodeproj/xcuserdata/Kyle.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | -------------------------------------------------------------------------------- /WebRTCVideoChat.xcodeproj/xcuserdata/Kyle.xcuserdatad/xcschemes/WebRTCVideoChat.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 33 | 39 | 40 | 41 | 42 | 43 | 49 | 50 | 51 | 52 | 53 | 54 | 64 | 66 | 72 | 73 | 74 | 75 | 76 | 77 | 83 | 85 | 91 | 92 | 93 | 94 | 96 | 97 | 100 | 101 | 102 | -------------------------------------------------------------------------------- /WebRTCVideoChat.xcodeproj/xcuserdata/Kyle.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | WebRTCVideoChat.xcscheme 8 | 9 | orderHint 10 | 0 11 | 12 | 13 | SuppressBuildableAutocreation 14 | 15 | 277297471F4D317A009D3044 16 | 17 | primary 18 | 19 | 20 | 2772975B1F4D317A009D3044 21 | 22 | primary 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /WebRTCVideoChat/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.swift 3 | // WebRTCVideoChat 4 | // 5 | // Created by Kyle Redfearn on 8/22/17. 6 | // Copyright © 2017 Kyle Redfearn. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | @UIApplicationMain 12 | class AppDelegate: UIResponder, UIApplicationDelegate { 13 | 14 | var window: UIWindow? 15 | 16 | 17 | func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { 18 | // Override point for customization after application launch. 19 | return true 20 | } 21 | 22 | func applicationWillResignActive(_ application: UIApplication) { 23 | // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. 24 | // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. 25 | } 26 | 27 | func applicationDidEnterBackground(_ application: UIApplication) { 28 | // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 29 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. 30 | } 31 | 32 | func applicationWillEnterForeground(_ application: UIApplication) { 33 | // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. 34 | } 35 | 36 | func applicationDidBecomeActive(_ application: UIApplication) { 37 | // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. 38 | } 39 | 40 | func applicationWillTerminate(_ application: UIApplication) { 41 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. 42 | } 43 | 44 | 45 | } 46 | 47 | -------------------------------------------------------------------------------- /WebRTCVideoChat/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "size" : "29x29", 6 | "scale" : "2x" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "size" : "29x29", 11 | "scale" : "3x" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "size" : "40x40", 16 | "scale" : "2x" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "size" : "40x40", 21 | "scale" : "3x" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "size" : "60x60", 26 | "scale" : "2x" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "size" : "60x60", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "idiom" : "ipad", 35 | "size" : "29x29", 36 | "scale" : "1x" 37 | }, 38 | { 39 | "idiom" : "ipad", 40 | "size" : "29x29", 41 | "scale" : "2x" 42 | }, 43 | { 44 | "idiom" : "ipad", 45 | "size" : "40x40", 46 | "scale" : "1x" 47 | }, 48 | { 49 | "idiom" : "ipad", 50 | "size" : "40x40", 51 | "scale" : "2x" 52 | }, 53 | { 54 | "idiom" : "ipad", 55 | "size" : "76x76", 56 | "scale" : "1x" 57 | }, 58 | { 59 | "idiom" : "ipad", 60 | "size" : "76x76", 61 | "scale" : "2x" 62 | } 63 | ], 64 | "info" : { 65 | "version" : 1, 66 | "author" : "xcode" 67 | } 68 | } -------------------------------------------------------------------------------- /WebRTCVideoChat/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /WebRTCVideoChat/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /WebRTCVideoChat/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | LSRequiresIPhoneOS 22 | 23 | NSCameraUsageDescription 24 | I want to use your camera 25 | NSMicrophoneUsageDescription 26 | I want to use your microphone 27 | UILaunchStoryboardName 28 | LaunchScreen 29 | UIMainStoryboardFile 30 | Main 31 | UIRequiredDeviceCapabilities 32 | 33 | armv7 34 | 35 | UISupportedInterfaceOrientations 36 | 37 | UIInterfaceOrientationPortrait 38 | UIInterfaceOrientationLandscapeLeft 39 | UIInterfaceOrientationLandscapeRight 40 | 41 | UISupportedInterfaceOrientations~ipad 42 | 43 | UIInterfaceOrientationPortrait 44 | UIInterfaceOrientationPortraitUpsideDown 45 | UIInterfaceOrientationLandscapeLeft 46 | UIInterfaceOrientationLandscapeRight 47 | 48 | 49 | 50 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/NSURLSessionConfiguration+PNConfiguration.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief \c NSURLSessionConfiguration extension to provide limited \c NSURLSession configuration abilities for 8 | developers. 9 | 10 | @author Sergey Mamontov 11 | @since 4.4.0 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface NSURLSessionConfiguration (PNConfiguration) 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Configuration 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Retrieve reference on previously configured set of custom HTTP headers. 23 | @note Dictionary won't include headers provided by \b PubNub client. 24 | 25 | @since 4.4.0 26 | 27 | @return Previously configured custom set of HTTP headers which should be sent along with every request to 28 | \b PubNub service. 29 | */ 30 | + (nullable NSDictionary *)pn_HTTPAdditionalHeaders; 31 | 32 | /** 33 | @brief Extend additional headers with custom values. 34 | @discussion Additional set of headers which is not used by \b PubNub service but can be used by intermediate 35 | tunneling software. 36 | @note Next set of fields will be ignored: Accept, Accept-Encoding, User-Agent and Connection. 37 | 38 | @since 4.4.0 39 | 40 | @param HTTPAdditionalHeaders Reference on custom set of HTTP headers which should be sent along with every 41 | request to \b PubNub service. 42 | */ 43 | + (void)pn_setHTTPAdditionalHeaders:(nullable NSDictionary *)HTTPAdditionalHeaders; 44 | 45 | /** 46 | @brief Retrieve previously configured configured network service type. 47 | @note \c NSURLNetworkServiceTypeDefault is set by default and will be returned if nothing changed. 48 | 49 | @since 4.4.0 50 | 51 | @return One of \c NSURLRequestNetworkServiceType enum fields which represent target network service type. 52 | */ 53 | + (NSURLRequestNetworkServiceType)pn_networkServiceType; 54 | 55 | /** 56 | @brief Set target network service type. 57 | 58 | @since 4.4.0 59 | 60 | @param networkServiceType One of \c NSURLRequestNetworkServiceType enum fields which represent target network 61 | service type. 62 | */ 63 | + (void)pn_setNetworkServiceType:(NSURLRequestNetworkServiceType)networkServiceType; 64 | 65 | /** 66 | @brief Retrieve whether previously has been set to use \c WiFi access \b only or \c cellular can be used as 67 | well. 68 | 69 | @since 4.4.0 70 | 71 | @return \c YES in case if cellular data can be used as well to access \b PubNub service. 72 | */ 73 | + (BOOL)pn_allowsCellularAccess; 74 | 75 | /** 76 | @brief Set whether it is allowed to use cellular data to access \b PubNub service or not. 77 | @discussion \b Default: \b YES 78 | 79 | @since 4.4.0 80 | 81 | @param allowsCellularAccess Whether cellular data usage allowed to get access to \b PubNub service or not. 82 | */ 83 | + (void)pn_setAllowsCellularAccess:(BOOL)allowsCellularAccess; 84 | 85 | /** 86 | @brief Extra set of protocols which will handle requests which is sent to \b PubNub service. 87 | 88 | @since 4.4.0 89 | 90 | @return Previusly configured requests handling protocol classes. 91 | */ 92 | + (nullable NSArray *)pn_protocolClasses; 93 | 94 | /** 95 | @brief Configure extra set of protocols which will handle requests which is sent to \b PubNub service. 96 | @warning Protocol classes which is prefixed with: \b NS or \b _NS will be ignored. 97 | 98 | @since 4.4.0 99 | 100 | @param protocolClasses Reference on requests handling protocol classes which should be used with requests to 101 | \b PubNub service. 102 | */ 103 | + (void)pn_setProtocolClasses:(nullable NSArray *)protocolClasses; 104 | 105 | /** 106 | @brief Retrieve reference on previously configured connection proxy information. 107 | 108 | @since 4.4.0 109 | 110 | @return Previously configured connection proxy information which will be used by \c NSURLSession to open and 111 | send requests to \b PubNub service. 112 | */ 113 | + (nullable NSDictionary *)pn_connectionProxyDictionary; 114 | 115 | /** 116 | @brief Configure connection proxy. 117 | @discussion This dictionary will be used by \c NSURLSession to open connection to \b PubNub service and send 118 | requests using it. 119 | 120 | @since 4.4.0 121 | 122 | @param connectionProxyDictionary Dictionary which contain information to setup proxy-based connectino. 123 | */ 124 | + (void)pn_setConnectionProxyDictionary:(nullable NSDictionary *)connectionProxyDictionary; 125 | 126 | #pragma mark - 127 | 128 | 129 | @end 130 | 131 | NS_ASSUME_NONNULL_END 132 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNAES.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import "PNStructures.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which allow to perform AES based encryption/decryption on provided data. 9 | @discussion Encryption works with native Foundation objects which internally will be translated to JSON 10 | object. Decryption process will return Foundation object in response on Base64 encoded string. 11 | 12 | @author Sergey Mamontov 13 | @since 4.0 14 | @copyright © 2009-2017 PubNub, Inc. 15 | */ 16 | @interface PNAES : NSObject 17 | 18 | 19 | ///------------------------------------------------ 20 | /// @name Data encryption 21 | ///------------------------------------------------ 22 | 23 | /** 24 | @brief Encrypt \c data content and encode into Base64 string. 25 | @discussion Input \c data for example can be output of \a NSJSONSerialization or data created from 26 | \a NSString with UTF-8 encoding. 27 | 28 | @param data Reference on \a NSData object which should be encrypted. 29 | @param key Reference on key which should be used to encrypt data basing on it. 30 | 31 | @return Encrypted Base64-encoded string received from Foundation object. \c nil will be returned in case of 32 | failure. 33 | 34 | @since 4.0 35 | */ 36 | + (nullable NSString *)encrypt:(NSData *)data withKey:(NSString *)key; 37 | 38 | /** 39 | @brief Encrypt \c data content and encode into Base64 string. 40 | @discussion Input \c data for example can be output of \a NSJSONSerialization or data created from 41 | \a NSString with UTF-8 encoding. 42 | @discussion Extension to \c -encrypt:withKey: and allow to specify pointer where encryption error can be 43 | passed. 44 | 45 | @param data Reference on \a NSData object which should be encrypted. 46 | @param key Reference on key which should be used to encrypt data basing on it. 47 | @param error Reference on pointer into which encryption error will be stored in case of encryption 48 | failure. Error can be related to JSON string serialization as well as encryption 49 | itself. 50 | 51 | @return Encrypted Base64-encoded string received from Foundation object. \c nil will be returned 52 | in case of failure. 53 | 54 | @since 4.0 55 | */ 56 | + (nullable NSString *)encrypt:(NSData *)data withKey:(NSString *)key 57 | andError:(NSError *__autoreleasing *)error; 58 | 59 | 60 | ///------------------------------------------------ 61 | /// @name Data decryption 62 | ///------------------------------------------------ 63 | 64 | /** 65 | @brief Transform encrypted Base64 encoded string to \a NSData instance. 66 | @discussion Received data for example can be used with \a NSJSONSerialization to convert it's 67 | content to Foundation objects. 68 | 69 | @param object Reference on previously encrypted Base64-encoded string which should be decrypted. 70 | @param key Reference on key which should be used to decrypt data. 71 | 72 | @return Initial \a NSData which has been encrypted earlier. \c nil will be returned in case of 73 | decryption error. 74 | 75 | @since 4.0 76 | */ 77 | + (nullable NSData *)decrypt:(NSString *)object withKey:(NSString *)key; 78 | 79 | /** 80 | @brief Transform encrypted Base64 encoded string to \a NSData instance. 81 | @discussion Received data for example can be used with \a NSJSONSerialization to convert it's 82 | content to Foundation objects. 83 | @discussion Extension to \c -decrypt:withKey: and allow to specify pointer where decryption error can be 84 | passed. 85 | 86 | @param object Reference on previously encrypted Base64-encoded string which should be decrypted. 87 | @param key Reference on key which should be used to decrypt data. 88 | @param error Reference on pointer into which decryption error will be stored in case of decryption 89 | failure. Error can be related to JSON string deserialization as well as decryption 90 | itself. 91 | 92 | @return Initial \a NSData which has been encrypted earlier. \c nil will be returned in case of 93 | decryption error. 94 | 95 | @since 4.0 96 | */ 97 | + (nullable NSData *)decrypt:(NSString *)object withKey:(NSString *)key 98 | andError:(NSError *__autoreleasing *)error; 99 | 100 | #pragma mark - 101 | 102 | 103 | @end 104 | 105 | NS_ASSUME_NONNULL_END 106 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief API call builder pattern support class. 8 | @discussion Class basing on required API protocol collect user-provided arguments and pass them on \c send to 9 | corresponding API end-point. 10 | 11 | @author Sergey Mamontov 12 | @since 4.5.4 13 | @copyright © 2009-2017 PubNub, Inc. 14 | */ 15 | @interface PNAPICallBuilder : NSObject 16 | 17 | 18 | #pragma mark - 19 | 20 | 21 | @end 22 | 23 | NS_ASSUME_NONNULL_END 24 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNAPNSAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNAPICallBuilder.h" 2 | #import "PNStructures.h" 3 | 4 | 5 | #pragma mark Class forward 6 | 7 | @class PNAPNSModificationAPICallBuilder, PNAPNSAuditAPICallBuilder; 8 | 9 | 10 | NS_ASSUME_NONNULL_BEGIN 11 | 12 | /** 13 | @brief APNS API call builder. 14 | @discussion Class describe interface which provide access to various APNS manipulation and audition 15 | endpoints. 16 | 17 | @author Sergey Mamontov 18 | @since 4.5.4 19 | @copyright © 2009-2017 PubNub, Inc. 20 | */ 21 | @interface PNAPNSAPICallBuilder : PNAPICallBuilder 22 | 23 | 24 | ///------------------------------------------------ 25 | /// @name APNS state manipulation 26 | ///------------------------------------------------ 27 | 28 | /** 29 | @brief Stores reference on construction block which return \c builder which is responsible for push 30 | notifications state manipulation. 31 | @discussion On block call return builder which provide interface for push notification enabling on list of 32 | channel(s). 33 | 34 | @since 4.5.4 35 | */ 36 | @property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder *(^enable)(void); 37 | 38 | /** 39 | @brief Stores reference on construction block which return \c builder which is responsible for push 40 | notifications state manipulation. 41 | @discussion On block call return builder which provide interface for push notification disabling on list of 42 | channel(s). 43 | 44 | @since 4.5.4 45 | */ 46 | @property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder *(^disable)(void); 47 | 48 | 49 | ///------------------------------------------------ 50 | /// @name APNS state audition 51 | ///------------------------------------------------ 52 | 53 | /** 54 | @brief Stores reference on construction block which return \c builder which is responsible for push 55 | notifications state audition. 56 | @discussion On block call return builder which provide interface for push notification state audit (retrieve 57 | list of channels for which push notifications has been enabled). 58 | 59 | @since 4.5.4 60 | */ 61 | @property (nonatomic, readonly, strong) PNAPNSAuditAPICallBuilder *(^audit)(void); 62 | 63 | #pragma mark - 64 | 65 | 66 | @end 67 | 68 | NS_ASSUME_NONNULL_END 69 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNAPNSAuditAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNAPNSAPICallBuilder.h" 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief APNS state audit API call builder. 8 | @discussion Class describe interface which allow to audit current push notification state (retrieve push 9 | notification enabled channels list). 10 | 11 | @author Sergey Mamontov 12 | @since 4.5.4 13 | @copyright © 2009-2017 PubNub, Inc. 14 | */ 15 | @interface PNAPNSAuditAPICallBuilder : PNAPNSAPICallBuilder 16 | 17 | 18 | ///------------------------------------------------ 19 | /// @name Configuration 20 | ///------------------------------------------------ 21 | 22 | /** 23 | @brief Specify device push token against which push notification state manipulation should be done. 24 | @discussion On block call return block consume \a NSData which represent received from APNS device push 25 | token. 26 | 27 | @since 4.5.4 28 | */ 29 | @property (nonatomic, readonly, strong) PNAPNSAuditAPICallBuilder *(^token)(NSData *token); 30 | 31 | 32 | ///------------------------------------------------ 33 | /// @name Execution 34 | ///------------------------------------------------ 35 | 36 | /** 37 | @brief Perform composed API call. 38 | @discussion Execute API call and report processing results through passed comnpletion block. 39 | @discussion On block call return block which consume (\b required) push notifications status processing 40 | completion block which pass two arguments: \c result - in case of successful request processing 41 | \c data field will contain results of push notifications audit operation; \c status - in case if 42 | error occurred during request processing. 43 | 44 | @since 4.5.4 45 | */ 46 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNPushNotificationsStateAuditCompletionBlock block); 47 | 48 | #pragma mark - 49 | 50 | 51 | @end 52 | 53 | NS_ASSUME_NONNULL_END 54 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNAPNSEnabledChannelsResult.h: -------------------------------------------------------------------------------- 1 | #import "PNResult.h" 2 | #import "PNServiceData.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which allow to get access to APNS enabled channels processed result. 9 | 10 | @author Sergey Mamontov 11 | @since 4.0 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNAPNSEnabledChannelsData : PNServiceData 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Information 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Channels with active push notifications. 23 | 24 | @since 4.0 25 | */ 26 | @property (nonatomic, readonly, strong) NSArray *channels; 27 | 28 | #pragma mark - 29 | 30 | 31 | @end 32 | 33 | 34 | /** 35 | @brief Class which is used to provide access to request processing results. 36 | 37 | @author Sergey Mamontov 38 | @since 4.0 39 | @copyright © 2009-2017 PubNub, Inc. 40 | */ 41 | @interface PNAPNSEnabledChannelsResult : PNResult 42 | 43 | 44 | ///------------------------------------------------ 45 | /// @name Information 46 | ///------------------------------------------------ 47 | 48 | /** 49 | @brief Stores reference on APNS enabled channels audit request processing information. 50 | 51 | @since 4.0 52 | */ 53 | @property (nonatomic, readonly, strong) PNAPNSEnabledChannelsData *data; 54 | 55 | #pragma mark - 56 | 57 | 58 | @end 59 | 60 | NS_ASSUME_NONNULL_END 61 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNAPNSModificationAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNAPNSAPICallBuilder.h" 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief APNS state modification API call builder. 8 | @discussion Class describe interface which allow to modify push notification enabled channels list. 9 | 10 | @author Sergey Mamontov 11 | @since 4.5.4 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNAPNSModificationAPICallBuilder : PNAPNSAPICallBuilder 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Configuration 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Specify device push token against which push notification state manipulation should be done. 23 | @discussion On block call return block which consume \a NSData which represent received from APNS device push 24 | token. 25 | 26 | @since 4.5.4 27 | */ 28 | @property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder *(^token)(NSData *token); 29 | 30 | /** 31 | @brief Specify list of channels for APNS state manupulation. 32 | @discussion On block call return block which consume list of channel names for which APNS state manipulation 33 | should be perfored. 34 | @warning \b PubNub client will remove push notification state for all channels which is registered with 35 | passed \c token if \c nil or \c empty list will be passed during \c disable. 36 | 37 | @since 4.5.4 38 | */ 39 | @property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder *(^channels)(NSArray * _Nullable channels); 40 | 41 | 42 | ///------------------------------------------------ 43 | /// @name Execution 44 | ///------------------------------------------------ 45 | 46 | /** 47 | @brief Perform composed API call. 48 | @discussion Execute API call and report processing results through passed comnpletion block. 49 | @discussion On block call return block which consume (\b not required) push notifications state modification 50 | processing completion block which pass only one argument - request processing status to report 51 | about how data pushing was successful or not. 52 | 53 | @since 4.5.4 54 | */ 55 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNPushNotificationsStateModificationCompletionBlock _Nullable block); 56 | 57 | #pragma mark - 58 | 59 | 60 | @end 61 | 62 | NS_ASSUME_NONNULL_END 63 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNAcknowledgmentStatus.h: -------------------------------------------------------------------------------- 1 | #import "PNErrorStatus.h" 2 | 3 | 4 | /** 5 | @brief Class which is used to represent request processing status sent by server and mean what 6 | changes pushed with that request has been accepted. 7 | 8 | @author Sergey Mamontov 9 | @since 4.0 10 | @copyright © 2009-2017 PubNub, Inc. 11 | */ 12 | @interface PNAcknowledgmentStatus : PNErrorStatus 13 | 14 | 15 | #pragma mark - 16 | 17 | 18 | @end 19 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNChannelClientStateResult.h: -------------------------------------------------------------------------------- 1 | #import "PNResult.h" 2 | #import "PNServiceData.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which allow to get access to client state for channel processed result. 9 | 10 | @author Sergey Mamontov 11 | @since 4.0 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNChannelClientStateData : PNServiceData 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Information 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief User-provided client state information. 23 | 24 | @since 4.0 25 | */ 26 | @property (nonatomic, readonly, strong) NSDictionary *state; 27 | 28 | #pragma mark - 29 | 30 | 31 | @end 32 | 33 | 34 | /** 35 | @brief Class which is used to provide access to request processing results. 36 | 37 | @author Sergey Mamontov 38 | @since 4.0 39 | @copyright © 2009-2017 PubNub, Inc. 40 | */ 41 | @interface PNChannelClientStateResult : PNResult 42 | 43 | 44 | ///------------------------------------------------ 45 | /// @name Information 46 | ///------------------------------------------------ 47 | 48 | /** 49 | @brief Stores reference on client state for channel request processing information. 50 | 51 | @since 4.0 52 | */ 53 | @property (nonatomic, readonly, strong) PNChannelClientStateData *data; 54 | 55 | #pragma mark - 56 | 57 | 58 | @end 59 | 60 | NS_ASSUME_NONNULL_END 61 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNChannelGroupChannelsResult.h: -------------------------------------------------------------------------------- 1 | #import "PNResult.h" 2 | #import "PNServiceData.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which allow to get access to channel group's channels list audit processed result. 9 | 10 | @author Sergey Mamontov 11 | @since 4.0 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNChannelGroupChannelsData : PNServiceData 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Information 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Registered channels within channel group. 23 | @note In case if status object represent error, this property may contain list of channels to which client 24 | doesn't have access. 25 | 26 | @since 4.0 27 | */ 28 | @property (nonatomic, readonly, strong) NSArray *channels; 29 | 30 | #pragma mark - 31 | 32 | 33 | @end 34 | 35 | 36 | /** 37 | @brief Class which is used to provide access to request processing results. 38 | 39 | @author Sergey Mamontov 40 | @since 4.0 41 | @copyright © 2009-2017 PubNub, Inc. 42 | */ 43 | @interface PNChannelGroupChannelsResult : PNResult 44 | 45 | 46 | ///------------------------------------------------ 47 | /// @name Information 48 | ///------------------------------------------------ 49 | 50 | /** 51 | @brief Stores reference on channel group's channels list audit request processing information. 52 | 53 | @since 4.0 54 | */ 55 | @property (nonatomic, nonnull, readonly, strong) PNChannelGroupChannelsData *data; 56 | 57 | #pragma mark - 58 | 59 | 60 | @end 61 | 62 | NS_ASSUME_NONNULL_END 63 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNChannelGroupClientStateResult.h: -------------------------------------------------------------------------------- 1 | #import "PNServiceData.h" 2 | #import "PNResult.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which allow to get access to client state for channel group processed result. 9 | 10 | @author Sergey Mamontov 11 | @since 4.0 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNChannelGroupClientStateData : PNServiceData 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Information 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Multi channel client state information. 23 | 24 | @since 4.0 25 | */ 26 | @property (nonatomic, readonly, strong) NSDictionary *channels; 27 | 28 | #pragma mark - 29 | 30 | 31 | @end 32 | 33 | 34 | /** 35 | @brief Class which is used to provide access to request processing results. 36 | 37 | @author Sergey Mamontov 38 | @since 4.0 39 | @copyright © 2009-2017 PubNub, Inc. 40 | */ 41 | @interface PNChannelGroupClientStateResult : PNResult 42 | 43 | 44 | ///------------------------------------------------ 45 | /// @name Information 46 | ///------------------------------------------------ 47 | 48 | /** 49 | @brief Stores reference on client state for channel group request processing information. 50 | 51 | @since 4.0 52 | */ 53 | @property (nonatomic, readonly, strong) PNChannelGroupClientStateData *data; 54 | 55 | #pragma mark - 56 | 57 | 58 | @end 59 | 60 | NS_ASSUME_NONNULL_END 61 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNChannelGroupsResult.h: -------------------------------------------------------------------------------- 1 | #import "PNResult.h" 2 | #import "PNServiceData.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which allow to get access to channel groups list audit processed result. 9 | 10 | @author Sergey Mamontov 11 | @since 4.0 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNChannelGroupsData : PNServiceData 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Information 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Registered and active channel groups. 23 | 24 | @since 4.0 25 | */ 26 | @property (nonatomic, readonly, strong) NSArray *groups; 27 | 28 | #pragma mark - 29 | 30 | 31 | @end 32 | 33 | 34 | /** 35 | @brief Class which is used to provide access to request processing results. 36 | 37 | @author Sergey Mamontov 38 | @since 4.0 39 | @copyright © 2009-2017 PubNub, Inc. 40 | */ 41 | @interface PNChannelGroupsResult : PNResult 42 | 43 | 44 | ///------------------------------------------------ 45 | /// @name Information 46 | ///------------------------------------------------ 47 | 48 | /** 49 | @brief Stores reference on channel groups list audit request processing information. 50 | 51 | @since 4.0 52 | */ 53 | @property (nonatomic, nonnull, readonly, strong) PNChannelGroupsData *data; 54 | 55 | #pragma mark - 56 | 57 | 58 | @end 59 | 60 | NS_ASSUME_NONNULL_END 61 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNClientInformation.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief \b PubNub client information wrapper. 8 | @discussion This instance provide base information about \b PubNub client. 9 | 10 | @author Sergey Mamontov 11 | @since 4.0.5 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNClientInformation : NSObject 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Information 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Stores current client version number. 23 | 24 | @since 4.0.5 25 | */ 26 | @property (nonatomic, readonly) NSString *version; 27 | 28 | /** 29 | @brief Stores git SHA for commit on which current version is based. 30 | 31 | @since 4.0.5 32 | */ 33 | @property (nonatomic, readonly) NSString *commit; 34 | 35 | #pragma mark - 36 | 37 | 38 | @end 39 | 40 | NS_ASSUME_NONNULL_END 41 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNClientStateUpdateStatus.h: -------------------------------------------------------------------------------- 1 | #import "PNErrorStatus.h" 2 | #import "PNChannelClientStateResult.h" 3 | 4 | 5 | /** 6 | @brief Class which allow to get access to used client state during state update process. 7 | 8 | @author Sergey Mamontov 9 | @since 4.0 10 | @copyright © 2009-2017 PubNub, Inc. 11 | */ 12 | @interface PNClientStateUpdateData : PNChannelClientStateData 13 | 14 | 15 | #pragma mark - 16 | 17 | 18 | @end 19 | 20 | 21 | /** 22 | @brief Class which is used to provide access to request processing results. 23 | 24 | @author Sergey Mamontov 25 | @since 4.0 26 | @copyright © 2009-2017 PubNub, Inc. 27 | */ 28 | @interface PNClientStateUpdateStatus : PNErrorStatus 29 | 30 | 31 | ///------------------------------------------------ 32 | /// @name Information 33 | ///------------------------------------------------ 34 | 35 | /** 36 | @brief Stores reference on client state for channel request processing information. 37 | 38 | @since 4.0 39 | */ 40 | @property (nonatomic, nonnull, readonly, strong) PNClientStateUpdateData *data; 41 | 42 | #pragma mark - 43 | 44 | 45 | @end 46 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNDefines.h: -------------------------------------------------------------------------------- 1 | /** 2 | @author Sergey Mamontov 3 | @since 4.5.15 4 | @copyright © 2009-2017 PubNub, Inc. 5 | */ 6 | #ifndef PNDefines_h 7 | #define PNDefines_h 8 | 9 | // Whether iOS/tvOS 10.0, watchOS 3.0 and macOS 10.12 SDK API can be used (project's base SDK set to allow). 10 | #define PN_OS_VERSION_10_SDK_API_AVAILABLE 0 11 | #if (TARGET_OS_IOS && __IPHONE_OS_VERSION_MAX_ALLOWED >= 100000) || \ 12 | (TARGET_OS_WATCH && __WATCH_OS_VERSION_MAX_ALLOWED >= 30000) || \ 13 | (TARGET_OS_TV && __TV_OS_VERSION_MAX_ALLOWED >= 100000) || \ 14 | (TARGET_OS_OSX && __MAC_OS_X_VERSION_MAX_ALLOWED >= 101200) 15 | #undef PN_OS_VERSION_10_SDK_API_AVAILABLE 16 | #define PN_OS_VERSION_10_SDK_API_AVAILABLE 1 17 | #endif 18 | 19 | // Whether iOS/tvOS 10.0, watchOS 3.0 and macOS 10.12 SDK API can be used safely basing on minimum allowed OS 20 | // version which is set in project. 21 | #define PN_OS_VERSION_10_SDK_API_IS_SAFE 0 22 | #if (TARGET_OS_IOS && __IPHONE_OS_VERSION_MIN_REQUIRED >= 100000) || \ 23 | (TARGET_OS_WATCH && __WATCH_OS_VERSION_MIN_REQUIRED >= 30000) || \ 24 | (TARGET_OS_TV && __TV_OS_VERSION_MIN_REQUIRED >= 100000) || \ 25 | (TARGET_OS_OSX && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101200) 26 | #undef PN_OS_VERSION_10_SDK_API_IS_SAFE 27 | #define PN_OS_VERSION_10_SDK_API_IS_SAFE 1 28 | #endif 29 | 30 | #if PN_OS_VERSION_10_SDK_API_AVAILABLE 31 | #define PN_URLSESSION_TRANSACTION_METRICS_AVAILABLE 1 32 | #define PN_OS_UNFAIR_LOCK_AVAILABLE 1 33 | #else 34 | #define PN_URLSESSION_TRANSACTION_METRICS_AVAILABLE 0 35 | #define PN_OS_UNFAIR_LOCK_AVAILABLE 0 36 | #endif 37 | 38 | #endif // PNDefines_h 39 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNErrorCodes.h: -------------------------------------------------------------------------------- 1 | /** 2 | @brief Reference header for list of error domains and error codes constants. 3 | 4 | @author Sergey Mamontov 5 | @since 4.0 6 | @copyright © 2009-2017 PubNub, Inc. 7 | */ 8 | #import 9 | 10 | 11 | #ifndef PNErrorCodes_h 12 | #define PNErrorCodes_h 13 | 14 | ///------------------------------------------------ 15 | /// @name Error domains 16 | ///------------------------------------------------ 17 | 18 | 19 | static NSString * const kPNAESErrorDomain = @"PNAESErrorDomain"; 20 | static NSString * const kPNAPIErrorDomain = @"PNAPIErrorDomain"; 21 | 22 | 23 | ///------------------------------------------------ 24 | /// @name General error codes 25 | ///------------------------------------------------ 26 | 27 | static NSInteger const kPNUnknownErrorCode = -1; 28 | 29 | /** 30 | @brief Incomplete or unacceptable set of parameters. 31 | 32 | @since 4.0 33 | */ 34 | static NSInteger const kPNAPIUnacceptableParameters = 100; 35 | 36 | ///------------------------------------------------ 37 | /// @name Publish 38 | ///------------------------------------------------ 39 | 40 | static NSInteger const kPNEmptyMessageError = 3000; 41 | 42 | 43 | 44 | ///------------------------------------------------ 45 | /// @name AES Error domain codes 46 | ///------------------------------------------------ 47 | 48 | static NSInteger const kPNAESEmptyObjectError = 4000; 49 | static NSInteger const kPNAESConfigurationError = 4001; 50 | static NSInteger const kPNAESInsufficientMemoryError = 4002; 51 | static NSInteger const kPNAESDecryptionError = 4003; 52 | 53 | #endif // PNErrorCodes_h 54 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNErrorStatus.h: -------------------------------------------------------------------------------- 1 | #import "PNStatus.h" 2 | #import "PNServiceData.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which is used to provide access to additional data available to describe error status 9 | object. 10 | In most cases this object may represent information related to \b PAM error scope. 11 | 12 | @author Sergey Mamontov 13 | @since 4.0 14 | @copyright © 2009-2017 PubNub, Inc. 15 | */ 16 | @interface PNErrorData : PNServiceData 17 | 18 | 19 | ///------------------------------------------------ 20 | /// @name Information 21 | ///------------------------------------------------ 22 | 23 | /** 24 | @brief List of channels for which error has been triggered. 25 | 26 | @since 4.0 27 | */ 28 | @property (nonatomic, readonly, strong) NSArray *channels; 29 | 30 | /** 31 | @brief List of channel groups for which error has been triggered. 32 | 33 | @since 4.0 34 | */ 35 | @property (nonatomic, readonly, strong) NSArray *channelGroups; 36 | 37 | /** 38 | @brief Service-provided information about error. 39 | 40 | @since 4.0 41 | */ 42 | @property (nonatomic, readonly, strong) NSString *information; 43 | 44 | /** 45 | @brief Service-provided additional information about error. 46 | 47 | @since 4.0 48 | */ 49 | @property (nonatomic, nullable, readonly, strong) id data; 50 | 51 | #pragma mark - 52 | 53 | 54 | @end 55 | 56 | 57 | 58 | /** 59 | @brief Class which is used to provide information about why request processing did fail. Status can be 60 | returned by server or on local error event. 61 | 62 | @author Sergey Mamontov 63 | @since 4.0 64 | @copyright © 2009-2017 PubNub, Inc. 65 | */ 66 | @interface PNErrorStatus : PNStatus 67 | 68 | 69 | ///------------------------------------------------ 70 | /// @name Information 71 | ///------------------------------------------------ 72 | 73 | /** 74 | @brief Stores reference on additional information related to error status object. 75 | @discussion If error status arrived from \b PubNub network in most cases it will be because of \b PAM errors. 76 | 77 | @since 4.0 78 | */ 79 | @property (nonatomic, readonly, strong) PNErrorData *errorData; 80 | 81 | /** 82 | @brief Reference on data object which hold additional information about error and why it happened. 83 | 84 | @since 4.0.2 85 | */ 86 | @property (nonatomic, nullable, readonly, strong) id associatedObject; 87 | 88 | #pragma mark - 89 | 90 | 91 | @end 92 | 93 | NS_ASSUME_NONNULL_END 94 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNHistoryResult.h: -------------------------------------------------------------------------------- 1 | #import "PNResult.h" 2 | #import "PNServiceData.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which allow to get access to channel history processed result. 9 | 10 | @author Sergey Mamontov 11 | @since 4.0 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNHistoryData : PNServiceData 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Information 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Channel history messages. 23 | @discussion \b Important: for \c PNHistoryForChannelsOperation operation this property always will be 24 | \c empty array. 25 | 26 | @since 4.0 27 | */ 28 | @property (nonatomic, readonly, strong) NSArray *messages; 29 | 30 | /** 31 | @brief Channels history. 32 | @discussion Each key represent name of channel for which messages has been received and valus is list of 33 | messages from channel's storage. 34 | @discussion \b Important: for \c PNHistoryOperation operation this property always will be \c empty 35 | dictionary. 36 | 37 | @since 4.5.6 38 | */ 39 | @property (nonatomic, readonly, strong) NSDictionary *channels; 40 | 41 | /** 42 | @brief History time frame start time. 43 | @discussion \b Important: for \c PNHistoryForChannelsOperation operation this property always will be \b 0. 44 | 45 | @since 4.0 46 | */ 47 | @property (nonatomic, readonly, strong) NSNumber *start; 48 | 49 | /** 50 | @brief History time frame end time. 51 | @discussion \b Important: for \c PNHistoryForChannelsOperation operation this property always will be \b 0. 52 | 53 | @since 4.0 54 | */ 55 | @property (nonatomic, readonly, strong) NSNumber *end; 56 | 57 | #pragma mark - 58 | 59 | 60 | @end 61 | 62 | 63 | /** 64 | @brief Class which is used to provide access to request processing results. 65 | 66 | @author Sergey Mamontov 67 | @since 4.0 68 | @copyright © 2009-2017 PubNub, Inc. 69 | */ 70 | @interface PNHistoryResult : PNResult 71 | 72 | 73 | ///------------------------------------------------ 74 | /// @name Information 75 | ///------------------------------------------------ 76 | 77 | /** 78 | @brief Stores reference on channel history request processing information. 79 | 80 | @since 4.0 81 | */ 82 | @property (nonatomic, readonly, strong) PNHistoryData *data; 83 | 84 | #pragma mark - 85 | 86 | 87 | @end 88 | 89 | NS_ASSUME_NONNULL_END 90 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNObjectEventListener.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import "PubNub+Subscribe.h" 3 | 4 | 5 | #pragma mark Class forward 6 | 7 | @class PNPresenceEventResult, PNSubscribeStatus, PNMessageResult, PNErrorStatus; 8 | 9 | 10 | NS_ASSUME_NONNULL_BEGIN 11 | 12 | /** 13 | @brief Interface description for classes which would like to be registered for events from data 14 | object live feed. 15 | 16 | @author Sergey Mamontov 17 | @since 4.0 18 | @copyright © 2009-2017 PubNub, Inc. 19 | */ 20 | @protocol PNObjectEventListener 21 | 22 | 23 | @optional 24 | 25 | ///------------------------------------------------ 26 | /// @name Message and Events handler callbacks 27 | ///------------------------------------------------ 28 | 29 | /** 30 | @brief Notify listener about new message which arrived from one of remote data object's live feed 31 | on which client subscribed at this moment. 32 | 33 | @param client Reference on \b PubNub client which triggered this callback method call. 34 | @param message Reference on \b PNResult instance which store message information in \c data 35 | property. 36 | 37 | @since 4.0 38 | */ 39 | - (void)client:(PubNub *)client didReceiveMessage:(PNMessageResult *)message; 40 | 41 | /** 42 | @brief Notify listener about new presence events which arrived from one of remote data object's 43 | presence live feed on which client subscribed at this moment. 44 | 45 | @param client Reference on \b PubNub client which triggered this callback method call. 46 | @param event Reference on \b PNResult instance which store presence event information in 47 | \c data property. 48 | 49 | @since 4.0 50 | */ 51 | - (void)client:(PubNub *)client didReceivePresenceEvent:(PNPresenceEventResult *)event; 52 | 53 | 54 | ///------------------------------------------------ 55 | /// @name Status change handler. 56 | ///------------------------------------------------ 57 | 58 | /** 59 | @brief Notify listener about subscription state changes. 60 | @discussion This callback can fire when client tried to subscribe on channels for which it doesn't 61 | have access rights or when network went down and client unexpectedly disconnected. 62 | 63 | @param client Reference on \b PubNub client which triggered this callback method call. 64 | @param status Reference on \b PNStatus instance which store subscriber state information. 65 | 66 | @since 4.0 67 | */ 68 | - (void)client:(PubNub *)client didReceiveStatus:(PNStatus *)status; 69 | 70 | #pragma mark - 71 | 72 | @end 73 | 74 | NS_ASSUME_NONNULL_END 75 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNPresenceAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNAPICallBuilder.h" 2 | #import "PNStructures.h" 3 | 4 | 5 | #pragma mark Class forward 6 | 7 | @class PNPresenceWhereNowAPICallBuilder, PNPresenceHereNowAPICallBuilder; 8 | 9 | 10 | NS_ASSUME_NONNULL_BEGIN 11 | 12 | /** 13 | @brief Presence API call builder. 14 | @discussion Class describe interface which provide access to various presence endpoints. 15 | 16 | @author Sergey Mamontov 17 | @since 4.5.4 18 | @copyright © 2009-2017 PubNub, Inc. 19 | */ 20 | @interface PNPresenceAPICallBuilder : PNAPICallBuilder 21 | 22 | 23 | ///------------------------------------------------ 24 | /// @name Here Now 25 | ///------------------------------------------------ 26 | 27 | /** 28 | @brief Stores reference on construction block which return \c builder which is responsible for access to 29 | 'here now' API. 30 | @discussion On block call return builder which provide interface to access channel / group 'here now' 31 | presence information. 32 | 33 | @since 4.5.4 34 | */ 35 | @property (nonatomic, readonly, strong) PNPresenceHereNowAPICallBuilder *(^hereNow)(void); 36 | 37 | 38 | ///------------------------------------------------ 39 | /// @name Where Now 40 | ///------------------------------------------------ 41 | 42 | /** 43 | @brief Stores reference on construction block which return \c builder which is responsible for access to 44 | 'where now' API. 45 | @discussion On block call return builder which provide interface to access user's presence information (on 46 | which channels \c user subscribed). 47 | 48 | @since 4.5.4 49 | */ 50 | @property (nonatomic, readonly, strong) PNPresenceWhereNowAPICallBuilder *(^whereNow)(void); 51 | 52 | #pragma mark - 53 | 54 | 55 | @end 56 | 57 | NS_ASSUME_NONNULL_END 58 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNPresenceChannelGroupHereNowAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNPresenceHereNowAPICallBuilder.h" 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief Channel \b group 'here now' API call builder. 8 | @discussion Class describe interface which provide access to channel \b group 'here now' API. 9 | 10 | @author Sergey Mamontov 11 | @since 4.5.4 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNPresenceChannelGroupHereNowAPICallBuilder : PNPresenceHereNowAPICallBuilder 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Configuration 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Specify exact type of data which should be received. 23 | @discussion On block call return block which consume one of \b PNHereNowVerbosityLevel fields to instruct 24 | what exactly data it expected in response. 25 | 26 | @since 4.5.4 27 | */ 28 | @property (nonatomic, readonly, strong) PNPresenceChannelGroupHereNowAPICallBuilder *(^verbosity)(PNHereNowVerbosityLevel verbosity); 29 | 30 | 31 | ///------------------------------------------------ 32 | /// @name Execution 33 | ///------------------------------------------------ 34 | 35 | /** 36 | @brief Perform composed API call. 37 | @discussion Execute API call and report processing results through passed comnpletion block. 38 | @discussion On block call return block which consume (\b required) here now processing completion block which 39 | pass two arguments: \c result - in case of successful request processing \c data field will 40 | contain results of here now operation; \c status - in case if error occurred during request 41 | processing. 42 | 43 | @since 4.5.4 44 | */ 45 | #pragma clang diagnostic push 46 | #pragma clang diagnostic ignored "-Wincompatible-pointer-types" 47 | #pragma clang diagnostic ignored "-Wincompatible-property-type" 48 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNChannelGroupHereNowCompletionBlock block); 49 | #pragma clang diagnostic pop 50 | 51 | #pragma mark - 52 | 53 | 54 | @end 55 | 56 | NS_ASSUME_NONNULL_END 57 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNPresenceChannelGroupHereNowResult.h: -------------------------------------------------------------------------------- 1 | #import "PNPresenceGlobalHereNowResult.h" 2 | 3 | 4 | /** 5 | @brief Class which allow to get access to channel groups presence processed result. 6 | 7 | @author Sergey Mamontov 8 | @since 4.0 9 | @copyright © 2009-2017 PubNub, Inc. 10 | */ 11 | @interface PNPresenceChannelGroupHereNowData : PNPresenceGlobalHereNowData 12 | 13 | 14 | #pragma mark - 15 | 16 | 17 | @end 18 | 19 | 20 | /** 21 | @brief Class which is used to provide access to request processing results. 22 | 23 | @author Sergey Mamontov 24 | @since 4.0 25 | @copyright © 2009-2017 PubNub, Inc. 26 | */ 27 | @interface PNPresenceChannelGroupHereNowResult : PNResult 28 | 29 | 30 | ///------------------------------------------------ 31 | /// @name Information 32 | ///------------------------------------------------ 33 | 34 | /** 35 | @brief Stores reference on channel group presence request processing information. 36 | 37 | @since 4.0 38 | */ 39 | @property (nonatomic, nonnull, readonly, strong) PNPresenceChannelGroupHereNowData *data; 40 | 41 | 42 | #pragma mark - 43 | 44 | 45 | @end 46 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNPresenceChannelHereNowAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNPresenceHereNowAPICallBuilder.h" 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief \b Channel 'here now' API call builder. 8 | @discussion Class describe interface which provide access to \b channel 'here now' API. 9 | 10 | @author Sergey Mamontov 11 | @since 4.5.4 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNPresenceChannelHereNowAPICallBuilder : PNPresenceHereNowAPICallBuilder 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Configuration 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Specify exact type of data which should be received. 23 | @discussion Returned block consume one of \b PNHereNowVerbosityLevel fields to instruct what exactly data it 24 | expected in response. 25 | 26 | @since 4.5.4 27 | */ 28 | @property (nonatomic, readonly, strong) PNPresenceChannelHereNowAPICallBuilder *(^verbosity)(PNHereNowVerbosityLevel verbosity); 29 | 30 | 31 | ///------------------------------------------------ 32 | /// @name Execution 33 | ///------------------------------------------------ 34 | 35 | /** 36 | @brief Perform composed API call. 37 | @discussion Execute API call and report processing results through passed comnpletion block. 38 | @discussion On block call return block which consume (\b required) here now processing completion block which 39 | pass two arguments: \c result - in case of successful request processing \c data field will 40 | contain results of here now operation; \c status - in case if error occurred during request 41 | processing. 42 | 43 | @since 4.5.4 44 | */ 45 | #pragma clang diagnostic push 46 | #pragma clang diagnostic ignored "-Wincompatible-pointer-types" 47 | #pragma clang diagnostic ignored "-Wincompatible-property-type" 48 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNHereNowCompletionBlock block); 49 | #pragma clang diagnostic pop 50 | 51 | #pragma mark - 52 | 53 | 54 | @end 55 | 56 | NS_ASSUME_NONNULL_END 57 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNPresenceChannelHereNowResult.h: -------------------------------------------------------------------------------- 1 | #import "PNResult.h" 2 | #import "PNServiceData.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which allow to get access to channel presence processed result. 9 | 10 | @author Sergey Mamontov 11 | @since 4.0 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNPresenceChannelHereNowData : PNServiceData 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Information 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Active channel subscribers unique identifiers. 23 | @note This object can be empty in case if only occupancy has been requested. 24 | @note This object can contain list of uuids or dictionary with uuids and client state information 25 | bound to them. 26 | 27 | @since 4.0 28 | */ 29 | @property (nonatomic, nullable, readonly, strong) id uuids; 30 | 31 | /** 32 | @brief Active subscribers count. 33 | 34 | @since 4.0 35 | */ 36 | @property (nonatomic, readonly, strong) NSNumber *occupancy; 37 | 38 | #pragma mark - 39 | 40 | 41 | @end 42 | 43 | 44 | /** 45 | @brief Class which is used to provide access to request processing results. 46 | 47 | @author Sergey Mamontov 48 | @since 4.0 49 | @copyright © 2009-2017 PubNub, Inc. 50 | */ 51 | @interface PNPresenceChannelHereNowResult : PNResult 52 | 53 | 54 | ///------------------------------------------------ 55 | /// @name Information 56 | ///------------------------------------------------ 57 | 58 | /** 59 | @brief Stores reference on channel presence request processing information. 60 | 61 | @since 4.0 62 | */ 63 | @property (nonatomic, readonly, strong) PNPresenceChannelHereNowData *data; 64 | 65 | #pragma mark - 66 | 67 | 68 | @end 69 | 70 | NS_ASSUME_NONNULL_END 71 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNPresenceGlobalHereNowResult.h: -------------------------------------------------------------------------------- 1 | #import "PNResult.h" 2 | #import "PNServiceData.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which allow to get access to global presence processed result. 9 | 10 | @author Sergey Mamontov 11 | @since 4.0 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNPresenceGlobalHereNowData : PNServiceData 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Information 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Active channels list. 23 | @discussion Each dictionary key represent channel name and it's value is presence information for it. 24 | 25 | @since 4.0 26 | */ 27 | @property (nonatomic, readonly, strong) NSDictionary *channels; 28 | 29 | /** 30 | @brief Total number of active channels. 31 | 32 | @since 4.0 33 | */ 34 | @property (nonatomic, readonly, strong) NSNumber *totalChannels; 35 | 36 | /** 37 | @brief Total number of subscribers. 38 | 39 | @since 4.0 40 | */ 41 | @property (nonatomic, readonly, strong) NSNumber *totalOccupancy; 42 | 43 | #pragma mark - 44 | 45 | 46 | @end 47 | 48 | 49 | /** 50 | @brief Class which is used to provide access to request processing results. 51 | 52 | @author Sergey Mamontov 53 | @since 4.0 54 | @copyright © 2009-2017 PubNub, Inc. 55 | */ 56 | @interface PNPresenceGlobalHereNowResult : PNResult 57 | 58 | 59 | ///------------------------------------------------ 60 | /// @name Information 61 | ///------------------------------------------------ 62 | 63 | /** 64 | @brief Stores reference on global presence request processing information. 65 | 66 | @since 4.0 67 | */ 68 | @property (nonatomic, readonly, strong) PNPresenceGlobalHereNowData *data; 69 | 70 | #pragma mark - 71 | 72 | 73 | @end 74 | 75 | NS_ASSUME_NONNULL_END 76 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNPresenceHereNowAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNPresenceAPICallBuilder.h" 2 | 3 | 4 | #pragma mark Class forward 5 | 6 | @class PNPresenceChannelGroupHereNowAPICallBuilder, PNPresenceChannelHereNowAPICallBuilder; 7 | 8 | 9 | NS_ASSUME_NONNULL_BEGIN 10 | 11 | /** 12 | @brief Presence 'here now' API call builder. 13 | @discussion Class describe interface which provide access to various 'here now' presence endpoints. 14 | 15 | @author Sergey Mamontov 16 | @since 4.5.4 17 | @copyright © 2009-2017 PubNub, Inc. 18 | */ 19 | @interface PNPresenceHereNowAPICallBuilder : PNPresenceAPICallBuilder 20 | 21 | 22 | ///------------------------------------------------ 23 | /// @name Channel 24 | ///------------------------------------------------ 25 | 26 | /** 27 | @brief Stores reference on builder which is responsible for access to \c channel 'here now' API. 28 | @discussion Returned block consume name of \c channel for which 'here now' presence information should be 29 | requested. 30 | 31 | @since 4.5.4 32 | */ 33 | @property (nonatomic, readonly, strong) PNPresenceChannelHereNowAPICallBuilder *(^channel)(NSString *channel); 34 | 35 | 36 | ///------------------------------------------------ 37 | /// @name Channel Group 38 | ///------------------------------------------------ 39 | 40 | /** 41 | @brief Stores reference on builder which is responsible for access to channel \c group 'here now' API. 42 | @discussion On block call return block which consume name of channel \c group for which 'here now' presence 43 | information should be requested. 44 | 45 | @since 4.5.4 46 | */ 47 | @property (nonatomic, readonly, strong) PNPresenceChannelGroupHereNowAPICallBuilder *(^channelGroup)(NSString *channelGroup); 48 | 49 | 50 | ///------------------------------------------------ 51 | /// @name Global 52 | ///------------------------------------------------ 53 | 54 | /** 55 | @brief Specify exact type of data which should be received. 56 | @discussion On block call return block which consume one of \b PNHereNowVerbosityLevel fields to instruct 57 | what exactly data it expected in response. 58 | 59 | @since 4.5.4 60 | */ 61 | @property (nonatomic, readonly, strong) PNPresenceHereNowAPICallBuilder *(^verbosity)(PNHereNowVerbosityLevel verbosity); 62 | 63 | /** 64 | @brief Perform composed API call. 65 | @discussion Execute API call and report processing results through passed comnpletion block. 66 | @discussion On block call return block which consume (\b required) here now processing completion block which 67 | pass two arguments: \c result - in case of successful request processing \c data field will 68 | contain results of here now operation; \c status - in case if error occurred during request 69 | processing. 70 | 71 | @since 4.5.4 72 | */ 73 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNGlobalHereNowCompletionBlock block); 74 | 75 | #pragma mark - 76 | 77 | 78 | @end 79 | 80 | NS_ASSUME_NONNULL_END 81 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNPresenceWhereNowAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNPresenceAPICallBuilder.h" 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief \b User 'where now' API call builder. 8 | @discussion Class describe interface which provide access to \b user 'where now' API. 9 | 10 | @author Sergey Mamontov 11 | @since 4.5.4 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNPresenceWhereNowAPICallBuilder : PNPresenceAPICallBuilder 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Configuration 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Specify unique \c user idetifier. 23 | @discussion On block call return block which consume unique \c user idetifier for which should be retireved 24 | presence information (list of channels on which \c user subscribed). 25 | 26 | @since 4.5.4 27 | */ 28 | @property (nonatomic, readonly, strong) PNPresenceWhereNowAPICallBuilder *(^uuid)(NSString *uuid); 29 | 30 | 31 | ///------------------------------------------------ 32 | /// @name Execution 33 | ///------------------------------------------------ 34 | 35 | /** 36 | @brief Perform composed API call. 37 | @discussion Execute API call and report processing results through passed comnpletion block. 38 | @discussion On block call return block which consume (\b required) where now processing completion block 39 | which pass two arguments: \c result - in case of successful request processing \c data field will 40 | contain results of where now operation; \c status - in case if error occurred during request 41 | processing. 42 | 43 | @since 4.5.4 44 | */ 45 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNWhereNowCompletionBlock block); 46 | 47 | #pragma mark - 48 | 49 | 50 | @end 51 | 52 | NS_ASSUME_NONNULL_END 53 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNPresenceWhereNowResult.h: -------------------------------------------------------------------------------- 1 | #import "PNResult.h" 2 | #import "PNServiceData.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which allow to get access to client presence processed result. 9 | 10 | @author Sergey Mamontov 11 | @since 4.0 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNPresenceWhereNowData : PNServiceData 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Information 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief List of channels on which client subscribed. 23 | 24 | @since 4.0 25 | */ 26 | @property (nonatomic, readonly, strong) NSArray *channels; 27 | 28 | #pragma mark - 29 | 30 | 31 | @end 32 | 33 | 34 | /** 35 | @brief Class which is used to provide access to request processing results. 36 | 37 | @author Sergey Mamontov 38 | @since 4.0 39 | @copyright © 2009-2017 PubNub, Inc. 40 | */ 41 | @interface PNPresenceWhereNowResult : PNResult 42 | 43 | 44 | ///------------------------------------------------ 45 | /// @name Information 46 | ///------------------------------------------------ 47 | 48 | /** 49 | @brief Stores reference on client presence request processing information. 50 | 51 | @since 4.0 52 | */ 53 | @property (nonatomic, readonly, strong) PNPresenceWhereNowData *data; 54 | 55 | #pragma mark - 56 | 57 | 58 | @end 59 | 60 | NS_ASSUME_NONNULL_END 61 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNPublishAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNAPICallBuilder.h" 2 | #import "PNStructures.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Publish API call builder. 9 | @discussion Class describe interface which provide access to publish API. 10 | 11 | @author Sergey Mamontov 12 | @since 4.5.4 13 | @copyright © 2009-2017 PubNub, Inc. 14 | */ 15 | @interface PNPublishAPICallBuilder : PNAPICallBuilder 16 | 17 | 18 | ///------------------------------------------------ 19 | /// @name Configuration 20 | ///------------------------------------------------ 21 | 22 | /** 23 | @brief Specify name of channel. 24 | @discussion On block call return block which consume (\b required) name of \c channel to which \c message 25 | should be sent. 26 | 27 | @since 4.5.4 28 | */ 29 | @property (nonatomic, readonly, strong) PNPublishAPICallBuilder *(^channel)(NSString *channel); 30 | 31 | /** 32 | @brief Specify message. 33 | @discussion On block call return block which consume Foundation object (\a NSString, \a NSNumber, \a NSArray, 34 | \a NSDictionary) which will be published. 35 | @discussion Provided object will be serialized into JSON string before pushing to \b PubNub service. If 36 | client has been configured with cipher key message will be encrypted as well. 37 | @note Objects can be pushed only to regular channels. 38 | 39 | @since 4.5.4 40 | */ 41 | @property (nonatomic, readonly, strong) PNPublishAPICallBuilder *(^message)(id message); 42 | 43 | /** 44 | @brief Specify message metadata. 45 | @discussion On block call return block which consume \b NSDictionary with values which should be used by 46 | \b PubNub service to filter messages. 47 | 48 | @since 4.5.4 49 | */ 50 | @property (nonatomic, readonly, strong) PNPublishAPICallBuilder *(^metadata)(NSDictionary *metadata); 51 | 52 | /** 53 | @brief Specify whether published \c message should be stored or not. 54 | @discussion On block call return block which consume \a BOOL and specify wheter published \c message should 55 | be stored in history / storage or not. 56 | 57 | @since 4.5.4 58 | */ 59 | @property (nonatomic, readonly, strong) PNPublishAPICallBuilder *(^shouldStore)(BOOL shouldStore); 60 | 61 | /** 62 | @brief Specify for how many hours published \c message should be stored. 63 | @discussion On block call return block which consume \a NSUInteger and specify for how many hours published 64 | message should be stored in channel's storage. 65 | @note If \c shouldStore is set to \c NO this value will be ignored. If value is \b 0 then message will 66 | be stored in channel's storage or \b N hours (if non-zero value passed). 67 | 68 | @since 4.5.5 69 | */ 70 | @property (nonatomic, readonly, strong) PNPublishAPICallBuilder *(^ttl)(NSUInteger ttl); 71 | 72 | /** 73 | @brief Specify whether published \c message should be compressed or not. 74 | @discussion On block call return block which consume \a BOOL and specify wheter published \c message should 75 | be compressed and sent with \c POST request or not. 76 | 77 | @since 4.5.4 78 | */ 79 | @property (nonatomic, readonly, strong) PNPublishAPICallBuilder *(^compress)(BOOL compress); 80 | 81 | /** 82 | @brief Specify whether published \c message should be replicated across the PubNub Real-Time Network and 83 | sent simultaneously to all subscribed clients on a channel. 84 | 85 | @since 4.5.4 86 | */ 87 | @property (nonatomic, readonly, strong) PNPublishAPICallBuilder *(^replicate)(BOOL replicate); 88 | 89 | /** 90 | @brief Specify message push payloads. 91 | @discussion On block call return block which consume \b NSDictionary with payloads for different vendors 92 | (Apple with "apns" key and Google with "gcm") which is used to deliver updates while application 93 | not in foreground. 94 | 95 | @since 4.5.4 96 | */ 97 | @property (nonatomic, readonly, strong) PNPublishAPICallBuilder *(^payloads)(NSDictionary *payload); 98 | 99 | 100 | ///------------------------------------------------ 101 | /// @name Execution 102 | ///------------------------------------------------ 103 | 104 | /** 105 | @brief Perform composed API call. 106 | @discussion Execute API call and report processing results through passed comnpletion block. 107 | @discussion On block call return block which consume (\b not required) publish processing completion block 108 | which pass only one argument - request processing status to report about how data pushing was 109 | successful or not. 110 | 111 | @since 4.5.4 112 | */ 113 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNPublishCompletionBlock _Nullable block); 114 | 115 | #pragma mark - 116 | 117 | 118 | @end 119 | 120 | NS_ASSUME_NONNULL_END 121 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNPublishSizeAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNAPICallBuilder.h" 2 | #import "PNStructures.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Publish message size calculation API call builder. 9 | @discussion Class describe interface which provide ability to calculate resulting size of message which 10 | can be published. 11 | 12 | @author Sergey Mamontov 13 | @since 4.5.4 14 | @copyright © 2009-2017 PubNub, Inc. 15 | */ 16 | @interface PNPublishSizeAPICallBuilder : PNAPICallBuilder 17 | 18 | 19 | ///------------------------------------------------ 20 | /// @name Configuration 21 | ///------------------------------------------------ 22 | 23 | /** 24 | @brief Specify name of channel. 25 | @discussion On block call return block which consume (\b required) name of \c channel to which \c message 26 | size should be calculated. 27 | 28 | @since 4.5.4 29 | */ 30 | @property (nonatomic, readonly, strong) PNPublishSizeAPICallBuilder *(^channel)(NSString *channel); 31 | 32 | /** 33 | @brief Specify message. 34 | @discussion On block call return block which consume Foundation object (\a NSString, \a NSNumber, \a NSArray, 35 | \a NSDictionary) which will be published. 36 | @discussion Provided object will be serialized into JSON string before pushing to \b PubNub service. If 37 | client has been configured with cipher key message will be encrypted as well. 38 | @note Objects can be pushed only to regular channels. 39 | 40 | @since 4.5.4 41 | */ 42 | @property (nonatomic, readonly, strong) PNPublishSizeAPICallBuilder *(^message)(id message); 43 | 44 | /** 45 | @brief Specify message metadata. 46 | @discussion On block call return block which consume \b NSDictionary with values which should be used by 47 | \b PubNub service to filter messages. 48 | 49 | @since 4.5.4 50 | */ 51 | @property (nonatomic, readonly, strong) PNPublishSizeAPICallBuilder *(^metadata)(NSDictionary *metadata); 52 | 53 | /** 54 | @brief Specify whether published \c message should be stored or not. 55 | @discussion On block call return block which consume \a BOOL and specify wheter published \c message should 56 | be stored in history / storage or not. 57 | 58 | @since 4.5.4 59 | */ 60 | @property (nonatomic, readonly, strong) PNPublishSizeAPICallBuilder *(^shouldStore)(BOOL shouldStore); 61 | 62 | /** 63 | @brief Specify for how many hours published \c message should be stored. 64 | @discussion On block call return block which consume \a NSUInteger and specify for how many hours published 65 | message should be stored in channel's storage. 66 | @note If \c shouldStore is set to \c NO this value will be ignored. If value is \b 0 then message will 67 | be stored in channel's storage or \b N hours (if non-zero value passed). 68 | 69 | @since 4.5.5 70 | */ 71 | @property (nonatomic, readonly, strong) PNPublishSizeAPICallBuilder *(^ttl)(NSUInteger ttl); 72 | 73 | /** 74 | @brief Specify whether published \c message should be compressed or not. 75 | @discussion On block call return block which consume \a BOOL and specify wheter published \c message should 76 | be compressed and sent with \c POST request or not. 77 | 78 | @since 4.5.4 79 | */ 80 | @property (nonatomic, readonly, strong) PNPublishSizeAPICallBuilder *(^compress)(BOOL compress); 81 | 82 | /** 83 | @brief Specify whether published \c message should be replicated across the PubNub Real-Time Network and 84 | sent simultaneously to all subscribed clients on a channel. 85 | 86 | @since 4.5.4 87 | */ 88 | @property (nonatomic, readonly, strong) PNPublishSizeAPICallBuilder *(^replicate)(BOOL replicate); 89 | 90 | 91 | ///------------------------------------------------ 92 | /// @name Execution 93 | ///------------------------------------------------ 94 | 95 | /** 96 | @brief Perform composed API call. 97 | @discussion Execute API call and report processing results through passed comnpletion block. 98 | @discussion On block call return block which consume (\b required) block which should be sent, when message 99 | size calculation will be completed. 100 | 101 | @since 4.5.4 102 | */ 103 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNMessageSizeCalculationCompletionBlock block); 104 | 105 | #pragma mark - 106 | 107 | 108 | @end 109 | 110 | NS_ASSUME_NONNULL_END 111 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNPublishStatus.h: -------------------------------------------------------------------------------- 1 | #import "PNAcknowledgmentStatus.h" 2 | #import "PNServiceData.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which is used to provide access to additional data available to describe publish 9 | status. 10 | 11 | @author Sergey Mamontov 12 | @since 4.0 13 | @copyright © 2009-2017 PubNub, Inc. 14 | */ 15 | @interface PNPublishData : PNServiceData 16 | 17 | 18 | ///------------------------------------------------ 19 | /// @name Information 20 | ///------------------------------------------------ 21 | 22 | /** 23 | @brief Service-provided time stamp at which message has been pushed to remote data object live feed. 24 | 25 | @since 4.0 26 | */ 27 | @property (nonatomic, readonly, strong) NSNumber *timetoken; 28 | 29 | /** 30 | @brief Service-provide information about service response message. 31 | 32 | @since 4.0 33 | */ 34 | @property (nonatomic, readonly, strong) NSString *information; 35 | 36 | #pragma mark - 37 | 38 | 39 | @end 40 | 41 | 42 | /** 43 | @brief Class which is used to provide information about request processing. 44 | 45 | @author Sergey Mamontov 46 | @since 4.0 47 | @copyright © 2009-2017 PubNub, Inc. 48 | */ 49 | @interface PNPublishStatus : PNAcknowledgmentStatus 50 | 51 | 52 | ///------------------------------------------------ 53 | /// @name Information 54 | ///------------------------------------------------ 55 | 56 | /** 57 | @brief Stores reference on publish request processing status information. 58 | 59 | @since 4.0 60 | */ 61 | @property (nonatomic, readonly, strong) PNPublishData *data; 62 | 63 | #pragma mark - 64 | 65 | 66 | @end 67 | 68 | NS_ASSUME_NONNULL_END 69 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNResult.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import "PNStructures.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which is used to describe server response. 9 | @discussion This object contains response itself and also set of data which has been used to communicate with 10 | \b PubNub service to get this response. 11 | 12 | @author Sergey Mamontov 13 | @since 4.0 14 | @copyright © 2009-2017 PubNub, Inc. 15 | */ 16 | @interface PNResult: NSObject 17 | 18 | 19 | ///------------------------------------------------ 20 | /// @name Information 21 | ///------------------------------------------------ 22 | 23 | /** 24 | @brief Stores HTTP status code with which \c request completed processing with \b PubNub service. 25 | 26 | @since 4.0 27 | */ 28 | @property (nonatomic, readonly, assign) NSInteger statusCode; 29 | 30 | /** 31 | @brief Represent type of operation which has been issued to \b PubNub service and received response stored in 32 | \c response and processed response in \c data. 33 | 34 | @since 4.0 35 | */ 36 | @property (nonatomic, readonly, assign) PNOperationType operation; 37 | 38 | /** 39 | @brief Stores whether secured connection has been used to send request or not. 40 | 41 | @since 4.0 42 | */ 43 | @property (nonatomic, readonly, assign, getter = isTLSEnabled) BOOL TLSEnabled; 44 | 45 | /** 46 | @brief UUID which is currently used by client to identify user on \b PubNub service. 47 | 48 | @since 4.0 49 | */ 50 | @property (nonatomic, readonly, copy) NSString *uuid; 51 | 52 | /** 53 | @brief Authorization which is used to get access to protected remote resources. 54 | @discussion Some resources can be protected by \b PAM functionality and access done using this authorization 55 | key. 56 | 57 | @since 4.0 58 | */ 59 | @property (nonatomic, nullable, readonly, copy) NSString *authKey; 60 | 61 | /** 62 | @brief Stores reference on \b PubNub service host name or IP address against which \c request has been 63 | called. 64 | 65 | @since 4.0 66 | */ 67 | @property (nonatomic, readonly, copy) NSString *origin; 68 | 69 | /** 70 | @brief Stores reference on copy of original request which has been used to fetch or push data to \b PubNub 71 | service. 72 | 73 | @since 4.0 74 | */ 75 | @property (nonatomic, nullable, readonly, copy) NSURLRequest *clientRequest; 76 | 77 | /** 78 | @brief Stringified \c operation value. 79 | 80 | @return Stringified representation for \c operation property which store value from \b PNOperationType. 81 | */ 82 | - (NSString *)stringifiedOperation; 83 | 84 | #pragma mark - 85 | 86 | 87 | @end 88 | 89 | NS_ASSUME_NONNULL_END 90 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNServiceData.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | 4 | /** 5 | @brief Instance used by subclasses to provide access to service response dictionary entries using methods 6 | with strict return type. 7 | 8 | @author Sergey Mamontov 9 | @since 4.0 10 | @copyright © 2009-2017 PubNub, Inc. 11 | */ 12 | @interface PNServiceData : NSObject 13 | 14 | 15 | #pragma mark - 16 | 17 | 18 | @end 19 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNStateAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNAPICallBuilder.h" 2 | #import "PNStructures.h" 3 | 4 | 5 | #pragma mark Class forward 6 | 7 | @class PNStateModificationAPICallBuilder, PNStateAuditAPICallBuilder; 8 | 9 | 10 | NS_ASSUME_NONNULL_BEGIN 11 | 12 | /** 13 | @brief State API call builder. 14 | @discussion Class describe interface which provide access to various state manipulation and audition 15 | endpoints. 16 | 17 | @author Sergey Mamontov 18 | @since 4.5.4 19 | @copyright © 2009-2017 PubNub, Inc. 20 | */ 21 | @interface PNStateAPICallBuilder : PNAPICallBuilder 22 | 23 | 24 | ///------------------------------------------------ 25 | /// @name Presence state manipulation 26 | ///------------------------------------------------ 27 | 28 | /** 29 | @brief Stores reference on construction block which return \c builder which is responsible for access to presence state modification. 30 | @discussion On block call return builder which provide interface for user presence state modification. 31 | 32 | @since 4.5.4 33 | */ 34 | @property (nonatomic, readonly, strong) PNStateModificationAPICallBuilder *(^set)(void); 35 | 36 | 37 | ///------------------------------------------------ 38 | /// @name Presence state audition 39 | ///------------------------------------------------ 40 | 41 | /** 42 | @brief Stores reference on construction block which return \c builder which is responsible for access, to presence state audit. 43 | @discussion On block call return builder which provide interface for user's presence state audit (retrieve 44 | state information which has been set for user on \c channel and / or channel \c group). 45 | 46 | @since 4.5.4 47 | */ 48 | @property (nonatomic, readonly, strong) PNStateAuditAPICallBuilder *(^audit)(void); 49 | 50 | #pragma mark - 51 | 52 | 53 | @end 54 | 55 | NS_ASSUME_NONNULL_END 56 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNStateAuditAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNStateAPICallBuilder.h" 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief Presence state audit API call builder. 8 | @discussion Class describe interface which allow to audit user's presence state (retrieve state information 9 | which has been set for user on \c channel and / or channel \c group). 10 | 11 | @author Sergey Mamontov 12 | @since 4.5.4 13 | @copyright © 2009-2017 PubNub, Inc. 14 | */ 15 | @interface PNStateAuditAPICallBuilder : PNStateAPICallBuilder 16 | 17 | 18 | ///------------------------------------------------ 19 | /// @name Configuration 20 | ///------------------------------------------------ 21 | 22 | /** 23 | @brief Specify unique \c user identifier. 24 | @discussion On block call return block which consume (\b required) unique \c user identifier for which 25 | presence state audition should be done for provided \c channel or channel \c group. 26 | 27 | @since 4.5.4 28 | */ 29 | @property (nonatomic, readonly, strong) PNStateAuditAPICallBuilder *(^uuid)(NSString *uuid); 30 | 31 | /** 32 | @brief Specify \c channel name. 33 | @discussion On block call return block which consume name of \c channel for which \c user's presence state 34 | should be audited. 35 | 36 | @since 4.5.4 37 | */ 38 | @property (nonatomic, readonly, strong) PNStateAuditAPICallBuilder *(^channel)(NSString *channel); 39 | 40 | /** 41 | @brief Specify channel \c group name. 42 | @discussion On block call return block which consume name of channel \c group for which \c user's presence 43 | state should be audited. 44 | 45 | @since 4.5.4 46 | */ 47 | @property (nonatomic, readonly, strong) PNStateAuditAPICallBuilder *(^channelGroup)(NSString *channelGroup); 48 | 49 | 50 | ///------------------------------------------------ 51 | /// @name Execution 52 | ///------------------------------------------------ 53 | 54 | /** 55 | @brief Perform composed API call. 56 | @discussion Execute API call and report processing results through passed comnpletion block. 57 | @discussion On block call return block which consume (\b required) state audition for user on channel 58 | processing completion block which pass two arguments: \c result - in case of successful request 59 | processing \c data field will contain results of client state retrieve operation; \c status - in 60 | case if error occurred during request processing. 61 | 62 | @since 4.5.4 63 | */ 64 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNChannelStateCompletionBlock block); 65 | 66 | #pragma mark - 67 | 68 | 69 | @end 70 | 71 | NS_ASSUME_NONNULL_END 72 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNStateModificationAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNStateAPICallBuilder.h" 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief Presence state modification API call builder. 8 | @discussion Class describe interface which allow to modify \c user's presence state for \c channel and / or 9 | channel \c group. 10 | 11 | @author Sergey Mamontov 12 | @since 4.5.4 13 | @copyright © 2009-2017 PubNub, Inc. 14 | */ 15 | @interface PNStateModificationAPICallBuilder : PNStateAPICallBuilder 16 | 17 | 18 | ///------------------------------------------------ 19 | /// @name Configuration 20 | ///------------------------------------------------ 21 | 22 | /** 23 | @brief Specify unique \c user identifier. 24 | @discussion On block call return block which consume (\b required) unique \c user identifier for which 25 | presence state should be modified on provided \c channel or channel \c group. 26 | 27 | @since 4.5.4 28 | */ 29 | @property (nonatomic, readonly, strong) PNStateModificationAPICallBuilder *(^uuid)(NSString *uuid); 30 | 31 | 32 | /** 33 | @brief Specify \c user's presence state. 34 | @discussion On block call return block which consume dictionary which should be bound to \c uuid on specified 35 | \c channel or channel \c group. 36 | 37 | @since 4.5.4 38 | */ 39 | @property (nonatomic, readonly, strong) PNStateModificationAPICallBuilder *(^state)(NSDictionary * _Nullable state); 40 | 41 | /** 42 | @brief Specify \c channel name. 43 | @discussion On block call return block which consume name of \c channel for which \c user's presence state 44 | should be modified. 45 | 46 | @since 4.5.4 47 | */ 48 | @property (nonatomic, readonly, strong) PNStateModificationAPICallBuilder *(^channel)(NSString *channel); 49 | 50 | /** 51 | @brief Specify channel \c group name. 52 | @discussion On block call return block which consume name of channel \c group for which \c user's presence 53 | state should be modified. 54 | 55 | @since 4.5.4 56 | */ 57 | @property (nonatomic, readonly, strong) PNStateModificationAPICallBuilder *(^channelGroup)(NSString *channelGroup); 58 | 59 | 60 | ///------------------------------------------------ 61 | /// @name Execution 62 | ///------------------------------------------------ 63 | 64 | /** 65 | @brief Perform composed API call. 66 | @discussion Execute API call and report processing results through passed comnpletion block. 67 | @discussion On block call return block which consume (\b not required) state modification for user on channel 68 | processing completion block which pass only one argument - request processing status to report 69 | about how data pushing was successful or not. 70 | 71 | @since 4.5.4 72 | */ 73 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNSetStateCompletionBlock _Nullable block); 74 | 75 | #pragma mark - 76 | 77 | 78 | @end 79 | 80 | NS_ASSUME_NONNULL_END 81 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNStatus.h: -------------------------------------------------------------------------------- 1 | #import "PNResult.h" 2 | #import "PNStructures.h" 3 | 4 | 5 | 6 | NS_ASSUME_NONNULL_BEGIN 7 | 8 | /** 9 | @brief Class which is used to describe error response from server or any non-request related client 10 | state changes. 11 | @discussion In case of error this instance may contain service response in \c data. Also this object hold 12 | additional information about current client state. 13 | 14 | @author Sergey Mamontov 15 | @since 4.0 16 | @copyright © 2009-2017 PubNub, Inc. 17 | */ 18 | @interface PNStatus : PNResult 19 | 20 | 21 | ///------------------------------------------------ 22 | /// @name Information 23 | ///------------------------------------------------ 24 | 25 | /** 26 | @brief One of \b PNStatusCategory fields which provide information about for which status this instance has 27 | been created. 28 | 29 | @return Processing status category. 30 | 31 | @since 4.0 32 | */ 33 | @property (nonatomic, readonly, assign) PNStatusCategory category; 34 | 35 | /** 36 | @brief Whether status object represent error or not. 37 | 38 | @return \c YES in case if status represent request processing error. 39 | 40 | @since 4.0 41 | */ 42 | @property (nonatomic, readonly, assign, getter = isError) BOOL error; 43 | 44 | /** 45 | @brief Auto-retry configuration information. 46 | @discussion In most cases client will keep retry request sending till it won't be successful or canceled with 47 | \c -cancelAutomaticRetry method. 48 | 49 | @return \c YES in case if request which represented with this failed status will be resent 50 | automatically or not. 51 | 52 | @since 4.0 53 | */ 54 | @property (nonatomic, readonly, assign, getter = willAutomaticallyRetry) BOOL automaticallyRetry; 55 | 56 | /** 57 | @brief Stringified \c category value. 58 | 59 | @return Stringified representation for \c category property which store value from \b PNStatusCategory. 60 | */ 61 | - (NSString *)stringifiedCategory; 62 | 63 | 64 | ///------------------------------------------------ 65 | /// @name Recovery 66 | ///------------------------------------------------ 67 | 68 | /** 69 | @brief Try to resent request associated with processing status object. 70 | @discussion Some operations which perform automatic retry attempts will ignore method call. 71 | 72 | @since 4.0 73 | */ 74 | - (void)retry; 75 | 76 | /** 77 | @brief For some requests client try to resent them to \b PubNub for processing. 78 | @discussion This method can be performed only on operations which respond with \c YES on 79 | \c willAutomaticallyRetry property. Other operation types will ignore method call. 80 | 81 | @since 4.0 82 | */ 83 | - (void)cancelAutomaticRetry; 84 | 85 | #pragma mark - 86 | 87 | 88 | @end 89 | 90 | NS_ASSUME_NONNULL_END 91 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNStreamAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNAPICallBuilder.h" 2 | #import "PNStructures.h" 3 | 4 | 5 | #pragma mark Class forward 6 | 7 | @class PNStreamModificationAPICallBuilder, PNStreamAuditAPICallBuilder; 8 | 9 | 10 | NS_ASSUME_NONNULL_BEGIN 11 | 12 | /** 13 | @brief Stream API call builder. 14 | @discussion Class describe interface which provide access to various stream manipulation and audition 15 | endpoints. 16 | 17 | @author Sergey Mamontov 18 | @since 4.5.4 19 | @copyright © 2009-2017 PubNub, Inc. 20 | */ 21 | @interface PNStreamAPICallBuilder : PNAPICallBuilder 22 | 23 | 24 | ///------------------------------------------------ 25 | /// @name Stream state manipulation 26 | ///------------------------------------------------ 27 | 28 | /** 29 | @brief Stores reference on construction block which return \c builder for stream state modification API. 30 | @discussion On block call return builder which provide interface for channel(s) \b addition to channel 31 | \c group. 32 | 33 | @since 4.5.4 34 | */ 35 | @property (nonatomic, readonly, strong) PNStreamModificationAPICallBuilder *(^add)(void); 36 | 37 | /** 38 | @brief Stores reference on construction block which return \c builder for stream state modification API. 39 | @discussion On block call return builder which provide interface for channel(s) \b removal from channel 40 | \c group. 41 | 42 | @since 4.5.4 43 | */ 44 | @property (nonatomic, readonly, strong) PNStreamModificationAPICallBuilder *(^remove)(void); 45 | 46 | 47 | ///------------------------------------------------ 48 | /// @name Stream state audit 49 | ///------------------------------------------------ 50 | 51 | /** 52 | @brief Stores reference on construction block which return \c builder for stream state audit API. 53 | @discussion On block call return builder which provide interface for stream state audit (retrieve list of 54 | channels which belong to provided channel \c group). 55 | 56 | @since 4.5.4 57 | */ 58 | @property (nonatomic, readonly, strong) PNStreamAuditAPICallBuilder *(^audit)(void); 59 | 60 | #pragma mark - 61 | 62 | 63 | @end 64 | 65 | NS_ASSUME_NONNULL_END 66 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNStreamAuditAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNStreamAPICallBuilder.h" 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief Stream audit API call builder. 8 | @discussion Protocol describe interface which provide access to stream audition endpoints. 9 | 10 | @author Sergey Mamontov 11 | @since 4.5.4 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNStreamAuditAPICallBuilder : PNStreamAPICallBuilder 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Configuration 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Specify channel \c group for audition. 23 | @discussion On block call return block which consume (\b required) name of channel \c group for which list of 24 | registered channels should be received. 25 | 26 | @since 4.5.4 27 | */ 28 | @property (nonatomic, readonly, strong) PNStreamAuditAPICallBuilder *(^channelGroup)(NSString *channelGroup); 29 | 30 | 31 | ///------------------------------------------------ 32 | /// @name Execution 33 | ///------------------------------------------------ 34 | 35 | /** 36 | @brief Perform composed API call. 37 | @discussion Execute API call and report processing results through passed comnpletion block. 38 | @discussion On block call return block which consume (\b required) channels audition process completion block 39 | which pass two arguments: \c result - in case of successful request processing \c data field will 40 | contain results of channel groups channels audition operation; \c status - in case if error 41 | occurred during request processing. 42 | 43 | @since 4.5.4 44 | */ 45 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNGroupChannelsAuditCompletionBlock block); 46 | 47 | #pragma mark - 48 | 49 | 50 | @end 51 | 52 | NS_ASSUME_NONNULL_END 53 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNStreamModificationAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNStreamAPICallBuilder.h" 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief Stream modification API call builder. 8 | @discussion Class describe interface which allow to \b add channel(s) to channel \c group. 9 | 10 | @author Sergey Mamontov 11 | @since 4.5.4 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNStreamModificationAPICallBuilder : PNStreamAPICallBuilder 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Configuration 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Specify channel \c group for modification. 23 | @discussion On block call return block which consume (\b required) name of channel \c group for which list of 24 | registered channels should be modified. 25 | 26 | @since 4.5.4 27 | */ 28 | @property (nonatomic, readonly, strong) PNStreamModificationAPICallBuilder *(^channelGroup)(NSString *channelGroup); 29 | 30 | /** 31 | @brief Specify channel name(s) list. 32 | @discussion On block call return block which consume channel name(s) list which should be used during 33 | channel \c group registered channels list modification. 34 | @warning \b PubNub client will remove specified channel \c group if \c nil or \c empty list will be passed 35 | during \c remove. 36 | 37 | @since 4.5.4 38 | */ 39 | @property (nonatomic, readonly, strong) PNStreamModificationAPICallBuilder *(^channels)(NSArray *channels); 40 | 41 | 42 | ///------------------------------------------------ 43 | /// @name Execution 44 | ///------------------------------------------------ 45 | 46 | /** 47 | @brief Perform composed API call. 48 | @discussion Execute API call and report processing results through passed comnpletion block. 49 | @discussion On block call return block which consume (\b not required) channel group modification process 50 | completion block which pass only one argument - request processing status to report about how 51 | data pushing was successful or not. 52 | 53 | @since 4.5.4 54 | */ 55 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNChannelGroupChangeCompletionBlock _Nullable block); 56 | 57 | #pragma mark - 58 | 59 | 60 | @end 61 | 62 | NS_ASSUME_NONNULL_END 63 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNSubscribeAPIBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNAPICallBuilder.h" 2 | #import "PNStructures.h" 3 | 4 | 5 | #pragma mark Class forward 6 | 7 | @class PNSubscribeChannelsOrGroupsAPIBuilder; 8 | 9 | 10 | NS_ASSUME_NONNULL_BEGIN 11 | 12 | /** 13 | @brief Subscribe API call builder. 14 | @discussion Class describe interface which provide access to various subscription endpoints. 15 | 16 | @author Sergey Mamontov 17 | @since 4.5.4 18 | @copyright © 2009-2017 PubNub, Inc. 19 | */ 20 | @interface PNSubscribeAPIBuilder : PNAPICallBuilder 21 | 22 | 23 | ///------------------------------------------------ 24 | /// @name Channels and Channel Groups 25 | ///------------------------------------------------ 26 | 27 | /** 28 | @brief Stores reference on construction block which return \c builder which is responsible for access to 29 | subscription API. 30 | @discussion On block call return block which consume list of \c channel name(s) from which \b PubNub client 31 | should subscribe. 32 | 33 | @since 4.5.4 34 | */ 35 | @property (nonatomic, readonly, strong) PNSubscribeChannelsOrGroupsAPIBuilder *(^channels)(NSArray *channels); 36 | 37 | /** 38 | @brief Stores reference on construction block which return \c builder which is responsible for access to 39 | subscription API. 40 | @discussion On block call return block which consume list of channel \c group name(s) from which \b PubNub 41 | client should subscribe. 42 | 43 | @since 4.5.4 44 | */ 45 | @property (nonatomic, readonly, strong) PNSubscribeChannelsOrGroupsAPIBuilder *(^channelGroups)(NSArray *channelGroups); 46 | 47 | 48 | ///------------------------------------------------ 49 | /// @name Presence 50 | ///------------------------------------------------ 51 | 52 | /** 53 | @brief Specify list of presence \c channel name(s). 54 | @discussion On block call return block which consume list of presence \c channel name(s) for which \b PubNub 55 | client should subscribe. 56 | 57 | @since 4.5.4 58 | */ 59 | @property (nonatomic, readonly, strong) PNSubscribeAPIBuilder *(^presenceChannels)(NSArray *presenceChannels); 60 | 61 | 62 | ///------------------------------------------------ 63 | /// @name Execution 64 | ///------------------------------------------------ 65 | 66 | /** 67 | @brief Perform composed API call. 68 | 69 | @since 4.5.4 70 | */ 71 | @property (nonatomic, readonly, strong) dispatch_block_t perform; 72 | 73 | #pragma mark - 74 | 75 | 76 | @end 77 | 78 | NS_ASSUME_NONNULL_END 79 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNSubscribeChannelsOrGroupsAPIBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNSubscribeAPIBuilder.h" 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief Subscribe API call builder. 8 | @discussion Class describe interface which allow to subscribe to \c channel(s) or channel \c group(s) with 9 | set of additional optinos. 10 | 11 | @author Sergey Mamontov 12 | @since 4.5.4 13 | @copyright © 2009-2017 PubNub, Inc. 14 | */ 15 | @interface PNSubscribeChannelsOrGroupsAPIBuilder : PNSubscribeAPIBuilder 16 | 17 | 18 | ///------------------------------------------------ 19 | /// @name Configuration 20 | ///------------------------------------------------ 21 | 22 | /** 23 | @brief Specify whether subscription should be done for presence as well. 24 | @discussion On block call return block which consume \a BOOL and specify wheter client should subscribe to 25 | presence \c channel(s) or presence channel \c group(s). 26 | 27 | @since 4.5.4 28 | */ 29 | @property (nonatomic, readonly, strong) PNSubscribeChannelsOrGroupsAPIBuilder *(^withPresence)(BOOL withPresence); 30 | 31 | /** 32 | @brief Specify \c time from which client should try to catch up on messages. 33 | @discussion On block call return block which consume time token from which client should try to catch up on 34 | messages. 35 | @note Value will be converted to required precision internally. 36 | 37 | @since 4.5.4 38 | */ 39 | @property (nonatomic, readonly, strong) PNSubscribeChannelsOrGroupsAPIBuilder *(^withTimetoken)(NSNumber *withTimetoken); 40 | 41 | /** 42 | @brief Specify \c user's presence state for \c channel(s) and channel \c group(s). 43 | @discussion On block call return block which consume dictionary which should be bound to \c uuid and contain 44 | list of \c state for each of which key is name of \c channel or channel \c group where it should 45 | be set. 46 | 47 | @since 4.5.4 48 | */ 49 | @property (nonatomic, readonly, strong) PNSubscribeChannelsOrGroupsAPIBuilder *(^state)(NSDictionary *state); 50 | 51 | 52 | ///------------------------------------------------ 53 | /// @name Execution 54 | ///------------------------------------------------ 55 | 56 | /** 57 | @brief Perform composed API call. 58 | 59 | @since 4.5.4 60 | */ 61 | @property (nonatomic, readonly, strong) dispatch_block_t perform; 62 | 63 | #pragma mark - 64 | 65 | 66 | @end 67 | 68 | NS_ASSUME_NONNULL_END 69 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNSubscribeStatus.h: -------------------------------------------------------------------------------- 1 | #import "PNErrorStatus.h" 2 | #import "PNServiceData.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Base class which allow to get access to general information about subscribe loop. 9 | 10 | @author Sergey Mamontov 11 | @since 4.0 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNSubscriberData : PNServiceData 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Information 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Name of channel for which subscriber received data. 23 | 24 | @since 4.5.2 25 | */ 26 | @property (nonatomic, readonly, strong) NSString *channel; 27 | 28 | /** 29 | @brief Name of \c channel or channel \c group (in case if not equal to \c channel). 30 | 31 | @since 4.5.2 32 | */ 33 | @property (nonatomic, nullable, readonly, strong) NSString *subscription; 34 | 35 | /** 36 | @brief Name of regular channel or channel group. 37 | 38 | @since 4.0 39 | */ 40 | @property (nonatomic, nullable, readonly, strong) NSString *subscribedChannel 41 | DEPRECATED_MSG_ATTRIBUTE("Property will be removed soon. Use 'subscription' property instead."); 42 | 43 | /** 44 | @brief Name of channel in case if \c -subscribedChannel represent channel group. 45 | 46 | @since 4.0 47 | */ 48 | @property (nonatomic, nullable, readonly, strong) NSString *actualChannel 49 | DEPRECATED_MSG_ATTRIBUTE("Property will be removed soon. Use 'channel' property instead."); 50 | 51 | /** 52 | @brief Time at which event arrived. 53 | 54 | @since 4.0 55 | */ 56 | @property (nonatomic, readonly, strong) NSNumber *timetoken; 57 | 58 | /** 59 | @brief Stores reference on metadata information which has been passed along with received event. 60 | 61 | @since 4.3.0 62 | */ 63 | @property (nonatomic, nullable, readonly, strong) NSDictionary *userMetadata; 64 | 65 | #pragma mark - 66 | 67 | 68 | @end 69 | 70 | 71 | /** 72 | @brief Class which is used to provide access to request processing results. 73 | 74 | @author Sergey Mamontov 75 | @since 4.0 76 | @copyright © 2009-2017 PubNub, Inc. 77 | */ 78 | @interface PNSubscribeStatus : PNErrorStatus 79 | 80 | 81 | ///------------------------------------------------ 82 | /// @name Information 83 | ///------------------------------------------------ 84 | 85 | /** 86 | @brief Time token which has been used to establish current subscription cycle. 87 | 88 | @since 4.0 89 | */ 90 | @property (nonatomic, readonly, strong) NSNumber *currentTimetoken; 91 | 92 | /** 93 | @brief Stores reference on previous key which has been used in subscription cycle to receive 94 | \c currentTimetoken along with other events. 95 | 96 | @since 4.0 97 | */ 98 | @property (nonatomic, readonly, strong) NSNumber *lastTimeToken; 99 | 100 | /** 101 | @brief List of channels on which client currently subscribed. 102 | 103 | @since 4.0 104 | */ 105 | @property (nonatomic, readonly, copy) NSArray *subscribedChannels; 106 | 107 | /** 108 | @brief List of channel group names on which client currently subscribed. 109 | 110 | @since 4.0 111 | */ 112 | @property (nonatomic, readonly, copy) NSArray *subscribedChannelGroups; 113 | 114 | /** 115 | @brief Structured \b PNResult \c data field information. 116 | 117 | @since 4.0 118 | */ 119 | @property (nonatomic, readonly, strong) PNSubscriberData *data; 120 | 121 | #pragma mark - 122 | 123 | 124 | @end 125 | 126 | NS_ASSUME_NONNULL_END 127 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNTimeAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNAPICallBuilder.h" 2 | #import "PNStructures.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Time API call builder. 9 | @discussion Class describe interface which allow to use time API endpoint. 10 | 11 | @author Sergey Mamontov 12 | @since 4.5.4 13 | @copyright © 2009-2017 PubNub, Inc. 14 | */ 15 | @interface PNTimeAPICallBuilder : PNAPICallBuilder 16 | 17 | 18 | ///------------------------------------------------ 19 | /// @name Execution 20 | ///------------------------------------------------ 21 | 22 | /** 23 | @brief Perform composed API call. 24 | @discussion Execute API call and report processing results through passed comnpletion block. 25 | @discussion On block call return block which consume (\b required) time request process results handling 26 | block which pass two arguments: \c result - in case of successful request processing \c data 27 | field will contain server-provided time token; \c status - in case if error occurred during 28 | request processing. 29 | 30 | @since 4.5.4 31 | */ 32 | @property (nonatomic, readonly, strong) void(^performWithCompletion)(PNTimeCompletionBlock block); 33 | 34 | #pragma mark - 35 | 36 | 37 | @end 38 | 39 | NS_ASSUME_NONNULL_END 40 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNTimeResult.h: -------------------------------------------------------------------------------- 1 | #import "PNResult.h" 2 | #import "PNServiceData.h" 3 | 4 | 5 | NS_ASSUME_NONNULL_BEGIN 6 | 7 | /** 8 | @brief Class which allow to get access to time API processed result. 9 | 10 | @author Sergey Mamontov 11 | @since 4.0 12 | @copyright © 2009-2017 PubNub, Inc. 13 | */ 14 | @interface PNTimeData : PNServiceData 15 | 16 | 17 | ///------------------------------------------------ 18 | /// @name Information 19 | ///------------------------------------------------ 20 | 21 | /** 22 | @brief Current time on \b PubNub network servers. 23 | 24 | @since 4.0 25 | */ 26 | @property (nonatomic, readonly, strong) NSNumber *timetoken; 27 | 28 | #pragma mark - 29 | 30 | 31 | @end 32 | 33 | 34 | /** 35 | @brief Class which is used to provide access to request processing results. 36 | 37 | @author Sergey Mamontov 38 | @since 4.0 39 | @copyright © 2009-2017 PubNub, Inc. 40 | */ 41 | @interface PNTimeResult : PNResult 42 | 43 | 44 | ///------------------------------------------------ 45 | /// @name Information 46 | ///------------------------------------------------ 47 | 48 | /** 49 | @brief Stores reference on time request processing information. 50 | 51 | @since 4.0 52 | */ 53 | @property (nonatomic, readonly, strong) PNTimeData *data; 54 | 55 | #pragma mark - 56 | 57 | 58 | @end 59 | 60 | NS_ASSUME_NONNULL_END 61 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNUnsubscribeAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNAPICallBuilder.h" 2 | #import "PNStructures.h" 3 | 4 | 5 | #pragma mark Class forward 6 | 7 | @class PNUnsubscribeChannelsOrGroupsAPICallBuilder; 8 | 9 | 10 | NS_ASSUME_NONNULL_BEGIN 11 | 12 | /** 13 | @brief Unsubscribe API call builder. 14 | @discussion Class describe interface which provide access to various unsubscription endpoints. 15 | 16 | @author Sergey Mamontov 17 | @since 4.5.4 18 | @copyright © 2009-2017 PubNub, Inc. 19 | */ 20 | @interface PNUnsubscribeAPICallBuilder : PNAPICallBuilder 21 | 22 | 23 | ///------------------------------------------------ 24 | /// @name Channels and Channel Groups 25 | ///------------------------------------------------ 26 | 27 | /** 28 | @brief Stores reference on construction block which return \c builder which is responsible for access to 29 | unsubscription API. 30 | @discussion On block call return block which consume list of \c channel name(s) from which \b PubNub client 31 | should unsubscribe. 32 | 33 | @since 4.5.4 34 | */ 35 | @property (nonatomic, readonly, strong) PNUnsubscribeChannelsOrGroupsAPICallBuilder *(^channels)(NSArray *channels); 36 | 37 | /** 38 | @brief Stores reference on construction block which return \c builder which is responsible for access to 39 | unsubscription API. 40 | @discussion On block call return block which consume list of channel \c group name(s) from which \b PubNub 41 | client should unsubscribe. 42 | 43 | @since 4.5.4 44 | */ 45 | @property (nonatomic, readonly, strong) PNUnsubscribeChannelsOrGroupsAPICallBuilder *(^channelGroups)(NSArray *channelGroups); 46 | 47 | 48 | ///------------------------------------------------ 49 | /// @name Presence 50 | ///------------------------------------------------ 51 | 52 | /** 53 | @brief Specify list of presence \c channel(s). 54 | @discussion On block call return block which consume list of presence \c channel name(s) from which \b PubNub 55 | client should unsubscribe. 56 | 57 | @since 4.5.4 58 | */ 59 | @property (nonatomic, readonly, strong) PNUnsubscribeAPICallBuilder *(^presenceChannels)(NSArray *presenceChannels); 60 | 61 | 62 | ///------------------------------------------------ 63 | /// @name Execution 64 | ///------------------------------------------------ 65 | 66 | /** 67 | @brief Perform composed API call. 68 | @warning If no list of \c channel(s) or channel \c group(s) has been specified before method call - \b PubNub 69 | client will unsubscribed from all \c channel(s) and channel \c group(s) (including presence 70 | \c channel(s) and channel \c group(s)). 71 | 72 | @since 4.5.4 73 | */ 74 | @property (nonatomic, readonly, strong) dispatch_block_t perform; 75 | 76 | #pragma mark - 77 | 78 | 79 | @end 80 | 81 | NS_ASSUME_NONNULL_END 82 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PNUnsubscribeChannelsOrGroupsAPICallBuilder.h: -------------------------------------------------------------------------------- 1 | #import "PNUnsubscribeAPICallBuilder.h" 2 | 3 | 4 | NS_ASSUME_NONNULL_BEGIN 5 | 6 | /** 7 | @brief Unsubscribe API call builder. 8 | @discussion Class describe interface which allow to unsubscribe from \c channel(s) or channel \c group(s) 9 | with set of additional optinos. 10 | 11 | @author Sergey Mamontov 12 | @since 4.5.4 13 | @copyright © 2009-2017 PubNub, Inc. 14 | */ 15 | @interface PNUnsubscribeChannelsOrGroupsAPICallBuilder : PNUnsubscribeAPICallBuilder 16 | 17 | 18 | ///------------------------------------------------ 19 | /// @name Configuration 20 | ///------------------------------------------------ 21 | 22 | /** 23 | @brief Specify whether unsubscription should be done for presence as well. 24 | @discussion On block call return block which consume \a BOOL and specify wheter client should unsubscribe 25 | from presence \c channel(s) or presence channel \c group(s). 26 | 27 | @since 4.5.4 28 | */ 29 | @property (nonatomic, readonly, strong) PNUnsubscribeChannelsOrGroupsAPICallBuilder *(^withPresence)(BOOL withPresence); 30 | 31 | 32 | ///------------------------------------------------ 33 | /// @name Execution 34 | ///------------------------------------------------ 35 | 36 | /** 37 | @brief Perform composed API call. 38 | @warning If no list of presence \c channel name(s) has been specified before method call - \b PubNub client 39 | will unsubscribed from all \c channel(s) and channel \c group(s) (including presence \c channel(s) 40 | and channel \c group(s)). 41 | 42 | @since 4.5.4 43 | */ 44 | @property (nonatomic, readonly, strong) dispatch_block_t perform; 45 | 46 | #pragma mark - 47 | 48 | 49 | @end 50 | 51 | NS_ASSUME_NONNULL_END 52 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PubNub+Time.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import "PNTimeAPICallBuilder.h" 3 | #import "PubNub+Core.h" 4 | 5 | 6 | #pragma mark Class forward 7 | 8 | @class PNErrorStatus, PNTimeResult; 9 | 10 | 11 | NS_ASSUME_NONNULL_BEGIN 12 | 13 | #pragma mark - API group interface 14 | 15 | /** 16 | @brief \b PubNub client core class extension to provide access to 'time' API group. 17 | 18 | @author Sergey Mamontov 19 | @since 4.0 20 | @copyright © 2009-2017 PubNub, Inc. 21 | */ 22 | @interface PubNub (Time) 23 | 24 | 25 | ///------------------------------------------------ 26 | /// @name API Builder support 27 | ///------------------------------------------------ 28 | 29 | /** 30 | @brief Stores reference on time API access \c builder construction block. 31 | @discussion On block call return builder which allow to configure parameters for time API access. 32 | 33 | @since 4.5.4 34 | */ 35 | @property (nonatomic, readonly, strong) PNTimeAPICallBuilder *(^time)(void); 36 | 37 | 38 | ///------------------------------------------------ 39 | /// @name Time token request 40 | ///------------------------------------------------ 41 | 42 | /** 43 | @brief Request current time from \b PubNub service servers. 44 | @discussion \b Example: 45 | 46 | @code 47 | PNConfiguration *configuration = [PNConfiguration configurationWithPublishKey:@"demo" 48 | subscribeKey:@"demo"]; 49 | self.client = [PubNub clientWithConfiguration:configuration]; 50 | [self.client timeWithCompletion:^(PNTimeResult *result, PNErrorStatus *status) { 51 | 52 | // Check whether request successfully completed or not. 53 | if (!status.isError) { 54 | 55 | // Handle downloaded server time token using: result.data.timetoken 56 | } 57 | // Request processing failed. 58 | else { 59 | 60 | // Handle tmie token download error. Check 'category' property to find out possible 61 | // issue because of which request did fail. 62 | // 63 | // Request can be resent using: [status retry]; 64 | } 65 | }]; 66 | @endcode 67 | 68 | @param block Time request process results handling block which pass two arguments: \c result - in 69 | case of successful request processing \c data field will contain server-provided time 70 | token; \c status - in case if error occurred during request processing. 71 | 72 | @since 4.0 73 | */ 74 | - (void)timeWithCompletion:(PNTimeCompletionBlock)block NS_SWIFT_NAME(timeWithCompletion(_:)); 75 | 76 | #pragma mark - 77 | 78 | 79 | @end 80 | 81 | NS_ASSUME_NONNULL_END 82 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Headers/PubNub.h: -------------------------------------------------------------------------------- 1 | /** 2 | @author Sergey Mamontov 3 | @version 4.2.0 4 | @copyright © 2009-2016 PubNub, Inc. 5 | */ 6 | #import 7 | 8 | 9 | //! Project version number for PubNub. 10 | FOUNDATION_EXPORT double PubNubVersionNumber; 11 | 12 | //! Project version string for PubNub. 13 | FOUNDATION_EXPORT const unsigned char PubNubVersionString[]; 14 | 15 | 16 | // Protocols 17 | #import "PNObjectEventListener.h" 18 | 19 | // Categories 20 | #import "NSURLSessionConfiguration+PNConfiguration.h" 21 | 22 | // Data objects 23 | #import "PNPresenceChannelGroupHereNowResult.h" 24 | #import "PNChannelGroupClientStateResult.h" 25 | #import "PNPresenceChannelHereNowResult.h" 26 | #import "PNPresenceGlobalHereNowResult.h" 27 | #import "PNChannelGroupChannelsResult.h" 28 | #import "PNAPNSEnabledChannelsResult.h" 29 | #import "PNChannelClientStateResult.h" 30 | #import "PNClientStateUpdateStatus.h" 31 | #import "PNPresenceWhereNowResult.h" 32 | #import "PNAcknowledgmentStatus.h" 33 | #import "PNChannelGroupsResult.h" 34 | #import "PNClientInformation.h" 35 | #import "PNSubscriberResults.h" 36 | #import "PNSubscribeStatus.h" 37 | #import "PNPublishStatus.h" 38 | #import "PNHistoryResult.h" 39 | #import "PNServiceData.h" 40 | #import "PNErrorStatus.h" 41 | #import "PNTimeResult.h" 42 | #import "PNResult.h" 43 | #import "PNStatus.h" 44 | 45 | // API 46 | #import "PubNub+Core.h" 47 | #import "PubNub+ChannelGroup.h" 48 | #import "PubNub+Subscribe.h" 49 | #import "PNConfiguration.h" 50 | #import "PubNub+Presence.h" 51 | #import "PubNub+Publish.h" 52 | #import "PubNub+History.h" 53 | #import "PubNub+State.h" 54 | #import "PNErrorCodes.h" 55 | #import "PNStructures.h" 56 | #import "PubNub+APNS.h" 57 | #import "PubNub+Time.h" 58 | #import "PNLLogger.h" 59 | #import "PNResult.h" 60 | #import "PNStatus.h" 61 | #import "PNAES.h" 62 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Info.plist: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redfearnk/WebRTCVideoChat/66296df00f66492a863ff94cf714d6eea0e9eb99/WebRTCVideoChat/PubNub.framework/Info.plist -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/Modules/module.modulemap: -------------------------------------------------------------------------------- 1 | framework module PubNub { 2 | umbrella header "PubNub.h" 3 | 4 | link "z" 5 | export * 6 | module * { export * } 7 | } 8 | -------------------------------------------------------------------------------- /WebRTCVideoChat/PubNub.framework/PubNub: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redfearnk/WebRTCVideoChat/66296df00f66492a863ff94cf714d6eea0e9eb99/WebRTCVideoChat/PubNub.framework/PubNub -------------------------------------------------------------------------------- /WebRTCVideoChat/ViewController.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.swift 3 | // WebRTCVideoChat 4 | // 5 | // Created by Kyle Redfearn on 8/22/17. 6 | // Copyright © 2017 Kyle Redfearn. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | import WebRTC 11 | 12 | class ViewController: UIViewController, WebRTCClientDelegate { 13 | 14 | @IBOutlet weak var connectButton: UIButton! 15 | weak var remoteView: RTCEAGLVideoView? 16 | weak var localView: RTCEAGLVideoView? 17 | 18 | override func viewDidLoad() { 19 | super.viewDidLoad() 20 | // Do any additional setup after loading the view, typically from a nib. 21 | WebRTCClient.shared.delegate = self 22 | } 23 | 24 | override func didReceiveMemoryWarning() { 25 | super.didReceiveMemoryWarning() 26 | // Dispose of any resources that can be recreated. 27 | } 28 | 29 | @IBAction func connectTapped(_ sender: Any) { 30 | WebRTCClient.shared.startConnection() 31 | } 32 | 33 | func webRTCClientReady() { 34 | self.connectButton.isEnabled = true 35 | } 36 | 37 | func webRTCClientDidAddRemote(videoTrack: RTCVideoTrack) { 38 | DispatchQueue.main.async { 39 | self.connectButton.isHidden = true 40 | if self.remoteView == nil { 41 | let videoView = RTCEAGLVideoView(frame: self.view.bounds) 42 | if let local = self.localView { 43 | self.view.insertSubview(videoView, belowSubview: local) 44 | } else { 45 | self.view.addSubview(videoView) 46 | } 47 | self.remoteView = videoView 48 | } 49 | videoTrack.add(self.remoteView!) 50 | } 51 | } 52 | 53 | func webRTCClientDidAddLocal(videoTrack: RTCVideoTrack) { 54 | DispatchQueue.main.async { 55 | self.connectButton.isHidden = true 56 | if self.localView == nil { 57 | let videoView = RTCEAGLVideoView(frame: CGRect(x: 0, y: 0, width:100, height: 100)) 58 | self.view.addSubview(videoView) 59 | self.localView = videoView 60 | } 61 | videoTrack.add(self.localView!) 62 | } 63 | } 64 | 65 | func didRecieve(image: UIImage) { 66 | // if let view = self.openGLView { 67 | //// vie 68 | // } 69 | } 70 | } 71 | 72 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCAVFoundationVideoSource.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | #import 13 | 14 | @class AVCaptureSession; 15 | @class RTCMediaConstraints; 16 | @class RTCPeerConnectionFactory; 17 | 18 | NS_ASSUME_NONNULL_BEGIN 19 | 20 | /** 21 | * DEPRECATED Use RTCCameraVideoCapturer instead. 22 | * 23 | * RTCAVFoundationVideoSource is a video source that uses 24 | * webrtc::AVFoundationVideoCapturer. We do not currently provide a wrapper for 25 | * that capturer because cricket::VideoCapturer is not ref counted and we cannot 26 | * guarantee its lifetime. Instead, we expose its properties through the ref 27 | * counted video source interface. 28 | */ 29 | RTC_EXPORT 30 | @interface RTCAVFoundationVideoSource : RTCVideoSource 31 | 32 | - (instancetype)init NS_UNAVAILABLE; 33 | 34 | /** 35 | * Calling this function will cause frames to be scaled down to the 36 | * requested resolution. Also, frames will be cropped to match the 37 | * requested aspect ratio, and frames will be dropped to match the 38 | * requested fps. The requested aspect ratio is orientation agnostic and 39 | * will be adjusted to maintain the input orientation, so it doesn't 40 | * matter if e.g. 1280x720 or 720x1280 is requested. 41 | */ 42 | - (void)adaptOutputFormatToWidth:(int)width height:(int)height fps:(int)fps; 43 | 44 | /** Returns whether rear-facing camera is available for use. */ 45 | @property(nonatomic, readonly) BOOL canUseBackCamera; 46 | 47 | /** Switches the camera being used (either front or back). */ 48 | @property(nonatomic, assign) BOOL useBackCamera; 49 | 50 | /** Returns the active capture session. */ 51 | @property(nonatomic, readonly) AVCaptureSession *captureSession; 52 | 53 | @end 54 | 55 | NS_ASSUME_NONNULL_END 56 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCAudioSessionConfiguration.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC Project Authors. All rights reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | #import 13 | 14 | #import "WebRTC/RTCMacros.h" 15 | 16 | NS_ASSUME_NONNULL_BEGIN 17 | 18 | extern const int kRTCAudioSessionPreferredNumberOfChannels; 19 | extern const double kRTCAudioSessionHighPerformanceSampleRate; 20 | extern const double kRTCAudioSessionLowComplexitySampleRate; 21 | extern const double kRTCAudioSessionHighPerformanceIOBufferDuration; 22 | extern const double kRTCAudioSessionLowComplexityIOBufferDuration; 23 | 24 | // Struct to hold configuration values. 25 | RTC_EXPORT 26 | @interface RTCAudioSessionConfiguration : NSObject 27 | 28 | @property(nonatomic, strong) NSString *category; 29 | @property(nonatomic, assign) AVAudioSessionCategoryOptions categoryOptions; 30 | @property(nonatomic, strong) NSString *mode; 31 | @property(nonatomic, assign) double sampleRate; 32 | @property(nonatomic, assign) NSTimeInterval ioBufferDuration; 33 | @property(nonatomic, assign) NSInteger inputNumberOfChannels; 34 | @property(nonatomic, assign) NSInteger outputNumberOfChannels; 35 | 36 | /** Initializes configuration to defaults. */ 37 | - (instancetype)init NS_DESIGNATED_INITIALIZER; 38 | 39 | /** Returns the current configuration of the audio session. */ 40 | + (instancetype)currentConfiguration; 41 | /** Returns the configuration that WebRTC needs. */ 42 | + (instancetype)webRTCConfiguration; 43 | /** Provide a way to override the default configuration. */ 44 | + (void)setWebRTCConfiguration:(RTCAudioSessionConfiguration *)configuration; 45 | 46 | @end 47 | 48 | NS_ASSUME_NONNULL_END 49 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCAudioSource.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | #import 15 | 16 | NS_ASSUME_NONNULL_BEGIN 17 | 18 | RTC_EXPORT 19 | @interface RTCAudioSource : RTCMediaSource 20 | 21 | - (instancetype)init NS_UNAVAILABLE; 22 | 23 | // Sets the volume for the RTCMediaSource. |volume| is a gain value in the range 24 | // [0, 10]. 25 | // Temporary fix to be able to modify volume of remote audio tracks. 26 | // TODO(kthelgason): Property stays here temporarily until a proper volume-api 27 | // is available on the surface exposed by webrtc. 28 | @property(nonatomic, assign) double volume; 29 | 30 | @end 31 | 32 | NS_ASSUME_NONNULL_END 33 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCAudioTrack.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | #import 13 | 14 | NS_ASSUME_NONNULL_BEGIN 15 | 16 | @class RTCAudioSource; 17 | 18 | RTC_EXPORT 19 | @interface RTCAudioTrack : RTCMediaStreamTrack 20 | 21 | - (instancetype)init NS_UNAVAILABLE; 22 | 23 | /** The audio source for this audio track. */ 24 | @property(nonatomic, readonly) RTCAudioSource *source; 25 | 26 | @end 27 | 28 | NS_ASSUME_NONNULL_END 29 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCCameraPreviewView.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC Project Authors. All rights reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | #import 13 | 14 | #import 15 | 16 | @class AVCaptureSession; 17 | @class RTCAVFoundationVideoSource; 18 | 19 | /** RTCCameraPreviewView is a view that renders local video from an 20 | * AVCaptureSession. 21 | */ 22 | RTC_EXPORT 23 | @interface RTCCameraPreviewView : UIView 24 | 25 | /** The capture session being rendered in the view. Capture session 26 | * is assigned to AVCaptureVideoPreviewLayer async in the same 27 | * queue that the AVCaptureSession is started/stopped. 28 | */ 29 | @property(nonatomic, strong) AVCaptureSession *captureSession; 30 | 31 | @end 32 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCCameraVideoCapturer.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2017 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | #import 13 | 14 | #import 15 | #import 16 | 17 | NS_ASSUME_NONNULL_BEGIN 18 | 19 | RTC_EXPORT 20 | // Camera capture that implements RTCVideoCapturer. Delivers frames to a RTCVideoCapturerDelegate 21 | // (usually RTCVideoSource). 22 | @interface RTCCameraVideoCapturer : RTCVideoCapturer 23 | 24 | // Capture session that is used for capturing. Valid from initialization to dealloc. 25 | @property(readonly, nonatomic) AVCaptureSession *captureSession; 26 | 27 | // Returns list of available capture devices that support video capture. 28 | + (NSArray *)captureDevices; 29 | // Returns list of formats that are supported by this class for this device. 30 | + (NSArray *)supportedFormatsForDevice:(AVCaptureDevice *)device; 31 | 32 | // Starts and stops the capture session asynchronously. 33 | - (void)startCaptureWithDevice:(AVCaptureDevice *)device 34 | format:(AVCaptureDeviceFormat *)format 35 | fps:(NSInteger)fps; 36 | // Stops the capture session asynchronously. 37 | - (void)stopCapture; 38 | 39 | @end 40 | 41 | NS_ASSUME_NONNULL_END 42 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCConfiguration.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | @class RTCIceServer; 16 | @class RTCIntervalRange; 17 | 18 | /** 19 | * Represents the ice transport policy. This exposes the same states in C++, 20 | * which include one more state than what exists in the W3C spec. 21 | */ 22 | typedef NS_ENUM(NSInteger, RTCIceTransportPolicy) { 23 | RTCIceTransportPolicyNone, 24 | RTCIceTransportPolicyRelay, 25 | RTCIceTransportPolicyNoHost, 26 | RTCIceTransportPolicyAll 27 | }; 28 | 29 | /** Represents the bundle policy. */ 30 | typedef NS_ENUM(NSInteger, RTCBundlePolicy) { 31 | RTCBundlePolicyBalanced, 32 | RTCBundlePolicyMaxCompat, 33 | RTCBundlePolicyMaxBundle 34 | }; 35 | 36 | /** Represents the rtcp mux policy. */ 37 | typedef NS_ENUM(NSInteger, RTCRtcpMuxPolicy) { 38 | RTCRtcpMuxPolicyNegotiate, 39 | RTCRtcpMuxPolicyRequire 40 | }; 41 | 42 | /** Represents the tcp candidate policy. */ 43 | typedef NS_ENUM(NSInteger, RTCTcpCandidatePolicy) { 44 | RTCTcpCandidatePolicyEnabled, 45 | RTCTcpCandidatePolicyDisabled 46 | }; 47 | 48 | /** Represents the candidate network policy. */ 49 | typedef NS_ENUM(NSInteger, RTCCandidateNetworkPolicy) { 50 | RTCCandidateNetworkPolicyAll, 51 | RTCCandidateNetworkPolicyLowCost 52 | }; 53 | 54 | /** Represents the continual gathering policy. */ 55 | typedef NS_ENUM(NSInteger, RTCContinualGatheringPolicy) { 56 | RTCContinualGatheringPolicyGatherOnce, 57 | RTCContinualGatheringPolicyGatherContinually 58 | }; 59 | 60 | /** Represents the encryption key type. */ 61 | typedef NS_ENUM(NSInteger, RTCEncryptionKeyType) { 62 | RTCEncryptionKeyTypeRSA, 63 | RTCEncryptionKeyTypeECDSA, 64 | }; 65 | 66 | NS_ASSUME_NONNULL_BEGIN 67 | 68 | RTC_EXPORT 69 | @interface RTCConfiguration : NSObject 70 | 71 | /** An array of Ice Servers available to be used by ICE. */ 72 | @property(nonatomic, copy) NSArray *iceServers; 73 | 74 | /** Which candidates the ICE agent is allowed to use. The W3C calls it 75 | * |iceTransportPolicy|, while in C++ it is called |type|. */ 76 | @property(nonatomic, assign) RTCIceTransportPolicy iceTransportPolicy; 77 | 78 | /** The media-bundling policy to use when gathering ICE candidates. */ 79 | @property(nonatomic, assign) RTCBundlePolicy bundlePolicy; 80 | 81 | /** The rtcp-mux policy to use when gathering ICE candidates. */ 82 | @property(nonatomic, assign) RTCRtcpMuxPolicy rtcpMuxPolicy; 83 | @property(nonatomic, assign) RTCTcpCandidatePolicy tcpCandidatePolicy; 84 | @property(nonatomic, assign) RTCCandidateNetworkPolicy candidateNetworkPolicy; 85 | @property(nonatomic, assign) 86 | RTCContinualGatheringPolicy continualGatheringPolicy; 87 | 88 | /** By default, the PeerConnection will use a limited number of IPv6 network 89 | * interfaces, in order to avoid too many ICE candidate pairs being created 90 | * and delaying ICE completion. 91 | * 92 | * Can be set to INT_MAX to effectively disable the limit. 93 | */ 94 | @property(nonatomic, assign) int maxIPv6Networks; 95 | 96 | @property(nonatomic, assign) int audioJitterBufferMaxPackets; 97 | @property(nonatomic, assign) BOOL audioJitterBufferFastAccelerate; 98 | @property(nonatomic, assign) int iceConnectionReceivingTimeout; 99 | @property(nonatomic, assign) int iceBackupCandidatePairPingInterval; 100 | 101 | /** Key type used to generate SSL identity. Default is ECDSA. */ 102 | @property(nonatomic, assign) RTCEncryptionKeyType keyType; 103 | 104 | /** ICE candidate pool size as defined in JSEP. Default is 0. */ 105 | @property(nonatomic, assign) int iceCandidatePoolSize; 106 | 107 | /** Prune turn ports on the same network to the same turn server. 108 | * Default is NO. 109 | */ 110 | @property(nonatomic, assign) BOOL shouldPruneTurnPorts; 111 | 112 | /** If set to YES, this means the ICE transport should presume TURN-to-TURN 113 | * candidate pairs will succeed, even before a binding response is received. 114 | */ 115 | @property(nonatomic, assign) BOOL shouldPresumeWritableWhenFullyRelayed; 116 | 117 | /** If set to non-nil, controls the minimal interval between consecutive ICE 118 | * check packets. 119 | */ 120 | @property(nonatomic, copy, nullable) NSNumber *iceCheckMinInterval; 121 | 122 | /** ICE Periodic Regathering 123 | * If set, WebRTC will periodically create and propose candidates without 124 | * starting a new ICE generation. The regathering happens continuously with 125 | * interval specified in milliseconds by the uniform distribution [a, b]. 126 | */ 127 | @property(nonatomic, strong, nullable) RTCIntervalRange *iceRegatherIntervalRange; 128 | 129 | - (instancetype)init; 130 | 131 | @end 132 | 133 | NS_ASSUME_NONNULL_END 134 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCDataChannel.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | #import 13 | 14 | #import 15 | 16 | NS_ASSUME_NONNULL_BEGIN 17 | 18 | RTC_EXPORT 19 | @interface RTCDataBuffer : NSObject 20 | 21 | /** NSData representation of the underlying buffer. */ 22 | @property(nonatomic, readonly) NSData *data; 23 | 24 | /** Indicates whether |data| contains UTF-8 or binary data. */ 25 | @property(nonatomic, readonly) BOOL isBinary; 26 | 27 | - (instancetype)init NS_UNAVAILABLE; 28 | 29 | /** 30 | * Initialize an RTCDataBuffer from NSData. |isBinary| indicates whether |data| 31 | * contains UTF-8 or binary data. 32 | */ 33 | - (instancetype)initWithData:(NSData *)data isBinary:(BOOL)isBinary; 34 | 35 | @end 36 | 37 | 38 | @class RTCDataChannel; 39 | RTC_EXPORT 40 | @protocol RTCDataChannelDelegate 41 | 42 | /** The data channel state changed. */ 43 | - (void)dataChannelDidChangeState:(RTCDataChannel *)dataChannel; 44 | 45 | /** The data channel successfully received a data buffer. */ 46 | - (void)dataChannel:(RTCDataChannel *)dataChannel 47 | didReceiveMessageWithBuffer:(RTCDataBuffer *)buffer; 48 | 49 | @optional 50 | /** The data channel's |bufferedAmount| changed. */ 51 | - (void)dataChannel:(RTCDataChannel *)dataChannel 52 | didChangeBufferedAmount:(uint64_t)amount; 53 | 54 | @end 55 | 56 | 57 | /** Represents the state of the data channel. */ 58 | typedef NS_ENUM(NSInteger, RTCDataChannelState) { 59 | RTCDataChannelStateConnecting, 60 | RTCDataChannelStateOpen, 61 | RTCDataChannelStateClosing, 62 | RTCDataChannelStateClosed, 63 | }; 64 | 65 | RTC_EXPORT 66 | @interface RTCDataChannel : NSObject 67 | 68 | /** 69 | * A label that can be used to distinguish this data channel from other data 70 | * channel objects. 71 | */ 72 | @property(nonatomic, readonly) NSString *label; 73 | 74 | /** Whether the data channel can send messages in unreliable mode. */ 75 | @property(nonatomic, readonly) BOOL isReliable DEPRECATED_ATTRIBUTE; 76 | 77 | /** Returns whether this data channel is ordered or not. */ 78 | @property(nonatomic, readonly) BOOL isOrdered; 79 | 80 | /** Deprecated. Use maxPacketLifeTime. */ 81 | @property(nonatomic, readonly) NSUInteger maxRetransmitTime 82 | DEPRECATED_ATTRIBUTE; 83 | 84 | /** 85 | * The length of the time window (in milliseconds) during which transmissions 86 | * and retransmissions may occur in unreliable mode. 87 | */ 88 | @property(nonatomic, readonly) uint16_t maxPacketLifeTime; 89 | 90 | /** 91 | * The maximum number of retransmissions that are attempted in unreliable mode. 92 | */ 93 | @property(nonatomic, readonly) uint16_t maxRetransmits; 94 | 95 | /** 96 | * The name of the sub-protocol used with this data channel, if any. Otherwise 97 | * this returns an empty string. 98 | */ 99 | @property(nonatomic, readonly) NSString *protocol; 100 | 101 | /** 102 | * Returns whether this data channel was negotiated by the application or not. 103 | */ 104 | @property(nonatomic, readonly) BOOL isNegotiated; 105 | 106 | /** Deprecated. Use channelId. */ 107 | @property(nonatomic, readonly) NSInteger streamId DEPRECATED_ATTRIBUTE; 108 | 109 | /** The identifier for this data channel. */ 110 | @property(nonatomic, readonly) int channelId; 111 | 112 | /** The state of the data channel. */ 113 | @property(nonatomic, readonly) RTCDataChannelState readyState; 114 | 115 | /** 116 | * The number of bytes of application data that have been queued using 117 | * |sendData:| but that have not yet been transmitted to the network. 118 | */ 119 | @property(nonatomic, readonly) uint64_t bufferedAmount; 120 | 121 | /** The delegate for this data channel. */ 122 | @property(nonatomic, weak) id delegate; 123 | 124 | - (instancetype)init NS_UNAVAILABLE; 125 | 126 | /** Closes the data channel. */ 127 | - (void)close; 128 | 129 | /** Attempt to send |data| on this data channel's underlying data transport. */ 130 | - (BOOL)sendData:(RTCDataBuffer *)data; 131 | 132 | @end 133 | 134 | NS_ASSUME_NONNULL_END 135 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCDataChannelConfiguration.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | #import 13 | 14 | #import 15 | 16 | NS_ASSUME_NONNULL_BEGIN 17 | 18 | RTC_EXPORT 19 | @interface RTCDataChannelConfiguration : NSObject 20 | 21 | /** Set to YES if ordered delivery is required. */ 22 | @property(nonatomic, assign) BOOL isOrdered; 23 | 24 | /** Deprecated. Use maxPacketLifeTime. */ 25 | @property(nonatomic, assign) NSInteger maxRetransmitTimeMs DEPRECATED_ATTRIBUTE; 26 | 27 | /** 28 | * Max period in milliseconds in which retransmissions will be sent. After this 29 | * time, no more retransmissions will be sent. -1 if unset. 30 | */ 31 | @property(nonatomic, assign) int maxPacketLifeTime; 32 | 33 | /** The max number of retransmissions. -1 if unset. */ 34 | @property(nonatomic, assign) int maxRetransmits; 35 | 36 | /** Set to YES if the channel has been externally negotiated and we do not send 37 | * an in-band signalling in the form of an "open" message. 38 | */ 39 | @property(nonatomic, assign) BOOL isNegotiated; 40 | 41 | /** Deprecated. Use channelId. */ 42 | @property(nonatomic, assign) int streamId DEPRECATED_ATTRIBUTE; 43 | 44 | /** The id of the data channel. */ 45 | @property(nonatomic, assign) int channelId; 46 | 47 | /** Set by the application and opaque to the WebRTC implementation. */ 48 | @property(nonatomic) NSString *protocol; 49 | 50 | @end 51 | 52 | NS_ASSUME_NONNULL_END 53 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCDispatcher.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | typedef NS_ENUM(NSInteger, RTCDispatcherQueueType) { 16 | // Main dispatcher queue. 17 | RTCDispatcherTypeMain, 18 | // Used for starting/stopping AVCaptureSession, and assigning 19 | // capture session to AVCaptureVideoPreviewLayer. 20 | RTCDispatcherTypeCaptureSession, 21 | // Used for operations on AVAudioSession. 22 | RTCDispatcherTypeAudioSession, 23 | }; 24 | 25 | /** Dispatcher that asynchronously dispatches blocks to a specific 26 | * shared dispatch queue. 27 | */ 28 | RTC_EXPORT 29 | @interface RTCDispatcher : NSObject 30 | 31 | - (instancetype)init NS_UNAVAILABLE; 32 | 33 | /** Dispatch the block asynchronously on the queue for dispatchType. 34 | * @param dispatchType The queue type to dispatch on. 35 | * @param block The block to dispatch asynchronously. 36 | */ 37 | + (void)dispatchAsyncOnType:(RTCDispatcherQueueType)dispatchType 38 | block:(dispatch_block_t)block; 39 | 40 | /** Returns YES if run on queue for the dispatchType otherwise NO. 41 | * Useful for asserting that a method is run on a correct queue. 42 | */ 43 | + (BOOL)isOnQueueForType:(RTCDispatcherQueueType)dispatchType; 44 | 45 | @end 46 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCEAGLVideoView.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | #import 13 | 14 | #import 15 | #import 16 | #import 17 | 18 | NS_ASSUME_NONNULL_BEGIN 19 | 20 | @class RTCEAGLVideoView; 21 | RTC_EXPORT 22 | @protocol RTCEAGLVideoViewDelegate 23 | 24 | - (void)videoView:(RTCEAGLVideoView *)videoView didChangeVideoSize:(CGSize)size; 25 | 26 | @end 27 | 28 | /** 29 | * RTCEAGLVideoView is an RTCVideoRenderer which renders video frames in its 30 | * bounds using OpenGLES 2.0 or OpenGLES 3.0. 31 | */ 32 | RTC_EXPORT 33 | @interface RTCEAGLVideoView : UIView 34 | 35 | @property(nonatomic, weak) id delegate; 36 | 37 | - (instancetype)initWithFrame:(CGRect)frame 38 | shader:(id)shader NS_DESIGNATED_INITIALIZER; 39 | 40 | - (instancetype)initWithCoder:(NSCoder *)aDecoder 41 | shader:(id)shader NS_DESIGNATED_INITIALIZER; 42 | 43 | @end 44 | 45 | NS_ASSUME_NONNULL_END 46 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCFieldTrials.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC Project Authors. All rights reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | /** The only valid value for the following if set is kRTCFieldTrialEnabledValue. */ 16 | RTC_EXTERN NSString * const kRTCFieldTrialAudioSendSideBweKey; 17 | RTC_EXTERN NSString * const kRTCFieldTrialSendSideBweWithOverheadKey; 18 | RTC_EXTERN NSString * const kRTCFieldTrialFlexFec03AdvertisedKey; 19 | RTC_EXTERN NSString * const kRTCFieldTrialFlexFec03Key; 20 | RTC_EXTERN NSString * const kRTCFieldTrialImprovedBitrateEstimateKey; 21 | RTC_EXTERN NSString * const kRTCFieldTrialH264HighProfileKey; 22 | RTC_EXTERN NSString * const kRTCFieldTrialMinimizeResamplingOnMobileKey; 23 | 24 | /** The valid value for field trials above. */ 25 | RTC_EXTERN NSString * const kRTCFieldTrialEnabledValue; 26 | 27 | /** Use a string returned by RTCFieldTrialMedianSlopeFilterValue as the value. */ 28 | RTC_EXTERN NSString * const kRTCFieldTrialMedianSlopeFilterKey; 29 | RTC_EXTERN NSString *RTCFieldTrialMedianSlopeFilterValue( 30 | size_t windowSize, double thresholdGain); 31 | 32 | /** Use a string returned by RTCFieldTrialTrendlineFilterValue as the value. */ 33 | RTC_EXTERN NSString * const kRTCFieldTrialTrendlineFilterKey; 34 | /** Returns a valid value for kRTCFieldTrialTrendlineFilterKey. */ 35 | RTC_EXTERN NSString *RTCFieldTrialTrendlineFilterValue( 36 | size_t windowSize, double smoothingCoeff, double thresholdGain); 37 | 38 | /** Initialize field trials using a dictionary mapping field trial keys to their values. See above 39 | * for valid keys and values. 40 | * Must be called before any other call into WebRTC. See: 41 | * webrtc/system_wrappers/include/field_trial_default.h 42 | */ 43 | RTC_EXTERN void RTCInitFieldTrialDictionary(NSDictionary *fieldTrials); 44 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCFileLogger.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | typedef NS_ENUM(NSUInteger, RTCFileLoggerSeverity) { 16 | RTCFileLoggerSeverityVerbose, 17 | RTCFileLoggerSeverityInfo, 18 | RTCFileLoggerSeverityWarning, 19 | RTCFileLoggerSeverityError 20 | }; 21 | 22 | typedef NS_ENUM(NSUInteger, RTCFileLoggerRotationType) { 23 | RTCFileLoggerTypeCall, 24 | RTCFileLoggerTypeApp, 25 | }; 26 | 27 | NS_ASSUME_NONNULL_BEGIN 28 | 29 | // This class intercepts WebRTC logs and saves them to a file. The file size 30 | // will not exceed the given maximum bytesize. When the maximum bytesize is 31 | // reached, logs are rotated according to the rotationType specified. 32 | // For kRTCFileLoggerTypeCall, logs from the beginning and the end 33 | // are preserved while the middle section is overwritten instead. 34 | // For kRTCFileLoggerTypeApp, the oldest log is overwritten. 35 | // This class is not threadsafe. 36 | RTC_EXPORT 37 | @interface RTCFileLogger : NSObject 38 | 39 | // The severity level to capture. The default is kRTCFileLoggerSeverityInfo. 40 | @property(nonatomic, assign) RTCFileLoggerSeverity severity; 41 | 42 | // The rotation type for this file logger. The default is 43 | // kRTCFileLoggerTypeCall. 44 | @property(nonatomic, readonly) RTCFileLoggerRotationType rotationType; 45 | 46 | // Disables buffering disk writes. Should be set before |start|. Buffering 47 | // is enabled by default for performance. 48 | @property(nonatomic, assign) BOOL shouldDisableBuffering; 49 | 50 | // Default constructor provides default settings for dir path, file size and 51 | // rotation type. 52 | - (instancetype)init; 53 | 54 | // Create file logger with default rotation type. 55 | - (instancetype)initWithDirPath:(NSString *)dirPath 56 | maxFileSize:(NSUInteger)maxFileSize; 57 | 58 | - (instancetype)initWithDirPath:(NSString *)dirPath 59 | maxFileSize:(NSUInteger)maxFileSize 60 | rotationType:(RTCFileLoggerRotationType)rotationType 61 | NS_DESIGNATED_INITIALIZER; 62 | 63 | // Starts writing WebRTC logs to disk if not already started. Overwrites any 64 | // existing file(s). 65 | - (void)start; 66 | 67 | // Stops writing WebRTC logs to disk. This method is also called on dealloc. 68 | - (void)stop; 69 | 70 | // Returns the current contents of the logs, or nil if start has been called 71 | // without a stop. 72 | - (NSData *)logData; 73 | 74 | @end 75 | 76 | NS_ASSUME_NONNULL_END 77 | 78 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCIceCandidate.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | NS_ASSUME_NONNULL_BEGIN 16 | 17 | RTC_EXPORT 18 | @interface RTCIceCandidate : NSObject 19 | 20 | /** 21 | * If present, the identifier of the "media stream identification" for the media 22 | * component this candidate is associated with. 23 | */ 24 | @property(nonatomic, readonly, nullable) NSString *sdpMid; 25 | 26 | /** 27 | * The index (starting at zero) of the media description this candidate is 28 | * associated with in the SDP. 29 | */ 30 | @property(nonatomic, readonly) int sdpMLineIndex; 31 | 32 | /** The SDP string for this candidate. */ 33 | @property(nonatomic, readonly) NSString *sdp; 34 | 35 | /** The URL of the ICE server which this candidate is gathered from. */ 36 | @property(nonatomic, readonly, nullable) NSString *serverUrl; 37 | 38 | - (instancetype)init NS_UNAVAILABLE; 39 | 40 | /** 41 | * Initialize an RTCIceCandidate from SDP. 42 | */ 43 | - (instancetype)initWithSdp:(NSString *)sdp 44 | sdpMLineIndex:(int)sdpMLineIndex 45 | sdpMid:(nullable NSString *)sdpMid 46 | NS_DESIGNATED_INITIALIZER; 47 | 48 | @end 49 | 50 | NS_ASSUME_NONNULL_END 51 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCIceServer.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | typedef NS_ENUM(NSUInteger, RTCTlsCertPolicy) { 16 | RTCTlsCertPolicySecure, 17 | RTCTlsCertPolicyInsecureNoCheck 18 | }; 19 | 20 | NS_ASSUME_NONNULL_BEGIN 21 | 22 | RTC_EXPORT 23 | @interface RTCIceServer : NSObject 24 | 25 | /** URI(s) for this server represented as NSStrings. */ 26 | @property(nonatomic, readonly) NSArray *urlStrings; 27 | 28 | /** Username to use if this RTCIceServer object is a TURN server. */ 29 | @property(nonatomic, readonly, nullable) NSString *username; 30 | 31 | /** Credential to use if this RTCIceServer object is a TURN server. */ 32 | @property(nonatomic, readonly, nullable) NSString *credential; 33 | 34 | /** 35 | * TLS certificate policy to use if this RTCIceServer object is a TURN server. 36 | */ 37 | @property(nonatomic, readonly) RTCTlsCertPolicy tlsCertPolicy; 38 | 39 | /** 40 | If the URIs in |urls| only contain IP addresses, this field can be used 41 | to indicate the hostname, which may be necessary for TLS (using the SNI 42 | extension). If |urls| itself contains the hostname, this isn't necessary. 43 | */ 44 | @property(nonatomic, readonly, nullable) NSString *hostname; 45 | 46 | - (nonnull instancetype)init NS_UNAVAILABLE; 47 | 48 | /** Convenience initializer for a server with no authentication (e.g. STUN). */ 49 | - (instancetype)initWithURLStrings:(NSArray *)urlStrings; 50 | 51 | /** 52 | * Initialize an RTCIceServer with its associated URLs, optional username, 53 | * optional credential, and credentialType. 54 | */ 55 | - (instancetype)initWithURLStrings:(NSArray *)urlStrings 56 | username:(nullable NSString *)username 57 | credential:(nullable NSString *)credential; 58 | 59 | /** 60 | * Initialize an RTCIceServer with its associated URLs, optional username, 61 | * optional credential, and TLS cert policy. 62 | */ 63 | - (instancetype)initWithURLStrings:(NSArray *)urlStrings 64 | username:(nullable NSString *)username 65 | credential:(nullable NSString *)credential 66 | tlsCertPolicy:(RTCTlsCertPolicy)tlsCertPolicy; 67 | 68 | /** 69 | * Initialize an RTCIceServer with its associated URLs, optional username, 70 | * optional credential, TLS cert policy and hostname. 71 | */ 72 | - (instancetype)initWithURLStrings:(NSArray *)urlStrings 73 | username:(nullable NSString *)username 74 | credential:(nullable NSString *)credential 75 | tlsCertPolicy:(RTCTlsCertPolicy)tlsCertPolicy 76 | hostname:(nullable NSString *)hostname NS_DESIGNATED_INITIALIZER; 77 | 78 | @end 79 | 80 | NS_ASSUME_NONNULL_END 81 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCIntervalRange.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2017 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | NS_ASSUME_NONNULL_BEGIN 14 | 15 | @interface RTCIntervalRange : NSObject 16 | 17 | @property(nonatomic, readonly) NSInteger min; 18 | @property(nonatomic, readonly) NSInteger max; 19 | 20 | - (instancetype)init; 21 | - (instancetype)initWithMin:(NSInteger)min 22 | max:(NSInteger)max 23 | NS_DESIGNATED_INITIALIZER; 24 | 25 | @end 26 | 27 | NS_ASSUME_NONNULL_END 28 | 29 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCLegacyStatsReport.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | NS_ASSUME_NONNULL_BEGIN 16 | 17 | /** This does not currently conform to the spec. */ 18 | RTC_EXPORT 19 | @interface RTCLegacyStatsReport : NSObject 20 | 21 | /** Time since 1970-01-01T00:00:00Z in milliseconds. */ 22 | @property(nonatomic, readonly) CFTimeInterval timestamp; 23 | 24 | /** The type of stats held by this object. */ 25 | @property(nonatomic, readonly) NSString *type; 26 | 27 | /** The identifier for this object. */ 28 | @property(nonatomic, readonly) NSString *reportId; 29 | 30 | /** A dictionary holding the actual stats. */ 31 | @property(nonatomic, readonly) NSDictionary *values; 32 | 33 | - (instancetype)init NS_UNAVAILABLE; 34 | 35 | @end 36 | 37 | NS_ASSUME_NONNULL_END 38 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCLogging.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | // Subset of rtc::LoggingSeverity. 16 | typedef NS_ENUM(NSInteger, RTCLoggingSeverity) { 17 | RTCLoggingSeverityVerbose, 18 | RTCLoggingSeverityInfo, 19 | RTCLoggingSeverityWarning, 20 | RTCLoggingSeverityError, 21 | }; 22 | 23 | // Wrapper for C++ LOG(sev) macros. 24 | // Logs the log string to the webrtc logstream for the given severity. 25 | RTC_EXTERN void RTCLogEx(RTCLoggingSeverity severity, NSString* log_string); 26 | 27 | // Wrapper for rtc::LogMessage::LogToDebug. 28 | // Sets the minimum severity to be logged to console. 29 | RTC_EXTERN void RTCSetMinDebugLogLevel(RTCLoggingSeverity severity); 30 | 31 | // Returns the filename with the path prefix removed. 32 | RTC_EXTERN NSString* RTCFileName(const char* filePath); 33 | 34 | // Some convenience macros. 35 | 36 | #define RTCLogString(format, ...) \ 37 | [NSString stringWithFormat:@"(%@:%d %s): " format, \ 38 | RTCFileName(__FILE__), \ 39 | __LINE__, \ 40 | __FUNCTION__, \ 41 | ##__VA_ARGS__] 42 | 43 | #define RTCLogFormat(severity, format, ...) \ 44 | do { \ 45 | NSString* log_string = RTCLogString(format, ##__VA_ARGS__); \ 46 | RTCLogEx(severity, log_string); \ 47 | } while (false) 48 | 49 | #define RTCLogVerbose(format, ...) \ 50 | RTCLogFormat(RTCLoggingSeverityVerbose, format, ##__VA_ARGS__) \ 51 | 52 | #define RTCLogInfo(format, ...) \ 53 | RTCLogFormat(RTCLoggingSeverityInfo, format, ##__VA_ARGS__) \ 54 | 55 | #define RTCLogWarning(format, ...) \ 56 | RTCLogFormat(RTCLoggingSeverityWarning, format, ##__VA_ARGS__) \ 57 | 58 | #define RTCLogError(format, ...) \ 59 | RTCLogFormat(RTCLoggingSeverityError, format, ##__VA_ARGS__) \ 60 | 61 | #if !defined(NDEBUG) 62 | #define RTCLogDebug(format, ...) RTCLogInfo(format, ##__VA_ARGS__) 63 | #else 64 | #define RTCLogDebug(format, ...) \ 65 | do { \ 66 | } while (false) 67 | #endif 68 | 69 | #define RTCLog(format, ...) RTCLogInfo(format, ##__VA_ARGS__) 70 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCMTLVideoView.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2017 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import "WebRTC/RTCVideoRenderer.h" 14 | 15 | // Check if metal is supported in WebRTC. 16 | // NOTE: Currently arm64 == Metal. 17 | #if defined(__aarch64__) 18 | #define RTC_SUPPORTS_METAL 19 | #endif 20 | 21 | NS_ASSUME_NONNULL_BEGIN 22 | 23 | /** 24 | * RTCMTLVideoView is thin wrapper around MTKView. 25 | * 26 | * It has id property that renders video frames in the view's 27 | * bounds using Metal. 28 | * NOTE: always check if metal is available on the running device via 29 | * RTC_SUPPORTS_METAL macro before initializing this class. 30 | */ 31 | NS_CLASS_AVAILABLE_IOS(9) 32 | 33 | RTC_EXPORT 34 | @interface RTCMTLVideoView : UIView 35 | 36 | @end 37 | NS_ASSUME_NONNULL_END 38 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCMacros.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC Project Authors. All rights reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #ifndef WEBRTC_SDK_OBJC_FRAMEWORK_HEADERS_WEBRTC_RTCMACROS_H_ 12 | #define WEBRTC_SDK_OBJC_FRAMEWORK_HEADERS_WEBRTC_RTCMACROS_H_ 13 | 14 | #define RTC_EXPORT __attribute__((visibility("default"))) 15 | 16 | #if defined(__cplusplus) 17 | #define RTC_EXTERN extern "C" RTC_EXPORT 18 | #else 19 | #define RTC_EXTERN extern RTC_EXPORT 20 | #endif 21 | 22 | #ifdef __OBJC__ 23 | #define RTC_FWD_DECL_OBJC_CLASS(classname) @class classname 24 | #else 25 | #define RTC_FWD_DECL_OBJC_CLASS(classname) typedef struct objc_object classname 26 | #endif 27 | 28 | #endif // WEBRTC_SDK_OBJC_FRAMEWORK_HEADERS_WEBRTC_RTCMACROS_H_ 29 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCMediaConstraints.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | NS_ASSUME_NONNULL_BEGIN 16 | 17 | /** Constraint keys for media sources. */ 18 | RTC_EXTERN NSString * const kRTCMediaConstraintsMinAspectRatio; 19 | RTC_EXTERN NSString * const kRTCMediaConstraintsMaxAspectRatio; 20 | RTC_EXTERN NSString * const kRTCMediaConstraintsMaxWidth; 21 | RTC_EXTERN NSString * const kRTCMediaConstraintsMinWidth; 22 | RTC_EXTERN NSString * const kRTCMediaConstraintsMaxHeight; 23 | RTC_EXTERN NSString * const kRTCMediaConstraintsMinHeight; 24 | RTC_EXTERN NSString * const kRTCMediaConstraintsMaxFrameRate; 25 | RTC_EXTERN NSString * const kRTCMediaConstraintsMinFrameRate; 26 | RTC_EXTERN NSString * const kRTCMediaConstraintsLevelControl; 27 | /** The value for this key should be a base64 encoded string containing 28 | * the data from the serialized configuration proto. 29 | */ 30 | RTC_EXTERN NSString * const kRTCMediaConstraintsAudioNetworkAdaptorConfig; 31 | 32 | /** Constraint keys for generating offers and answers. */ 33 | RTC_EXTERN NSString * const kRTCMediaConstraintsIceRestart; 34 | RTC_EXTERN NSString * const kRTCMediaConstraintsOfferToReceiveAudio; 35 | RTC_EXTERN NSString * const kRTCMediaConstraintsOfferToReceiveVideo; 36 | RTC_EXTERN NSString * const kRTCMediaConstraintsVoiceActivityDetection; 37 | 38 | /** Constraint values for Boolean parameters. */ 39 | RTC_EXTERN NSString * const kRTCMediaConstraintsValueTrue; 40 | RTC_EXTERN NSString * const kRTCMediaConstraintsValueFalse; 41 | 42 | RTC_EXPORT 43 | @interface RTCMediaConstraints : NSObject 44 | 45 | - (instancetype)init NS_UNAVAILABLE; 46 | 47 | /** Initialize with mandatory and/or optional constraints. */ 48 | - (instancetype)initWithMandatoryConstraints: 49 | (nullable NSDictionary *)mandatory 50 | optionalConstraints: 51 | (nullable NSDictionary *)optional 52 | NS_DESIGNATED_INITIALIZER; 53 | 54 | @end 55 | 56 | NS_ASSUME_NONNULL_END 57 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCMediaSource.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | typedef NS_ENUM(NSInteger, RTCSourceState) { 16 | RTCSourceStateInitializing, 17 | RTCSourceStateLive, 18 | RTCSourceStateEnded, 19 | RTCSourceStateMuted, 20 | }; 21 | 22 | NS_ASSUME_NONNULL_BEGIN 23 | 24 | RTC_EXPORT 25 | @interface RTCMediaSource : NSObject 26 | 27 | /** The current state of the RTCMediaSource. */ 28 | @property(nonatomic, readonly) RTCSourceState state; 29 | 30 | - (instancetype)init NS_UNAVAILABLE; 31 | 32 | @end 33 | 34 | NS_ASSUME_NONNULL_END 35 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCMediaStream.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | NS_ASSUME_NONNULL_BEGIN 16 | 17 | @class RTCAudioTrack; 18 | @class RTCPeerConnectionFactory; 19 | @class RTCVideoTrack; 20 | 21 | RTC_EXPORT 22 | @interface RTCMediaStream : NSObject 23 | 24 | /** The audio tracks in this stream. */ 25 | @property(nonatomic, strong, readonly) NSArray *audioTracks; 26 | 27 | /** The video tracks in this stream. */ 28 | @property(nonatomic, strong, readonly) NSArray *videoTracks; 29 | 30 | /** An identifier for this media stream. */ 31 | @property(nonatomic, readonly) NSString *streamId; 32 | 33 | - (instancetype)init NS_UNAVAILABLE; 34 | 35 | /** Adds the given audio track to this media stream. */ 36 | - (void)addAudioTrack:(RTCAudioTrack *)audioTrack; 37 | 38 | /** Adds the given video track to this media stream. */ 39 | - (void)addVideoTrack:(RTCVideoTrack *)videoTrack; 40 | 41 | /** Removes the given audio track to this media stream. */ 42 | - (void)removeAudioTrack:(RTCAudioTrack *)audioTrack; 43 | 44 | /** Removes the given video track to this media stream. */ 45 | - (void)removeVideoTrack:(RTCVideoTrack *)videoTrack; 46 | 47 | @end 48 | 49 | NS_ASSUME_NONNULL_END 50 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCMediaStreamTrack.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | /** 16 | * Represents the state of the track. This exposes the same states in C++. 17 | */ 18 | typedef NS_ENUM(NSInteger, RTCMediaStreamTrackState) { 19 | RTCMediaStreamTrackStateLive, 20 | RTCMediaStreamTrackStateEnded 21 | }; 22 | 23 | NS_ASSUME_NONNULL_BEGIN 24 | 25 | RTC_EXTERN NSString * const kRTCMediaStreamTrackKindAudio; 26 | RTC_EXTERN NSString * const kRTCMediaStreamTrackKindVideo; 27 | 28 | RTC_EXPORT 29 | @interface RTCMediaStreamTrack : NSObject 30 | 31 | /** 32 | * The kind of track. For example, "audio" if this track represents an audio 33 | * track and "video" if this track represents a video track. 34 | */ 35 | @property(nonatomic, readonly) NSString *kind; 36 | 37 | /** An identifier string. */ 38 | @property(nonatomic, readonly) NSString *trackId; 39 | 40 | /** The enabled state of the track. */ 41 | @property(nonatomic, assign) BOOL isEnabled; 42 | 43 | /** The state of the track. */ 44 | @property(nonatomic, readonly) RTCMediaStreamTrackState readyState; 45 | 46 | - (instancetype)init NS_UNAVAILABLE; 47 | 48 | @end 49 | 50 | NS_ASSUME_NONNULL_END 51 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCMetrics.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | #import 15 | 16 | /** 17 | * Enables gathering of metrics (which can be fetched with 18 | * RTCGetAndResetMetrics). Must be called before any other call into WebRTC. 19 | */ 20 | RTC_EXTERN void RTCEnableMetrics(); 21 | 22 | /** Gets and clears native histograms. */ 23 | RTC_EXTERN NSArray *RTCGetAndResetMetrics(); 24 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCMetricsSampleInfo.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | NS_ASSUME_NONNULL_BEGIN 16 | 17 | RTC_EXPORT 18 | @interface RTCMetricsSampleInfo : NSObject 19 | 20 | /** 21 | * Example of RTCMetricsSampleInfo: 22 | * name: "WebRTC.Video.InputFramesPerSecond" 23 | * min: 1 24 | * max: 100 25 | * bucketCount: 50 26 | * samples: [29]:2 [30]:1 27 | */ 28 | 29 | /** The name of the histogram. */ 30 | @property(nonatomic, readonly) NSString *name; 31 | 32 | /** The minimum bucket value. */ 33 | @property(nonatomic, readonly) int min; 34 | 35 | /** The maximum bucket value. */ 36 | @property(nonatomic, readonly) int max; 37 | 38 | /** The number of buckets. */ 39 | @property(nonatomic, readonly) int bucketCount; 40 | 41 | /** A dictionary holding the samples . */ 42 | @property(nonatomic, readonly) NSDictionary *samples; 43 | 44 | - (instancetype)init NS_UNAVAILABLE; 45 | 46 | @end 47 | 48 | NS_ASSUME_NONNULL_END 49 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCPeerConnectionFactory.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | NS_ASSUME_NONNULL_BEGIN 16 | 17 | @class RTCAVFoundationVideoSource; 18 | @class RTCAudioSource; 19 | @class RTCAudioTrack; 20 | @class RTCConfiguration; 21 | @class RTCMediaConstraints; 22 | @class RTCMediaStream; 23 | @class RTCPeerConnection; 24 | @class RTCVideoSource; 25 | @class RTCVideoTrack; 26 | @protocol RTCPeerConnectionDelegate; 27 | @protocol RTCVideoEncoderFactory; 28 | @protocol RTCVideoDecoderFactory; 29 | 30 | RTC_EXPORT 31 | @interface RTCPeerConnectionFactory : NSObject 32 | 33 | /* Initialize object with default H264 video encoder/decoder factories */ 34 | - (instancetype)init; 35 | 36 | /* Initialize object with injectable video encoder/decoder factories */ 37 | - (instancetype)initWithEncoderFactory:(nullable id)encoderFactory 38 | decoderFactory:(nullable id)decoderFactory 39 | NS_DESIGNATED_INITIALIZER; 40 | 41 | /** Initialize an RTCAudioSource with constraints. */ 42 | - (RTCAudioSource *)audioSourceWithConstraints:(nullable RTCMediaConstraints *)constraints; 43 | 44 | /** Initialize an RTCAudioTrack with an id. Convenience ctor to use an audio source with no 45 | * constraints. 46 | */ 47 | - (RTCAudioTrack *)audioTrackWithTrackId:(NSString *)trackId; 48 | 49 | /** Initialize an RTCAudioTrack with a source and an id. */ 50 | - (RTCAudioTrack *)audioTrackWithSource:(RTCAudioSource *)source 51 | trackId:(NSString *)trackId; 52 | 53 | /** Initialize an RTCAVFoundationVideoSource with constraints. */ 54 | - (RTCAVFoundationVideoSource *)avFoundationVideoSourceWithConstraints: 55 | (nullable RTCMediaConstraints *)constraints; 56 | 57 | /** Initialize a generic RTCVideoSource. The RTCVideoSource should be passed to a RTCVideoCapturer 58 | * implementation, e.g. RTCCameraVideoCapturer, in order to produce frames. 59 | */ 60 | - (RTCVideoSource *)videoSource; 61 | 62 | /** Initialize an RTCVideoTrack with a source and an id. */ 63 | - (RTCVideoTrack *)videoTrackWithSource:(RTCVideoSource *)source 64 | trackId:(NSString *)trackId; 65 | 66 | /** Initialize an RTCMediaStream with an id. */ 67 | - (RTCMediaStream *)mediaStreamWithStreamId:(NSString *)streamId; 68 | 69 | /** Initialize an RTCPeerConnection with a configuration, constraints, and 70 | * delegate. 71 | */ 72 | - (RTCPeerConnection *)peerConnectionWithConfiguration: 73 | (RTCConfiguration *)configuration 74 | constraints: 75 | (RTCMediaConstraints *)constraints 76 | delegate: 77 | (nullable id)delegate; 78 | 79 | /** Start an AecDump recording. This API call will likely change in the future. */ 80 | - (BOOL)startAecDumpWithFilePath:(NSString *)filePath 81 | maxSizeInBytes:(int64_t)maxSizeInBytes; 82 | 83 | /* Stop an active AecDump recording */ 84 | - (void)stopAecDump; 85 | 86 | @end 87 | 88 | NS_ASSUME_NONNULL_END 89 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCRtpCodecParameters.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | NS_ASSUME_NONNULL_BEGIN 16 | 17 | RTC_EXTERN const NSString * const kRTCRtxCodecName; 18 | RTC_EXTERN const NSString * const kRTCRedCodecName; 19 | RTC_EXTERN const NSString * const kRTCUlpfecCodecName; 20 | RTC_EXTERN const NSString * const kRTCFlexfecCodecName; 21 | RTC_EXTERN const NSString * const kRTCOpusCodecName; 22 | RTC_EXTERN const NSString * const kRTCIsacCodecName; 23 | RTC_EXTERN const NSString * const kRTCL16CodecName; 24 | RTC_EXTERN const NSString * const kRTCG722CodecName; 25 | RTC_EXTERN const NSString * const kRTCIlbcCodecName; 26 | RTC_EXTERN const NSString * const kRTCPcmuCodecName; 27 | RTC_EXTERN const NSString * const kRTCPcmaCodecName; 28 | RTC_EXTERN const NSString * const kRTCDtmfCodecName; 29 | RTC_EXTERN const NSString * const kRTCComfortNoiseCodecName; 30 | RTC_EXTERN const NSString * const kRTCVp8CodecName; 31 | RTC_EXTERN const NSString * const kRTCVp9CodecName; 32 | RTC_EXTERN const NSString * const kRTCH264CodecName; 33 | 34 | /** Defined in http://w3c.github.io/webrtc-pc/#idl-def-RTCRtpCodecParameters */ 35 | RTC_EXPORT 36 | @interface RTCRtpCodecParameters : NSObject 37 | 38 | /** The RTP payload type. */ 39 | @property(nonatomic, assign) int payloadType; 40 | 41 | /** 42 | * The codec MIME subtype. Valid types are listed in: 43 | * http://www.iana.org/assignments/rtp-parameters/rtp-parameters.xhtml#rtp-parameters-2 44 | * 45 | * Several supported types are represented by the constants above. 46 | */ 47 | @property(nonatomic, readonly, nonnull) NSString *name; 48 | 49 | /** 50 | * The media type of this codec. Equivalent to MIME top-level type. 51 | * 52 | * Valid values are kRTCMediaStreamTrackKindAudio and 53 | * kRTCMediaStreamTrackKindVideo. 54 | */ 55 | @property(nonatomic, readonly, nonnull) NSString *kind; 56 | 57 | /** The codec clock rate expressed in Hertz. */ 58 | @property(nonatomic, readonly, nullable) NSNumber *clockRate; 59 | 60 | /** 61 | * The number of channels (mono=1, stereo=2). 62 | * Set to null for video codecs. 63 | **/ 64 | @property(nonatomic, readonly, nullable) NSNumber *numChannels; 65 | 66 | - (instancetype)init NS_DESIGNATED_INITIALIZER; 67 | 68 | @end 69 | 70 | NS_ASSUME_NONNULL_END 71 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCRtpEncodingParameters.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | NS_ASSUME_NONNULL_BEGIN 16 | 17 | RTC_EXPORT 18 | @interface RTCRtpEncodingParameters : NSObject 19 | 20 | /** Controls whether the encoding is currently transmitted. */ 21 | @property(nonatomic, assign) BOOL isActive; 22 | 23 | /** The maximum bitrate to use for the encoding, or nil if there is no 24 | * limit. 25 | */ 26 | @property(nonatomic, copy, nullable) NSNumber *maxBitrateBps; 27 | 28 | /** The SSRC being used by this encoding. */ 29 | @property(nonatomic, readonly, nullable) NSNumber *ssrc; 30 | 31 | - (instancetype)init NS_DESIGNATED_INITIALIZER; 32 | 33 | @end 34 | 35 | NS_ASSUME_NONNULL_END 36 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCRtpParameters.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | #import 15 | #import 16 | 17 | NS_ASSUME_NONNULL_BEGIN 18 | 19 | RTC_EXPORT 20 | @interface RTCRtpParameters : NSObject 21 | 22 | /** The currently active encodings in the order of preference. */ 23 | @property(nonatomic, copy) NSArray *encodings; 24 | 25 | /** The negotiated set of send codecs in order of preference. */ 26 | @property(nonatomic, copy) NSArray *codecs; 27 | 28 | - (instancetype)init NS_DESIGNATED_INITIALIZER; 29 | 30 | @end 31 | 32 | NS_ASSUME_NONNULL_END 33 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCRtpReceiver.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | #import 15 | #import 16 | 17 | NS_ASSUME_NONNULL_BEGIN 18 | 19 | /** Represents the media type of the RtpReceiver. */ 20 | typedef NS_ENUM(NSInteger, RTCRtpMediaType) { 21 | RTCRtpMediaTypeAudio, 22 | RTCRtpMediaTypeVideo, 23 | RTCRtpMediaTypeData, 24 | }; 25 | 26 | @class RTCRtpReceiver; 27 | 28 | RTC_EXPORT 29 | @protocol RTCRtpReceiverDelegate 30 | 31 | /** Called when the first RTP packet is received. 32 | * 33 | * Note: Currently if there are multiple RtpReceivers of the same media type, 34 | * they will all call OnFirstPacketReceived at once. 35 | * 36 | * For example, if we create three audio receivers, A/B/C, they will listen to 37 | * the same signal from the underneath network layer. Whenever the first audio packet 38 | * is received, the underneath signal will be fired. All the receivers A/B/C will be 39 | * notified and the callback of the receiver's delegate will be called. 40 | * 41 | * The process is the same for video receivers. 42 | */ 43 | - (void)rtpReceiver:(RTCRtpReceiver *)rtpReceiver 44 | didReceiveFirstPacketForMediaType:(RTCRtpMediaType)mediaType; 45 | 46 | @end 47 | 48 | RTC_EXPORT 49 | @protocol RTCRtpReceiver 50 | 51 | /** A unique identifier for this receiver. */ 52 | @property(nonatomic, readonly) NSString *receiverId; 53 | 54 | /** The currently active RTCRtpParameters, as defined in 55 | * https://www.w3.org/TR/webrtc/#idl-def-RTCRtpParameters. 56 | * 57 | * The WebRTC specification only defines RTCRtpParameters in terms of senders, 58 | * but this API also applies them to receivers, similar to ORTC: 59 | * http://ortc.org/wp-content/uploads/2016/03/ortc.html#rtcrtpparameters*. 60 | */ 61 | @property(nonatomic, readonly) RTCRtpParameters *parameters; 62 | 63 | /** The RTCMediaStreamTrack associated with the receiver. 64 | * Note: reading this property returns a new instance of 65 | * RTCMediaStreamTrack. Use isEqual: instead of == to compare 66 | * RTCMediaStreamTrack instances. 67 | */ 68 | @property(nonatomic, readonly) RTCMediaStreamTrack *track; 69 | 70 | /** The delegate for this RtpReceiver. */ 71 | @property(nonatomic, weak) id delegate; 72 | 73 | @end 74 | 75 | RTC_EXPORT 76 | @interface RTCRtpReceiver : NSObject 77 | 78 | - (instancetype)init NS_UNAVAILABLE; 79 | 80 | @end 81 | 82 | NS_ASSUME_NONNULL_END 83 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCRtpSender.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | #import 15 | #import 16 | 17 | NS_ASSUME_NONNULL_BEGIN 18 | 19 | RTC_EXPORT 20 | @protocol RTCRtpSender 21 | 22 | /** A unique identifier for this sender. */ 23 | @property(nonatomic, readonly) NSString *senderId; 24 | 25 | /** The currently active RTCRtpParameters, as defined in 26 | * https://www.w3.org/TR/webrtc/#idl-def-RTCRtpParameters. 27 | */ 28 | @property(nonatomic, copy) RTCRtpParameters *parameters; 29 | 30 | /** The RTCMediaStreamTrack associated with the sender. 31 | * Note: reading this property returns a new instance of 32 | * RTCMediaStreamTrack. Use isEqual: instead of == to compare 33 | * RTCMediaStreamTrack instances. 34 | */ 35 | @property(nonatomic, copy, nullable) RTCMediaStreamTrack *track; 36 | 37 | @end 38 | 39 | RTC_EXPORT 40 | @interface RTCRtpSender : NSObject 41 | 42 | - (instancetype)init NS_UNAVAILABLE; 43 | 44 | @end 45 | 46 | NS_ASSUME_NONNULL_END 47 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCSSLAdapter.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | /** 16 | * Initialize and clean up the SSL library. Failure is fatal. These call the 17 | * corresponding functions in webrtc/rtc_base/ssladapter.h. 18 | */ 19 | RTC_EXTERN BOOL RTCInitializeSSL(); 20 | RTC_EXTERN BOOL RTCCleanupSSL(); 21 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCSessionDescription.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | /** 16 | * Represents the session description type. This exposes the same types that are 17 | * in C++, which doesn't include the rollback type that is in the W3C spec. 18 | */ 19 | typedef NS_ENUM(NSInteger, RTCSdpType) { 20 | RTCSdpTypeOffer, 21 | RTCSdpTypePrAnswer, 22 | RTCSdpTypeAnswer, 23 | }; 24 | 25 | NS_ASSUME_NONNULL_BEGIN 26 | 27 | RTC_EXPORT 28 | @interface RTCSessionDescription : NSObject 29 | 30 | /** The type of session description. */ 31 | @property(nonatomic, readonly) RTCSdpType type; 32 | 33 | /** The SDP string representation of this session description. */ 34 | @property(nonatomic, readonly) NSString *sdp; 35 | 36 | - (instancetype)init NS_UNAVAILABLE; 37 | 38 | /** Initialize a session description with a type and SDP string. */ 39 | - (instancetype)initWithType:(RTCSdpType)type sdp:(NSString *)sdp 40 | NS_DESIGNATED_INITIALIZER; 41 | 42 | + (NSString *)stringForType:(RTCSdpType)type; 43 | 44 | + (RTCSdpType)typeForString:(NSString *)string; 45 | 46 | @end 47 | 48 | NS_ASSUME_NONNULL_END 49 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCTracing.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC Project Authors. All rights reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | RTC_EXTERN void RTCSetupInternalTracer(); 16 | /** Starts capture to specified file. Must be a valid writable path. 17 | * Returns YES if capture starts. 18 | */ 19 | RTC_EXTERN BOOL RTCStartInternalCapture(NSString *filePath); 20 | RTC_EXTERN void RTCStopInternalCapture(); 21 | RTC_EXTERN void RTCShutdownInternalTracer(); 22 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCVideoCapturer.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2017 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | NS_ASSUME_NONNULL_BEGIN 14 | 15 | @class RTCVideoCapturer; 16 | 17 | RTC_EXPORT 18 | @protocol RTCVideoCapturerDelegate 19 | - (void)capturer:(RTCVideoCapturer *)capturer didCaptureVideoFrame:(RTCVideoFrame *)frame; 20 | @end 21 | 22 | RTC_EXPORT 23 | @interface RTCVideoCapturer : NSObject 24 | 25 | @property(nonatomic, readonly, weak) id delegate; 26 | 27 | - (instancetype)initWithDelegate:(id)delegate; 28 | 29 | @end 30 | 31 | NS_ASSUME_NONNULL_END 32 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCVideoCodecFactory.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2017 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | #import 15 | 16 | NS_ASSUME_NONNULL_BEGIN 17 | 18 | /** RTCVideoEncoderFactory is an Objective-C version of cricket::WebRtcVideoEncoderFactory. */ 19 | RTC_EXPORT 20 | @protocol RTCVideoEncoderFactory 21 | 22 | - (id)createEncoder:(RTCVideoCodecInfo *)info; 23 | - (NSArray *)supportedCodecs; 24 | 25 | @end 26 | 27 | /** RTCVideoDecoderFactory is an Objective-C version of cricket::WebRtcVideoDecoderFactory. */ 28 | RTC_EXPORT 29 | @protocol RTCVideoDecoderFactory 30 | 31 | - (id)createDecoder:(RTCVideoCodecInfo *)info; 32 | - (NSArray *)supportedCodecs; 33 | 34 | @end 35 | 36 | NS_ASSUME_NONNULL_END 37 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCVideoCodecH264.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2017 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | #import 15 | 16 | /** Class for H264 specific config. */ 17 | typedef NS_ENUM(NSUInteger, RTCH264PacketizationMode) { 18 | NonInterleaved = 0, // Mode 1 - STAP-A, FU-A is allowed 19 | SingleNalUnit // Mode 0 - only single NALU allowed 20 | }; 21 | 22 | RTC_EXPORT 23 | @interface RTCCodecSpecificInfoH264 : NSObject 24 | 25 | @property(nonatomic, assign) RTCH264PacketizationMode packetizationMode; 26 | 27 | @end 28 | 29 | /** Encoder. */ 30 | RTC_EXPORT 31 | @interface RTCVideoEncoderH264 : NSObject 32 | @end 33 | 34 | /** Decoder. */ 35 | RTC_EXPORT 36 | @interface RTCVideoDecoderH264 : NSObject 37 | @end 38 | 39 | /** Encoder factory. */ 40 | RTC_EXPORT 41 | @interface RTCVideoEncoderFactoryH264 : NSObject 42 | @end 43 | 44 | /** Decoder factory. */ 45 | RTC_EXPORT 46 | @interface RTCVideoDecoderFactoryH264 : NSObject 47 | @end 48 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCVideoFrame.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | #import 13 | 14 | #import 15 | 16 | NS_ASSUME_NONNULL_BEGIN 17 | 18 | typedef NS_ENUM(NSInteger, RTCVideoRotation) { 19 | RTCVideoRotation_0 = 0, 20 | RTCVideoRotation_90 = 90, 21 | RTCVideoRotation_180 = 180, 22 | RTCVideoRotation_270 = 270, 23 | }; 24 | 25 | @protocol RTCVideoFrameBuffer; 26 | 27 | // RTCVideoFrame is an ObjectiveC version of webrtc::VideoFrame. 28 | RTC_EXPORT 29 | @interface RTCVideoFrame : NSObject 30 | 31 | /** Width without rotation applied. */ 32 | @property(nonatomic, readonly) int width; 33 | 34 | /** Height without rotation applied. */ 35 | @property(nonatomic, readonly) int height; 36 | @property(nonatomic, readonly) RTCVideoRotation rotation; 37 | /** Accessing YUV data should only be done for I420 frames, i.e. if nativeHandle 38 | * is null. It is always possible to get such a frame by calling 39 | * newI420VideoFrame. 40 | */ 41 | @property(nonatomic, readonly, nullable) 42 | const uint8_t *dataY DEPRECATED_MSG_ATTRIBUTE("use [buffer toI420]"); 43 | @property(nonatomic, readonly, nullable) 44 | const uint8_t *dataU DEPRECATED_MSG_ATTRIBUTE("use [buffer toI420]"); 45 | @property(nonatomic, readonly, nullable) 46 | const uint8_t *dataV DEPRECATED_MSG_ATTRIBUTE("use [buffer toI420]"); 47 | @property(nonatomic, readonly) int strideY DEPRECATED_MSG_ATTRIBUTE("use [buffer toI420]"); 48 | @property(nonatomic, readonly) int strideU DEPRECATED_MSG_ATTRIBUTE("use [buffer toI420]"); 49 | @property(nonatomic, readonly) int strideV DEPRECATED_MSG_ATTRIBUTE("use [buffer toI420]"); 50 | 51 | /** Timestamp in nanoseconds. */ 52 | @property(nonatomic, readonly) int64_t timeStampNs; 53 | 54 | /** Timestamp 90 kHz. */ 55 | @property(nonatomic, assign) int32_t timeStamp; 56 | 57 | /** The native handle should be a pixel buffer on iOS. */ 58 | @property(nonatomic, readonly) 59 | CVPixelBufferRef nativeHandle DEPRECATED_MSG_ATTRIBUTE("use buffer instead"); 60 | 61 | @property(nonatomic, readonly) id buffer; 62 | 63 | - (instancetype)init NS_UNAVAILABLE; 64 | - (instancetype)new NS_UNAVAILABLE; 65 | 66 | /** Initialize an RTCVideoFrame from a pixel buffer, rotation, and timestamp. 67 | * Deprecated - initialize with a RTCCVPixelBuffer instead 68 | */ 69 | - (instancetype)initWithPixelBuffer:(CVPixelBufferRef)pixelBuffer 70 | rotation:(RTCVideoRotation)rotation 71 | timeStampNs:(int64_t)timeStampNs 72 | DEPRECATED_MSG_ATTRIBUTE("use initWithBuffer instead"); 73 | 74 | /** Initialize an RTCVideoFrame from a pixel buffer combined with cropping and 75 | * scaling. Cropping will be applied first on the pixel buffer, followed by 76 | * scaling to the final resolution of scaledWidth x scaledHeight. 77 | */ 78 | - (instancetype)initWithPixelBuffer:(CVPixelBufferRef)pixelBuffer 79 | scaledWidth:(int)scaledWidth 80 | scaledHeight:(int)scaledHeight 81 | cropWidth:(int)cropWidth 82 | cropHeight:(int)cropHeight 83 | cropX:(int)cropX 84 | cropY:(int)cropY 85 | rotation:(RTCVideoRotation)rotation 86 | timeStampNs:(int64_t)timeStampNs 87 | DEPRECATED_MSG_ATTRIBUTE("use initWithBuffer instead"); 88 | 89 | /** Initialize an RTCVideoFrame from a frame buffer, rotation, and timestamp. 90 | */ 91 | - (instancetype)initWithBuffer:(id)frameBuffer 92 | rotation:(RTCVideoRotation)rotation 93 | timeStampNs:(int64_t)timeStampNs; 94 | 95 | /** Return a frame that is guaranteed to be I420, i.e. it is possible to access 96 | * the YUV data on it. 97 | */ 98 | - (RTCVideoFrame *)newI420VideoFrame; 99 | 100 | @end 101 | 102 | NS_ASSUME_NONNULL_END 103 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCVideoFrameBuffer.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2017 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | #import 13 | 14 | NS_ASSUME_NONNULL_BEGIN 15 | 16 | @protocol RTCI420Buffer; 17 | 18 | // RTCVideoFrameBuffer is an ObjectiveC version of webrtc::VideoFrameBuffer. 19 | RTC_EXPORT 20 | @protocol RTCVideoFrameBuffer 21 | 22 | @property(nonatomic, readonly) int width; 23 | @property(nonatomic, readonly) int height; 24 | 25 | - (id)toI420; 26 | 27 | @end 28 | 29 | /** Protocol for RTCVideoFrameBuffers containing YUV planar data. */ 30 | @protocol RTCYUVPlanarBuffer 31 | 32 | @property(nonatomic, readonly) int chromaWidth; 33 | @property(nonatomic, readonly) int chromaHeight; 34 | @property(nonatomic, readonly) const uint8_t *dataY; 35 | @property(nonatomic, readonly) const uint8_t *dataU; 36 | @property(nonatomic, readonly) const uint8_t *dataV; 37 | @property(nonatomic, readonly) int strideY; 38 | @property(nonatomic, readonly) int strideU; 39 | @property(nonatomic, readonly) int strideV; 40 | 41 | - (instancetype)initWithWidth:(int)width height:(int)height; 42 | - (instancetype)initWithWidth:(int)width 43 | height:(int)height 44 | strideY:(int)strideY 45 | strideU:(int)strideU 46 | strideV:(int)strideV; 47 | 48 | @end 49 | 50 | /** Extension of the YUV planar data buffer with mutable data access */ 51 | @protocol RTCMutableYUVPlanarBuffer 52 | 53 | @property(nonatomic, readonly) uint8_t *mutableDataY; 54 | @property(nonatomic, readonly) uint8_t *mutableDataU; 55 | @property(nonatomic, readonly) uint8_t *mutableDataV; 56 | 57 | @end 58 | 59 | /** Protocol for RTCYUVPlanarBuffers containing I420 data */ 60 | @protocol RTCI420Buffer 61 | @end 62 | 63 | /** Extension of the I420 buffer with mutable data access */ 64 | @protocol RTCMutableI420Buffer 65 | @end 66 | 67 | /** RTCVideoFrameBuffer containing a CVPixelBufferRef */ 68 | RTC_EXPORT 69 | @interface RTCCVPixelBuffer : NSObject 70 | 71 | @property(nonatomic, readonly) CVPixelBufferRef pixelBuffer; 72 | 73 | - (instancetype)initWithPixelBuffer:(CVPixelBufferRef)pixelBuffer; 74 | - (instancetype)initWithPixelBuffer:(CVPixelBufferRef)pixelBuffer 75 | adaptedWidth:(int)adaptedWidth 76 | adaptedHeight:(int)adaptedHeight 77 | cropWidth:(int)cropWidth 78 | cropHeight:(int)cropHeight 79 | cropX:(int)cropX 80 | cropY:(int)cropY; 81 | 82 | - (BOOL)requiresCropping; 83 | - (BOOL)requiresScalingToWidth:(int)width height:(int)height; 84 | - (int)bufferSizeForCroppingAndScalingToWidth:(int)width height:(int)height; 85 | /** The minimum size of the |tmpBuffer| must be the number of bytes returned from the 86 | * bufferSizeForCroppingAndScalingToWidth:height: method. 87 | */ 88 | - (BOOL)cropAndScaleTo:(CVPixelBufferRef)outputPixelBuffer withTempBuffer:(uint8_t *)tmpBuffer; 89 | 90 | @end 91 | 92 | /** RTCI420Buffer implements the RTCI420Buffer protocol */ 93 | RTC_EXPORT 94 | @interface RTCI420Buffer : NSObject 95 | @end 96 | 97 | /** Mutable version of RTCI420Buffer */ 98 | RTC_EXPORT 99 | @interface RTCMutableI420Buffer : RTCI420Buffer 100 | @end 101 | 102 | NS_ASSUME_NONNULL_END 103 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCVideoRenderer.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | #if TARGET_OS_IPHONE 13 | #import 14 | #endif 15 | 16 | #import 17 | 18 | NS_ASSUME_NONNULL_BEGIN 19 | 20 | @class RTCVideoFrame; 21 | 22 | RTC_EXPORT 23 | @protocol RTCVideoRenderer 24 | 25 | /** The size of the frame. */ 26 | - (void)setSize:(CGSize)size; 27 | 28 | /** The frame to be displayed. */ 29 | - (void)renderFrame:(nullable RTCVideoFrame *)frame; 30 | 31 | @end 32 | 33 | NS_ASSUME_NONNULL_END 34 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCVideoSource.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | #import 15 | #import 16 | 17 | NS_ASSUME_NONNULL_BEGIN 18 | 19 | RTC_EXPORT 20 | 21 | @interface RTCVideoSource : RTCMediaSource 22 | 23 | - (instancetype)init NS_UNAVAILABLE; 24 | 25 | /** 26 | * Calling this function will cause frames to be scaled down to the 27 | * requested resolution. Also, frames will be cropped to match the 28 | * requested aspect ratio, and frames will be dropped to match the 29 | * requested fps. The requested aspect ratio is orientation agnostic and 30 | * will be adjusted to maintain the input orientation, so it doesn't 31 | * matter if e.g. 1280x720 or 720x1280 is requested. 32 | */ 33 | - (void)adaptOutputFormatToWidth:(int)width height:(int)height fps:(int)fps; 34 | 35 | @end 36 | 37 | NS_ASSUME_NONNULL_END 38 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCVideoTrack.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2015 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | NS_ASSUME_NONNULL_BEGIN 16 | 17 | @protocol RTCVideoRenderer; 18 | @class RTCPeerConnectionFactory; 19 | @class RTCVideoSource; 20 | 21 | RTC_EXPORT 22 | @interface RTCVideoTrack : RTCMediaStreamTrack 23 | 24 | /** The video source for this video track. */ 25 | @property(nonatomic, readonly) RTCVideoSource *source; 26 | 27 | - (instancetype)init NS_UNAVAILABLE; 28 | 29 | /** Register a renderer that will render all frames received on this track. */ 30 | - (void)addRenderer:(id)renderer; 31 | 32 | /** Deregister a renderer. */ 33 | - (void)removeRenderer:(id)renderer; 34 | 35 | @end 36 | 37 | NS_ASSUME_NONNULL_END 38 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/RTCVideoViewShading.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2017 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | #import 14 | 15 | NS_ASSUME_NONNULL_BEGIN 16 | 17 | /** 18 | * RTCVideoViewShading provides a way for apps to customize the OpenGL(ES) shaders used in 19 | * rendering for the RTCEAGLVideoView/RTCNSGLVideoView. 20 | */ 21 | RTC_EXPORT 22 | @protocol RTCVideoViewShading 23 | 24 | /** Callback for I420 frames. Each plane is given as a texture. */ 25 | - (void)applyShadingForFrameWithWidth:(int)width 26 | height:(int)height 27 | rotation:(RTCVideoRotation)rotation 28 | yPlane:(GLuint)yPlane 29 | uPlane:(GLuint)uPlane 30 | vPlane:(GLuint)vPlane; 31 | 32 | /** Callback for NV12 frames. Each plane is given as a texture. */ 33 | - (void)applyShadingForFrameWithWidth:(int)width 34 | height:(int)height 35 | rotation:(RTCVideoRotation)rotation 36 | yPlane:(GLuint)yPlane 37 | uvPlane:(GLuint)uvPlane; 38 | 39 | @end 40 | 41 | NS_ASSUME_NONNULL_END 42 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/UIDevice+RTCDevice.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | 13 | typedef NS_ENUM(NSInteger, RTCDeviceType) { 14 | RTCDeviceTypeUnknown, 15 | RTCDeviceTypeIPhone1G, 16 | RTCDeviceTypeIPhone3G, 17 | RTCDeviceTypeIPhone3GS, 18 | RTCDeviceTypeIPhone4, 19 | RTCDeviceTypeIPhone4Verizon, 20 | RTCDeviceTypeIPhone4S, 21 | RTCDeviceTypeIPhone5GSM, 22 | RTCDeviceTypeIPhone5GSM_CDMA, 23 | RTCDeviceTypeIPhone5CGSM, 24 | RTCDeviceTypeIPhone5CGSM_CDMA, 25 | RTCDeviceTypeIPhone5SGSM, 26 | RTCDeviceTypeIPhone5SGSM_CDMA, 27 | RTCDeviceTypeIPhone6Plus, 28 | RTCDeviceTypeIPhone6, 29 | RTCDeviceTypeIPhone6S, 30 | RTCDeviceTypeIPhone6SPlus, 31 | RTCDeviceTypeIPodTouch1G, 32 | RTCDeviceTypeIPodTouch2G, 33 | RTCDeviceTypeIPodTouch3G, 34 | RTCDeviceTypeIPodTouch4G, 35 | RTCDeviceTypeIPodTouch5G, 36 | RTCDeviceTypeIPad, 37 | RTCDeviceTypeIPad2Wifi, 38 | RTCDeviceTypeIPad2GSM, 39 | RTCDeviceTypeIPad2CDMA, 40 | RTCDeviceTypeIPad2Wifi2, 41 | RTCDeviceTypeIPadMiniWifi, 42 | RTCDeviceTypeIPadMiniGSM, 43 | RTCDeviceTypeIPadMiniGSM_CDMA, 44 | RTCDeviceTypeIPad3Wifi, 45 | RTCDeviceTypeIPad3GSM_CDMA, 46 | RTCDeviceTypeIPad3GSM, 47 | RTCDeviceTypeIPad4Wifi, 48 | RTCDeviceTypeIPad4GSM, 49 | RTCDeviceTypeIPad4GSM_CDMA, 50 | RTCDeviceTypeIPadAirWifi, 51 | RTCDeviceTypeIPadAirCellular, 52 | RTCDeviceTypeIPadMini2GWifi, 53 | RTCDeviceTypeIPadMini2GCellular, 54 | RTCDeviceTypeSimulatori386, 55 | RTCDeviceTypeSimulatorx86_64, 56 | }; 57 | 58 | @interface UIDevice (RTCDevice) 59 | 60 | + (RTCDeviceType)deviceType; 61 | + (NSString *)stringForDeviceType:(RTCDeviceType)deviceType; 62 | + (BOOL)isIOS9OrLater; 63 | 64 | @end 65 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Headers/WebRTC.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 | * 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 6 | * tree. An additional intellectual property rights grant can be found 7 | * in the file PATENTS. All contributing project authors may 8 | * be found in the AUTHORS file in the root of the source tree. 9 | */ 10 | 11 | #import 12 | #import 13 | #import 14 | #import 15 | #if TARGET_OS_IPHONE 16 | #import 17 | #endif 18 | #import 19 | #import 20 | #import 21 | #import 22 | #if TARGET_OS_IPHONE 23 | #import 24 | #import 25 | #endif 26 | #import 27 | #import 28 | #import 29 | #import 30 | #import 31 | #import 32 | #import 33 | #import 34 | #import 35 | #import 36 | #import 37 | #import 38 | #import 39 | #import 40 | #import 41 | #import 42 | #import 43 | #import 44 | #import 45 | #import 46 | #import 47 | #import 48 | #import 49 | #import 50 | #import 51 | #import 52 | #import 53 | #import 54 | #import 55 | #import 56 | #import 57 | #if TARGET_OS_IPHONE 58 | #import 59 | #endif 60 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Info.plist: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redfearnk/WebRTCVideoChat/66296df00f66492a863ff94cf714d6eea0e9eb99/WebRTCVideoChat/WebRTC.framework/Info.plist -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/Modules/module.modulemap: -------------------------------------------------------------------------------- 1 | framework module WebRTC { 2 | umbrella header "WebRTC.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /WebRTCVideoChat/WebRTC.framework/WebRTC: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/redfearnk/WebRTCVideoChat/66296df00f66492a863ff94cf714d6eea0e9eb99/WebRTCVideoChat/WebRTC.framework/WebRTC -------------------------------------------------------------------------------- /WebRTCVideoChatTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | 22 | 23 | -------------------------------------------------------------------------------- /WebRTCVideoChatTests/WebRTCVideoChatTests.swift: -------------------------------------------------------------------------------- 1 | // 2 | // WebRTCVideoChatTests.swift 3 | // WebRTCVideoChatTests 4 | // 5 | // Created by Kyle Redfearn on 8/22/17. 6 | // Copyright © 2017 Kyle Redfearn. All rights reserved. 7 | // 8 | 9 | import XCTest 10 | @testable import WebRTCVideoChat 11 | 12 | class WebRTCVideoChatTests: XCTestCase { 13 | 14 | override func setUp() { 15 | super.setUp() 16 | // Put setup code here. This method is called before the invocation of each test method in the class. 17 | } 18 | 19 | override func tearDown() { 20 | // Put teardown code here. This method is called after the invocation of each test method in the class. 21 | super.tearDown() 22 | } 23 | 24 | func testExample() { 25 | // This is an example of a functional test case. 26 | // Use XCTAssert and related functions to verify your tests produce the correct results. 27 | } 28 | 29 | func testPerformanceExample() { 30 | // This is an example of a performance test case. 31 | self.measure { 32 | // Put the code you want to measure the time of here. 33 | } 34 | } 35 | 36 | } 37 | --------------------------------------------------------------------------------