Is it possible to implement Counting Semaphore in ios application?
I was unable to find a native IOS object to do this but it works just fine using the C library:
#import "dispatch/semaphore.h"
...
dispatch_semaphore_t activity;
...
activity = dispatch_semaphore_create(0);
...
dispatch_semaphore_signal(activity);
...
dispatch_semaphore_wait(activity, DISPATCH_TIME_FOREVER);
Hope that helps.