1   /**
2    * Copyright (c) 2000-2009 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.blogs.service.persistence;
24  
25  import com.liferay.portal.service.persistence.BasePersistence;
26  
27  /**
28   * <a href="BlogsEntryPersistence.java.html"><b><i>View Source</i></b></a>
29   *
30   * @author Brian Wing Shun Chan
31   *
32   */
33  public interface BlogsEntryPersistence extends BasePersistence {
34      public void cacheResult(
35          com.liferay.portlet.blogs.model.BlogsEntry blogsEntry);
36  
37      public void cacheResult(
38          java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> blogsEntries);
39  
40      public void clearCache();
41  
42      public com.liferay.portlet.blogs.model.BlogsEntry create(long entryId);
43  
44      public com.liferay.portlet.blogs.model.BlogsEntry remove(long entryId)
45          throws com.liferay.portal.SystemException,
46              com.liferay.portlet.blogs.NoSuchEntryException;
47  
48      public com.liferay.portlet.blogs.model.BlogsEntry remove(
49          com.liferay.portlet.blogs.model.BlogsEntry blogsEntry)
50          throws com.liferay.portal.SystemException;
51  
52      /**
53       * @deprecated Use <code>update(BlogsEntry blogsEntry, boolean merge)</code>.
54       */
55      public com.liferay.portlet.blogs.model.BlogsEntry update(
56          com.liferay.portlet.blogs.model.BlogsEntry blogsEntry)
57          throws com.liferay.portal.SystemException;
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        blogsEntry 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 blogsEntry 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 com.liferay.portlet.blogs.model.BlogsEntry update(
73          com.liferay.portlet.blogs.model.BlogsEntry blogsEntry, boolean merge)
74          throws com.liferay.portal.SystemException;
75  
76      public com.liferay.portlet.blogs.model.BlogsEntry updateImpl(
77          com.liferay.portlet.blogs.model.BlogsEntry blogsEntry, boolean merge)
78          throws com.liferay.portal.SystemException;
79  
80      public com.liferay.portlet.blogs.model.BlogsEntry findByPrimaryKey(
81          long entryId)
82          throws com.liferay.portal.SystemException,
83              com.liferay.portlet.blogs.NoSuchEntryException;
84  
85      public com.liferay.portlet.blogs.model.BlogsEntry fetchByPrimaryKey(
86          long entryId) throws com.liferay.portal.SystemException;
87  
88      public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByUuid(
89          java.lang.String uuid) throws com.liferay.portal.SystemException;
90  
91      public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByUuid(
92          java.lang.String uuid, int start, int end)
93          throws com.liferay.portal.SystemException;
94  
95      public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByUuid(
96          java.lang.String uuid, int start, int end,
97          com.liferay.portal.kernel.util.OrderByComparator obc)
98          throws com.liferay.portal.SystemException;
99  
100     public com.liferay.portlet.blogs.model.BlogsEntry findByUuid_First(
101         java.lang.String uuid,
102         com.liferay.portal.kernel.util.OrderByComparator obc)
103         throws com.liferay.portal.SystemException,
104             com.liferay.portlet.blogs.NoSuchEntryException;
105 
106     public com.liferay.portlet.blogs.model.BlogsEntry findByUuid_Last(
107         java.lang.String uuid,
108         com.liferay.portal.kernel.util.OrderByComparator obc)
109         throws com.liferay.portal.SystemException,
110             com.liferay.portlet.blogs.NoSuchEntryException;
111 
112     public com.liferay.portlet.blogs.model.BlogsEntry[] findByUuid_PrevAndNext(
113         long entryId, java.lang.String uuid,
114         com.liferay.portal.kernel.util.OrderByComparator obc)
115         throws com.liferay.portal.SystemException,
116             com.liferay.portlet.blogs.NoSuchEntryException;
117 
118     public com.liferay.portlet.blogs.model.BlogsEntry findByUUID_G(
119         java.lang.String uuid, long groupId)
120         throws com.liferay.portal.SystemException,
121             com.liferay.portlet.blogs.NoSuchEntryException;
122 
123     public com.liferay.portlet.blogs.model.BlogsEntry fetchByUUID_G(
124         java.lang.String uuid, long groupId)
125         throws com.liferay.portal.SystemException;
126 
127     public com.liferay.portlet.blogs.model.BlogsEntry fetchByUUID_G(
128         java.lang.String uuid, long groupId, boolean retrieveFromCache)
129         throws com.liferay.portal.SystemException;
130 
131     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByGroupId(
132         long groupId) throws com.liferay.portal.SystemException;
133 
134     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByGroupId(
135         long groupId, int start, int end)
136         throws com.liferay.portal.SystemException;
137 
138     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByGroupId(
139         long groupId, int start, int end,
140         com.liferay.portal.kernel.util.OrderByComparator obc)
141         throws com.liferay.portal.SystemException;
142 
143     public com.liferay.portlet.blogs.model.BlogsEntry findByGroupId_First(
144         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
145         throws com.liferay.portal.SystemException,
146             com.liferay.portlet.blogs.NoSuchEntryException;
147 
148     public com.liferay.portlet.blogs.model.BlogsEntry findByGroupId_Last(
149         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
150         throws com.liferay.portal.SystemException,
151             com.liferay.portlet.blogs.NoSuchEntryException;
152 
153     public com.liferay.portlet.blogs.model.BlogsEntry[] findByGroupId_PrevAndNext(
154         long entryId, long groupId,
155         com.liferay.portal.kernel.util.OrderByComparator obc)
156         throws com.liferay.portal.SystemException,
157             com.liferay.portlet.blogs.NoSuchEntryException;
158 
159     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByCompanyId(
160         long companyId) throws com.liferay.portal.SystemException;
161 
162     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByCompanyId(
163         long companyId, int start, int end)
164         throws com.liferay.portal.SystemException;
165 
166     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByCompanyId(
167         long companyId, int start, int end,
168         com.liferay.portal.kernel.util.OrderByComparator obc)
169         throws com.liferay.portal.SystemException;
170 
171     public com.liferay.portlet.blogs.model.BlogsEntry findByCompanyId_First(
172         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
173         throws com.liferay.portal.SystemException,
174             com.liferay.portlet.blogs.NoSuchEntryException;
175 
176     public com.liferay.portlet.blogs.model.BlogsEntry findByCompanyId_Last(
177         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
178         throws com.liferay.portal.SystemException,
179             com.liferay.portlet.blogs.NoSuchEntryException;
180 
181     public com.liferay.portlet.blogs.model.BlogsEntry[] findByCompanyId_PrevAndNext(
182         long entryId, long companyId,
183         com.liferay.portal.kernel.util.OrderByComparator obc)
184         throws com.liferay.portal.SystemException,
185             com.liferay.portlet.blogs.NoSuchEntryException;
186 
187     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByG_U(
188         long groupId, long userId) throws com.liferay.portal.SystemException;
189 
190     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByG_U(
191         long groupId, long userId, int start, int end)
192         throws com.liferay.portal.SystemException;
193 
194     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByG_U(
195         long groupId, long userId, int start, int end,
196         com.liferay.portal.kernel.util.OrderByComparator obc)
197         throws com.liferay.portal.SystemException;
198 
199     public com.liferay.portlet.blogs.model.BlogsEntry findByG_U_First(
200         long groupId, long userId,
201         com.liferay.portal.kernel.util.OrderByComparator obc)
202         throws com.liferay.portal.SystemException,
203             com.liferay.portlet.blogs.NoSuchEntryException;
204 
205     public com.liferay.portlet.blogs.model.BlogsEntry findByG_U_Last(
206         long groupId, long userId,
207         com.liferay.portal.kernel.util.OrderByComparator obc)
208         throws com.liferay.portal.SystemException,
209             com.liferay.portlet.blogs.NoSuchEntryException;
210 
211     public com.liferay.portlet.blogs.model.BlogsEntry[] findByG_U_PrevAndNext(
212         long entryId, long groupId, long userId,
213         com.liferay.portal.kernel.util.OrderByComparator obc)
214         throws com.liferay.portal.SystemException,
215             com.liferay.portlet.blogs.NoSuchEntryException;
216 
217     public com.liferay.portlet.blogs.model.BlogsEntry findByG_UT(long groupId,
218         java.lang.String urlTitle)
219         throws com.liferay.portal.SystemException,
220             com.liferay.portlet.blogs.NoSuchEntryException;
221 
222     public com.liferay.portlet.blogs.model.BlogsEntry fetchByG_UT(
223         long groupId, java.lang.String urlTitle)
224         throws com.liferay.portal.SystemException;
225 
226     public com.liferay.portlet.blogs.model.BlogsEntry fetchByG_UT(
227         long groupId, java.lang.String urlTitle, boolean retrieveFromCache)
228         throws com.liferay.portal.SystemException;
229 
230     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByG_D_D(
231         long groupId, java.util.Date displayDate, boolean draft)
232         throws com.liferay.portal.SystemException;
233 
234     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByG_D_D(
235         long groupId, java.util.Date displayDate, boolean draft, int start,
236         int end) throws com.liferay.portal.SystemException;
237 
238     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByG_D_D(
239         long groupId, java.util.Date displayDate, boolean draft, int start,
240         int end, com.liferay.portal.kernel.util.OrderByComparator obc)
241         throws com.liferay.portal.SystemException;
242 
243     public com.liferay.portlet.blogs.model.BlogsEntry findByG_D_D_First(
244         long groupId, java.util.Date displayDate, boolean draft,
245         com.liferay.portal.kernel.util.OrderByComparator obc)
246         throws com.liferay.portal.SystemException,
247             com.liferay.portlet.blogs.NoSuchEntryException;
248 
249     public com.liferay.portlet.blogs.model.BlogsEntry findByG_D_D_Last(
250         long groupId, java.util.Date displayDate, boolean draft,
251         com.liferay.portal.kernel.util.OrderByComparator obc)
252         throws com.liferay.portal.SystemException,
253             com.liferay.portlet.blogs.NoSuchEntryException;
254 
255     public com.liferay.portlet.blogs.model.BlogsEntry[] findByG_D_D_PrevAndNext(
256         long entryId, long groupId, java.util.Date displayDate, boolean draft,
257         com.liferay.portal.kernel.util.OrderByComparator obc)
258         throws com.liferay.portal.SystemException,
259             com.liferay.portlet.blogs.NoSuchEntryException;
260 
261     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByC_D_D(
262         long companyId, java.util.Date displayDate, boolean draft)
263         throws com.liferay.portal.SystemException;
264 
265     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByC_D_D(
266         long companyId, java.util.Date displayDate, boolean draft, int start,
267         int end) throws com.liferay.portal.SystemException;
268 
269     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByC_D_D(
270         long companyId, java.util.Date displayDate, boolean draft, int start,
271         int end, com.liferay.portal.kernel.util.OrderByComparator obc)
272         throws com.liferay.portal.SystemException;
273 
274     public com.liferay.portlet.blogs.model.BlogsEntry findByC_D_D_First(
275         long companyId, java.util.Date displayDate, boolean draft,
276         com.liferay.portal.kernel.util.OrderByComparator obc)
277         throws com.liferay.portal.SystemException,
278             com.liferay.portlet.blogs.NoSuchEntryException;
279 
280     public com.liferay.portlet.blogs.model.BlogsEntry findByC_D_D_Last(
281         long companyId, java.util.Date displayDate, boolean draft,
282         com.liferay.portal.kernel.util.OrderByComparator obc)
283         throws com.liferay.portal.SystemException,
284             com.liferay.portlet.blogs.NoSuchEntryException;
285 
286     public com.liferay.portlet.blogs.model.BlogsEntry[] findByC_D_D_PrevAndNext(
287         long entryId, long companyId, java.util.Date displayDate,
288         boolean draft, com.liferay.portal.kernel.util.OrderByComparator obc)
289         throws com.liferay.portal.SystemException,
290             com.liferay.portlet.blogs.NoSuchEntryException;
291 
292     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByG_U_D_D(
293         long groupId, long userId, java.util.Date displayDate, boolean draft)
294         throws com.liferay.portal.SystemException;
295 
296     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByG_U_D_D(
297         long groupId, long userId, java.util.Date displayDate, boolean draft,
298         int start, int end) throws com.liferay.portal.SystemException;
299 
300     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findByG_U_D_D(
301         long groupId, long userId, java.util.Date displayDate, boolean draft,
302         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
303         throws com.liferay.portal.SystemException;
304 
305     public com.liferay.portlet.blogs.model.BlogsEntry findByG_U_D_D_First(
306         long groupId, long userId, java.util.Date displayDate, boolean draft,
307         com.liferay.portal.kernel.util.OrderByComparator obc)
308         throws com.liferay.portal.SystemException,
309             com.liferay.portlet.blogs.NoSuchEntryException;
310 
311     public com.liferay.portlet.blogs.model.BlogsEntry findByG_U_D_D_Last(
312         long groupId, long userId, java.util.Date displayDate, boolean draft,
313         com.liferay.portal.kernel.util.OrderByComparator obc)
314         throws com.liferay.portal.SystemException,
315             com.liferay.portlet.blogs.NoSuchEntryException;
316 
317     public com.liferay.portlet.blogs.model.BlogsEntry[] findByG_U_D_D_PrevAndNext(
318         long entryId, long groupId, long userId, java.util.Date displayDate,
319         boolean draft, com.liferay.portal.kernel.util.OrderByComparator obc)
320         throws com.liferay.portal.SystemException,
321             com.liferay.portlet.blogs.NoSuchEntryException;
322 
323     public java.util.List<Object> findWithDynamicQuery(
324         com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
325         throws com.liferay.portal.SystemException;
326 
327     public java.util.List<Object> findWithDynamicQuery(
328         com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
329         int end) throws com.liferay.portal.SystemException;
330 
331     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findAll()
332         throws com.liferay.portal.SystemException;
333 
334     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findAll(
335         int start, int end) throws com.liferay.portal.SystemException;
336 
337     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> findAll(
338         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
339         throws com.liferay.portal.SystemException;
340 
341     public void removeByUuid(java.lang.String uuid)
342         throws com.liferay.portal.SystemException;
343 
344     public void removeByUUID_G(java.lang.String uuid, long groupId)
345         throws com.liferay.portal.SystemException,
346             com.liferay.portlet.blogs.NoSuchEntryException;
347 
348     public void removeByGroupId(long groupId)
349         throws com.liferay.portal.SystemException;
350 
351     public void removeByCompanyId(long companyId)
352         throws com.liferay.portal.SystemException;
353 
354     public void removeByG_U(long groupId, long userId)
355         throws com.liferay.portal.SystemException;
356 
357     public void removeByG_UT(long groupId, java.lang.String urlTitle)
358         throws com.liferay.portal.SystemException,
359             com.liferay.portlet.blogs.NoSuchEntryException;
360 
361     public void removeByG_D_D(long groupId, java.util.Date displayDate,
362         boolean draft) throws com.liferay.portal.SystemException;
363 
364     public void removeByC_D_D(long companyId, java.util.Date displayDate,
365         boolean draft) throws com.liferay.portal.SystemException;
366 
367     public void removeByG_U_D_D(long groupId, long userId,
368         java.util.Date displayDate, boolean draft)
369         throws com.liferay.portal.SystemException;
370 
371     public void removeAll() throws com.liferay.portal.SystemException;
372 
373     public int countByUuid(java.lang.String uuid)
374         throws com.liferay.portal.SystemException;
375 
376     public int countByUUID_G(java.lang.String uuid, long groupId)
377         throws com.liferay.portal.SystemException;
378 
379     public int countByGroupId(long groupId)
380         throws com.liferay.portal.SystemException;
381 
382     public int countByCompanyId(long companyId)
383         throws com.liferay.portal.SystemException;
384 
385     public int countByG_U(long groupId, long userId)
386         throws com.liferay.portal.SystemException;
387 
388     public int countByG_UT(long groupId, java.lang.String urlTitle)
389         throws com.liferay.portal.SystemException;
390 
391     public int countByG_D_D(long groupId, java.util.Date displayDate,
392         boolean draft) throws com.liferay.portal.SystemException;
393 
394     public int countByC_D_D(long companyId, java.util.Date displayDate,
395         boolean draft) throws com.liferay.portal.SystemException;
396 
397     public int countByG_U_D_D(long groupId, long userId,
398         java.util.Date displayDate, boolean draft)
399         throws com.liferay.portal.SystemException;
400 
401     public int countAll() throws com.liferay.portal.SystemException;
402 }