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;
24  
25  import com.liferay.portal.PortalException;
26  import com.liferay.portal.SystemException;
27  import com.liferay.portal.kernel.annotation.Isolation;
28  import com.liferay.portal.kernel.annotation.Propagation;
29  import com.liferay.portal.kernel.annotation.Transactional;
30  
31  /**
32   * <a href="BlogsEntryLocalService.java.html"><b><i>View Source</i></b></a>
33   *
34   * <p>
35   * ServiceBuilder generated this class. Modifications in this class will be
36   * overwritten the next time is generated.
37   * </p>
38   *
39   * <p>
40   * This interface defines the service. The default implementation is
41   * <code>com.liferay.portlet.blogs.service.impl.BlogsEntryLocalServiceImpl</code>.
42   * Modify methods in that class and rerun ServiceBuilder to populate this class
43   * and all other generated classes.
44   * </p>
45   *
46   * <p>
47   * This is a local service. Methods of this service will not have security checks based on the propagated JAAS credentials because this service can only be accessed from within the same VM.
48   * </p>
49   *
50   * @author Brian Wing Shun Chan
51   *
52   * @see com.liferay.portlet.blogs.service.BlogsEntryLocalServiceUtil
53   *
54   */
55  @Transactional(isolation = Isolation.PORTAL, rollbackFor =  {
56      PortalException.class, SystemException.class})
57  public interface BlogsEntryLocalService {
58      public com.liferay.portlet.blogs.model.BlogsEntry addBlogsEntry(
59          com.liferay.portlet.blogs.model.BlogsEntry blogsEntry)
60          throws com.liferay.portal.SystemException;
61  
62      public com.liferay.portlet.blogs.model.BlogsEntry createBlogsEntry(
63          long entryId);
64  
65      public void deleteBlogsEntry(long entryId)
66          throws com.liferay.portal.SystemException,
67              com.liferay.portal.PortalException;
68  
69      public void deleteBlogsEntry(
70          com.liferay.portlet.blogs.model.BlogsEntry blogsEntry)
71          throws com.liferay.portal.SystemException;
72  
73      public java.util.List<Object> dynamicQuery(
74          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
75          throws com.liferay.portal.SystemException;
76  
77      public java.util.List<Object> dynamicQuery(
78          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
79          int end) throws com.liferay.portal.SystemException;
80  
81      @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
82      public com.liferay.portlet.blogs.model.BlogsEntry getBlogsEntry(
83          long entryId)
84          throws com.liferay.portal.SystemException,
85              com.liferay.portal.PortalException;
86  
87      @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
88      public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getBlogsEntries(
89          int start, int end) throws com.liferay.portal.SystemException;
90  
91      @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
92      public int getBlogsEntriesCount() throws com.liferay.portal.SystemException;
93  
94      public com.liferay.portlet.blogs.model.BlogsEntry updateBlogsEntry(
95          com.liferay.portlet.blogs.model.BlogsEntry blogsEntry)
96          throws com.liferay.portal.SystemException;
97  
98      public com.liferay.portlet.blogs.model.BlogsEntry updateBlogsEntry(
99          com.liferay.portlet.blogs.model.BlogsEntry blogsEntry, boolean merge)
100         throws com.liferay.portal.SystemException;
101 
102     public com.liferay.portlet.blogs.model.BlogsEntry addEntry(long userId,
103         java.lang.String title, java.lang.String content, int displayDateMonth,
104         int displayDateDay, int displayDateYear, int displayDateHour,
105         int displayDateMinute, boolean draft, boolean allowTrackbacks,
106         java.lang.String[] trackbacks,
107         com.liferay.portal.service.ServiceContext serviceContext)
108         throws com.liferay.portal.PortalException,
109             com.liferay.portal.SystemException;
110 
111     public com.liferay.portlet.blogs.model.BlogsEntry addEntry(
112         java.lang.String uuid, long userId, java.lang.String title,
113         java.lang.String content, int displayDateMonth, int displayDateDay,
114         int displayDateYear, int displayDateHour, int displayDateMinute,
115         boolean draft, boolean allowTrackbacks, java.lang.String[] trackbacks,
116         com.liferay.portal.service.ServiceContext serviceContext)
117         throws com.liferay.portal.PortalException,
118             com.liferay.portal.SystemException;
119 
120     public void addEntryResources(long entryId,
121         boolean addCommunityPermissions, boolean addGuestPermissions)
122         throws com.liferay.portal.PortalException,
123             com.liferay.portal.SystemException;
124 
125     public void addEntryResources(
126         com.liferay.portlet.blogs.model.BlogsEntry entry,
127         boolean addCommunityPermissions, boolean addGuestPermissions)
128         throws com.liferay.portal.PortalException,
129             com.liferay.portal.SystemException;
130 
131     public void addEntryResources(long entryId,
132         java.lang.String[] communityPermissions,
133         java.lang.String[] guestPermissions)
134         throws com.liferay.portal.PortalException,
135             com.liferay.portal.SystemException;
136 
137     public void addEntryResources(
138         com.liferay.portlet.blogs.model.BlogsEntry entry,
139         java.lang.String[] communityPermissions,
140         java.lang.String[] guestPermissions)
141         throws com.liferay.portal.PortalException,
142             com.liferay.portal.SystemException;
143 
144     public void deleteEntries(long groupId)
145         throws com.liferay.portal.PortalException,
146             com.liferay.portal.SystemException;
147 
148     public void deleteEntry(long entryId)
149         throws com.liferay.portal.PortalException,
150             com.liferay.portal.SystemException;
151 
152     public void deleteEntry(com.liferay.portlet.blogs.model.BlogsEntry entry)
153         throws com.liferay.portal.PortalException,
154             com.liferay.portal.SystemException;
155 
156     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
157     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getCompanyEntries(
158         long companyId, int start, int end)
159         throws com.liferay.portal.SystemException;
160 
161     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
162     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getCompanyEntries(
163         long companyId, int start, int end,
164         com.liferay.portal.kernel.util.OrderByComparator obc)
165         throws com.liferay.portal.SystemException;
166 
167     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
168     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getCompanyEntries(
169         long companyId, boolean draft, int start, int end)
170         throws com.liferay.portal.SystemException;
171 
172     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
173     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getCompanyEntries(
174         long companyId, boolean draft, int start, int end,
175         com.liferay.portal.kernel.util.OrderByComparator obc)
176         throws com.liferay.portal.SystemException;
177 
178     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
179     public int getCompanyEntriesCount(long companyId)
180         throws com.liferay.portal.SystemException;
181 
182     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
183     public int getCompanyEntriesCount(long companyId, boolean draft)
184         throws com.liferay.portal.SystemException;
185 
186     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
187     public com.liferay.portlet.blogs.model.BlogsEntry[] getEntriesPrevAndNext(
188         long entryId)
189         throws com.liferay.portal.PortalException,
190             com.liferay.portal.SystemException;
191 
192     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
193     public com.liferay.portlet.blogs.model.BlogsEntry getEntry(long entryId)
194         throws com.liferay.portal.PortalException,
195             com.liferay.portal.SystemException;
196 
197     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
198     public com.liferay.portlet.blogs.model.BlogsEntry getEntry(long groupId,
199         java.lang.String urlTitle)
200         throws com.liferay.portal.PortalException,
201             com.liferay.portal.SystemException;
202 
203     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
204     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getGroupEntries(
205         long groupId, int start, int end)
206         throws com.liferay.portal.SystemException;
207 
208     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
209     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getGroupEntries(
210         long groupId, int start, int end,
211         com.liferay.portal.kernel.util.OrderByComparator obc)
212         throws com.liferay.portal.SystemException;
213 
214     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
215     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getGroupEntries(
216         long groupId, boolean draft, int start, int end)
217         throws com.liferay.portal.SystemException;
218 
219     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
220     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getGroupEntries(
221         long groupId, boolean draft, int start, int end,
222         com.liferay.portal.kernel.util.OrderByComparator obc)
223         throws com.liferay.portal.SystemException;
224 
225     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
226     public int getGroupEntriesCount(long groupId)
227         throws com.liferay.portal.SystemException;
228 
229     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
230     public int getGroupEntriesCount(long groupId, boolean draft)
231         throws com.liferay.portal.SystemException;
232 
233     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
234     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getGroupUserEntries(
235         long groupId, long userId, int start, int end)
236         throws com.liferay.portal.SystemException;
237 
238     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
239     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getGroupUserEntries(
240         long groupId, long userId, int start, int end,
241         com.liferay.portal.kernel.util.OrderByComparator obc)
242         throws com.liferay.portal.SystemException;
243 
244     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
245     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getGroupUserEntries(
246         long groupId, long userId, boolean draft, int start, int end)
247         throws com.liferay.portal.SystemException;
248 
249     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
250     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getGroupUserEntries(
251         long groupId, long userId, boolean draft, int start, int end,
252         com.liferay.portal.kernel.util.OrderByComparator obc)
253         throws com.liferay.portal.SystemException;
254 
255     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
256     public int getGroupUserEntriesCount(long groupId, long userId)
257         throws com.liferay.portal.SystemException;
258 
259     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
260     public int getGroupUserEntriesCount(long groupId, long userId, boolean draft)
261         throws com.liferay.portal.SystemException;
262 
263     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
264     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getNoAssetEntries()
265         throws com.liferay.portal.SystemException;
266 
267     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
268     public java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getOrganizationEntries(
269         long organizationId, boolean draft, int start, int end)
270         throws com.liferay.portal.SystemException;
271 
272     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
273     public int getOrganizationEntriesCount(long organizationId, boolean draft)
274         throws com.liferay.portal.SystemException;
275 
276     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
277     public java.lang.String getUrlTitle(long entryId, java.lang.String title);
278 
279     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
280     public void reIndex(long entryId) throws com.liferay.portal.SystemException;
281 
282     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
283     public void reIndex(com.liferay.portlet.blogs.model.BlogsEntry entry)
284         throws com.liferay.portal.SystemException;
285 
286     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
287     public void reIndex(java.lang.String[] ids)
288         throws com.liferay.portal.SystemException;
289 
290     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
291     public com.liferay.portal.kernel.search.Hits search(long companyId,
292         long groupId, long userId, long ownerUserId, java.lang.String keywords,
293         int start, int end) throws com.liferay.portal.SystemException;
294 
295     public com.liferay.portlet.blogs.model.BlogsEntry updateEntry(long userId,
296         long entryId, java.lang.String title, java.lang.String content,
297         int displayDateMonth, int displayDateDay, int displayDateYear,
298         int displayDateHour, int displayDateMinute, boolean draft,
299         boolean allowTrackbacks, java.lang.String[] trackbacks,
300         com.liferay.portal.service.ServiceContext serviceContext)
301         throws com.liferay.portal.PortalException,
302             com.liferay.portal.SystemException;
303 
304     public void updateEntryResources(
305         com.liferay.portlet.blogs.model.BlogsEntry entry,
306         java.lang.String[] communityPermissions,
307         java.lang.String[] guestPermissions)
308         throws com.liferay.portal.PortalException,
309             com.liferay.portal.SystemException;
310 
311     public void updateTagsAsset(long userId,
312         com.liferay.portlet.blogs.model.BlogsEntry entry,
313         java.lang.String[] tagsEntries)
314         throws com.liferay.portal.PortalException,
315             com.liferay.portal.SystemException;
316 }