1   /**
2    * Copyright (c) 2000-2009 Liferay, Inc. All rights reserved.
3    *
4    *
5    *
6    *
7    * The contents of this file are subject to the terms of the Liferay Enterprise
8    * Subscription License ("License"). You may not use this file except in
9    * compliance with the License. You can obtain a copy of the License by
10   * contacting Liferay, Inc. See the License for the specific language governing
11   * permissions and limitations under the License, including but not limited to
12   * distribution rights 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.journal.service.persistence;
24  
25  import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
26  
27  /**
28   * <a href="JournalArticleFinderUtil.java.html"><b><i>View Source</i></b></a>
29   *
30   * @author Brian Wing Shun Chan
31   */
32  public class JournalArticleFinderUtil {
33      public static int countByKeywords(long companyId, long groupId,
34          java.lang.String keywords, java.lang.Double version,
35          java.lang.String type, java.lang.String structureId,
36          java.lang.String templateId, java.util.Date displayDateGT,
37          java.util.Date displayDateLT, java.lang.Boolean approved,
38          java.lang.Boolean expired, java.util.Date reviewDate)
39          throws com.liferay.portal.SystemException {
40          return getFinder()
41                     .countByKeywords(companyId, groupId, keywords, version,
42              type, structureId, templateId, displayDateGT, displayDateLT,
43              approved, expired, reviewDate);
44      }
45  
46      public static int countByC_G_A_V_T_D_C_T_S_T_D_A_E_R(long companyId,
47          long groupId, java.lang.String articleId, java.lang.Double version,
48          java.lang.String title, java.lang.String description,
49          java.lang.String content, java.lang.String type,
50          java.lang.String structureId, java.lang.String templateId,
51          java.util.Date displayDateGT, java.util.Date displayDateLT,
52          java.lang.Boolean approved, java.lang.Boolean expired,
53          java.util.Date reviewDate, boolean andOperator)
54          throws com.liferay.portal.SystemException {
55          return getFinder()
56                     .countByC_G_A_V_T_D_C_T_S_T_D_A_E_R(companyId, groupId,
57              articleId, version, title, description, content, type, structureId,
58              templateId, displayDateGT, displayDateLT, approved, expired,
59              reviewDate, andOperator);
60      }
61  
62      public static int countByC_G_A_V_T_D_C_T_S_T_D_A_E_R(long companyId,
63          long groupId, java.lang.String articleId, java.lang.Double version,
64          java.lang.String title, java.lang.String description,
65          java.lang.String content, java.lang.String type,
66          java.lang.String[] structureIds, java.lang.String[] templateIds,
67          java.util.Date displayDateGT, java.util.Date displayDateLT,
68          java.lang.Boolean approved, java.lang.Boolean expired,
69          java.util.Date reviewDate, boolean andOperator)
70          throws com.liferay.portal.SystemException {
71          return getFinder()
72                     .countByC_G_A_V_T_D_C_T_S_T_D_A_E_R(companyId, groupId,
73              articleId, version, title, description, content, type,
74              structureIds, templateIds, displayDateGT, displayDateLT, approved,
75              expired, reviewDate, andOperator);
76      }
77  
78      public static int countByC_G_A_V_T_D_C_T_S_T_D_A_E_R(long companyId,
79          long groupId, java.lang.String[] articleIds, java.lang.Double version,
80          java.lang.String[] titles, java.lang.String[] descriptions,
81          java.lang.String[] contents, java.lang.String type,
82          java.lang.String[] structureIds, java.lang.String[] templateIds,
83          java.util.Date displayDateGT, java.util.Date displayDateLT,
84          java.lang.Boolean approved, java.lang.Boolean expired,
85          java.util.Date reviewDate, boolean andOperator)
86          throws com.liferay.portal.SystemException {
87          return getFinder()
88                     .countByC_G_A_V_T_D_C_T_S_T_D_A_E_R(companyId, groupId,
89              articleIds, version, titles, descriptions, contents, type,
90              structureIds, templateIds, displayDateGT, displayDateLT, approved,
91              expired, reviewDate, andOperator);
92      }
93  
94      public static java.util.List<com.liferay.portlet.journal.model.JournalArticle> findByExpirationDate(
95          java.lang.Boolean expired, java.util.Date expirationDateLT,
96          java.util.Date expirationDateGT)
97          throws com.liferay.portal.SystemException {
98          return getFinder()
99                     .findByExpirationDate(expired, expirationDateLT,
100             expirationDateGT);
101     }
102 
103     public static java.util.List<com.liferay.portlet.journal.model.JournalArticle> findByKeywords(
104         long companyId, long groupId, java.lang.String keywords,
105         java.lang.Double version, java.lang.String type,
106         java.lang.String structureId, java.lang.String templateId,
107         java.util.Date displayDateGT, java.util.Date displayDateLT,
108         java.lang.Boolean approved, java.lang.Boolean expired,
109         java.util.Date reviewDate, int start, int end,
110         com.liferay.portal.kernel.util.OrderByComparator obc)
111         throws com.liferay.portal.SystemException {
112         return getFinder()
113                    .findByKeywords(companyId, groupId, keywords, version, type,
114             structureId, templateId, displayDateGT, displayDateLT, approved,
115             expired, reviewDate, start, end, obc);
116     }
117 
118     public static java.util.List<com.liferay.portlet.journal.model.JournalArticle> findByReviewDate(
119         java.util.Date reviewDateLT, java.util.Date reviewDateGT)
120         throws com.liferay.portal.SystemException {
121         return getFinder().findByReviewDate(reviewDateLT, reviewDateGT);
122     }
123 
124     public static com.liferay.portlet.journal.model.JournalArticle findByR_D(
125         long resourcePrimKey, java.util.Date displayDate)
126         throws com.liferay.portal.SystemException,
127             com.liferay.portlet.journal.NoSuchArticleException {
128         return getFinder().findByR_D(resourcePrimKey, displayDate);
129     }
130 
131     public static java.util.List<com.liferay.portlet.journal.model.JournalArticle> findByC_G_A_V_T_D_C_T_S_T_D_A_E_R(
132         long companyId, long groupId, java.lang.String articleId,
133         java.lang.Double version, java.lang.String title,
134         java.lang.String description, java.lang.String content,
135         java.lang.String type, java.lang.String structureId,
136         java.lang.String templateId, java.util.Date displayDateGT,
137         java.util.Date displayDateLT, java.lang.Boolean approved,
138         java.lang.Boolean expired, java.util.Date reviewDate,
139         boolean andOperator, int start, int end,
140         com.liferay.portal.kernel.util.OrderByComparator obc)
141         throws com.liferay.portal.SystemException {
142         return getFinder()
143                    .findByC_G_A_V_T_D_C_T_S_T_D_A_E_R(companyId, groupId,
144             articleId, version, title, description, content, type, structureId,
145             templateId, displayDateGT, displayDateLT, approved, expired,
146             reviewDate, andOperator, start, end, obc);
147     }
148 
149     public static java.util.List<com.liferay.portlet.journal.model.JournalArticle> findByC_G_A_V_T_D_C_T_S_T_D_A_E_R(
150         long companyId, long groupId, java.lang.String articleId,
151         java.lang.Double version, java.lang.String title,
152         java.lang.String description, java.lang.String content,
153         java.lang.String type, java.lang.String[] structureIds,
154         java.lang.String[] templateIds, java.util.Date displayDateGT,
155         java.util.Date displayDateLT, java.lang.Boolean approved,
156         java.lang.Boolean expired, java.util.Date reviewDate,
157         boolean andOperator, int start, int end,
158         com.liferay.portal.kernel.util.OrderByComparator obc)
159         throws com.liferay.portal.SystemException {
160         return getFinder()
161                    .findByC_G_A_V_T_D_C_T_S_T_D_A_E_R(companyId, groupId,
162             articleId, version, title, description, content, type,
163             structureIds, templateIds, displayDateGT, displayDateLT, approved,
164             expired, reviewDate, andOperator, start, end, obc);
165     }
166 
167     public static java.util.List<com.liferay.portlet.journal.model.JournalArticle> findByC_G_A_V_T_D_C_T_S_T_D_A_E_R(
168         long companyId, long groupId, java.lang.String[] articleIds,
169         java.lang.Double version, java.lang.String[] titles,
170         java.lang.String[] descriptions, java.lang.String[] contents,
171         java.lang.String type, java.lang.String[] structureIds,
172         java.lang.String[] templateIds, java.util.Date displayDateGT,
173         java.util.Date displayDateLT, java.lang.Boolean approved,
174         java.lang.Boolean expired, java.util.Date reviewDate,
175         boolean andOperator, int start, int end,
176         com.liferay.portal.kernel.util.OrderByComparator obc)
177         throws com.liferay.portal.SystemException {
178         return getFinder()
179                    .findByC_G_A_V_T_D_C_T_S_T_D_A_E_R(companyId, groupId,
180             articleIds, version, titles, descriptions, contents, type,
181             structureIds, templateIds, displayDateGT, displayDateLT, approved,
182             expired, reviewDate, andOperator, start, end, obc);
183     }
184 
185     public static JournalArticleFinder getFinder() {
186         if (_finder == null) {
187             _finder = (JournalArticleFinder)PortalBeanLocatorUtil.locate(JournalArticleFinder.class.getName());
188         }
189 
190         return _finder;
191     }
192 
193     public void setFinder(JournalArticleFinder finder) {
194         _finder = finder;
195     }
196 
197     private static JournalArticleFinder _finder;
198 }