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