What does @synchronized() do?
The @synchronized directive is a convenient way to create mutex locks on the fly in Objective-C code. The @synchronized directive does what any other mutex lock would do — it prevents different threads from acquiring the same lock at the same time.