1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * The contents of this file are subject to the terms of the Liferay Enterprise
5    * Subscription License ("License"). You may not use this file except in
6    * compliance with the License. You can obtain a copy of the License by
7    * contacting Liferay, Inc. See the License for the specific language governing
8    * permissions and limitations under the License, including but not limited to
9    * distribution rights of the Software.
10   *
11   *
12   *
13   */
14  
15  package com.liferay.portlet.blogs.service.persistence;
16  
17  import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
18  import com.liferay.portal.kernel.util.ReferenceRegistry;
19  
20  /**
21   * <a href="BlogsStatsUserFinderUtil.java.html"><b><i>View Source</i></b></a>
22   *
23   * @author Brian Wing Shun Chan
24   */
25  public class BlogsStatsUserFinderUtil {
26      public static int countByOrganizationId(long organizationId)
27          throws com.liferay.portal.SystemException {
28          return getFinder().countByOrganizationId(organizationId);
29      }
30  
31      public static int countByOrganizationIds(
32          java.util.List<java.lang.Long> organizationIds)
33          throws com.liferay.portal.SystemException {
34          return getFinder().countByOrganizationIds(organizationIds);
35      }
36  
37      public static java.util.List<com.liferay.portlet.blogs.model.BlogsStatsUser> findByGroupIds(
38          long companyId, long groupId, int start, int end)
39          throws com.liferay.portal.SystemException {
40          return getFinder().findByGroupIds(companyId, groupId, start, end);
41      }
42  
43      public static java.util.List<com.liferay.portlet.blogs.model.BlogsStatsUser> findByOrganizationId(
44          long organizationId, int start, int end,
45          com.liferay.portal.kernel.util.OrderByComparator obc)
46          throws com.liferay.portal.SystemException {
47          return getFinder().findByOrganizationId(organizationId, start, end, obc);
48      }
49  
50      public static java.util.List<com.liferay.portlet.blogs.model.BlogsStatsUser> findByOrganizationIds(
51          java.util.List<java.lang.Long> organizationIds, int start, int end,
52          com.liferay.portal.kernel.util.OrderByComparator obc)
53          throws com.liferay.portal.SystemException {
54          return getFinder()
55                     .findByOrganizationIds(organizationIds, start, end, obc);
56      }
57  
58      public static BlogsStatsUserFinder getFinder() {
59          if (_finder == null) {
60              _finder = (BlogsStatsUserFinder)PortalBeanLocatorUtil.locate(BlogsStatsUserFinder.class.getName());
61  
62              ReferenceRegistry.registerReference(BlogsStatsUserFinderUtil.class,
63                  "_finder");
64          }
65  
66          return _finder;
67      }
68  
69      public void setFinder(BlogsStatsUserFinder finder) {
70          _finder = finder;
71  
72          ReferenceRegistry.registerReference(BlogsStatsUserFinderUtil.class,
73              "_finder");
74      }
75  
76      private static BlogsStatsUserFinder _finder;
77  }