001
014
015 package com.liferay.portlet.announcements.service.persistence;
016
017 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018 import com.liferay.portal.kernel.dao.orm.DynamicQuery;
019 import com.liferay.portal.kernel.exception.SystemException;
020 import com.liferay.portal.kernel.util.OrderByComparator;
021 import com.liferay.portal.service.ServiceContext;
022
023 import com.liferay.portlet.announcements.model.AnnouncementsFlag;
024
025 import java.util.List;
026
027
033 public class AnnouncementsFlagUtil {
034
037 public static void clearCache() {
038 getPersistence().clearCache();
039 }
040
041
044 public static void clearCache(AnnouncementsFlag announcementsFlag) {
045 getPersistence().clearCache(announcementsFlag);
046 }
047
048
051 public long countWithDynamicQuery(DynamicQuery dynamicQuery)
052 throws SystemException {
053 return getPersistence().countWithDynamicQuery(dynamicQuery);
054 }
055
056
059 public static List<AnnouncementsFlag> findWithDynamicQuery(
060 DynamicQuery dynamicQuery) throws SystemException {
061 return getPersistence().findWithDynamicQuery(dynamicQuery);
062 }
063
064
067 public static List<AnnouncementsFlag> findWithDynamicQuery(
068 DynamicQuery dynamicQuery, int start, int end)
069 throws SystemException {
070 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
071 }
072
073
076 public static List<AnnouncementsFlag> findWithDynamicQuery(
077 DynamicQuery dynamicQuery, int start, int end,
078 OrderByComparator orderByComparator) throws SystemException {
079 return getPersistence()
080 .findWithDynamicQuery(dynamicQuery, start, end,
081 orderByComparator);
082 }
083
084
087 public static AnnouncementsFlag remove(AnnouncementsFlag announcementsFlag)
088 throws SystemException {
089 return getPersistence().remove(announcementsFlag);
090 }
091
092
095 public static AnnouncementsFlag update(
096 AnnouncementsFlag announcementsFlag, boolean merge)
097 throws SystemException {
098 return getPersistence().update(announcementsFlag, merge);
099 }
100
101
104 public static AnnouncementsFlag update(
105 AnnouncementsFlag announcementsFlag, boolean merge,
106 ServiceContext serviceContext) throws SystemException {
107 return getPersistence().update(announcementsFlag, merge, serviceContext);
108 }
109
110 public static void cacheResult(
111 com.liferay.portlet.announcements.model.AnnouncementsFlag announcementsFlag) {
112 getPersistence().cacheResult(announcementsFlag);
113 }
114
115 public static void cacheResult(
116 java.util.List<com.liferay.portlet.announcements.model.AnnouncementsFlag> announcementsFlags) {
117 getPersistence().cacheResult(announcementsFlags);
118 }
119
120 public static com.liferay.portlet.announcements.model.AnnouncementsFlag create(
121 long flagId) {
122 return getPersistence().create(flagId);
123 }
124
125 public static com.liferay.portlet.announcements.model.AnnouncementsFlag remove(
126 long flagId)
127 throws com.liferay.portal.kernel.exception.SystemException,
128 com.liferay.portlet.announcements.NoSuchFlagException {
129 return getPersistence().remove(flagId);
130 }
131
132 public static com.liferay.portlet.announcements.model.AnnouncementsFlag updateImpl(
133 com.liferay.portlet.announcements.model.AnnouncementsFlag announcementsFlag,
134 boolean merge)
135 throws com.liferay.portal.kernel.exception.SystemException {
136 return getPersistence().updateImpl(announcementsFlag, merge);
137 }
138
139 public static com.liferay.portlet.announcements.model.AnnouncementsFlag findByPrimaryKey(
140 long flagId)
141 throws com.liferay.portal.kernel.exception.SystemException,
142 com.liferay.portlet.announcements.NoSuchFlagException {
143 return getPersistence().findByPrimaryKey(flagId);
144 }
145
146 public static com.liferay.portlet.announcements.model.AnnouncementsFlag fetchByPrimaryKey(
147 long flagId) throws com.liferay.portal.kernel.exception.SystemException {
148 return getPersistence().fetchByPrimaryKey(flagId);
149 }
150
151 public static java.util.List<com.liferay.portlet.announcements.model.AnnouncementsFlag> findByEntryId(
152 long entryId)
153 throws com.liferay.portal.kernel.exception.SystemException {
154 return getPersistence().findByEntryId(entryId);
155 }
156
157 public static java.util.List<com.liferay.portlet.announcements.model.AnnouncementsFlag> findByEntryId(
158 long entryId, int start, int end)
159 throws com.liferay.portal.kernel.exception.SystemException {
160 return getPersistence().findByEntryId(entryId, start, end);
161 }
162
163 public static java.util.List<com.liferay.portlet.announcements.model.AnnouncementsFlag> findByEntryId(
164 long entryId, int start, int end,
165 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
166 throws com.liferay.portal.kernel.exception.SystemException {
167 return getPersistence()
168 .findByEntryId(entryId, start, end, orderByComparator);
169 }
170
171 public static com.liferay.portlet.announcements.model.AnnouncementsFlag findByEntryId_First(
172 long entryId,
173 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
174 throws com.liferay.portal.kernel.exception.SystemException,
175 com.liferay.portlet.announcements.NoSuchFlagException {
176 return getPersistence().findByEntryId_First(entryId, orderByComparator);
177 }
178
179 public static com.liferay.portlet.announcements.model.AnnouncementsFlag findByEntryId_Last(
180 long entryId,
181 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
182 throws com.liferay.portal.kernel.exception.SystemException,
183 com.liferay.portlet.announcements.NoSuchFlagException {
184 return getPersistence().findByEntryId_Last(entryId, orderByComparator);
185 }
186
187 public static com.liferay.portlet.announcements.model.AnnouncementsFlag[] findByEntryId_PrevAndNext(
188 long flagId, long entryId,
189 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
190 throws com.liferay.portal.kernel.exception.SystemException,
191 com.liferay.portlet.announcements.NoSuchFlagException {
192 return getPersistence()
193 .findByEntryId_PrevAndNext(flagId, entryId, orderByComparator);
194 }
195
196 public static com.liferay.portlet.announcements.model.AnnouncementsFlag findByU_E_V(
197 long userId, long entryId, int value)
198 throws com.liferay.portal.kernel.exception.SystemException,
199 com.liferay.portlet.announcements.NoSuchFlagException {
200 return getPersistence().findByU_E_V(userId, entryId, value);
201 }
202
203 public static com.liferay.portlet.announcements.model.AnnouncementsFlag fetchByU_E_V(
204 long userId, long entryId, int value)
205 throws com.liferay.portal.kernel.exception.SystemException {
206 return getPersistence().fetchByU_E_V(userId, entryId, value);
207 }
208
209 public static com.liferay.portlet.announcements.model.AnnouncementsFlag fetchByU_E_V(
210 long userId, long entryId, int value, boolean retrieveFromCache)
211 throws com.liferay.portal.kernel.exception.SystemException {
212 return getPersistence()
213 .fetchByU_E_V(userId, entryId, value, retrieveFromCache);
214 }
215
216 public static java.util.List<com.liferay.portlet.announcements.model.AnnouncementsFlag> findAll()
217 throws com.liferay.portal.kernel.exception.SystemException {
218 return getPersistence().findAll();
219 }
220
221 public static java.util.List<com.liferay.portlet.announcements.model.AnnouncementsFlag> findAll(
222 int start, int end)
223 throws com.liferay.portal.kernel.exception.SystemException {
224 return getPersistence().findAll(start, end);
225 }
226
227 public static java.util.List<com.liferay.portlet.announcements.model.AnnouncementsFlag> findAll(
228 int start, int end,
229 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
230 throws com.liferay.portal.kernel.exception.SystemException {
231 return getPersistence().findAll(start, end, orderByComparator);
232 }
233
234 public static void removeByEntryId(long entryId)
235 throws com.liferay.portal.kernel.exception.SystemException {
236 getPersistence().removeByEntryId(entryId);
237 }
238
239 public static void removeByU_E_V(long userId, long entryId, int value)
240 throws com.liferay.portal.kernel.exception.SystemException,
241 com.liferay.portlet.announcements.NoSuchFlagException {
242 getPersistence().removeByU_E_V(userId, entryId, value);
243 }
244
245 public static void removeAll()
246 throws com.liferay.portal.kernel.exception.SystemException {
247 getPersistence().removeAll();
248 }
249
250 public static int countByEntryId(long entryId)
251 throws com.liferay.portal.kernel.exception.SystemException {
252 return getPersistence().countByEntryId(entryId);
253 }
254
255 public static int countByU_E_V(long userId, long entryId, int value)
256 throws com.liferay.portal.kernel.exception.SystemException {
257 return getPersistence().countByU_E_V(userId, entryId, value);
258 }
259
260 public static int countAll()
261 throws com.liferay.portal.kernel.exception.SystemException {
262 return getPersistence().countAll();
263 }
264
265 public static AnnouncementsFlagPersistence getPersistence() {
266 if (_persistence == null) {
267 _persistence = (AnnouncementsFlagPersistence)PortalBeanLocatorUtil.locate(AnnouncementsFlagPersistence.class.getName());
268 }
269
270 return _persistence;
271 }
272
273 public void setPersistence(AnnouncementsFlagPersistence persistence) {
274 _persistence = persistence;
275 }
276
277 private static AnnouncementsFlagPersistence _persistence;
278 }