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.wiki.service.persistence;
16  
17  import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
18  import com.liferay.portal.kernel.util.ReferenceRegistry;
19  
20  /**
21   * <a href="WikiPageFinderUtil.java.html"><b><i>View Source</i></b></a>
22   *
23   * @author Brian Wing Shun Chan
24   */
25  public class WikiPageFinderUtil {
26      public static int countByCreateDate(long nodeId, java.util.Date createDate,
27          boolean before) throws com.liferay.portal.SystemException {
28          return getFinder().countByCreateDate(nodeId, createDate, before);
29      }
30  
31      public static int countByCreateDate(long nodeId,
32          java.sql.Timestamp createDate, boolean before)
33          throws com.liferay.portal.SystemException {
34          return getFinder().countByCreateDate(nodeId, createDate, before);
35      }
36  
37      public static com.liferay.portlet.wiki.model.WikiPage findByResourcePrimKey(
38          long resourcePrimKey)
39          throws com.liferay.portal.SystemException,
40              com.liferay.portlet.wiki.NoSuchPageException {
41          return getFinder().findByResourcePrimKey(resourcePrimKey);
42      }
43  
44      public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> findByCreateDate(
45          long nodeId, java.util.Date createDate, boolean before, int start,
46          int end) throws com.liferay.portal.SystemException {
47          return getFinder()
48                     .findByCreateDate(nodeId, createDate, before, start, end);
49      }
50  
51      public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> findByCreateDate(
52          long nodeId, java.sql.Timestamp createDate, boolean before, int start,
53          int end) throws com.liferay.portal.SystemException {
54          return getFinder()
55                     .findByCreateDate(nodeId, createDate, before, start, end);
56      }
57  
58      public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> findByNoAssets()
59          throws com.liferay.portal.SystemException {
60          return getFinder().findByNoAssets();
61      }
62  
63      public static WikiPageFinder getFinder() {
64          if (_finder == null) {
65              _finder = (WikiPageFinder)PortalBeanLocatorUtil.locate(WikiPageFinder.class.getName());
66  
67              ReferenceRegistry.registerReference(WikiPageFinderUtil.class,
68                  "_finder");
69          }
70  
71          return _finder;
72      }
73  
74      public void setFinder(WikiPageFinder finder) {
75          _finder = finder;
76  
77          ReferenceRegistry.registerReference(WikiPageFinderUtil.class, "_finder");
78      }
79  
80      private static WikiPageFinder _finder;
81  }