1   /**
2    * Copyright (c) 2000-2008 Liferay, Inc. All rights reserved.
3    *
4    * Permission is hereby granted, free of charge, to any person obtaining a copy
5    * of this software and associated documentation files (the "Software"), to deal
6    * in the Software without restriction, including without limitation the rights
7    * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8    * copies of the Software, and to permit persons to whom the Software is
9    * furnished to do so, subject to the following conditions:
10   *
11   * The above copyright notice and this permission notice shall be included in
12   * all copies or substantial portions of the Software.
13   *
14   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15   * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16   * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17   * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18   * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19   * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20   * SOFTWARE.
21   */
22  
23  package com.liferay.portlet.social.service.persistence;
24  
25  /**
26   * <a href="SocialRelationUtil.java.html"><b><i>View Source</i></b></a>
27   *
28   * @author Brian Wing Shun Chan
29   *
30   */
31  public class SocialRelationUtil {
32      public static com.liferay.portlet.social.model.SocialRelation create(
33          long relationId) {
34          return getPersistence().create(relationId);
35      }
36  
37      public static com.liferay.portlet.social.model.SocialRelation remove(
38          long relationId)
39          throws com.liferay.portal.SystemException,
40              com.liferay.portlet.social.NoSuchRelationException {
41          return getPersistence().remove(relationId);
42      }
43  
44      public static com.liferay.portlet.social.model.SocialRelation remove(
45          com.liferay.portlet.social.model.SocialRelation socialRelation)
46          throws com.liferay.portal.SystemException {
47          return getPersistence().remove(socialRelation);
48      }
49  
50      /**
51       * @deprecated Use <code>update(SocialRelation socialRelation, boolean merge)</code>.
52       */
53      public static com.liferay.portlet.social.model.SocialRelation update(
54          com.liferay.portlet.social.model.SocialRelation socialRelation)
55          throws com.liferay.portal.SystemException {
56          return getPersistence().update(socialRelation);
57      }
58  
59      /**
60       * Add, update, or merge, the entity. This method also calls the model
61       * listeners to trigger the proper events associated with adding, deleting,
62       * or updating an entity.
63       *
64       * @param        socialRelation the entity to add, update, or merge
65       * @param        merge boolean value for whether to merge the entity. The
66       *                default value is false. Setting merge to true is more
67       *                expensive and should only be true when socialRelation is
68       *                transient. See LEP-5473 for a detailed discussion of this
69       *                method.
70       * @return        true if the portlet can be displayed via Ajax
71       */
72      public static com.liferay.portlet.social.model.SocialRelation update(
73          com.liferay.portlet.social.model.SocialRelation socialRelation,
74          boolean merge) throws com.liferay.portal.SystemException {
75          return getPersistence().update(socialRelation, merge);
76      }
77  
78      public static com.liferay.portlet.social.model.SocialRelation updateImpl(
79          com.liferay.portlet.social.model.SocialRelation socialRelation,
80          boolean merge) throws com.liferay.portal.SystemException {
81          return getPersistence().updateImpl(socialRelation, merge);
82      }
83  
84      public static com.liferay.portlet.social.model.SocialRelation findByPrimaryKey(
85          long relationId)
86          throws com.liferay.portal.SystemException,
87              com.liferay.portlet.social.NoSuchRelationException {
88          return getPersistence().findByPrimaryKey(relationId);
89      }
90  
91      public static com.liferay.portlet.social.model.SocialRelation fetchByPrimaryKey(
92          long relationId) throws com.liferay.portal.SystemException {
93          return getPersistence().fetchByPrimaryKey(relationId);
94      }
95  
96      public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByUuid(
97          java.lang.String uuid) throws com.liferay.portal.SystemException {
98          return getPersistence().findByUuid(uuid);
99      }
100 
101     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByUuid(
102         java.lang.String uuid, int begin, int end)
103         throws com.liferay.portal.SystemException {
104         return getPersistence().findByUuid(uuid, begin, end);
105     }
106 
107     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByUuid(
108         java.lang.String uuid, int begin, int end,
109         com.liferay.portal.kernel.util.OrderByComparator obc)
110         throws com.liferay.portal.SystemException {
111         return getPersistence().findByUuid(uuid, begin, end, obc);
112     }
113 
114     public static com.liferay.portlet.social.model.SocialRelation findByUuid_First(
115         java.lang.String uuid,
116         com.liferay.portal.kernel.util.OrderByComparator obc)
117         throws com.liferay.portal.SystemException,
118             com.liferay.portlet.social.NoSuchRelationException {
119         return getPersistence().findByUuid_First(uuid, obc);
120     }
121 
122     public static com.liferay.portlet.social.model.SocialRelation findByUuid_Last(
123         java.lang.String uuid,
124         com.liferay.portal.kernel.util.OrderByComparator obc)
125         throws com.liferay.portal.SystemException,
126             com.liferay.portlet.social.NoSuchRelationException {
127         return getPersistence().findByUuid_Last(uuid, obc);
128     }
129 
130     public static com.liferay.portlet.social.model.SocialRelation[] findByUuid_PrevAndNext(
131         long relationId, java.lang.String uuid,
132         com.liferay.portal.kernel.util.OrderByComparator obc)
133         throws com.liferay.portal.SystemException,
134             com.liferay.portlet.social.NoSuchRelationException {
135         return getPersistence().findByUuid_PrevAndNext(relationId, uuid, obc);
136     }
137 
138     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByCompanyId(
139         long companyId) throws com.liferay.portal.SystemException {
140         return getPersistence().findByCompanyId(companyId);
141     }
142 
143     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByCompanyId(
144         long companyId, int begin, int end)
145         throws com.liferay.portal.SystemException {
146         return getPersistence().findByCompanyId(companyId, begin, end);
147     }
148 
149     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByCompanyId(
150         long companyId, int begin, int end,
151         com.liferay.portal.kernel.util.OrderByComparator obc)
152         throws com.liferay.portal.SystemException {
153         return getPersistence().findByCompanyId(companyId, begin, end, obc);
154     }
155 
156     public static com.liferay.portlet.social.model.SocialRelation findByCompanyId_First(
157         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
158         throws com.liferay.portal.SystemException,
159             com.liferay.portlet.social.NoSuchRelationException {
160         return getPersistence().findByCompanyId_First(companyId, obc);
161     }
162 
163     public static com.liferay.portlet.social.model.SocialRelation findByCompanyId_Last(
164         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
165         throws com.liferay.portal.SystemException,
166             com.liferay.portlet.social.NoSuchRelationException {
167         return getPersistence().findByCompanyId_Last(companyId, obc);
168     }
169 
170     public static com.liferay.portlet.social.model.SocialRelation[] findByCompanyId_PrevAndNext(
171         long relationId, long companyId,
172         com.liferay.portal.kernel.util.OrderByComparator obc)
173         throws com.liferay.portal.SystemException,
174             com.liferay.portlet.social.NoSuchRelationException {
175         return getPersistence()
176                    .findByCompanyId_PrevAndNext(relationId, companyId, obc);
177     }
178 
179     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByUserId1(
180         long userId1) throws com.liferay.portal.SystemException {
181         return getPersistence().findByUserId1(userId1);
182     }
183 
184     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByUserId1(
185         long userId1, int begin, int end)
186         throws com.liferay.portal.SystemException {
187         return getPersistence().findByUserId1(userId1, begin, end);
188     }
189 
190     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByUserId1(
191         long userId1, int begin, int end,
192         com.liferay.portal.kernel.util.OrderByComparator obc)
193         throws com.liferay.portal.SystemException {
194         return getPersistence().findByUserId1(userId1, begin, end, obc);
195     }
196 
197     public static com.liferay.portlet.social.model.SocialRelation findByUserId1_First(
198         long userId1, com.liferay.portal.kernel.util.OrderByComparator obc)
199         throws com.liferay.portal.SystemException,
200             com.liferay.portlet.social.NoSuchRelationException {
201         return getPersistence().findByUserId1_First(userId1, obc);
202     }
203 
204     public static com.liferay.portlet.social.model.SocialRelation findByUserId1_Last(
205         long userId1, com.liferay.portal.kernel.util.OrderByComparator obc)
206         throws com.liferay.portal.SystemException,
207             com.liferay.portlet.social.NoSuchRelationException {
208         return getPersistence().findByUserId1_Last(userId1, obc);
209     }
210 
211     public static com.liferay.portlet.social.model.SocialRelation[] findByUserId1_PrevAndNext(
212         long relationId, long userId1,
213         com.liferay.portal.kernel.util.OrderByComparator obc)
214         throws com.liferay.portal.SystemException,
215             com.liferay.portlet.social.NoSuchRelationException {
216         return getPersistence()
217                    .findByUserId1_PrevAndNext(relationId, userId1, obc);
218     }
219 
220     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByUserId2(
221         long userId2) throws com.liferay.portal.SystemException {
222         return getPersistence().findByUserId2(userId2);
223     }
224 
225     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByUserId2(
226         long userId2, int begin, int end)
227         throws com.liferay.portal.SystemException {
228         return getPersistence().findByUserId2(userId2, begin, end);
229     }
230 
231     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByUserId2(
232         long userId2, int begin, int end,
233         com.liferay.portal.kernel.util.OrderByComparator obc)
234         throws com.liferay.portal.SystemException {
235         return getPersistence().findByUserId2(userId2, begin, end, obc);
236     }
237 
238     public static com.liferay.portlet.social.model.SocialRelation findByUserId2_First(
239         long userId2, com.liferay.portal.kernel.util.OrderByComparator obc)
240         throws com.liferay.portal.SystemException,
241             com.liferay.portlet.social.NoSuchRelationException {
242         return getPersistence().findByUserId2_First(userId2, obc);
243     }
244 
245     public static com.liferay.portlet.social.model.SocialRelation findByUserId2_Last(
246         long userId2, com.liferay.portal.kernel.util.OrderByComparator obc)
247         throws com.liferay.portal.SystemException,
248             com.liferay.portlet.social.NoSuchRelationException {
249         return getPersistence().findByUserId2_Last(userId2, obc);
250     }
251 
252     public static com.liferay.portlet.social.model.SocialRelation[] findByUserId2_PrevAndNext(
253         long relationId, long userId2,
254         com.liferay.portal.kernel.util.OrderByComparator obc)
255         throws com.liferay.portal.SystemException,
256             com.liferay.portlet.social.NoSuchRelationException {
257         return getPersistence()
258                    .findByUserId2_PrevAndNext(relationId, userId2, obc);
259     }
260 
261     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByType(
262         int type) throws com.liferay.portal.SystemException {
263         return getPersistence().findByType(type);
264     }
265 
266     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByType(
267         int type, int begin, int end) throws com.liferay.portal.SystemException {
268         return getPersistence().findByType(type, begin, end);
269     }
270 
271     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByType(
272         int type, int begin, int end,
273         com.liferay.portal.kernel.util.OrderByComparator obc)
274         throws com.liferay.portal.SystemException {
275         return getPersistence().findByType(type, begin, end, obc);
276     }
277 
278     public static com.liferay.portlet.social.model.SocialRelation findByType_First(
279         int type, com.liferay.portal.kernel.util.OrderByComparator obc)
280         throws com.liferay.portal.SystemException,
281             com.liferay.portlet.social.NoSuchRelationException {
282         return getPersistence().findByType_First(type, obc);
283     }
284 
285     public static com.liferay.portlet.social.model.SocialRelation findByType_Last(
286         int type, com.liferay.portal.kernel.util.OrderByComparator obc)
287         throws com.liferay.portal.SystemException,
288             com.liferay.portlet.social.NoSuchRelationException {
289         return getPersistence().findByType_Last(type, obc);
290     }
291 
292     public static com.liferay.portlet.social.model.SocialRelation[] findByType_PrevAndNext(
293         long relationId, int type,
294         com.liferay.portal.kernel.util.OrderByComparator obc)
295         throws com.liferay.portal.SystemException,
296             com.liferay.portlet.social.NoSuchRelationException {
297         return getPersistence().findByType_PrevAndNext(relationId, type, obc);
298     }
299 
300     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByC_T(
301         long companyId, int type) throws com.liferay.portal.SystemException {
302         return getPersistence().findByC_T(companyId, type);
303     }
304 
305     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByC_T(
306         long companyId, int type, int begin, int end)
307         throws com.liferay.portal.SystemException {
308         return getPersistence().findByC_T(companyId, type, begin, end);
309     }
310 
311     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByC_T(
312         long companyId, int type, int begin, int end,
313         com.liferay.portal.kernel.util.OrderByComparator obc)
314         throws com.liferay.portal.SystemException {
315         return getPersistence().findByC_T(companyId, type, begin, end, obc);
316     }
317 
318     public static com.liferay.portlet.social.model.SocialRelation findByC_T_First(
319         long companyId, int type,
320         com.liferay.portal.kernel.util.OrderByComparator obc)
321         throws com.liferay.portal.SystemException,
322             com.liferay.portlet.social.NoSuchRelationException {
323         return getPersistence().findByC_T_First(companyId, type, obc);
324     }
325 
326     public static com.liferay.portlet.social.model.SocialRelation findByC_T_Last(
327         long companyId, int type,
328         com.liferay.portal.kernel.util.OrderByComparator obc)
329         throws com.liferay.portal.SystemException,
330             com.liferay.portlet.social.NoSuchRelationException {
331         return getPersistence().findByC_T_Last(companyId, type, obc);
332     }
333 
334     public static com.liferay.portlet.social.model.SocialRelation[] findByC_T_PrevAndNext(
335         long relationId, long companyId, int type,
336         com.liferay.portal.kernel.util.OrderByComparator obc)
337         throws com.liferay.portal.SystemException,
338             com.liferay.portlet.social.NoSuchRelationException {
339         return getPersistence()
340                    .findByC_T_PrevAndNext(relationId, companyId, type, obc);
341     }
342 
343     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByU1_T(
344         long userId1, int type) throws com.liferay.portal.SystemException {
345         return getPersistence().findByU1_T(userId1, type);
346     }
347 
348     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByU1_T(
349         long userId1, int type, int begin, int end)
350         throws com.liferay.portal.SystemException {
351         return getPersistence().findByU1_T(userId1, type, begin, end);
352     }
353 
354     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByU1_T(
355         long userId1, int type, int begin, int end,
356         com.liferay.portal.kernel.util.OrderByComparator obc)
357         throws com.liferay.portal.SystemException {
358         return getPersistence().findByU1_T(userId1, type, begin, end, obc);
359     }
360 
361     public static com.liferay.portlet.social.model.SocialRelation findByU1_T_First(
362         long userId1, int type,
363         com.liferay.portal.kernel.util.OrderByComparator obc)
364         throws com.liferay.portal.SystemException,
365             com.liferay.portlet.social.NoSuchRelationException {
366         return getPersistence().findByU1_T_First(userId1, type, obc);
367     }
368 
369     public static com.liferay.portlet.social.model.SocialRelation findByU1_T_Last(
370         long userId1, int type,
371         com.liferay.portal.kernel.util.OrderByComparator obc)
372         throws com.liferay.portal.SystemException,
373             com.liferay.portlet.social.NoSuchRelationException {
374         return getPersistence().findByU1_T_Last(userId1, type, obc);
375     }
376 
377     public static com.liferay.portlet.social.model.SocialRelation[] findByU1_T_PrevAndNext(
378         long relationId, long userId1, int type,
379         com.liferay.portal.kernel.util.OrderByComparator obc)
380         throws com.liferay.portal.SystemException,
381             com.liferay.portlet.social.NoSuchRelationException {
382         return getPersistence()
383                    .findByU1_T_PrevAndNext(relationId, userId1, type, obc);
384     }
385 
386     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByU2_T(
387         long userId2, int type) throws com.liferay.portal.SystemException {
388         return getPersistence().findByU2_T(userId2, type);
389     }
390 
391     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByU2_T(
392         long userId2, int type, int begin, int end)
393         throws com.liferay.portal.SystemException {
394         return getPersistence().findByU2_T(userId2, type, begin, end);
395     }
396 
397     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findByU2_T(
398         long userId2, int type, int begin, int end,
399         com.liferay.portal.kernel.util.OrderByComparator obc)
400         throws com.liferay.portal.SystemException {
401         return getPersistence().findByU2_T(userId2, type, begin, end, obc);
402     }
403 
404     public static com.liferay.portlet.social.model.SocialRelation findByU2_T_First(
405         long userId2, int type,
406         com.liferay.portal.kernel.util.OrderByComparator obc)
407         throws com.liferay.portal.SystemException,
408             com.liferay.portlet.social.NoSuchRelationException {
409         return getPersistence().findByU2_T_First(userId2, type, obc);
410     }
411 
412     public static com.liferay.portlet.social.model.SocialRelation findByU2_T_Last(
413         long userId2, int type,
414         com.liferay.portal.kernel.util.OrderByComparator obc)
415         throws com.liferay.portal.SystemException,
416             com.liferay.portlet.social.NoSuchRelationException {
417         return getPersistence().findByU2_T_Last(userId2, type, obc);
418     }
419 
420     public static com.liferay.portlet.social.model.SocialRelation[] findByU2_T_PrevAndNext(
421         long relationId, long userId2, int type,
422         com.liferay.portal.kernel.util.OrderByComparator obc)
423         throws com.liferay.portal.SystemException,
424             com.liferay.portlet.social.NoSuchRelationException {
425         return getPersistence()
426                    .findByU2_T_PrevAndNext(relationId, userId2, type, obc);
427     }
428 
429     public static com.liferay.portlet.social.model.SocialRelation findByU1_U2_T(
430         long userId1, long userId2, int type)
431         throws com.liferay.portal.SystemException,
432             com.liferay.portlet.social.NoSuchRelationException {
433         return getPersistence().findByU1_U2_T(userId1, userId2, type);
434     }
435 
436     public static com.liferay.portlet.social.model.SocialRelation fetchByU1_U2_T(
437         long userId1, long userId2, int type)
438         throws com.liferay.portal.SystemException {
439         return getPersistence().fetchByU1_U2_T(userId1, userId2, type);
440     }
441 
442     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findWithDynamicQuery(
443         com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer)
444         throws com.liferay.portal.SystemException {
445         return getPersistence().findWithDynamicQuery(queryInitializer);
446     }
447 
448     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findWithDynamicQuery(
449         com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer,
450         int begin, int end) throws com.liferay.portal.SystemException {
451         return getPersistence()
452                    .findWithDynamicQuery(queryInitializer, begin, end);
453     }
454 
455     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findAll()
456         throws com.liferay.portal.SystemException {
457         return getPersistence().findAll();
458     }
459 
460     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findAll(
461         int begin, int end) throws com.liferay.portal.SystemException {
462         return getPersistence().findAll(begin, end);
463     }
464 
465     public static java.util.List<com.liferay.portlet.social.model.SocialRelation> findAll(
466         int begin, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
467         throws com.liferay.portal.SystemException {
468         return getPersistence().findAll(begin, end, obc);
469     }
470 
471     public static void removeByUuid(java.lang.String uuid)
472         throws com.liferay.portal.SystemException {
473         getPersistence().removeByUuid(uuid);
474     }
475 
476     public static void removeByCompanyId(long companyId)
477         throws com.liferay.portal.SystemException {
478         getPersistence().removeByCompanyId(companyId);
479     }
480 
481     public static void removeByUserId1(long userId1)
482         throws com.liferay.portal.SystemException {
483         getPersistence().removeByUserId1(userId1);
484     }
485 
486     public static void removeByUserId2(long userId2)
487         throws com.liferay.portal.SystemException {
488         getPersistence().removeByUserId2(userId2);
489     }
490 
491     public static void removeByType(int type)
492         throws com.liferay.portal.SystemException {
493         getPersistence().removeByType(type);
494     }
495 
496     public static void removeByC_T(long companyId, int type)
497         throws com.liferay.portal.SystemException {
498         getPersistence().removeByC_T(companyId, type);
499     }
500 
501     public static void removeByU1_T(long userId1, int type)
502         throws com.liferay.portal.SystemException {
503         getPersistence().removeByU1_T(userId1, type);
504     }
505 
506     public static void removeByU2_T(long userId2, int type)
507         throws com.liferay.portal.SystemException {
508         getPersistence().removeByU2_T(userId2, type);
509     }
510 
511     public static void removeByU1_U2_T(long userId1, long userId2, int type)
512         throws com.liferay.portal.SystemException,
513             com.liferay.portlet.social.NoSuchRelationException {
514         getPersistence().removeByU1_U2_T(userId1, userId2, type);
515     }
516 
517     public static void removeAll() throws com.liferay.portal.SystemException {
518         getPersistence().removeAll();
519     }
520 
521     public static int countByUuid(java.lang.String uuid)
522         throws com.liferay.portal.SystemException {
523         return getPersistence().countByUuid(uuid);
524     }
525 
526     public static int countByCompanyId(long companyId)
527         throws com.liferay.portal.SystemException {
528         return getPersistence().countByCompanyId(companyId);
529     }
530 
531     public static int countByUserId1(long userId1)
532         throws com.liferay.portal.SystemException {
533         return getPersistence().countByUserId1(userId1);
534     }
535 
536     public static int countByUserId2(long userId2)
537         throws com.liferay.portal.SystemException {
538         return getPersistence().countByUserId2(userId2);
539     }
540 
541     public static int countByType(int type)
542         throws com.liferay.portal.SystemException {
543         return getPersistence().countByType(type);
544     }
545 
546     public static int countByC_T(long companyId, int type)
547         throws com.liferay.portal.SystemException {
548         return getPersistence().countByC_T(companyId, type);
549     }
550 
551     public static int countByU1_T(long userId1, int type)
552         throws com.liferay.portal.SystemException {
553         return getPersistence().countByU1_T(userId1, type);
554     }
555 
556     public static int countByU2_T(long userId2, int type)
557         throws com.liferay.portal.SystemException {
558         return getPersistence().countByU2_T(userId2, type);
559     }
560 
561     public static int countByU1_U2_T(long userId1, long userId2, int type)
562         throws com.liferay.portal.SystemException {
563         return getPersistence().countByU1_U2_T(userId1, userId2, type);
564     }
565 
566     public static int countAll() throws com.liferay.portal.SystemException {
567         return getPersistence().countAll();
568     }
569 
570     public static SocialRelationPersistence getPersistence() {
571         return _getUtil()._persistence;
572     }
573 
574     public void setPersistence(SocialRelationPersistence persistence) {
575         _persistence = persistence;
576     }
577 
578     private static SocialRelationUtil _getUtil() {
579         if (_util == null) {
580             _util = (SocialRelationUtil)com.liferay.portal.kernel.bean.BeanLocatorUtil.locate(_UTIL);
581         }
582 
583         return _util;
584     }
585 
586     private static final String _UTIL = SocialRelationUtil.class.getName();
587     private static SocialRelationUtil _util;
588     private SocialRelationPersistence _persistence;
589 }