diff --git a/Demo/Demo.xcodeproj/project.pbxproj b/Demo/Demo.xcodeproj/project.pbxproj index 2cf24b02353ddf8be732a0566b6a4f02a1527bb0..74ec7605459db5b6accb3f0eaa096289c781effd 100644 --- a/Demo/Demo.xcodeproj/project.pbxproj +++ b/Demo/Demo.xcodeproj/project.pbxproj @@ -26,15 +26,17 @@ 772E49C722F19F950009DFD2 /* videoAd.mp4 in Resources */ = {isa = PBXBuildFile; fileRef = 772E49C522F19F940009DFD2 /* videoAd.mp4 */; }; 77303F6722F98A3A00A51176 /* Advertisement.mp4 in Resources */ = {isa = PBXBuildFile; fileRef = 77303F6622F98A3A00A51176 /* Advertisement.mp4 */; }; 77303F6A22F98F2D00A51176 /* landingPageIcon.png in Resources */ = {isa = PBXBuildFile; fileRef = 77303F6922F98F2D00A51176 /* landingPageIcon.png */; }; - 7781CA6122C4BBD1002805DB /* sdkconfig.xml in Resources */ = {isa = PBXBuildFile; fileRef = 7781CA6022C4BBD1002805DB /* sdkconfig.xml */; }; AF353EDF1CFC24FB00969035 /* AdSupport.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AF353EDE1CFC24FB00969035 /* AdSupport.framework */; }; AF4B464B218AB16400BE2F3F /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AF353EE01CFC251C00969035 /* SystemConfiguration.framework */; }; AF4B464C218AB18300BE2F3F /* CoreLocation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AF353ED91CFC24E400969035 /* CoreLocation.framework */; }; AF6EA2E51EF655AD000DF811 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AF6EA2E41EF655AD000DF811 /* Images.xcassets */; }; AF7D89611EF655F50069A7DC /* Launch Screen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AF7D89601EF655F50069A7DC /* Launch Screen.storyboard */; }; AFB3717E1F3854E10092930F /* admaster.js in Resources */ = {isa = PBXBuildFile; fileRef = AFB3717D1F3854E10092930F /* admaster.js */; }; - C765ABEC23262CDA0066E906 /* libMobileTrackingSimulator.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 2ABB195518DAFA0300C7CAA9 /* libMobileTrackingSimulator.a */; }; + C726E4B5238665E1000EC447 /* sdkconfig.xml in Resources */ = {isa = PBXBuildFile; fileRef = C726E4B4238665E1000EC447 /* sdkconfig.xml */; }; + C74B783D237557EA0031DE10 /* Photos.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C74B7838237557EA0031DE10 /* Photos.framework */; }; C765ABED23262CE00066E906 /* WebKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C765ABE923262CC20066E906 /* WebKit.framework */; }; + C78B6BB0236C303F0022BD30 /* libMobileTrackingSimulator.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 2ABB195518DAFA0300C7CAA9 /* libMobileTrackingSimulator.a */; }; + C78B6BC5236C33A60022BD30 /* CoreMotion.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C78B6BC0236C33A60022BD30 /* CoreMotion.framework */; }; /* End PBXBuildFile section */ /* Begin PBXContainerItemProxy section */ @@ -66,13 +68,6 @@ remoteGlobalIDString = 2A81721B18DAEB3A00E0EFEC; remoteInfo = MobileTrackingSimulator; }; - 77BDFC40230D44CE00079FDF /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 2A0C4E5218D6D19700200F18 /* MobileTracking.xcodeproj */; - proxyType = 1; - remoteGlobalIDString = 2A8171FF18DAEB3A00E0EFEC; - remoteInfo = MobileTrackingSimulator; - }; /* End PBXContainerItemProxy section */ /* Begin PBXFileReference section */ @@ -107,7 +102,6 @@ 772E49C522F19F940009DFD2 /* videoAd.mp4 */ = {isa = PBXFileReference; lastKnownFileType = file; path = videoAd.mp4; sourceTree = ""; }; 77303F6622F98A3A00A51176 /* Advertisement.mp4 */ = {isa = PBXFileReference; lastKnownFileType = file; path = Advertisement.mp4; sourceTree = ""; }; 77303F6922F98F2D00A51176 /* landingPageIcon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = landingPageIcon.png; sourceTree = ""; }; - 7781CA6022C4BBD1002805DB /* sdkconfig.xml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = sdkconfig.xml; sourceTree = ""; }; AF2DFF4021955F0300B10C3F /* libxml2.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libxml2.tbd; path = usr/lib/libxml2.tbd; sourceTree = SDKROOT; }; AF353ED91CFC24E400969035 /* CoreLocation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreLocation.framework; path = System/Library/Frameworks/CoreLocation.framework; sourceTree = SDKROOT; }; AF353EDE1CFC24FB00969035 /* AdSupport.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AdSupport.framework; path = System/Library/Frameworks/AdSupport.framework; sourceTree = SDKROOT; }; @@ -115,7 +109,10 @@ AF6EA2E41EF655AD000DF811 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = ""; }; AF7D89601EF655F50069A7DC /* Launch Screen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = "Launch Screen.storyboard"; sourceTree = ""; }; AFB3717D1F3854E10092930F /* admaster.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = admaster.js; sourceTree = ""; }; + C726E4B4238665E1000EC447 /* sdkconfig.xml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = sdkconfig.xml; sourceTree = ""; }; + C74B7838237557EA0031DE10 /* Photos.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Photos.framework; path = System/Library/Frameworks/Photos.framework; sourceTree = SDKROOT; }; C765ABE923262CC20066E906 /* WebKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = WebKit.framework; path = System/Library/Frameworks/WebKit.framework; sourceTree = SDKROOT; }; + C78B6BC0236C33A60022BD30 /* CoreMotion.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreMotion.framework; path = System/Library/Frameworks/CoreMotion.framework; sourceTree = SDKROOT; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -123,8 +120,10 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + C74B783D237557EA0031DE10 /* Photos.framework in Frameworks */, + C78B6BC5236C33A60022BD30 /* CoreMotion.framework in Frameworks */, C765ABED23262CE00066E906 /* WebKit.framework in Frameworks */, - C765ABEC23262CDA0066E906 /* libMobileTrackingSimulator.a in Frameworks */, + C78B6BB0236C303F0022BD30 /* libMobileTrackingSimulator.a in Frameworks */, AF4B464C218AB18300BE2F3F /* CoreLocation.framework in Frameworks */, AF4B464B218AB16400BE2F3F /* SystemConfiguration.framework in Frameworks */, AF353EDF1CFC24FB00969035 /* AdSupport.framework in Frameworks */, @@ -167,6 +166,8 @@ 2A0C4E1C18D6D18700200F18 /* Frameworks */ = { isa = PBXGroup; children = ( + C74B7838237557EA0031DE10 /* Photos.framework */, + C78B6BC0236C33A60022BD30 /* CoreMotion.framework */, C765ABE923262CC20066E906 /* WebKit.framework */, AF2DFF4021955F0300B10C3F /* libxml2.tbd */, AF353EE01CFC251C00969035 /* SystemConfiguration.framework */, @@ -200,8 +201,8 @@ 772E49B722F195970009DFD2 /* VideoViewController.m */, 772E49B422F195950009DFD2 /* VideoViewController.xib */, AFB3717D1F3854E10092930F /* admaster.js */, + C726E4B4238665E1000EC447 /* sdkconfig.xml */, 2A0C4E2F18D6D18700200F18 /* Main.storyboard */, - 7781CA6022C4BBD1002805DB /* sdkconfig.xml */, AF7D89601EF655F50069A7DC /* Launch Screen.storyboard */, AF6EA2E41EF655AD000DF811 /* Images.xcassets */, 2A0C4E2418D6D18700200F18 /* Supporting Files */, @@ -262,7 +263,6 @@ buildRules = ( ); dependencies = ( - 77BDFC41230D44CE00079FDF /* PBXTargetDependency */, ); name = Demo; productName = Demo; @@ -366,13 +366,13 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( - 7781CA6122C4BBD1002805DB /* sdkconfig.xml in Resources */, 77303F6722F98A3A00A51176 /* Advertisement.mp4 in Resources */, 772E49BD22F1959B0009DFD2 /* VideoViewController.xib in Resources */, AF6EA2E51EF655AD000DF811 /* Images.xcassets in Resources */, 772E49C222F1959B0009DFD2 /* NormalViewController.xib in Resources */, 77303F6A22F98F2D00A51176 /* landingPageIcon.png in Resources */, 772E49C722F19F950009DFD2 /* videoAd.mp4 in Resources */, + C726E4B5238665E1000EC447 /* sdkconfig.xml in Resources */, 2A0C4E2818D6D18700200F18 /* InfoPlist.strings in Resources */, AFB3717E1F3854E10092930F /* admaster.js in Resources */, AF7D89611EF655F50069A7DC /* Launch Screen.storyboard in Resources */, @@ -421,11 +421,6 @@ target = 2A0C4E1918D6D18700200F18 /* Demo */; targetProxy = 2A0C4E4018D6D18700200F18 /* PBXContainerItemProxy */; }; - 77BDFC41230D44CE00079FDF /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - name = MobileTrackingSimulator; - targetProxy = 77BDFC40230D44CE00079FDF /* PBXContainerItemProxy */; - }; /* End PBXTargetDependency section */ /* Begin PBXVariantGroup section */ @@ -562,7 +557,7 @@ /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include, ); INFOPLIST_FILE = "Demo/Demo-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; + IPHONEOS_DEPLOYMENT_TARGET = 10.0; LIBRARY_SEARCH_PATHS = ( "$(inherited)", "$(PROJECT_DIR)/Demo", @@ -599,7 +594,7 @@ /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include, ); INFOPLIST_FILE = "Demo/Demo-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; + IPHONEOS_DEPLOYMENT_TARGET = 10.0; LIBRARY_SEARCH_PATHS = ( "$(inherited)", "$(PROJECT_DIR)/Demo", diff --git a/Demo/Demo/Demo-Info.plist b/Demo/Demo/Demo-Info.plist index 07537ff0a683c2340a3207dbcddfab33fc245a09..ca3a99724b03299c703d76f3aec8d23a38e43ef3 100755 --- a/Demo/Demo/Demo-Info.plist +++ b/Demo/Demo/Demo-Info.plist @@ -26,6 +26,8 @@ ???? CFBundleVersion 1.0 + LSApplicationCategoryType + LSRequiresIPhoneOS NSAppTransportSecurity @@ -33,6 +35,8 @@ NSAllowsArbitraryLoads + NSLocationWhenInUseUsageDescription + 是否允许App通过您的地理位置信息获取您周边的相关数据 UILaunchStoryboardName Launch Screen UIMainStoryboardFile @@ -46,7 +50,5 @@ UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown - NSLocationWhenInUseUsageDescription - 是否允许App通过您的地理位置信息获取您周边的相关数据 diff --git a/Demo/Demo/VideoViewController.m b/Demo/Demo/VideoViewController.m index 426ddf0b6300e030dbff121ee5adb85119e937b8..6797e8c31a4d80068a0eefb8094e7ac417b0aff3 100644 --- a/Demo/Demo/VideoViewController.m +++ b/Demo/Demo/VideoViewController.m @@ -15,8 +15,8 @@ @interface VideoViewController () @property (weak, nonatomic) IBOutlet UIScrollView *bottomScrollView; -@property (nonatomic, strong) AVPlayerViewController *avMoviePlayerController;; -@property (nonatomic, strong)UIView *tapview; +@property (nonatomic, strong)UIView *avMovieView; +@property(nonatomic,strong)AVPlayer * player; @property (nonatomic, strong) UILabel *remindLabel; @property (nonatomic, assign)NSInteger type; @property (nonatomic, strong)NSString *navtitle; @@ -54,20 +54,27 @@ // 视频 NSURL *url = [[NSBundle mainBundle] URLForResource:@"Advertisement.mp4" withExtension:nil]; - _avMoviePlayerController = [[AVPlayerViewController alloc]init]; - _avMoviePlayerController.player = [AVPlayer playerWithURL:url]; - - _avMoviePlayerController.showsPlaybackControls = NO; + _avMovieView = [[UIView alloc]initWithFrame: CGRectMake(0, 0, [UIScreen mainScreen].bounds.size.width, 320)]; + _avMovieView.backgroundColor = [UIColor blackColor]; + + [_bottomScrollView addSubview:_avMovieView]; + + + AVPlayerItem * playerItem = [AVPlayerItem playerItemWithURL:url]; + _player = [AVPlayer playerWithPlayerItem:playerItem]; + AVPlayerLayer * playerLayer = [AVPlayerLayer playerLayerWithPlayer:_player]; + playerLayer.frame = _avMovieView.bounds; + playerLayer.videoGravity = AVLayerVideoGravityResizeAspect; + + [_avMovieView.layer addSublayer:playerLayer]; - _avMoviePlayerController.view.frame = CGRectMake(0, 0, [UIScreen mainScreen].bounds.size.width, 320); - [_bottomScrollView addSubview:_avMoviePlayerController.view]; if (_type == 0 || _type == 1) { // 广告开始播放的情况下调用;网络的广告资源需要等资源加载成功开始播放的情况下调用 // 可视化视频曝光 - [[MobileTracking sharedInstance] viewVideo:_viewUrl ad:_avMoviePlayerController.view videoPlayType:_type]; + [[MobileTracking sharedInstance] viewVideo:_viewUrl ad:_avMovieView videoPlayType:_type]; } @@ -78,10 +85,10 @@ UITapGestureRecognizer *tableViewGesture = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(tapView:)]; - [_avMoviePlayerController.view addGestureRecognizer:tableViewGesture]; + [_avMovieView addGestureRecognizer:tableViewGesture]; // 播放的内容提醒:广告&正片 - _remindLabel = [[UILabel alloc]initWithFrame:CGRectMake(0, 550, [UIScreen mainScreen].bounds.size.width, 50)]; + _remindLabel = [[UILabel alloc]initWithFrame:CGRectMake(0, 350, [UIScreen mainScreen].bounds.size.width, 50)]; if (_type == 0 || _type == 1) { _remindLabel.text = @"status:前贴片广告播放中..."; } else { @@ -94,8 +101,8 @@ [super viewWillAppear:animated]; if (_type == 0 || _type == 1|| self.view.tag ==1) { - if (_avMoviePlayerController.player.timeControlStatus == AVPlayerTimeControlStatusPaused) { - [_avMoviePlayerController.player play]; + if (_player.timeControlStatus == AVPlayerTimeControlStatusPaused) { + [_player play]; } } @@ -104,31 +111,43 @@ //停止监测 - (void)finishedPlay { [[MobileTracking sharedInstance]stop:_viewUrl]; - if (_tapview) { - [_tapview removeFromSuperview]; + for (UIGestureRecognizer * gesture in _avMovieView.gestureRecognizers) { + [gesture removeTarget:self action:@selector(tapView:)]; } _remindLabel.text = @"status:视频播放中..."; - NSURL *url = [[NSBundle mainBundle] URLForResource:@"videoAd.mp4" withExtension:nil]; - _avMoviePlayerController.player = [AVPlayer playerWithURL:url];; - [_avMoviePlayerController.player play]; + NSURL *url = [[NSBundle mainBundle] URLForResource:@"videoAd.mp4" withExtension:nil]; + AVPlayerItem * playerItem = [AVPlayerItem playerItemWithURL:url]; + _player = [AVPlayer playerWithPlayerItem:playerItem]; + AVPlayerLayer * playerLayer = [AVPlayerLayer playerLayerWithPlayer:_player]; + playerLayer.frame = _avMovieView.bounds; + playerLayer.videoGravity = AVLayerVideoGravityResizeAspect; + for (CALayer *layer in _avMovieView.layer.sublayers) { + if ([layer class] == [AVPlayerLayer class]) { + [layer removeFromSuperlayer]; + } + } + + + [_avMovieView.layer addSublayer:playerLayer]; + [_player play]; } //点击url - (void)tapView:(UITapGestureRecognizer *)tap { - if (_avMoviePlayerController.player.timeControlStatus == AVPlayerTimeControlStatusPaused) { + if (_player.timeControlStatus == AVPlayerTimeControlStatusPaused) { self.view.tag =1; - [_avMoviePlayerController.player play]; + [_player play]; - [[MobileTracking sharedInstance] viewVideo:_viewUrl ad:_avMoviePlayerController.view videoPlayType:_type]; + [[MobileTracking sharedInstance] viewVideo:_viewUrl ad:_avMovieView videoPlayType:_type]; _remindLabel.text = @"status:前贴片广告播放中..."; } else { // 可视化视频点击 [[MobileTracking sharedInstance]click:_clickUrl]; - [_avMoviePlayerController.player pause]; + [_player pause]; SecondViewController *secondVC = [[SecondViewController alloc]init]; [self.navigationController pushViewController:secondVC animated:YES]; @@ -137,14 +156,6 @@ } -/* -#pragma mark - Navigation - -// In a storyboard-based application, you will often want to do a little preparation before navigation -- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender { - // Get the new view controller using [segue destinationViewController]. - // Pass the selected object to the new view controller. -} -*/ + @end diff --git a/Demo/Demo/sdkconfig.xml b/Demo/Demo/sdkconfig.xml index d46bf37c6d1eb27affbe55ef93b174bd26903780..4a540a2cc2214d17b7b71095a814a3e04cac6ed3 100644 --- a/Demo/Demo/sdkconfig.xml +++ b/Demo/Demo/sdkconfig.xml @@ -2,17 +2,17 @@ - + - + 0 60 60 - + @@ -28,23 +28,23 @@ 20 - + admaster - + - + admaster.com.cn - + @@ -52,7 +52,7 @@ 0b - + true @@ -60,7 +60,7 @@ 259200 0 - + @@ -72,18 +72,18 @@ md5 - + - - https://p.attri.mobi/a - - 24 - - true + + https://p.attri.mobi/a + + 24 + + true - + @@ -175,7 +175,7 @@ true true - + @@ -227,7 +227,7 @@ true - + @@ -243,8 +243,8 @@ true - - + + @@ -254,10 +254,10 @@ false - + - + ImpressionID @@ -265,7 +265,7 @@ true true - + @@ -352,7 +352,7 @@ true - + @@ -397,7 +397,7 @@ true - + - + - + , @@ -420,7 +420,7 @@ true - + miaozhen @@ -441,21 +441,21 @@ 604800 1 - + md5 raw md5 md5 - - + + - - /apl/ - - 24 - false + + /apl/ + + 24 + false @@ -511,7 +511,7 @@ true true - + OAID @@ -519,7 +519,7 @@ true true - + ADID @@ -771,7 +771,7 @@ true true - + AdviewabilityStrongInteract @@ -779,20 +779,144 @@ true true - + - - & - - - https://g.cn.miaozhen.com/x/k=adid - + + + + + isRoot + l1 + true + true + + + + Electricity + l2 + true + true + + + + isCharging + l3 + true + true + + + + isSimulator + l4 + true + true + + + + isHook + l5 + true + true + + + + isFlash + l6 + true + true + + + + Accelerometer + l7 + true + true + + + + Magnetometer + l8 + true + true + + + + Direction + l9 + true + true + + + + GyroActive + l10 + true + true + + + + Brightness + l11 + true + true + + + + Pressure + l12 + true + true + + + + Temperature + l13 + true + true + + + + Proximity + l14 + true + true + + + + DeviceMotion + l15 + true + true + + + + LineAccelerometer + l16 + true + true + + + + RotationVector + l17 + true + true + + + + & + + + https://g.cn.miaozhen.com/x/k=adid + + + svl = - + true - + girdsum @@ -800,7 +924,6 @@ gridsumdissector.com - @@ -814,10 +937,10 @@ 1 - raw - md5 + md5 + raw md5 - raw + md5 @@ -830,63 +953,79 @@ true true - + TS ts true true - + MAC m true true - + IDFA if true true - + IMEI im true true - + ANDROIDID aid true true - + + + + OAID + oa + true + true + + + + + ADID + adid + true + true + + WIFI wifi true true - + AKEY ak true true - + ANAME an true true - + SCWH @@ -894,56 +1033,56 @@ true true - + OPENUDID oid true true - + ODIN odin true true - + TERM term true true - + OSVS osvs true true - + LBS lbs true true - + MUID mid true true - + MUDS muds true true - + REDIRECTURL u @@ -961,17 +1100,17 @@ start - m201 + event=start true end - m203 + event=end true - + @@ -981,7 +1120,7 @@ false - + @@ -989,6 +1128,20 @@ viid true true + + + + ImpressionType + vitype + true + true + + + + AdviewabilityRecord + varecord + true + true @@ -1047,6 +1200,13 @@ true true + + + AdviewabilityForground + vfg + true + true + AdviewabilityLight @@ -1054,69 +1214,68 @@ true true + AdviewabilityForground - vfg - true - true - - - - Adviewability - vab + vafg true true - + - AdMeasurability - vm + AdviewabilityResult + varesult true true - - - - + AdviewabilityConfigArea - vca + vaconfarea true true - + AdviewabilityConfigThreshold - vct + vaconfth true true - + AdviewabilityVideoDuration - vcvd + vavd true true - + AdviewabilityVideoProgress - vcvp + vavp true true - + AdviewabilityVideoPlayType - vcpt + vavpt true true - + AdviewabilityVideoProgressPoint - vcpp + vavpp + true + true + + + + + AdviewabilityStrongInteract + vasi true true @@ -1128,8 +1287,8 @@ true - - + + adbug @@ -1164,28 +1323,28 @@ true true - + TS t true true - + MAC n true true - + IDFA z true true - + IDFAMD5 0j @@ -1198,21 +1357,21 @@ true true - + WIFI w true true - + AKEY x true true - + ANAME y @@ -1226,7 +1385,7 @@ true true - + OPENUDID o @@ -1239,14 +1398,14 @@ true true - + OSVS q true true - + LBS l @@ -1287,9 +1446,9 @@ false false - + - + ImpressionID @@ -1297,7 +1456,7 @@ true true - + AdviewabilityEvents 2j @@ -1370,7 +1529,7 @@ true true - + @@ -1379,8 +1538,8 @@ true - - + + rtbasia @@ -1408,12 +1567,12 @@ raw @@ -1678,7 +1837,651 @@ true - - - + + nielsen + + + + + uat.cr-nielsen.com + + + + 4A5DBD140 + pk + + + true + + 604800 + + 1 + + md5 + raw + md5 + raw + + + + + + + + + OS + os + + true + + true + + + + TS + ts + true + true + + + + MAC + mac + true + true + + + + IDFA + idfa + true + true + + + + IMEI + imei + true + true + + + + ANDROIDID + androidid + true + true + + + + WIFI + wifi + true + true + + + + AKEY + akey + true + true + + + + ANAME + aname + true + true + + + + + SCWH + scwh + true + true + + + + OPENUDID + openudid + true + true + + + + ODIN + odin + true + true + + + + TERM + term + true + true + + + + OSVS + osvs + true + true + + + + LBS + lbs + true + true + + + + MUID + muid + true + true + + + + MUDS + muds + true + true + + + + REDIRECTURL + ref + true + true + + + SDKVS + sdkvs + true + true + + + + + + start + start + true + + + + end + end + true + + + + + + + Adplacement + hat_pid + false + false + + + + + + + ImpressionID + imp_id + true + true + + + ImpressionType + vit + true + true + + + + + AdviewabilityEvents + vbe + true + true + + + + AdviewabilityTime + vts + true + true + + + + AdviewabilityFrame + vbf + true + true + + + + AdviewabilityPoint + vbp + true + true + + + + AdviewabilityAlpha + vba + true + true + + + + AdviewabilityShown + vbs + true + true + + + + AdviewabilityCoverRate + vbc + true + true + + + + AdviewabilityShowFrame + vsf + true + true + + + + AdviewabilityLight + vbl + true + true + + + + AdviewabilityForground + vfg + true + true + + + + Adviewability + vvb + true + true + + + + AdMeasurability + vmb + true + true + + + + + + + AdviewabilityConfigArea + vca + true + true + + + + AdviewabilityConfigThreshold + vct + true + true + + + + AdviewabilityVideoDuration + vcvd + true + true + + + + AdviewabilityVideoProgress + vcvp + true + true + + + + AdviewabilityVideoPlayType + vcpt + true + true + + + + AdviewabilityVideoProgressPoint + vcpp + true + true + + + + & + + = + + true + + + + TalkingData + + + + + + + .lnk0.com + + + DbXiUlEVN + s + + + false + + 604800 + + 1 + + md5 + raw + md5 + raw + + + + + + + + OS + osversion + true + true + + + TS + time + true + true + + + MAC + mac_md5 + true + true + + + IDFA + idfa + true + true + + + IMEI + imei_md5 + true + true + + + RAWIMEI + m3 + true + false + + + ANDROIDID + androidid + true + true + + + WIFI + nm + true + false + + + AKEY + pname + true + true + + + ANAME + aname + true + false + + + + SCWH + scwh + true + false + + + + WIFISSID + ssid + true + false + + + + WIFIBSSID + bssid + true + false + + + OPENUDID + openudid + true + false + + + TERM + devicetype + true + false + + + OSVS + osvs + true + false + + + LBS + mm + true + false + + + SDKVS + sdkvs + true + false + + + REDIRECTURL + o + true + false + + + + + + start + mb=start + false + + + + end + mb=end + false + + + + + Adplacement + adid + false + false + + + + + ImpressionID + vimpid + true + false + + + AdviewabilityRecord + va + true + false + + + AdviewabilityEvents + vct + true + false + + + AdviewabilityTime + 1 + true + false + + + AdviewabilityFrame + 2 + true + false + + + AdviewabilityPoint + 3 + true + false + + + AdviewabilityAlpha + 4 + true + false + + + AdviewabilityShown + 5 + true + false + + + AdviewabilityCoverRate + 6 + true + false + + + AdviewabilityShowFrame + 7 + true + false + + + AdviewabilityForground + 8 + true + false + + + AdviewabilityResult + vx + true + false + + + Adviewability + isview + true + false + + + AdMeasurability + ism + true + false + + + AdviewabilityConfigArea + vcr + true + false + + + AdviewabilityConfigThreshold + vtime + true + false + + + AdviewabilityVideoDuration + vb + true + false + + + AdviewabilityVideoProgress + vc + true + false + + + AdviewabilityVideoPlayType + vpt + true + false + + + AdviewabilityVideoProgressPoint + vj + true + false + + + + & + + = + + true + + + + diff --git a/MobileTracking/MobileTracking.xcodeproj/project.pbxproj b/MobileTracking/MobileTracking.xcodeproj/project.pbxproj index f5515b2223780871a6d790121bcc4f5d3af5aecf..39bc902766e95e5eaa0216b66e2c5e99d11e4a0a 100755 --- a/MobileTracking/MobileTracking.xcodeproj/project.pbxproj +++ b/MobileTracking/MobileTracking.xcodeproj/project.pbxproj @@ -116,6 +116,8 @@ AFB3717C1F3854770092930F /* ViewabilityJSService.m in Sources */ = {isa = PBXBuildFile; fileRef = AFB3716A1F3854770092930F /* ViewabilityJSService.m */; }; AFB87D332004BAA000A02E0C /* libMMASign.a in Frameworks */ = {isa = PBXBuildFile; fileRef = AFB87D322004BA9E00A02E0C /* libMMASign.a */; }; AFB87D342004BAA100A02E0C /* libMMASign.a in Frameworks */ = {isa = PBXBuildFile; fileRef = AFB87D322004BA9E00A02E0C /* libMMASign.a */; }; + C74B70AF2372C1900031DE10 /* MMA_IVTInfoService.m in Sources */ = {isa = PBXBuildFile; fileRef = C74B70AE2372C1900031DE10 /* MMA_IVTInfoService.m */; }; + C74B70B02372C1900031DE10 /* MMA_IVTInfoService.m in Sources */ = {isa = PBXBuildFile; fileRef = C74B70AE2372C1900031DE10 /* MMA_IVTInfoService.m */; }; C765ABE023262B660066E906 /* WebKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C765ABDF23262B660066E906 /* WebKit.framework */; }; C765ABE123262B710066E906 /* WebKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C765ABDF23262B660066E906 /* WebKit.framework */; }; C765ABE223262C040066E906 /* WebKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C765ABDF23262B660066E906 /* WebKit.framework */; }; @@ -251,6 +253,10 @@ AFB371691F3854770092930F /* ViewabilityJSService.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ViewabilityJSService.h; sourceTree = ""; }; AFB3716A1F3854770092930F /* ViewabilityJSService.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ViewabilityJSService.m; sourceTree = ""; }; AFB87D322004BA9E00A02E0C /* libMMASign.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libMMASign.a; sourceTree = ""; }; + C74B70AD2372C1900031DE10 /* MMA_IVTInfoService.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MMA_IVTInfoService.h; sourceTree = ""; }; + C74B70AE2372C1900031DE10 /* MMA_IVTInfoService.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MMA_IVTInfoService.m; sourceTree = ""; }; + C74B78322375573A0031DE10 /* Photos.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Photos.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Photos.framework; sourceTree = DEVELOPER_DIR; }; + C74B7835237557510031DE10 /* PhotosUI.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = PhotosUI.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/PhotosUI.framework; sourceTree = DEVELOPER_DIR; }; C765ABDF23262B660066E906 /* WebKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = WebKit.framework; path = System/Library/Frameworks/WebKit.framework; sourceTree = SDKROOT; }; /* End PBXFileReference section */ @@ -319,6 +325,8 @@ 2A632A1A18CEB10B00BE2533 /* Frameworks */ = { isa = PBXGroup; children = ( + C74B7835237557510031DE10 /* PhotosUI.framework */, + C74B78322375573A0031DE10 /* Photos.framework */, C765ABDF23262B660066E906 /* WebKit.framework */, 2ABFE29718CF2B5F007BD457 /* CoreLocation.framework */, 2ABFE28118CF1778007BD457 /* UIKit.framework */, @@ -479,6 +487,8 @@ 2ABFE29918CFF9EF007BD457 /* Service */ = { isa = PBXGroup; children = ( + C74B70AD2372C1900031DE10 /* MMA_IVTInfoService.h */, + C74B70AE2372C1900031DE10 /* MMA_IVTInfoService.m */, 2A79BC1D18D2DC2900FC62C1 /* MMA_TrackingInfoService.h */, 2A79BC1E18D2DC2900FC62C1 /* MMA_TrackingInfoService.m */, AF59E97120510DDF00994BCF /* MMA_LocationService.h */, @@ -707,6 +717,7 @@ AFB371711F3854770092930F /* VAJavascriptBridge.m in Sources */, 2ABFE2A118D02ED2007BD457 /* MMA_GTMNSString+URLArguments.m in Sources */, 7791985F229FB9C10090A788 /* MMA_AdViewMonitor.m in Sources */, + C74B70AF2372C1900031DE10 /* MMA_IVTInfoService.m in Sources */, AF1AAE9C1EF61EF300E9C276 /* VAMonitorConfig.m in Sources */, AFB3717B1F3854770092930F /* ViewabilityJSService.m in Sources */, AF1AAEA61EF61EF300E9C276 /* VAViewMonitor.m in Sources */, @@ -761,6 +772,7 @@ 2A81720C18DAEB3A00E0EFEC /* MMA_TaskQueue.m in Sources */, AFB371741F3854770092930F /* VAJavascriptParse.m in Sources */, AFB371721F3854770092930F /* VAJavascriptBridge.m in Sources */, + C74B70B02372C1900031DE10 /* MMA_IVTInfoService.m in Sources */, 2A81720D18DAEB3A00E0EFEC /* MMA_GTMNSString+URLArguments.m in Sources */, AF1AAE9D1EF61EF300E9C276 /* VAMonitorConfig.m in Sources */, AFB3717C1F3854770092930F /* ViewabilityJSService.m in Sources */, diff --git a/MobileTracking/MobileTracking/Config/MMA_SDKConfig.h b/MobileTracking/MobileTracking/Config/MMA_SDKConfig.h index 7c670ff69490812f6df5c3f593e0965af2bd0fc1..1538dad2777c2f6af7a414ffdc1d041edd847892 100755 --- a/MobileTracking/MobileTracking/Config/MMA_SDKConfig.h +++ b/MobileTracking/MobileTracking/Config/MMA_SDKConfig.h @@ -50,6 +50,7 @@ @property (nonatomic, strong) NSMutableDictionary *arguments; @property (nonatomic, strong) NSMutableDictionary *Adplacement; @property (nonatomic, strong) NSMutableDictionary *viewabilityarguments; +@property (nonatomic, strong) NSMutableDictionary *sensorarguments; @end /*--------------加密签名设置--------------*/ @interface MMA_Signature : NSObject @@ -76,6 +77,7 @@ @property (nonatomic, strong) MMA_Config *config ; @property (nonatomic, strong) NSString *separator; @property (nonatomic, strong) NSString *equalizer; +@property (nonatomic, strong) NSString *antidevice; @property (nonatomic, assign) Boolean timeStampUseSecond; @property (nonatomic, strong) NSString *jsname; @property (nonatomic, strong) NSString *jsurl; diff --git a/MobileTracking/MobileTracking/Config/MMA_XMLReader.m b/MobileTracking/MobileTracking/Config/MMA_XMLReader.m index 7c7513ae9737d72546eed8e4b659e7bec2cebe8b..e77b41ff11ffa28e8617255c11cda4117c9695c5 100755 --- a/MobileTracking/MobileTracking/Config/MMA_XMLReader.m +++ b/MobileTracking/MobileTracking/Config/MMA_XMLReader.m @@ -128,6 +128,7 @@ company.separator = [[[element elementsForName:@"separator" ] firstObject] stringValue]; company.equalizer = [[[element elementsForName:@"equalizer" ] firstObject] stringValue]; + company.antidevice = [[[element elementsForName:@"antidevice" ] firstObject] stringValue]; if (company.equalizer == nil) { company.equalizer = @""; } @@ -201,6 +202,19 @@ [company.config.viewabilityarguments setValue:argument forKey:argument.key]; } + + company.config.sensorarguments = [NSMutableDictionary dictionary]; + NSArray *sensorarguments = [element nodesForXPath:@"config/sensorarguments/argument" error:nil]; + for(MMA_GDataXMLElement *el in sensorarguments){ + MMA_Argument *argument = [[MMA_Argument alloc] init]; + argument.key = [self StringTrimFromElement:el name:@"key"]; + argument.value = [self StringTrimFromElement:el name:@"value"]; + argument.urlEncode = [[self StringTrimFromElement:el name:@"urlEncode"] boolValue]; + argument.isRequired = [[self StringTrimFromElement:el name:@"isRequired"] boolValue]; + [company.config.sensorarguments setValue:argument forKey:argument.key]; + } + + [sdkConfig.companies setValue:company forKey:company.name]; } } diff --git a/MobileTracking/MobileTracking/MMA_Macro.h b/MobileTracking/MobileTracking/MMA_Macro.h index c979897ceb84bccebab094810cd219822086d9c5..9013bb90752f9ad60a1d9d0f7c1cda4d570c47d4 100755 --- a/MobileTracking/MobileTracking/MMA_Macro.h +++ b/MobileTracking/MobileTracking/MMA_Macro.h @@ -9,7 +9,7 @@ #ifndef MobileTracking_Macro_h #define MobileTracking_Macro_h -#define MMA_SDK_VERSION @"V2.1.2" +#define MMA_SDK_VERSION @"V2.1.4" #define NOTIFICATION_VB @"viewability_notification" #define NOTIFICATION_EXPOSE @"expose_notification" @@ -34,6 +34,8 @@ #define UPDATE_SDK_CONFIG_WIFI_INTERVAL (1 * 24 * 60 * 60) #define UPDATE_SDK_CONFIG_3G_INTERVAL (3 * 24 * 60 * 60) #define LOCATION_UPDATE_INTERVAL 120 //定位刷新间隔 单位:秒 +#define SENSOR_UPDATE_INTERVAL 3600 //传感器刷新间隔 单位:秒 +#define SENSOR_COLLECT_TIME 0.5 //传感器采集时间 单位:秒 #define NETWORK_STATUS_WIFI 1 #define NETWORK_STATUS_3G 0 @@ -90,8 +92,53 @@ #define AD_VB_VIDEOPLAYTYPE @"AdviewabilityVideoPlayType" //可视监测传入的视频播放类型 #define AD_VB_VIDEOPROGRESS @"AdviewabilityVideoProgress" //可视视频播放进度监测事件类型字段 (string)播放 1/4:25 播放 1/2:50播放 3/4:75 播放完成:100 - - + + + + + + + + + +/**IVT参数*/ +/**是否越狱*/ +#define IVT_isRoot @"isRoot" +/**剩余电量*/ +#define IVT_electricity @"electricity" +/**是否充电*/ +#define IVT_isCharging @"isCharging" +/**是否模拟器*/ +#define IVT_isSimulator @"isSimulator" +/**是否hook*/ +#define IVT_isHook @"isHook" +/**是否刷机*/ +#define IVT_isFlash @"isFlash" +/**加速度*/ +#define IVT_Accelerometer @"Accelerometer" +/**磁场*/ +#define IVT_Magnetometer @"Magnetometer" +/**方向*/ +#define IVT_direction @"direction" +/**陀螺仪*/ +#define IVT_gyroActive @"gyroActive" +/**光线*/ +#define IVT_brightness @"brightness" +/**气压*/ +#define IVT_pressure @"pressure" +/**温度*/ +#define IVT_temperature @"temperature" +/**距离*/ +#define IVT_proximity @"proximity" +/**重力*/ +#define IVT_deviceMotion @"deviceMotion" +/**线性加速度*/ +#define IVT_lineAccelerometer @"lineAccelerometer" +/**旋转矢量*/ +#define IVT_RotationVector @"RotationVector" + +#define IVT_ARRAY @[IVT_isRoot,IVT_electricity,IVT_isCharging,IVT_isSimulator,IVT_isHook,IVT_isFlash,IVT_Accelerometer,IVT_Magnetometer,IVT_direction,IVT_gyroActive,IVT_brightness,IVT_pressure,IVT_temperature,IVT_proximity,IVT_deviceMotion,IVT_lineAccelerometer,IVT_RotationVector] + //switch #define AD_VB_POLICY @"viewabilityTrackPolicy" //可视化监测采集策略 diff --git a/MobileTracking/MobileTracking/MobileTracking.h b/MobileTracking/MobileTracking/MobileTracking.h index 43bd1c058b1a87035d3f330522af1d6dea82dc6d..510de4883c55547c8f619c5e82f27bb3df5470f2 100755 --- a/MobileTracking/MobileTracking/MobileTracking.h +++ b/MobileTracking/MobileTracking/MobileTracking.h @@ -6,7 +6,7 @@ // Copyright (c) 2014年 Admaster. All rights reserved. // -//#define MMA_SDK_VERSION @"V2.1.2" +//#define MMA_SDK_VERSION @"V2.1.4" #import diff --git a/MobileTracking/MobileTracking/MobileTracking.m b/MobileTracking/MobileTracking/MobileTracking.m index 35b8506f213448d30146b463f3590f8fdbf37065..0dc5e4a8185f5cb4e09df44d3a4df5f29a38c798 100755 --- a/MobileTracking/MobileTracking/MobileTracking.m +++ b/MobileTracking/MobileTracking/MobileTracking.m @@ -26,6 +26,7 @@ #import "VAMonitorConfig.h" #import "ViewabilityJSService.h" #import "VAViewCapture.h" +#import "MMA_IVTInfoService.h" @interface MobileTracking() @@ -93,12 +94,25 @@ [self initTimer]; [self openLBS]; [self initViewabilityService]; + // [self performSelector:@selector(initSensor) withObject:nil afterDelay:0.1]; } return self; } - +-(void)initSensor{ + + [[MMA_IVTInfoService sharedInstance] updateSensorInfo:^{ + + MMA_IVTInfoService * ivt = [MMA_IVTInfoService sharedInstance] ; + +// +// NSLog(@"加速度:%@ =陀螺仪:%@= 磁场:%@= 重力值:%@ = 方向值:%@= 气压:%@ = 光线强弱:%@",ivt.Accelerometer,ivt.gyroActive,ivt.Magnetometer,ivt.deviceMotion,ivt.direction,ivt.pressure,ivt.brightness); +// +// NSLog(@"越狱:%ld , 充电:%ld, 模拟器:%ld,剩余电量:%lf,距离:%ld",ivt.isRoot,ivt.isCharging,ivt.isSimulator,ivt.electricity,ivt.proximity); + }]; + +} - (void)initSdkConfig { @try { @@ -387,10 +401,26 @@ // 去掉字段2g 如果有2j 去掉AdMeasurability Adviewability AdviewabilityEvents ImpressionID四个字段生成链接 -- (MMA_VBOpenResult *)vbFilterURL:(NSString *)url isForViewability:(BOOL)viewability isVideo:(BOOL)isVideo { +- (MMA_VBOpenResult *)vbFilterURL:(NSString *)url isForViewability:(BOOL)viewability isVideo:(BOOL)isVideo videoPlayType:(NSInteger)type{ + + @try { MMA_Company *company = [self confirmCompany:url]; + NSString *svl = company.antidevice; + + if (svl) { + [[MMA_IVTInfoService sharedInstance] updateSensorInfo:^{ + +// MMA_IVTInfoService * ivt = [MMA_IVTInfoService sharedInstance] ; +// +// +// NSLog(@"加速度:%@ =陀螺仪:%@= 磁场:%@= 重力值:%@ = 方向值:%@= 气压:%@ = 光线强弱:%@",ivt.Accelerometer,ivt.GyroActive,ivt.Magnetometer,ivt.DeviceMotion,ivt.Direction,ivt.Pressure,ivt.Brightness); +// +// NSLog(@"越狱:%ld , 充电:%ld, 模拟器:%ld,剩余电量:%lf,距离:%ld",ivt.isRoot,ivt.isCharging,ivt.isSimulator,ivt.Electricity,ivt.Proximity); + }]; + } + MMA_VBOpenResult *res = [[MMA_VBOpenResult alloc] init]; res.config = self.viewabilityConfig; // 初始化默认配置为当前的配置 res.url = url; @@ -527,6 +557,11 @@ } else if([key isEqualToString:AD_VB_VIDEOPROGRESS]) { //2a res.config.needRecordProgress = YES; } + /**加入第一次可见曝光监测中videoType vg字段*/ + else if([key isEqualToString:AD_VB_VIDEOPLAYTYPE]&&isVideo) { //2a + reWriteString = [NSString stringWithFormat:@"%@%@%@%ld", separator, value, equalizer,(long)type] ; + + } // if contain enable key in url set viewability service OPEN(yes) // else if ([key isEqualToString:AD_VB_ENABLE]) { //2p // if([self isExitKey:value inURL:url withCompany:company]) { @@ -557,6 +592,42 @@ } res.canOpen = NO; } +#pragma mark == ivt == + + + if (svl) { + + + + + NSString *separator = company.separator; + NSString *equalizer = company.equalizer; + + NSArray *sensorArray = [MMA_IVTInfoService ArrayWithDict:company.config.sensorarguments]; + for (NSInteger i =0; i5) { + str = @"-"; + } + [mutableDic addEntriesFromDictionary:@{value:str?str:@"-"}]; + + + + + + } + } + } + + + if(mutableDic && mutableDic.count) { + + NSArray * ivtArray = [MMA_IVTInfoService ArrayWithDict2:mutableDic]; + + + NSString * ivtStr = [NSString stringWithFormat:@"{%@}", [ivtArray componentsJoinedByString:@","]]; + + [trackURL appendFormat:@"%@%@%@%@", company.separator, company.antidevice, company.equalizer, [ivtStr gtm_stringByEscapingForURLArgument]]; + + } + + } + + if (redirecturl !=nil&&![redirecturl isEqualToString:@""]) { [trackURL appendString:redirecturl]; } diff --git a/MobileTracking/MobileTracking/Service/MMA_IVTInfoService.h b/MobileTracking/MobileTracking/Service/MMA_IVTInfoService.h new file mode 100644 index 0000000000000000000000000000000000000000..f9e5d683e7f26f58c87af7189bd45824d269a74a --- /dev/null +++ b/MobileTracking/MobileTracking/Service/MMA_IVTInfoService.h @@ -0,0 +1,53 @@ +// +// MMA_IVTInfoService.h +// MobileTracking +// +// Created by DeveWang on 2019/11/1. +// Copyright © 2019 Admaster. All rights reserved. +// + +#import + + + +@interface MMA_IVTInfoService : NSObject ++ (MMA_IVTInfoService *)sharedInstance; + +/**是否越狱*/ +-(BOOL)isRoot; +/**剩余电量*/ +-(double)Electricity; +/**是否充电*/ +-(BOOL)isCharging; +/**是否模拟器*/ +-(BOOL)isSimulator; + /**距离*/ + -(BOOL)Proximity; + +/**加速度值*/ +@property(nonatomic,strong)NSArray * Accelerometer; +/**陀螺仪值*/ +@property(nonatomic,strong)NSArray * GyroActive; +/**磁场值*/ +@property(nonatomic,strong)NSArray * Magnetometer; +/**重力值*/ +@property(nonatomic,strong)NSArray * DeviceMotion; +/**气压值*/ +@property(nonatomic,copy)NSString * Pressure; +/**方向传感器*/ +@property(nonatomic,strong)NSArray * Direction; + +/**光线强弱*/ +@property(nonatomic,strong)NSArray * Brightness; + +-(void)updateSensorInfo:(void(^)())result; +/**距离上次刷新时间s*/ +-(NSInteger )timeDifference; + +//根据value排序 ++(NSArray*)ArrayWithDict:(NSDictionary*)dict; +//根据value排序2 ++(NSArray*)ArrayWithDict2:(NSDictionary*)dict; +@end + + diff --git a/MobileTracking/MobileTracking/Service/MMA_IVTInfoService.m b/MobileTracking/MobileTracking/Service/MMA_IVTInfoService.m new file mode 100644 index 0000000000000000000000000000000000000000..972ff450294de8709cbbb2c534b5101edbd29ea9 --- /dev/null +++ b/MobileTracking/MobileTracking/Service/MMA_IVTInfoService.m @@ -0,0 +1,550 @@ +// +// MMA_IVTInfoService.m +// MobileTracking +// +// Created by DeveWang on 2019/11/1. +// Copyright © 2019 Admaster. All rights reserved. +// + +#import "MMA_IVTInfoService.h" +#import +#import +#import +#import +#import "MMA_Log.h" +#import "MMA_Macro.h" +#import + +#define SENSOR_LAST_TIME @"SENSOR_LAST_TIME" +#define SENSOR_UPDATE_TIME 0.1 +/*--------------参数设置-----------------*/ +@interface MMA_Argument : NSObject + +@property (nonatomic, strong) NSString *key; +@property (nonatomic, strong) NSString *value; +@property (nonatomic, assign) Boolean urlEncode; +@property (nonatomic, assign) Boolean isRequired; + +@end + +@interface MMA_IVTInfoService () + +/**距离传感器是否可用*/ +@property(nonatomic,assign)BOOL proximityMonitoringEnabled; +/**加速器是否可用*/ +@property(nonatomic,assign)BOOL accelerationEnable; +/**陀螺仪是否可用*/ +@property(nonatomic,assign)BOOL gyroEnable; +/**磁力器是否可用*/ +@property(nonatomic,assign)BOOL magnetEnable; +/**摄像头亮度是否可用*/ +@property(nonatomic,assign)BOOL CameraBrightnessEnable; + +@property(nonatomic,assign)NSInteger lastTime; + +@property(nonatomic,strong)NSMutableArray * brightnessAry; +@property(nonatomic,strong)NSMutableArray * directionAry; +/**光感检测*/ +@property (nonatomic, strong) AVCaptureSession *session; +/**方向传感器*/ +@property (nonatomic, strong) CLLocationManager *locationManager; + +// 其他 +@property (nonatomic, strong) CMMotionManager *motionManage; +@property (nonatomic, strong) CMPedometer *pedometer; +@property (nonatomic, strong) AVCaptureSession *captureSession; +@property(nonatomic,strong) CMAltimeter *altimeter; + +@property (nonatomic, strong) dispatch_source_t gcd_timer; + +/**采集次数*/ +@property(nonatomic,assign)NSInteger Count; + + + + +@end + +@implementation MMA_IVTInfoService{ + + + __block BOOL _updateing ; + + +} + ++ (MMA_IVTInfoService *)sharedInstance { + + static MMA_IVTInfoService *_sharedInstance = nil; + static dispatch_once_t onceToken; + dispatch_once(&onceToken, ^{ + _sharedInstance = [[self alloc] init]; + _sharedInstance.brightnessAry = [[NSMutableArray alloc]init]; + _sharedInstance.directionAry = [[NSMutableArray alloc]init]; + _sharedInstance.Count = SENSOR_COLLECT_TIME/SENSOR_UPDATE_TIME; + // [_sharedInstance checkEnable]; + + }); + return _sharedInstance; +} + +- (CMMotionManager *)motionManage { + if (!_motionManage) { + + _motionManage = [[CMMotionManager alloc] init]; + // 控制传感器的更新间隔 + _motionManage.accelerometerUpdateInterval = SENSOR_UPDATE_TIME; + _motionManage.gyroUpdateInterval = SENSOR_UPDATE_TIME; + _motionManage.magnetometerUpdateInterval = SENSOR_UPDATE_TIME; + _motionManage.deviceMotionUpdateInterval = SENSOR_UPDATE_TIME; + + } + return _motionManage; +} +- (CLLocationManager *)locationManager { + if (!_locationManager) { + + _locationManager = [[CLLocationManager alloc] init]; + _locationManager.desiredAccuracy = kCLLocationAccuracyBest; + _locationManager.delegate = self; + [_locationManager requestWhenInUseAuthorization]; + + } + return _locationManager; +} + +- (AVCaptureSession *)session { + if (!_session) { + + _session = [[AVCaptureSession alloc] init]; + + } + return _session; +} + + + + +// 检查设备的可用性 +- (void)checkEnable{ + + // 距离传感器 + // 当设置proximityMonitoringEnabled为YES后,属性值仍然为NO,说明传感器不可用。 + [UIDevice currentDevice].proximityMonitoringEnabled = YES; + self.proximityMonitoringEnabled = [UIDevice currentDevice].proximityMonitoringEnabled; + [UIDevice currentDevice].proximityMonitoringEnabled = NO; + + + // 加速计 + self.accelerationEnable = self.motionManage.isAccelerometerAvailable; + + // 陀螺仪 + self.gyroEnable = self.motionManage.isGyroAvailable; + + // 磁力计 + self.magnetEnable = self.motionManage.isMagnetometerAvailable; + + // 摄像头 + self.CameraBrightnessEnable = [UIImagePickerController isCameraDeviceAvailable:UIImagePickerControllerCameraDeviceRear]; + + +} +-(void)updateSensorInfo:(void (^)())result{ + + if ([self timeDifference] v2) +// return NSOrderedDescending; +// else +// return NSOrderedSame; + return[v1 compare:v2 options:64];//正序 + }]; + + + + return sortedArray; + +} +/**字典根据value进行排序2*/ ++(NSArray*)ArrayWithDict2:(NSDictionary*)dict{ + + NSArray*keys = [dict allKeys]; + + + NSArray*sortedArray = [keys sortedArrayUsingComparator:^NSComparisonResult(id obj1,id obj2) { + + +// if (v1 < v2) +// return NSOrderedAscending; +// else if (v1 > v2) +// return NSOrderedDescending; +// else +// return NSOrderedSame; + return[obj1 compare:obj2 options:64];//正序 + }]; + + NSMutableArray *valueArray = [NSMutableArray array]; + for(NSString *sortSring in sortedArray){ + NSString *signSring = [NSString stringWithFormat:@"%@=%@",sortSring,[dict objectForKey:sortSring]]; + [valueArray addObject:signSring]; + } + + + return valueArray; + +} +-(void)saveLastTime{ + + self.lastTime = [[NSDate date] timeIntervalSince1970]; + [[NSUserDefaults standardUserDefaults] setInteger: self.lastTime forKey:SENSOR_LAST_TIME]; + +} + +@end diff --git a/MobileTracking/MobileTracking/Service/MMA_TrackingInfoService.m b/MobileTracking/MobileTracking/Service/MMA_TrackingInfoService.m index 3d2797e7e6bd9c9378d725ab98d2992e21e43bcf..ca9946aca164257f9511c95daca2506ea0aefee2 100755 --- a/MobileTracking/MobileTracking/Service/MMA_TrackingInfoService.m +++ b/MobileTracking/MobileTracking/Service/MMA_TrackingInfoService.m @@ -14,7 +14,7 @@ #import "MMA_Reachability.h" #import "MMA_Macro.h" #import - +static NSString *openUDID = nil; @implementation MMA_TrackingInfoService + (MMA_TrackingInfoService *)sharedInstance { @@ -71,8 +71,19 @@ - (NSString *)openUDID { - NSString *openUDID = [MMA_OpenUDID value]; - return openUDID ? openUDID : @""; + if (openUDID) { + + return openUDID; + }else{ + + dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(0 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{ + openUDID = [MMA_OpenUDID value]; + }); + + } + + + return openUDID ? openUDID : @""; } - (NSString *)location diff --git a/MobileTracking/MobileTracking/Vendor/RequestQueue/MMA_RequestQueue.m b/MobileTracking/MobileTracking/Vendor/RequestQueue/MMA_RequestQueue.m index 537f06c1130e6bd4f9e02d4730e688924c76fe49..e2ddbbd90dff97f82aa4849861b53413140499bc 100755 --- a/MobileTracking/MobileTracking/Vendor/RequestQueue/MMA_RequestQueue.m +++ b/MobileTracking/MobileTracking/Vendor/RequestQueue/MMA_RequestQueue.m @@ -142,6 +142,8 @@ NSString *const MMAHTTPResponseErrorDomain = @"MMAHTTPResponseErrorDomain"; } } + [self.connectionSession invalidateAndCancel]; + self.connectionSession = nil; } - (void)finish @@ -158,6 +160,8 @@ NSString *const MMAHTTPResponseErrorDomain = @"MMAHTTPResponseErrorDomain"; [self didChangeValueForKey:@"isExecuting"]; } } + [self.connectionSession invalidateAndCancel]; + self.connectionSession = nil; } - (NSSet *)autoRetryErrorCodes @@ -216,6 +220,9 @@ NSString *const MMAHTTPResponseErrorDomain = @"MMAHTTPResponseErrorDomain"; if (_completionHandler) _completionHandler(_responseReceived, _accumulatedData, error); } + + [self.connectionSession invalidateAndCancel]; + self.connectionSession = nil; } - (void) URLSession:(NSURLSession *)session dataTask:(nonnull NSURLSessionDataTask *)dataTask didReceiveData:(nonnull NSData *)data { @@ -226,11 +233,15 @@ NSString *const MMAHTTPResponseErrorDomain = @"MMAHTTPResponseErrorDomain"; } [_accumulatedData appendData:data]; + + } - (void) URLSession:(NSURLSession *)session dataTask:(NSURLSessionDataTask *)dataTask didReceiveResponse:(NSURLResponse *)response completionHandler:(void (^)(NSURLSessionResponseDisposition))completionHandler { _responseReceived = response; completionHandler(NSURLSessionResponseAllow); + + } @@ -240,6 +251,8 @@ NSString *const MMAHTTPResponseErrorDomain = @"MMAHTTPResponseErrorDomain"; _isRedirect = YES; } completionHandler(request); + + } #pragma mark - NSURLConnectionDelegate diff --git a/MobileTracking/Viewability/VAMonitor.m b/MobileTracking/Viewability/VAMonitor.m index 8f9e71cf35dab603129fe52ad28a04b2c043c9e5..b3053c9365af4349103c658b8907964009ee64ca 100644 --- a/MobileTracking/Viewability/VAMonitor.m +++ b/MobileTracking/Viewability/VAMonitor.m @@ -207,10 +207,10 @@ } // 视频类型传入 - if (self.isVideo) { - [parmaters setValue:[NSString stringWithFormat:@"%ld", (long)self.config.videoPlayType] forKey:AD_VB_VIDEOPLAYTYPE]; - } - +// if (self.isVideo) { +// [parmaters setValue:[NSString stringWithFormat:@"%ld", (long)self.config.videoPlayType] forKey:AD_VB_VIDEOPLAYTYPE]; +// } +// NSMutableDictionary *accessDictionary = [NSMutableDictionary dictionary]; [parmaters enumerateKeysAndObjectsUsingBlock:^(NSString * key, id obj, BOOL * _Nonnull stop) { if([self canRecord:key]) { diff --git a/MobileTracking/Viewability/ViewabilityService.m b/MobileTracking/Viewability/ViewabilityService.m index f0d67ba1b418cb5c353ec4e39694235164be27e4..4f9c0eca529a713136a0a7b153c0905f91d793ce 100644 --- a/MobileTracking/Viewability/ViewabilityService.m +++ b/MobileTracking/Viewability/ViewabilityService.m @@ -184,16 +184,23 @@ static const char *view_capture_queue = "adview.capture.queue"; - (void)processCacheMonitorsWithDelegate:(id )delegate { dispatch_async(_captureQueue, ^{ if([[NSFileManager defaultManager] fileExistsAtPath:VA_MONITOR_SAVE_PATH isDirectory:nil]) { - NSDictionary *cacheMonitors = [NSKeyedUnarchiver unarchiveObjectWithData:[NSData dataWithContentsOfFile:VA_MONITOR_SAVE_PATH]]; - NSLog(@"读取%lu条缓存数据",(unsigned long)[[cacheMonitors allKeys] count]); - [cacheMonitors enumerateKeysAndObjectsUsingBlock:^(NSString * _Nonnull key, VAMonitor * _Nonnull obj, BOOL * _Nonnull stop) { - obj.delegate = delegate; - // 如果已经上传过监测数据,则不再上传 - if(obj.status != VAMonitorStatusUploaded) { - [obj stopAndUpload]; - } - }]; - [[NSFileManager defaultManager] removeItemAtPath:VA_MONITOR_SAVE_PATH error:nil]; + @try { + NSDictionary *cacheMonitors = [NSKeyedUnarchiver unarchiveObjectWithData:[NSData dataWithContentsOfFile:VA_MONITOR_SAVE_PATH]]; + NSLog(@"读取%lu条缓存数据",(unsigned long)[[cacheMonitors allKeys] count]); + [cacheMonitors enumerateKeysAndObjectsUsingBlock:^(NSString * _Nonnull key, VAMonitor * _Nonnull obj, BOOL * _Nonnull stop) { + obj.delegate = delegate; + // 如果已经上传过监测数据,则不再上传 + if(obj.status != VAMonitorStatusUploaded) { + [obj stopAndUpload]; + } + }]; + [[NSFileManager defaultManager] removeItemAtPath:VA_MONITOR_SAVE_PATH error:nil]; + } @catch (NSException *exception) { + + } @finally { + + } + } }); } diff --git a/MobileTracking/build.sh b/MobileTracking/build.sh index 273524e3fdac1f4abeb116deaad19207a67b60fd..3b70430688ce80fb4a6f014123cf58bfb30abb72 100755 --- a/MobileTracking/build.sh +++ b/MobileTracking/build.sh @@ -12,10 +12,10 @@ iphonesimulator_path=${UNIVERSAL_OUTPUTFOLDER}/${CONFIGURATION}-iphonesimulator ${$targetName:?"mush set targetName"} xcodebuild -target $targetName clean # clean project -xcodebuild -target $targetName -sdk iphoneos12.4 # build iphoneos +xcodebuild -target $targetName -sdk iphoneos13.0 # build iphoneos #build iphonesimulator -xcodebuild -target $targetName -configuration ${CONFIGURATION} -sdk iphonesimulator12.4 -arch x86_64 -arch i386 +xcodebuild -target $targetName -configuration ${CONFIGURATION} -sdk iphonesimulator13.0 -arch x86_64 -arch i386 if [ ! -d "$universal_path" ]; then #判断文件是否存在 不存在创建 中括号两边要空格 mkdir "$universal_path" diff --git a/OutputRelease/MobileTracking.h b/OutputRelease/MobileTracking.h index 43bd1c058b1a87035d3f330522af1d6dea82dc6d..510de4883c55547c8f619c5e82f27bb3df5470f2 100644 --- a/OutputRelease/MobileTracking.h +++ b/OutputRelease/MobileTracking.h @@ -6,7 +6,7 @@ // Copyright (c) 2014年 Admaster. All rights reserved. // -//#define MMA_SDK_VERSION @"V2.1.2" +//#define MMA_SDK_VERSION @"V2.1.4" #import diff --git a/OutputRelease/libMobileTracking.a b/OutputRelease/libMobileTracking.a index 90e27a79c18fe3d75519a7c644eb4509bbba2434..3324d63de8acb3d67095fc3485901afece5bda0f 100644 Binary files a/OutputRelease/libMobileTracking.a and b/OutputRelease/libMobileTracking.a differ diff --git a/OutputRelease/sdkconfig.xml b/OutputRelease/sdkconfig.xml index d46bf37c6d1eb27affbe55ef93b174bd26903780..4a540a2cc2214d17b7b71095a814a3e04cac6ed3 100644 --- a/OutputRelease/sdkconfig.xml +++ b/OutputRelease/sdkconfig.xml @@ -2,17 +2,17 @@ - + - + 0 60 60 - + @@ -28,23 +28,23 @@ 20 - + admaster - + - + admaster.com.cn - + @@ -52,7 +52,7 @@ 0b - + true @@ -60,7 +60,7 @@ 259200 0 - + @@ -72,18 +72,18 @@ md5 - + - - https://p.attri.mobi/a - - 24 - - true + + https://p.attri.mobi/a + + 24 + + true - + @@ -175,7 +175,7 @@ true true - + @@ -227,7 +227,7 @@ true - + @@ -243,8 +243,8 @@ true - - + + @@ -254,10 +254,10 @@ false - + - + ImpressionID @@ -265,7 +265,7 @@ true true - + @@ -352,7 +352,7 @@ true - + @@ -397,7 +397,7 @@ true - + - + - + , @@ -420,7 +420,7 @@ true - + miaozhen @@ -441,21 +441,21 @@ 604800 1 - + md5 raw md5 md5 - - + + - - /apl/ - - 24 - false + + /apl/ + + 24 + false @@ -511,7 +511,7 @@ true true - + OAID @@ -519,7 +519,7 @@ true true - + ADID @@ -771,7 +771,7 @@ true true - + AdviewabilityStrongInteract @@ -779,20 +779,144 @@ true true - + - - & - - - https://g.cn.miaozhen.com/x/k=adid - + + + + + isRoot + l1 + true + true + + + + Electricity + l2 + true + true + + + + isCharging + l3 + true + true + + + + isSimulator + l4 + true + true + + + + isHook + l5 + true + true + + + + isFlash + l6 + true + true + + + + Accelerometer + l7 + true + true + + + + Magnetometer + l8 + true + true + + + + Direction + l9 + true + true + + + + GyroActive + l10 + true + true + + + + Brightness + l11 + true + true + + + + Pressure + l12 + true + true + + + + Temperature + l13 + true + true + + + + Proximity + l14 + true + true + + + + DeviceMotion + l15 + true + true + + + + LineAccelerometer + l16 + true + true + + + + RotationVector + l17 + true + true + + + + & + + + https://g.cn.miaozhen.com/x/k=adid + + + svl = - + true - + girdsum @@ -800,7 +924,6 @@ gridsumdissector.com - @@ -814,10 +937,10 @@ 1 - raw - md5 + md5 + raw md5 - raw + md5 @@ -830,63 +953,79 @@ true true - + TS ts true true - + MAC m true true - + IDFA if true true - + IMEI im true true - + ANDROIDID aid true true - + + + + OAID + oa + true + true + + + + + ADID + adid + true + true + + WIFI wifi true true - + AKEY ak true true - + ANAME an true true - + SCWH @@ -894,56 +1033,56 @@ true true - + OPENUDID oid true true - + ODIN odin true true - + TERM term true true - + OSVS osvs true true - + LBS lbs true true - + MUID mid true true - + MUDS muds true true - + REDIRECTURL u @@ -961,17 +1100,17 @@ start - m201 + event=start true end - m203 + event=end true - + @@ -981,7 +1120,7 @@ false - + @@ -989,6 +1128,20 @@ viid true true + + + + ImpressionType + vitype + true + true + + + + AdviewabilityRecord + varecord + true + true @@ -1047,6 +1200,13 @@ true true + + + AdviewabilityForground + vfg + true + true + AdviewabilityLight @@ -1054,69 +1214,68 @@ true true + AdviewabilityForground - vfg - true - true - - - - Adviewability - vab + vafg true true - + - AdMeasurability - vm + AdviewabilityResult + varesult true true - - - - + AdviewabilityConfigArea - vca + vaconfarea true true - + AdviewabilityConfigThreshold - vct + vaconfth true true - + AdviewabilityVideoDuration - vcvd + vavd true true - + AdviewabilityVideoProgress - vcvp + vavp true true - + AdviewabilityVideoPlayType - vcpt + vavpt true true - + AdviewabilityVideoProgressPoint - vcpp + vavpp + true + true + + + + + AdviewabilityStrongInteract + vasi true true @@ -1128,8 +1287,8 @@ true - - + + adbug @@ -1164,28 +1323,28 @@ true true - + TS t true true - + MAC n true true - + IDFA z true true - + IDFAMD5 0j @@ -1198,21 +1357,21 @@ true true - + WIFI w true true - + AKEY x true true - + ANAME y @@ -1226,7 +1385,7 @@ true true - + OPENUDID o @@ -1239,14 +1398,14 @@ true true - + OSVS q true true - + LBS l @@ -1287,9 +1446,9 @@ false false - + - + ImpressionID @@ -1297,7 +1456,7 @@ true true - + AdviewabilityEvents 2j @@ -1370,7 +1529,7 @@ true true - + @@ -1379,8 +1538,8 @@ true - - + + rtbasia @@ -1408,12 +1567,12 @@ raw @@ -1678,7 +1837,651 @@ true - - - + + nielsen + + + + + uat.cr-nielsen.com + + + + 4A5DBD140 + pk + + + true + + 604800 + + 1 + + md5 + raw + md5 + raw + + + + + + + + + OS + os + + true + + true + + + + TS + ts + true + true + + + + MAC + mac + true + true + + + + IDFA + idfa + true + true + + + + IMEI + imei + true + true + + + + ANDROIDID + androidid + true + true + + + + WIFI + wifi + true + true + + + + AKEY + akey + true + true + + + + ANAME + aname + true + true + + + + + SCWH + scwh + true + true + + + + OPENUDID + openudid + true + true + + + + ODIN + odin + true + true + + + + TERM + term + true + true + + + + OSVS + osvs + true + true + + + + LBS + lbs + true + true + + + + MUID + muid + true + true + + + + MUDS + muds + true + true + + + + REDIRECTURL + ref + true + true + + + SDKVS + sdkvs + true + true + + + + + + start + start + true + + + + end + end + true + + + + + + + Adplacement + hat_pid + false + false + + + + + + + ImpressionID + imp_id + true + true + + + ImpressionType + vit + true + true + + + + + AdviewabilityEvents + vbe + true + true + + + + AdviewabilityTime + vts + true + true + + + + AdviewabilityFrame + vbf + true + true + + + + AdviewabilityPoint + vbp + true + true + + + + AdviewabilityAlpha + vba + true + true + + + + AdviewabilityShown + vbs + true + true + + + + AdviewabilityCoverRate + vbc + true + true + + + + AdviewabilityShowFrame + vsf + true + true + + + + AdviewabilityLight + vbl + true + true + + + + AdviewabilityForground + vfg + true + true + + + + Adviewability + vvb + true + true + + + + AdMeasurability + vmb + true + true + + + + + + + AdviewabilityConfigArea + vca + true + true + + + + AdviewabilityConfigThreshold + vct + true + true + + + + AdviewabilityVideoDuration + vcvd + true + true + + + + AdviewabilityVideoProgress + vcvp + true + true + + + + AdviewabilityVideoPlayType + vcpt + true + true + + + + AdviewabilityVideoProgressPoint + vcpp + true + true + + + + & + + = + + true + + + + TalkingData + + + + + + + .lnk0.com + + + DbXiUlEVN + s + + + false + + 604800 + + 1 + + md5 + raw + md5 + raw + + + + + + + + OS + osversion + true + true + + + TS + time + true + true + + + MAC + mac_md5 + true + true + + + IDFA + idfa + true + true + + + IMEI + imei_md5 + true + true + + + RAWIMEI + m3 + true + false + + + ANDROIDID + androidid + true + true + + + WIFI + nm + true + false + + + AKEY + pname + true + true + + + ANAME + aname + true + false + + + + SCWH + scwh + true + false + + + + WIFISSID + ssid + true + false + + + + WIFIBSSID + bssid + true + false + + + OPENUDID + openudid + true + false + + + TERM + devicetype + true + false + + + OSVS + osvs + true + false + + + LBS + mm + true + false + + + SDKVS + sdkvs + true + false + + + REDIRECTURL + o + true + false + + + + + + start + mb=start + false + + + + end + mb=end + false + + + + + Adplacement + adid + false + false + + + + + ImpressionID + vimpid + true + false + + + AdviewabilityRecord + va + true + false + + + AdviewabilityEvents + vct + true + false + + + AdviewabilityTime + 1 + true + false + + + AdviewabilityFrame + 2 + true + false + + + AdviewabilityPoint + 3 + true + false + + + AdviewabilityAlpha + 4 + true + false + + + AdviewabilityShown + 5 + true + false + + + AdviewabilityCoverRate + 6 + true + false + + + AdviewabilityShowFrame + 7 + true + false + + + AdviewabilityForground + 8 + true + false + + + AdviewabilityResult + vx + true + false + + + Adviewability + isview + true + false + + + AdMeasurability + ism + true + false + + + AdviewabilityConfigArea + vcr + true + false + + + AdviewabilityConfigThreshold + vtime + true + false + + + AdviewabilityVideoDuration + vb + true + false + + + AdviewabilityVideoProgress + vc + true + false + + + AdviewabilityVideoPlayType + vpt + true + false + + + AdviewabilityVideoProgressPoint + vj + true + false + + + + & + + = + + true + + + + diff --git a/README.md b/README.md index e0613366948accf8ae65b36032ad28c0ecc0b604..20c949b68234fb8804b5a44f4a81aec9085c0a60 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ 2. 在项目工程 App 的 Target Build Settings 中的 **Other Linker Flags** 选项里添加 **-lxml2** **-all_load** 或 **-lxml2** **-force_load** 静态库的绝对路径 3. 添加SDK需要的Framework 在需要添加SDK的项目的 Xcode 开发环境中选择 TARGETS-->Build Phases-->Link Binary With Libraries--> + 添加以下framework框架: - +4.需要在info.plist 新增NSMotionUsageDescription(Privacy - Motion Usage Description) 键值对,并进行说明。 ``` CoreLocation.framework libxml2.2.tbd @@ -14,6 +14,7 @@ CoreTelephony.framework SystemConfiguration.framework WebKit.framework + CoreMotion.framework ``` diff --git "a/\347\211\271\345\210\253\347\211\210/Bitcode/Release-iphoneos/libMobileTracking.a" "b/\347\211\271\345\210\253\347\211\210/Bitcode/Release-iphoneos/libMobileTracking.a" new file mode 100644 index 0000000000000000000000000000000000000000..1966aa21d88925b8840141964993e0953289c4e9 Binary files /dev/null and "b/\347\211\271\345\210\253\347\211\210/Bitcode/Release-iphoneos/libMobileTracking.a" differ diff --git "a/\347\211\271\345\210\253\347\211\210/Bitcode/Release-iphonesimulator/libMobileTracking.a" "b/\347\211\271\345\210\253\347\211\210/Bitcode/Release-iphonesimulator/libMobileTracking.a" new file mode 100644 index 0000000000000000000000000000000000000000..c53a5e536782313164c5a854de4f1445c2e06fe7 Binary files /dev/null and "b/\347\211\271\345\210\253\347\211\210/Bitcode/Release-iphonesimulator/libMobileTracking.a" differ diff --git "a/\347\211\271\345\210\253\347\211\210/Bitcode/Release-universal/libMobileTracking.a" "b/\347\211\271\345\210\253\347\211\210/Bitcode/Release-universal/libMobileTracking.a" new file mode 100644 index 0000000000000000000000000000000000000000..3324d63de8acb3d67095fc3485901afece5bda0f Binary files /dev/null and "b/\347\211\271\345\210\253\347\211\210/Bitcode/Release-universal/libMobileTracking.a" differ diff --git "a/\347\211\271\345\210\253\347\211\210/Bitcode/iphoneos/libMobileTracking.a" "b/\347\211\271\345\210\253\347\211\210/Bitcode/iphoneos/libMobileTracking.a" index 47f7b94add46982646c347c2823c32b2b79b3cdc..1966aa21d88925b8840141964993e0953289c4e9 100644 Binary files "a/\347\211\271\345\210\253\347\211\210/Bitcode/iphoneos/libMobileTracking.a" and "b/\347\211\271\345\210\253\347\211\210/Bitcode/iphoneos/libMobileTracking.a" differ diff --git "a/\347\211\271\345\210\253\347\211\210/Bitcode/iphonesimulator/libMobileTracking.a" "b/\347\211\271\345\210\253\347\211\210/Bitcode/iphonesimulator/libMobileTracking.a" index f755f84bddd1eb78741deded33d55ae7ba2d3ef0..c53a5e536782313164c5a854de4f1445c2e06fe7 100644 Binary files "a/\347\211\271\345\210\253\347\211\210/Bitcode/iphonesimulator/libMobileTracking.a" and "b/\347\211\271\345\210\253\347\211\210/Bitcode/iphonesimulator/libMobileTracking.a" differ diff --git "a/\347\211\271\345\210\253\347\211\210/Bitcode/universal/libMobileTracking.a" "b/\347\211\271\345\210\253\347\211\210/Bitcode/universal/libMobileTracking.a" index a130a14e506b68eb1f61e4e477cab6a43d058dcf..3324d63de8acb3d67095fc3485901afece5bda0f 100644 Binary files "a/\347\211\271\345\210\253\347\211\210/Bitcode/universal/libMobileTracking.a" and "b/\347\211\271\345\210\253\347\211\210/Bitcode/universal/libMobileTracking.a" differ diff --git "a/\347\211\271\345\210\253\347\211\210/noBitcode/Release-iphoneos/libMobileTracking.a" "b/\347\211\271\345\210\253\347\211\210/noBitcode/Release-iphoneos/libMobileTracking.a" new file mode 100644 index 0000000000000000000000000000000000000000..13d2a0da505f14bcdf5f3b7abe2de8f8f35ba6da Binary files /dev/null and "b/\347\211\271\345\210\253\347\211\210/noBitcode/Release-iphoneos/libMobileTracking.a" differ diff --git "a/\347\211\271\345\210\253\347\211\210/noBitcode/Release-iphonesimulator/libMobileTracking.a" "b/\347\211\271\345\210\253\347\211\210/noBitcode/Release-iphonesimulator/libMobileTracking.a" new file mode 100644 index 0000000000000000000000000000000000000000..523ce25d2cc3687472d8340a04f1c351fcc43855 Binary files /dev/null and "b/\347\211\271\345\210\253\347\211\210/noBitcode/Release-iphonesimulator/libMobileTracking.a" differ diff --git "a/\347\211\271\345\210\253\347\211\210/noBitcode/Release-universal/libMobileTracking.a" "b/\347\211\271\345\210\253\347\211\210/noBitcode/Release-universal/libMobileTracking.a" new file mode 100644 index 0000000000000000000000000000000000000000..bf6449511c46962d40dcd857592026e1fa6af321 Binary files /dev/null and "b/\347\211\271\345\210\253\347\211\210/noBitcode/Release-universal/libMobileTracking.a" differ diff --git "a/\347\211\271\345\210\253\347\211\210/noBitcode/iphoneos/libMobileTracking.a" "b/\347\211\271\345\210\253\347\211\210/noBitcode/iphoneos/libMobileTracking.a" index cc4e26bfade76653bf4cf419c4c00fa10c5e3c68..13d2a0da505f14bcdf5f3b7abe2de8f8f35ba6da 100644 Binary files "a/\347\211\271\345\210\253\347\211\210/noBitcode/iphoneos/libMobileTracking.a" and "b/\347\211\271\345\210\253\347\211\210/noBitcode/iphoneos/libMobileTracking.a" differ diff --git "a/\347\211\271\345\210\253\347\211\210/noBitcode/iphonesimulator/libMobileTracking.a" "b/\347\211\271\345\210\253\347\211\210/noBitcode/iphonesimulator/libMobileTracking.a" index d3bae2ea57971c0bcd6fc1f6b8d010ca5d90bca2..523ce25d2cc3687472d8340a04f1c351fcc43855 100644 Binary files "a/\347\211\271\345\210\253\347\211\210/noBitcode/iphonesimulator/libMobileTracking.a" and "b/\347\211\271\345\210\253\347\211\210/noBitcode/iphonesimulator/libMobileTracking.a" differ diff --git "a/\347\211\271\345\210\253\347\211\210/noBitcode/universal/libMobileTracking.a" "b/\347\211\271\345\210\253\347\211\210/noBitcode/universal/libMobileTracking.a" index 0b838ca20a7bbe91aa2a6f312a5e1c1254473a9e..bf6449511c46962d40dcd857592026e1fa6af321 100644 Binary files "a/\347\211\271\345\210\253\347\211\210/noBitcode/universal/libMobileTracking.a" and "b/\347\211\271\345\210\253\347\211\210/noBitcode/universal/libMobileTracking.a" differ