--- /dev/null
+/**
+ * Copyright (c) 2000-2012 Liferay, Inc. All rights reserved.
+ *
+ * This library is free software; you can redistribute it and/or modify it under
+ * the terms of the GNU Lesser General Public License as published by the Free
+ * Software Foundation; either version 2.1 of the License, or (at your option)
+ * any later version.
+ *
+ * This library is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details.
+ */
+
+package com.pentila.entSavoie.cdt.service.persistence;
+
+import com.liferay.portal.kernel.bean.PortletBeanLocatorUtil;
+import com.liferay.portal.kernel.dao.orm.DynamicQuery;
+import com.liferay.portal.kernel.exception.SystemException;
+import com.liferay.portal.kernel.util.OrderByComparator;
+import com.liferay.portal.kernel.util.ReferenceRegistry;
+import com.liferay.portal.service.ServiceContext;
+
+import com.pentila.entSavoie.cdt.model.WeeklySchedule;
+
+import java.util.List;
+
+/**
+ * The persistence utility for the weekly schedule service. This utility wraps {@link WeeklySchedulePersistenceImpl} and provides direct access to the database for CRUD operations. This utility should only be used by the service layer, as it must operate within a transaction. Never access this utility in a JSP, controller, model, or other front-end class.
+ *
+ * <p>
+ * Caching information and settings can be found in <code>portal.properties</code>
+ * </p>
+ *
+ * @author Cedric Lecarpentier
+ * @see WeeklySchedulePersistence
+ * @see WeeklySchedulePersistenceImpl
+ * @generated
+ */
+public class WeeklyScheduleUtil {
+ /*
+ * NOTE FOR DEVELOPERS:
+ *
+ * Never modify this class directly. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this class.
+ */
+
+ /**
+ * @see com.liferay.portal.service.persistence.BasePersistence#clearCache()
+ */
+ public static void clearCache() {
+ getPersistence().clearCache();
+ }
+
+ /**
+ * @see com.liferay.portal.service.persistence.BasePersistence#clearCache(com.liferay.portal.model.BaseModel)
+ */
+ public static void clearCache(WeeklySchedule weeklySchedule) {
+ getPersistence().clearCache(weeklySchedule);
+ }
+
+ /**
+ * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery)
+ */
+ public long countWithDynamicQuery(DynamicQuery dynamicQuery)
+ throws SystemException {
+ return getPersistence().countWithDynamicQuery(dynamicQuery);
+ }
+
+ /**
+ * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery)
+ */
+ public static List<WeeklySchedule> findWithDynamicQuery(
+ DynamicQuery dynamicQuery) throws SystemException {
+ return getPersistence().findWithDynamicQuery(dynamicQuery);
+ }
+
+ /**
+ * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int)
+ */
+ public static List<WeeklySchedule> findWithDynamicQuery(
+ DynamicQuery dynamicQuery, int start, int end)
+ throws SystemException {
+ return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
+ }
+
+ /**
+ * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator)
+ */
+ public static List<WeeklySchedule> findWithDynamicQuery(
+ DynamicQuery dynamicQuery, int start, int end,
+ OrderByComparator orderByComparator) throws SystemException {
+ return getPersistence()
+ .findWithDynamicQuery(dynamicQuery, start, end,
+ orderByComparator);
+ }
+
+ /**
+ * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean)
+ */
+ public static WeeklySchedule update(WeeklySchedule weeklySchedule,
+ boolean merge) throws SystemException {
+ return getPersistence().update(weeklySchedule, merge);
+ }
+
+ /**
+ * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean, ServiceContext)
+ */
+ public static WeeklySchedule update(WeeklySchedule weeklySchedule,
+ boolean merge, ServiceContext serviceContext) throws SystemException {
+ return getPersistence().update(weeklySchedule, merge, serviceContext);
+ }
+
+ /**
+ * Caches the weekly schedule in the entity cache if it is enabled.
+ *
+ * @param weeklySchedule the weekly schedule
+ */
+ public static void cacheResult(
+ com.pentila.entSavoie.cdt.model.WeeklySchedule weeklySchedule) {
+ getPersistence().cacheResult(weeklySchedule);
+ }
+
+ /**
+ * Caches the weekly schedules in the entity cache if it is enabled.
+ *
+ * @param weeklySchedules the weekly schedules
+ */
+ public static void cacheResult(
+ java.util.List<com.pentila.entSavoie.cdt.model.WeeklySchedule> weeklySchedules) {
+ getPersistence().cacheResult(weeklySchedules);
+ }
+
+ /**
+ * Creates a new weekly schedule with the primary key. Does not add the weekly schedule to the database.
+ *
+ * @param weeklySchedulePK the primary key for the new weekly schedule
+ * @return the new weekly schedule
+ */
+ public static com.pentila.entSavoie.cdt.model.WeeklySchedule create(
+ com.pentila.entSavoie.cdt.service.persistence.WeeklySchedulePK weeklySchedulePK) {
+ return getPersistence().create(weeklySchedulePK);
+ }
+
+ /**
+ * Removes the weekly schedule with the primary key from the database. Also notifies the appropriate model listeners.
+ *
+ * @param weeklySchedulePK the primary key of the weekly schedule
+ * @return the weekly schedule that was removed
+ * @throws com.pentila.entSavoie.cdt.NoSuchWeeklyScheduleException if a weekly schedule with the primary key could not be found
+ * @throws SystemException if a system exception occurred
+ */
+ public static com.pentila.entSavoie.cdt.model.WeeklySchedule remove(
+ com.pentila.entSavoie.cdt.service.persistence.WeeklySchedulePK weeklySchedulePK)
+ throws com.liferay.portal.kernel.exception.SystemException,
+ com.pentila.entSavoie.cdt.NoSuchWeeklyScheduleException {
+ return getPersistence().remove(weeklySchedulePK);
+ }
+
+ public static com.pentila.entSavoie.cdt.model.WeeklySchedule updateImpl(
+ com.pentila.entSavoie.cdt.model.WeeklySchedule weeklySchedule,
+ boolean merge)
+ throws com.liferay.portal.kernel.exception.SystemException {
+ return getPersistence().updateImpl(weeklySchedule, merge);
+ }
+
+ /**
+ * Returns the weekly schedule with the primary key or throws a {@link com.pentila.entSavoie.cdt.NoSuchWeeklyScheduleException} if it could not be found.
+ *
+ * @param weeklySchedulePK the primary key of the weekly schedule
+ * @return the weekly schedule
+ * @throws com.pentila.entSavoie.cdt.NoSuchWeeklyScheduleException if a weekly schedule with the primary key could not be found
+ * @throws SystemException if a system exception occurred
+ */
+ public static com.pentila.entSavoie.cdt.model.WeeklySchedule findByPrimaryKey(
+ com.pentila.entSavoie.cdt.service.persistence.WeeklySchedulePK weeklySchedulePK)
+ throws com.liferay.portal.kernel.exception.SystemException,
+ com.pentila.entSavoie.cdt.NoSuchWeeklyScheduleException {
+ return getPersistence().findByPrimaryKey(weeklySchedulePK);
+ }
+
+ /**
+ * Returns the weekly schedule with the primary key or returns <code>null</code> if it could not be found.
+ *
+ * @param weeklySchedulePK the primary key of the weekly schedule
+ * @return the weekly schedule, or <code>null</code> if a weekly schedule with the primary key could not be found
+ * @throws SystemException if a system exception occurred
+ */
+ public static com.pentila.entSavoie.cdt.model.WeeklySchedule fetchByPrimaryKey(
+ com.pentila.entSavoie.cdt.service.persistence.WeeklySchedulePK weeklySchedulePK)
+ throws com.liferay.portal.kernel.exception.SystemException {
+ return getPersistence().fetchByPrimaryKey(weeklySchedulePK);
+ }
+
+ /**
+ * Returns all the weekly schedules where schoolId = ?.
+ *
+ * @param schoolId the school ID
+ * @return the matching weekly schedules
+ * @throws SystemException if a system exception occurred
+ */
+ public static java.util.List<com.pentila.entSavoie.cdt.model.WeeklySchedule> findByschoolId(
+ long schoolId)
+ throws com.liferay.portal.kernel.exception.SystemException {
+ return getPersistence().findByschoolId(schoolId);
+ }
+
+ /**
+ * Returns a range of all the weekly schedules where schoolId = ?.
+ *
+ * <p>
+ * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
+ * </p>
+ *
+ * @param schoolId the school ID
+ * @param start the lower bound of the range of weekly schedules
+ * @param end the upper bound of the range of weekly schedules (not inclusive)
+ * @return the range of matching weekly schedules
+ * @throws SystemException if a system exception occurred
+ */
+ public static java.util.List<com.pentila.entSavoie.cdt.model.WeeklySchedule> findByschoolId(
+ long schoolId, int start, int end)
+ throws com.liferay.portal.kernel.exception.SystemException {
+ return getPersistence().findByschoolId(schoolId, start, end);
+ }
+
+ /**
+ * Returns an ordered range of all the weekly schedules where schoolId = ?.
+ *
+ * <p>
+ * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
+ * </p>
+ *
+ * @param schoolId the school ID
+ * @param start the lower bound of the range of weekly schedules
+ * @param end the upper bound of the range of weekly schedules (not inclusive)
+ * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
+ * @return the ordered range of matching weekly schedules
+ * @throws SystemException if a system exception occurred
+ */
+ public static java.util.List<com.pentila.entSavoie.cdt.model.WeeklySchedule> findByschoolId(
+ long schoolId, int start, int end,
+ com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
+ throws com.liferay.portal.kernel.exception.SystemException {
+ return getPersistence()
+ .findByschoolId(schoolId, start, end, orderByComparator);
+ }
+
+ /**
+ * Returns the first weekly schedule in the ordered set where schoolId = ?.
+ *
+ * @param schoolId the school ID
+ * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
+ * @return the first matching weekly schedule
+ * @throws com.pentila.entSavoie.cdt.NoSuchWeeklyScheduleException if a matching weekly schedule could not be found
+ * @throws SystemException if a system exception occurred
+ */
+ public static com.pentila.entSavoie.cdt.model.WeeklySchedule findByschoolId_First(
+ long schoolId,
+ com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
+ throws com.liferay.portal.kernel.exception.SystemException,
+ com.pentila.entSavoie.cdt.NoSuchWeeklyScheduleException {
+ return getPersistence().findByschoolId_First(schoolId, orderByComparator);
+ }
+
+ /**
+ * Returns the first weekly schedule in the ordered set where schoolId = ?.
+ *
+ * @param schoolId the school ID
+ * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
+ * @return the first matching weekly schedule, or <code>null</code> if a matching weekly schedule could not be found
+ * @throws SystemException if a system exception occurred
+ */
+ public static com.pentila.entSavoie.cdt.model.WeeklySchedule fetchByschoolId_First(
+ long schoolId,
+ com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
+ throws com.liferay.portal.kernel.exception.SystemException {
+ return getPersistence()
+ .fetchByschoolId_First(schoolId, orderByComparator);
+ }
+
+ /**
+ * Returns the last weekly schedule in the ordered set where schoolId = ?.
+ *
+ * @param schoolId the school ID
+ * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
+ * @return the last matching weekly schedule
+ * @throws com.pentila.entSavoie.cdt.NoSuchWeeklyScheduleException if a matching weekly schedule could not be found
+ * @throws SystemException if a system exception occurred
+ */
+ public static com.pentila.entSavoie.cdt.model.WeeklySchedule findByschoolId_Last(
+ long schoolId,
+ com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
+ throws com.liferay.portal.kernel.exception.SystemException,
+ com.pentila.entSavoie.cdt.NoSuchWeeklyScheduleException {
+ return getPersistence().findByschoolId_Last(schoolId, orderByComparator);
+ }
+
+ /**
+ * Returns the last weekly schedule in the ordered set where schoolId = ?.
+ *
+ * @param schoolId the school ID
+ * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
+ * @return the last matching weekly schedule, or <code>null</code> if a matching weekly schedule could not be found
+ * @throws SystemException if a system exception occurred
+ */
+ public static com.pentila.entSavoie.cdt.model.WeeklySchedule fetchByschoolId_Last(
+ long schoolId,
+ com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
+ throws com.liferay.portal.kernel.exception.SystemException {
+ return getPersistence().fetchByschoolId_Last(schoolId, orderByComparator);
+ }
+
+ /**
+ * Returns the weekly schedules before and after the current weekly schedule in the ordered set where schoolId = ?.
+ *
+ * @param weeklySchedulePK the primary key of the current weekly schedule
+ * @param schoolId the school ID
+ * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
+ * @return the previous, current, and next weekly schedule
+ * @throws com.pentila.entSavoie.cdt.NoSuchWeeklyScheduleException if a weekly schedule with the primary key could not be found
+ * @throws SystemException if a system exception occurred
+ */
+ public static com.pentila.entSavoie.cdt.model.WeeklySchedule[] findByschoolId_PrevAndNext(
+ com.pentila.entSavoie.cdt.service.persistence.WeeklySchedulePK weeklySchedulePK,
+ long schoolId,
+ com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
+ throws com.liferay.portal.kernel.exception.SystemException,
+ com.pentila.entSavoie.cdt.NoSuchWeeklyScheduleException {
+ return getPersistence()
+ .findByschoolId_PrevAndNext(weeklySchedulePK, schoolId,
+ orderByComparator);
+ }
+
+ /**
+ * Returns all the weekly schedules.
+ *
+ * @return the weekly schedules
+ * @throws SystemException if a system exception occurred
+ */
+ public static java.util.List<com.pentila.entSavoie.cdt.model.WeeklySchedule> findAll()
+ throws com.liferay.portal.kernel.exception.SystemException {
+ return getPersistence().findAll();
+ }
+
+ /**
+ * Returns a range of all the weekly schedules.
+ *
+ * <p>
+ * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
+ * </p>
+ *
+ * @param start the lower bound of the range of weekly schedules
+ * @param end the upper bound of the range of weekly schedules (not inclusive)
+ * @return the range of weekly schedules
+ * @throws SystemException if a system exception occurred
+ */
+ public static java.util.List<com.pentila.entSavoie.cdt.model.WeeklySchedule> findAll(
+ int start, int end)
+ throws com.liferay.portal.kernel.exception.SystemException {
+ return getPersistence().findAll(start, end);
+ }
+
+ /**
+ * Returns an ordered range of all the weekly schedules.
+ *
+ * <p>
+ * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
+ * </p>
+ *
+ * @param start the lower bound of the range of weekly schedules
+ * @param end the upper bound of the range of weekly schedules (not inclusive)
+ * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
+ * @return the ordered range of weekly schedules
+ * @throws SystemException if a system exception occurred
+ */
+ public static java.util.List<com.pentila.entSavoie.cdt.model.WeeklySchedule> findAll(
+ int start, int end,
+ com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
+ throws com.liferay.portal.kernel.exception.SystemException {
+ return getPersistence().findAll(start, end, orderByComparator);
+ }
+
+ /**
+ * Removes all the weekly schedules where schoolId = ? from the database.
+ *
+ * @param schoolId the school ID
+ * @throws SystemException if a system exception occurred
+ */
+ public static void removeByschoolId(long schoolId)
+ throws com.liferay.portal.kernel.exception.SystemException {
+ getPersistence().removeByschoolId(schoolId);
+ }
+
+ /**
+ * Removes all the weekly schedules from the database.
+ *
+ * @throws SystemException if a system exception occurred
+ */
+ public static void removeAll()
+ throws com.liferay.portal.kernel.exception.SystemException {
+ getPersistence().removeAll();
+ }
+
+ /**
+ * Returns the number of weekly schedules where schoolId = ?.
+ *
+ * @param schoolId the school ID
+ * @return the number of matching weekly schedules
+ * @throws SystemException if a system exception occurred
+ */
+ public static int countByschoolId(long schoolId)
+ throws com.liferay.portal.kernel.exception.SystemException {
+ return getPersistence().countByschoolId(schoolId);
+ }
+
+ /**
+ * Returns the number of weekly schedules.
+ *
+ * @return the number of weekly schedules
+ * @throws SystemException if a system exception occurred
+ */
+ public static int countAll()
+ throws com.liferay.portal.kernel.exception.SystemException {
+ return getPersistence().countAll();
+ }
+
+ public static WeeklySchedulePersistence getPersistence() {
+ if (_persistence == null) {
+ _persistence = (WeeklySchedulePersistence)PortletBeanLocatorUtil.locate(com.pentila.entSavoie.cdt.service.ClpSerializer.getServletContextName(),
+ WeeklySchedulePersistence.class.getName());
+
+ ReferenceRegistry.registerReference(WeeklyScheduleUtil.class,
+ "_persistence");
+ }
+
+ return _persistence;
+ }
+
+ /**
+ * @deprecated
+ */
+ public void setPersistence(WeeklySchedulePersistence persistence) {
+ }
+
+ private static WeeklySchedulePersistence _persistence;
+}
\ No newline at end of file