73747576777879
case CANCELLED: return CalculatedEnrollmentStatus.CANCELLED; } assert false; throw new PartakeRuntimeException(ServerErrorCode.LOGIC_ERROR); }
232233234235236237238
case PUBLISHED_PUBLIC_EVENT_ONLY: return indexDao.count(pcon, new String[] { "draft", "isPrivate" }, new Object[] { false, false }); } assert false; throw new PartakeRuntimeException(ServerErrorCode.LOGIC_ERROR); }
254255256257258259260
case PUBLISHED_PUBLIC_EVENT_ONLY: return indexDao.count(pcon, new String[] { "ownerId", "draft", "isPrivate" }, new Object[] { userId, false, false }); } assert false; throw new PartakeRuntimeException(ServerErrorCode.LOGIC_ERROR); }
404405406407408409410
else if (obj instanceof Integer) ps.setInt(nth, (Integer) obj); else if (obj instanceof Boolean) ps.setBoolean(nth, (Boolean) obj); else throw new PartakeRuntimeException(ServerErrorCode.LOGIC_ERROR); }
454455456457458459460
return new DateTime(event.getBeginDate().getTime() - 24 * 3600 * 1000 * applicationStartDayBeforeEvent); case FROM_CUSTOM_DAY: return customApplicationStartDate; } throw new PartakeRuntimeException(ServerErrorCode.LOGIC_ERROR); }
472473474475476477478
return event.getBeginDate().nDayBefore(applicationEndDayBeforeEvent); case TILL_CUSTOM_DAY: return customApplicationEndDate; } throw new PartakeRuntimeException(ServerErrorCode.LOGIC_ERROR); }
487488489490491492493
return acceptsTill(event).nHourBefore(reservationEndHourBeforeApplication); case TILL_CUSTOM_DAY: return customReservationEndDate; } throw new PartakeRuntimeException(ServerErrorCode.LOGIC_ERROR); }
2425262728293031323334
} @Override protected PartakeConnection getConnectionImpl(String name) throws DAOException { if (dataSource == null) throw new PartakeRuntimeException(ServerErrorCode.DB_CONNECTION_POOL_INITIALIZATION_FAILURE); long now = new Date().getTime(); try { Connection con = dataSource.getConnection(); con.setAutoCommit(false);