Package org.quartz

Examples of org.quartz.Calendar


                    misfiredTriggers[i].getName(),
                    misfiredTriggers[i].getGroup());

            if (trig == null) continue;

            Calendar cal = null;
            if (trig.getCalendarName() != null)
                    cal = retrieveCalendar(conn, null, trig.getCalendarName());

            String[] listeners = getDelegate().selectTriggerListeners(conn,
                trig.getName(), trig.getGroup());
View Full Code Here


            if (getMisfireThreshold() > 0)
                    misfireTime -= getMisfireThreshold();

            if (trig.getNextFireTime().getTime() > misfireTime) return false;

            Calendar cal = null;
            if (trig.getCalendarName() != null)
                    cal = retrieveCalendar(conn, ctxt, trig.getCalendarName());

            signaler.notifyTriggerListenersMisfired(trig);
View Full Code Here

    protected Calendar retrieveCalendar(Connection conn,
            SchedulingContext ctxt, String calName)
            throws JobPersistenceException {
        // all calendars are persistent, but we lazy-cache them during run
        // time...
        Calendar cal = (Calendar) calendarCache.get(calName);
        if (cal != null) return cal;

        try {
            cal = getDelegate().selectCalendar(conn, calName);
            calendarCache.put(calName, cal); // lazy-cache...
View Full Code Here

    protected TriggerFiredBundle triggerFired(Connection conn,
            SchedulingContext ctxt, Trigger trigger)
            throws JobPersistenceException {
        JobDetail job = null;
        Calendar cal = null;

        // Make sure trigger wasn't deleted, paused, or completed...
        try { // if trigger was deleted, state will be STATE_DELETED
            String state = getDelegate().selectTriggerState(conn,
                    trigger.getName(), trigger.getGroup());
View Full Code Here

    public Calendar retrieveCalendar(SchedulingContext ctxt, String calName)
            throws JobPersistenceException {
        Connection conn = getConnection();
        try {
            // no locks necessary for read...
            Calendar cal = retrieveCalendar(conn, ctxt, calName);
            commitConnection(conn);
            return cal;
        } catch (JobPersistenceException e) {
            rollbackConnection(conn);
            throw e;
View Full Code Here

            String selCal = rtp(SELECT_CALENDAR.toLowerCase());
            ps = conn.prepareStatement(selCal);
            ps.setString(1, calendarName);
            rs = ps.executeQuery();

            Calendar cal = null;
            if (rs.next()) {
                cal = (Calendar) getObjectFromBlob(rs, COL_CALENDAR.toLowerCase());
            }
            if (null == cal) {
                logger.warn("Couldn't find calendar with name '" + calendarName
View Full Code Here

        Date tnft = tw.trigger.getNextFireTime();
        if (tnft == null || tnft.getTime() > misfireTime) {
            return false;
        }

        Calendar cal = null;
        if (tw.trigger.getCalendarName() != null) {
            cal = retrieveCalendar(null, tw.trigger.getCalendarName());
        }

        signaler.notifyTriggerListenersMisfired((Trigger)tw.trigger.clone());
View Full Code Here

            // was the trigger completed, paused, blocked, etc. since being acquired?
            if (tw.state != TriggerWrapper.STATE_ACQUIRED) {
                return null;
            }

            Calendar cal = null;
            if (tw.trigger.getCalendarName() != null) {
                cal = retrieveCalendar(ctxt, tw.trigger.getCalendarName());
                if(cal == null)
                    return null;
            }
View Full Code Here

            String selCal = rtp(SELECT_CALENDAR);
            ps = conn.prepareStatement(selCal);
            ps.setString(1, calendarName);
            rs = ps.executeQuery();

            Calendar cal = null;
            if (rs.next()) {
                cal = (Calendar) getObjectFromBlob(rs, COL_CALENDAR);
            }
            if (null == cal) {
                logger.warn("Couldn't find calendar with name '" + calendarName
View Full Code Here

                            + triggerName + "': " + e.getMessage(), e);
        }
    }

    private void doUpdateOfMisfiredTrigger(Connection conn, SchedulingContext ctxt, Trigger trig, boolean forceState, String newStateIfNotComplete, boolean recovering) throws JobPersistenceException {
        Calendar cal = null;
        if (trig.getCalendarName() != null) {
            cal = retrieveCalendar(conn, ctxt, trig.getCalendarName());
        }

        signaler.notifyTriggerListenersMisfired(trig);
View Full Code Here

TOP

Related Classes of org.quartz.Calendar

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.