NSInteger kTimeoutDuration=10;
NSDate * oneDate=[NSDate date];
NSDate *limitDate = [oneDate dateByAddingTimeInterval:kTimeoutDuration];
NSLog(@"%@",oneDate);
NSLog(@"%@",limitDate);
TimeInterval 单位为1秒钟
2015-03-09 08:18:15.222 Simple[1227:23639] 2015-03-09 00:18:15 +0000
2015-03-09 08:18:15.223 Simple[1227:23639] 2015-03-09 00:18:25 +0000
网友评论