1
14
15 package com.liferay.portal.service.persistence;
16
17 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
18 import com.liferay.portal.kernel.dao.orm.DynamicQuery;
19 import com.liferay.portal.kernel.exception.SystemException;
20 import com.liferay.portal.model.Website;
21
22 import java.util.List;
23
24
37 public class WebsiteUtil {
38
41 public static void clearCache() {
42 getPersistence().clearCache();
43 }
44
45
48 public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery)
49 throws SystemException {
50 return getPersistence().findWithDynamicQuery(dynamicQuery);
51 }
52
53
56 public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery,
57 int start, int end) throws SystemException {
58 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
59 }
60
61
64 public static Website remove(Website website) throws SystemException {
65 return getPersistence().remove(website);
66 }
67
68
71 public static Website update(Website website, boolean merge)
72 throws SystemException {
73 return getPersistence().update(website, merge);
74 }
75
76 public static void cacheResult(com.liferay.portal.model.Website website) {
77 getPersistence().cacheResult(website);
78 }
79
80 public static void cacheResult(
81 java.util.List<com.liferay.portal.model.Website> websites) {
82 getPersistence().cacheResult(websites);
83 }
84
85 public static com.liferay.portal.model.Website create(long websiteId) {
86 return getPersistence().create(websiteId);
87 }
88
89 public static com.liferay.portal.model.Website remove(long websiteId)
90 throws com.liferay.portal.NoSuchWebsiteException,
91 com.liferay.portal.kernel.exception.SystemException {
92 return getPersistence().remove(websiteId);
93 }
94
95 public static com.liferay.portal.model.Website updateImpl(
96 com.liferay.portal.model.Website website, boolean merge)
97 throws com.liferay.portal.kernel.exception.SystemException {
98 return getPersistence().updateImpl(website, merge);
99 }
100
101 public static com.liferay.portal.model.Website findByPrimaryKey(
102 long websiteId)
103 throws com.liferay.portal.NoSuchWebsiteException,
104 com.liferay.portal.kernel.exception.SystemException {
105 return getPersistence().findByPrimaryKey(websiteId);
106 }
107
108 public static com.liferay.portal.model.Website fetchByPrimaryKey(
109 long websiteId)
110 throws com.liferay.portal.kernel.exception.SystemException {
111 return getPersistence().fetchByPrimaryKey(websiteId);
112 }
113
114 public static java.util.List<com.liferay.portal.model.Website> findByCompanyId(
115 long companyId)
116 throws com.liferay.portal.kernel.exception.SystemException {
117 return getPersistence().findByCompanyId(companyId);
118 }
119
120 public static java.util.List<com.liferay.portal.model.Website> findByCompanyId(
121 long companyId, int start, int end)
122 throws com.liferay.portal.kernel.exception.SystemException {
123 return getPersistence().findByCompanyId(companyId, start, end);
124 }
125
126 public static java.util.List<com.liferay.portal.model.Website> findByCompanyId(
127 long companyId, int start, int end,
128 com.liferay.portal.kernel.util.OrderByComparator obc)
129 throws com.liferay.portal.kernel.exception.SystemException {
130 return getPersistence().findByCompanyId(companyId, start, end, obc);
131 }
132
133 public static com.liferay.portal.model.Website findByCompanyId_First(
134 long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
135 throws com.liferay.portal.NoSuchWebsiteException,
136 com.liferay.portal.kernel.exception.SystemException {
137 return getPersistence().findByCompanyId_First(companyId, obc);
138 }
139
140 public static com.liferay.portal.model.Website findByCompanyId_Last(
141 long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
142 throws com.liferay.portal.NoSuchWebsiteException,
143 com.liferay.portal.kernel.exception.SystemException {
144 return getPersistence().findByCompanyId_Last(companyId, obc);
145 }
146
147 public static com.liferay.portal.model.Website[] findByCompanyId_PrevAndNext(
148 long websiteId, long companyId,
149 com.liferay.portal.kernel.util.OrderByComparator obc)
150 throws com.liferay.portal.NoSuchWebsiteException,
151 com.liferay.portal.kernel.exception.SystemException {
152 return getPersistence()
153 .findByCompanyId_PrevAndNext(websiteId, companyId, obc);
154 }
155
156 public static java.util.List<com.liferay.portal.model.Website> findByUserId(
157 long userId) throws com.liferay.portal.kernel.exception.SystemException {
158 return getPersistence().findByUserId(userId);
159 }
160
161 public static java.util.List<com.liferay.portal.model.Website> findByUserId(
162 long userId, int start, int end)
163 throws com.liferay.portal.kernel.exception.SystemException {
164 return getPersistence().findByUserId(userId, start, end);
165 }
166
167 public static java.util.List<com.liferay.portal.model.Website> findByUserId(
168 long userId, int start, int end,
169 com.liferay.portal.kernel.util.OrderByComparator obc)
170 throws com.liferay.portal.kernel.exception.SystemException {
171 return getPersistence().findByUserId(userId, start, end, obc);
172 }
173
174 public static com.liferay.portal.model.Website findByUserId_First(
175 long userId, com.liferay.portal.kernel.util.OrderByComparator obc)
176 throws com.liferay.portal.NoSuchWebsiteException,
177 com.liferay.portal.kernel.exception.SystemException {
178 return getPersistence().findByUserId_First(userId, obc);
179 }
180
181 public static com.liferay.portal.model.Website findByUserId_Last(
182 long userId, com.liferay.portal.kernel.util.OrderByComparator obc)
183 throws com.liferay.portal.NoSuchWebsiteException,
184 com.liferay.portal.kernel.exception.SystemException {
185 return getPersistence().findByUserId_Last(userId, obc);
186 }
187
188 public static com.liferay.portal.model.Website[] findByUserId_PrevAndNext(
189 long websiteId, long userId,
190 com.liferay.portal.kernel.util.OrderByComparator obc)
191 throws com.liferay.portal.NoSuchWebsiteException,
192 com.liferay.portal.kernel.exception.SystemException {
193 return getPersistence().findByUserId_PrevAndNext(websiteId, userId, obc);
194 }
195
196 public static java.util.List<com.liferay.portal.model.Website> findByC_C(
197 long companyId, long classNameId)
198 throws com.liferay.portal.kernel.exception.SystemException {
199 return getPersistence().findByC_C(companyId, classNameId);
200 }
201
202 public static java.util.List<com.liferay.portal.model.Website> findByC_C(
203 long companyId, long classNameId, int start, int end)
204 throws com.liferay.portal.kernel.exception.SystemException {
205 return getPersistence().findByC_C(companyId, classNameId, start, end);
206 }
207
208 public static java.util.List<com.liferay.portal.model.Website> findByC_C(
209 long companyId, long classNameId, int start, int end,
210 com.liferay.portal.kernel.util.OrderByComparator obc)
211 throws com.liferay.portal.kernel.exception.SystemException {
212 return getPersistence()
213 .findByC_C(companyId, classNameId, start, end, obc);
214 }
215
216 public static com.liferay.portal.model.Website findByC_C_First(
217 long companyId, long classNameId,
218 com.liferay.portal.kernel.util.OrderByComparator obc)
219 throws com.liferay.portal.NoSuchWebsiteException,
220 com.liferay.portal.kernel.exception.SystemException {
221 return getPersistence().findByC_C_First(companyId, classNameId, obc);
222 }
223
224 public static com.liferay.portal.model.Website findByC_C_Last(
225 long companyId, long classNameId,
226 com.liferay.portal.kernel.util.OrderByComparator obc)
227 throws com.liferay.portal.NoSuchWebsiteException,
228 com.liferay.portal.kernel.exception.SystemException {
229 return getPersistence().findByC_C_Last(companyId, classNameId, obc);
230 }
231
232 public static com.liferay.portal.model.Website[] findByC_C_PrevAndNext(
233 long websiteId, long companyId, long classNameId,
234 com.liferay.portal.kernel.util.OrderByComparator obc)
235 throws com.liferay.portal.NoSuchWebsiteException,
236 com.liferay.portal.kernel.exception.SystemException {
237 return getPersistence()
238 .findByC_C_PrevAndNext(websiteId, companyId, classNameId, obc);
239 }
240
241 public static java.util.List<com.liferay.portal.model.Website> findByC_C_C(
242 long companyId, long classNameId, long classPK)
243 throws com.liferay.portal.kernel.exception.SystemException {
244 return getPersistence().findByC_C_C(companyId, classNameId, classPK);
245 }
246
247 public static java.util.List<com.liferay.portal.model.Website> findByC_C_C(
248 long companyId, long classNameId, long classPK, int start, int end)
249 throws com.liferay.portal.kernel.exception.SystemException {
250 return getPersistence()
251 .findByC_C_C(companyId, classNameId, classPK, start, end);
252 }
253
254 public static java.util.List<com.liferay.portal.model.Website> findByC_C_C(
255 long companyId, long classNameId, long classPK, int start, int end,
256 com.liferay.portal.kernel.util.OrderByComparator obc)
257 throws com.liferay.portal.kernel.exception.SystemException {
258 return getPersistence()
259 .findByC_C_C(companyId, classNameId, classPK, start, end, obc);
260 }
261
262 public static com.liferay.portal.model.Website findByC_C_C_First(
263 long companyId, long classNameId, long classPK,
264 com.liferay.portal.kernel.util.OrderByComparator obc)
265 throws com.liferay.portal.NoSuchWebsiteException,
266 com.liferay.portal.kernel.exception.SystemException {
267 return getPersistence()
268 .findByC_C_C_First(companyId, classNameId, classPK, obc);
269 }
270
271 public static com.liferay.portal.model.Website findByC_C_C_Last(
272 long companyId, long classNameId, long classPK,
273 com.liferay.portal.kernel.util.OrderByComparator obc)
274 throws com.liferay.portal.NoSuchWebsiteException,
275 com.liferay.portal.kernel.exception.SystemException {
276 return getPersistence()
277 .findByC_C_C_Last(companyId, classNameId, classPK, obc);
278 }
279
280 public static com.liferay.portal.model.Website[] findByC_C_C_PrevAndNext(
281 long websiteId, long companyId, long classNameId, long classPK,
282 com.liferay.portal.kernel.util.OrderByComparator obc)
283 throws com.liferay.portal.NoSuchWebsiteException,
284 com.liferay.portal.kernel.exception.SystemException {
285 return getPersistence()
286 .findByC_C_C_PrevAndNext(websiteId, companyId, classNameId,
287 classPK, obc);
288 }
289
290 public static java.util.List<com.liferay.portal.model.Website> findByC_C_C_P(
291 long companyId, long classNameId, long classPK, boolean primary)
292 throws com.liferay.portal.kernel.exception.SystemException {
293 return getPersistence()
294 .findByC_C_C_P(companyId, classNameId, classPK, primary);
295 }
296
297 public static java.util.List<com.liferay.portal.model.Website> findByC_C_C_P(
298 long companyId, long classNameId, long classPK, boolean primary,
299 int start, int end)
300 throws com.liferay.portal.kernel.exception.SystemException {
301 return getPersistence()
302 .findByC_C_C_P(companyId, classNameId, classPK, primary,
303 start, end);
304 }
305
306 public static java.util.List<com.liferay.portal.model.Website> findByC_C_C_P(
307 long companyId, long classNameId, long classPK, boolean primary,
308 int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
309 throws com.liferay.portal.kernel.exception.SystemException {
310 return getPersistence()
311 .findByC_C_C_P(companyId, classNameId, classPK, primary,
312 start, end, obc);
313 }
314
315 public static com.liferay.portal.model.Website findByC_C_C_P_First(
316 long companyId, long classNameId, long classPK, boolean primary,
317 com.liferay.portal.kernel.util.OrderByComparator obc)
318 throws com.liferay.portal.NoSuchWebsiteException,
319 com.liferay.portal.kernel.exception.SystemException {
320 return getPersistence()
321 .findByC_C_C_P_First(companyId, classNameId, classPK,
322 primary, obc);
323 }
324
325 public static com.liferay.portal.model.Website findByC_C_C_P_Last(
326 long companyId, long classNameId, long classPK, boolean primary,
327 com.liferay.portal.kernel.util.OrderByComparator obc)
328 throws com.liferay.portal.NoSuchWebsiteException,
329 com.liferay.portal.kernel.exception.SystemException {
330 return getPersistence()
331 .findByC_C_C_P_Last(companyId, classNameId, classPK,
332 primary, obc);
333 }
334
335 public static com.liferay.portal.model.Website[] findByC_C_C_P_PrevAndNext(
336 long websiteId, long companyId, long classNameId, long classPK,
337 boolean primary, com.liferay.portal.kernel.util.OrderByComparator obc)
338 throws com.liferay.portal.NoSuchWebsiteException,
339 com.liferay.portal.kernel.exception.SystemException {
340 return getPersistence()
341 .findByC_C_C_P_PrevAndNext(websiteId, companyId,
342 classNameId, classPK, primary, obc);
343 }
344
345 public static java.util.List<com.liferay.portal.model.Website> findAll()
346 throws com.liferay.portal.kernel.exception.SystemException {
347 return getPersistence().findAll();
348 }
349
350 public static java.util.List<com.liferay.portal.model.Website> findAll(
351 int start, int end)
352 throws com.liferay.portal.kernel.exception.SystemException {
353 return getPersistence().findAll(start, end);
354 }
355
356 public static java.util.List<com.liferay.portal.model.Website> findAll(
357 int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
358 throws com.liferay.portal.kernel.exception.SystemException {
359 return getPersistence().findAll(start, end, obc);
360 }
361
362 public static void removeByCompanyId(long companyId)
363 throws com.liferay.portal.kernel.exception.SystemException {
364 getPersistence().removeByCompanyId(companyId);
365 }
366
367 public static void removeByUserId(long userId)
368 throws com.liferay.portal.kernel.exception.SystemException {
369 getPersistence().removeByUserId(userId);
370 }
371
372 public static void removeByC_C(long companyId, long classNameId)
373 throws com.liferay.portal.kernel.exception.SystemException {
374 getPersistence().removeByC_C(companyId, classNameId);
375 }
376
377 public static void removeByC_C_C(long companyId, long classNameId,
378 long classPK)
379 throws com.liferay.portal.kernel.exception.SystemException {
380 getPersistence().removeByC_C_C(companyId, classNameId, classPK);
381 }
382
383 public static void removeByC_C_C_P(long companyId, long classNameId,
384 long classPK, boolean primary)
385 throws com.liferay.portal.kernel.exception.SystemException {
386 getPersistence()
387 .removeByC_C_C_P(companyId, classNameId, classPK, primary);
388 }
389
390 public static void removeAll()
391 throws com.liferay.portal.kernel.exception.SystemException {
392 getPersistence().removeAll();
393 }
394
395 public static int countByCompanyId(long companyId)
396 throws com.liferay.portal.kernel.exception.SystemException {
397 return getPersistence().countByCompanyId(companyId);
398 }
399
400 public static int countByUserId(long userId)
401 throws com.liferay.portal.kernel.exception.SystemException {
402 return getPersistence().countByUserId(userId);
403 }
404
405 public static int countByC_C(long companyId, long classNameId)
406 throws com.liferay.portal.kernel.exception.SystemException {
407 return getPersistence().countByC_C(companyId, classNameId);
408 }
409
410 public static int countByC_C_C(long companyId, long classNameId,
411 long classPK)
412 throws com.liferay.portal.kernel.exception.SystemException {
413 return getPersistence().countByC_C_C(companyId, classNameId, classPK);
414 }
415
416 public static int countByC_C_C_P(long companyId, long classNameId,
417 long classPK, boolean primary)
418 throws com.liferay.portal.kernel.exception.SystemException {
419 return getPersistence()
420 .countByC_C_C_P(companyId, classNameId, classPK, primary);
421 }
422
423 public static int countAll()
424 throws com.liferay.portal.kernel.exception.SystemException {
425 return getPersistence().countAll();
426 }
427
428 public static WebsitePersistence getPersistence() {
429 if (_persistence == null) {
430 _persistence = (WebsitePersistence)PortalBeanLocatorUtil.locate(WebsitePersistence.class.getName());
431 }
432
433 return _persistence;
434 }
435
436 public void setPersistence(WebsitePersistence persistence) {
437 _persistence = persistence;
438 }
439
440 private static WebsitePersistence _persistence;
441 }