Files
daily-notification-plugin/ios/Plugin/DailyNotificationPlugin.swift
Matthew Raymer a8d92291e9 feat(ios): implement calculateNextRunTime method
Implemented schedule calculation utility method:

calculateNextRunTime():
- Calculates next run time from cron expression or HH:mm time string
- Supports cron format: "minute hour * * *" (e.g., "30 9 * * *" = 9:30 AM daily)
- Supports time format: "HH:mm" (e.g., "09:30" = 9:30 AM daily)
- Handles same-day vs next-day scheduling
- Returns nextRunAt timestamp in milliseconds
- Fallback to 24 hours from now if parsing fails

calculateNextRunTimeFromSchedule():
- Private helper method for schedule parsing
- Parses both cron and time formats
- Uses Calendar for date calculations
- Handles timezone-aware calculations

iOS Adaptations:
- Uses Calendar.current for date calculations
- TimeInterval conversion (Date to milliseconds)
- Handles edge cases (invalid formats, past times)

Progress: 48/52 methods implemented (92% complete)
2025-11-11 02:20:50 -08:00

88 KiB