/** * Used by {@link ScheduledApplication} to persistently schedule an application launch * @param descriptor * @param arguments * @param topic * @param eventFilter * @param recurring * @return the scheduled application * @throws InvalidSyntaxException * @throws ApplicationException */ public static ScheduledApplication addScheduledApp(ApplicationDescriptor descriptor, String scheduleId, Map arguments, String topic, String eventFilter, boolean recurring) throws InvalidSyntaxException, ApplicationException { if (!scheduling && !checkSchedulingSupport()) throw new ApplicationException(ApplicationException.APPLICATION_SCHEDULING_FAILED, "Cannot support scheduling without org.osgi.service.event package"); //$NON-NLS-1$ // check the event filter for correct syntax context.createFilter(eventFilter); EclipseScheduledApplication result; synchronized (scheduledApps) { result = new EclipseScheduledApplication(context, getNextScheduledID(scheduleId), descriptor.getApplicationId(), arguments, topic, eventFilter, recurring); addScheduledApp(result); saveData(FILE_APPSCHEDULED); } return result; }
/** * Used by {@link ScheduledApplication} to persistently schedule an application launch * @param descriptor * @param arguments * @param topic * @param eventFilter * @param recurring * @return the scheduled application * @throws InvalidSyntaxException * @throws ApplicationException */ public static ScheduledApplication addScheduledApp(ApplicationDescriptor descriptor, String scheduleId, Map arguments, String topic, String eventFilter, boolean recurring) throws InvalidSyntaxException, ApplicationException { if (!scheduling && !checkSchedulingSupport()) throw new ApplicationException(ApplicationException.APPLICATION_SCHEDULING_FAILED, "Cannot support scheduling without org.osgi.service.event package"); //$NON-NLS-1$ // check the event filter for correct syntax context.createFilter(eventFilter); EclipseScheduledApplication result; synchronized (scheduledApps) { result = new EclipseScheduledApplication(context, getNextScheduledID(scheduleId), descriptor.getApplicationId(), arguments, topic, eventFilter, recurring); addScheduledApp(result); saveData(FILE_APPSCHEDULED); } return result; }
/** * Used by {@link ScheduledApplication} to persistently schedule an application launch * @param descriptor * @param arguments * @param topic * @param eventFilter * @param recurring * @return the scheduled application * @throws InvalidSyntaxException * @throws ApplicationException */ public static ScheduledApplication addScheduledApp(ApplicationDescriptor descriptor, String scheduleId, Map arguments, String topic, String eventFilter, boolean recurring) throws InvalidSyntaxException, ApplicationException { if (!scheduling && !checkSchedulingSupport()) throw new ApplicationException(ApplicationException.APPLICATION_SCHEDULING_FAILED, "Cannot support scheduling without org.osgi.service.event package"); //$NON-NLS-1$ // check the event filter for correct syntax context.createFilter(eventFilter); EclipseScheduledApplication result; synchronized (scheduledApps) { result = new EclipseScheduledApplication(context, getNextScheduledID(scheduleId), descriptor.getApplicationId(), arguments, topic, eventFilter, recurring); addScheduledApp(result); saveData(FILE_APPSCHEDULED); } return result; }