How do I create and cancel unique UILocalNotification from a custom class?
Currently I have a timer with an alarm (local notification). I want to create a timer class from this code to create multiple timers and notifications (at most 5) and I am struggling with how to create and cancel unique notifications with a class method. - (UILocalNotification *) startAlarm { [self cancelAlarm]; //clear any previous alarms alarm = [[UILocalNotification alloc] init]; alarm.alertBody = @"alert msg" alarm.fireDate = [NSDate dateWithTimeInterval: alarmDuration sinceDate: startTime]; alarm.soundName = UILocalNotificationDefaultSoundName; [[UIApplication sharedApplication]