ios 开启线程定时请求某个方法

时间:2014-08-01 19:42:52   收藏:0   阅读:532


- (void)startLoop

{

        [NSThread detachNewThreadSelector:@selector(loopMethod) toTarget:self withObject:nil];

}


- (void)loopMethod

{

    [NSTimer scheduledTimerWithTimeInterval:3.0f target:self selector:@selector(requestIsHaveReview) userInfo:nil repeats:YES];

    NSRunLoop *loop = [NSRunLoop currentRunLoop];

    [loop run];

}

ios 开启线程定时请求某个方法,布布扣,bubuko.com

原文:http://blog.csdn.net/alincexiaohao/article/details/38340859

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!