I'm working on an app, in which I would call a method, and pass in parameter an NSTimeInterval
.
My method is declared like this :
-(void)MethodwithTime:(NSTimeInterval)t
{
NSLog(@"Test, T = %f", t);
...
}
I call it from a UIViewController
like this :
[myObject performSelector:@selector(MethodwithTime:) withObject:[NSNumber numberWithDouble:t]];
Because I read that NSTimeInterval
is a double. But the NSLog
test gives me some zeros... Test, T = 0.000000
How could I fix it?
Thanks !