NSTimer is used is several context. However, you have to to careful when you are going to invalidate the variable. For example:

Usually, you will use:

As you can see in the code above, the timer is switched off but the variable is unset, so it is dangerous. The best way could be:

or, in a global context: