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.messageboards.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="MBMessageLocalService.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   * {@link
42   * com.liferay.portlet.messageboards.service.impl.MBMessageLocalServiceImpl}}.
43   * Modify methods in that class and rerun ServiceBuilder to populate this class
44   * and all other generated classes.
45   * </p>
46   *
47   * <p>
48   * 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.
49   * </p>
50   *
51   * @author    Brian Wing Shun Chan
52   * @see       MBMessageLocalServiceUtil
53   * @generated
54   */
55  @Transactional(isolation = Isolation.PORTAL, rollbackFor =  {
56      PortalException.class, SystemException.class})
57  public interface MBMessageLocalService {
58      public com.liferay.portlet.messageboards.model.MBMessage addMBMessage(
59          com.liferay.portlet.messageboards.model.MBMessage mbMessage)
60          throws com.liferay.portal.SystemException;
61  
62      public com.liferay.portlet.messageboards.model.MBMessage createMBMessage(
63          long messageId);
64  
65      public void deleteMBMessage(long messageId)
66          throws com.liferay.portal.PortalException,
67              com.liferay.portal.SystemException;
68  
69      public void deleteMBMessage(
70          com.liferay.portlet.messageboards.model.MBMessage mbMessage)
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.messageboards.model.MBMessage getMBMessage(
83          long messageId)
84          throws com.liferay.portal.PortalException,
85              com.liferay.portal.SystemException;
86  
87      @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
88      public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getMBMessages(
89          int start, int end) throws com.liferay.portal.SystemException;
90  
91      @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
92      public int getMBMessagesCount() throws com.liferay.portal.SystemException;
93  
94      public com.liferay.portlet.messageboards.model.MBMessage updateMBMessage(
95          com.liferay.portlet.messageboards.model.MBMessage mbMessage)
96          throws com.liferay.portal.SystemException;
97  
98      public com.liferay.portlet.messageboards.model.MBMessage updateMBMessage(
99          com.liferay.portlet.messageboards.model.MBMessage mbMessage,
100         boolean merge) throws com.liferay.portal.SystemException;
101 
102     public com.liferay.portlet.messageboards.model.MBMessage addDiscussionMessage(
103         long userId, java.lang.String userName, java.lang.String className,
104         long classPK)
105         throws com.liferay.portal.PortalException,
106             com.liferay.portal.SystemException;
107 
108     public com.liferay.portlet.messageboards.model.MBMessage addDiscussionMessage(
109         long userId, java.lang.String userName, long groupId,
110         java.lang.String className, long classPK, long threadId,
111         long parentMessageId, java.lang.String subject, java.lang.String body)
112         throws com.liferay.portal.PortalException,
113             com.liferay.portal.SystemException;
114 
115     public com.liferay.portlet.messageboards.model.MBMessage addDiscussionMessage(
116         long userId, java.lang.String userName, long groupId,
117         java.lang.String className, long classPK, long threadId,
118         long parentMessageId, java.lang.String subject, java.lang.String body,
119         com.liferay.portal.theme.ThemeDisplay themeDisplay)
120         throws com.liferay.portal.PortalException,
121             com.liferay.portal.SystemException;
122 
123     public com.liferay.portlet.messageboards.model.MBMessage addMessage(
124         long userId, java.lang.String userName, long categoryId,
125         java.lang.String subject, java.lang.String body,
126         java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
127         boolean anonymous, double priority, java.lang.String[] tagsEntries,
128         javax.portlet.PortletPreferences prefs,
129         boolean addCommunityPermissions, boolean addGuestPermissions,
130         com.liferay.portal.theme.ThemeDisplay themeDisplay)
131         throws com.liferay.portal.PortalException,
132             com.liferay.portal.SystemException;
133 
134     public com.liferay.portlet.messageboards.model.MBMessage addMessage(
135         long userId, java.lang.String userName, long categoryId,
136         java.lang.String subject, java.lang.String body,
137         java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
138         boolean anonymous, double priority, java.lang.String[] tagsEntries,
139         javax.portlet.PortletPreferences prefs,
140         java.lang.String[] communityPermissions,
141         java.lang.String[] guestPermissions,
142         com.liferay.portal.theme.ThemeDisplay themeDisplay)
143         throws com.liferay.portal.PortalException,
144             com.liferay.portal.SystemException;
145 
146     public com.liferay.portlet.messageboards.model.MBMessage addMessage(
147         long userId, java.lang.String userName, long categoryId,
148         java.lang.String subject, java.lang.String body,
149         java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
150         boolean anonymous, double priority, java.lang.String[] tagsEntries,
151         javax.portlet.PortletPreferences prefs,
152         java.lang.Boolean addCommunityPermissions,
153         java.lang.Boolean addGuestPermissions,
154         java.lang.String[] communityPermissions,
155         java.lang.String[] guestPermissions,
156         com.liferay.portal.theme.ThemeDisplay themeDisplay)
157         throws com.liferay.portal.PortalException,
158             com.liferay.portal.SystemException;
159 
160     public com.liferay.portlet.messageboards.model.MBMessage addMessage(
161         long userId, java.lang.String userName, long categoryId, long threadId,
162         long parentMessageId, java.lang.String subject, java.lang.String body,
163         java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
164         boolean anonymous, double priority, java.lang.String[] tagsEntries,
165         javax.portlet.PortletPreferences prefs,
166         boolean addCommunityPermissions, boolean addGuestPermissions,
167         com.liferay.portal.theme.ThemeDisplay themeDisplay)
168         throws com.liferay.portal.PortalException,
169             com.liferay.portal.SystemException;
170 
171     public com.liferay.portlet.messageboards.model.MBMessage addMessage(
172         long userId, java.lang.String userName, long categoryId, long threadId,
173         long parentMessageId, java.lang.String subject, java.lang.String body,
174         java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
175         boolean anonymous, double priority, java.lang.String[] tagsEntries,
176         javax.portlet.PortletPreferences prefs,
177         java.lang.String[] communityPermissions,
178         java.lang.String[] guestPermissions,
179         com.liferay.portal.theme.ThemeDisplay themeDisplay)
180         throws com.liferay.portal.PortalException,
181             com.liferay.portal.SystemException;
182 
183     public com.liferay.portlet.messageboards.model.MBMessage addMessage(
184         java.lang.String uuid, long userId, java.lang.String userName,
185         long categoryId, long threadId, long parentMessageId,
186         java.lang.String subject, java.lang.String body,
187         java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
188         boolean anonymous, double priority, java.lang.String[] tagsEntries,
189         javax.portlet.PortletPreferences prefs,
190         boolean addCommunityPermissions, boolean addGuestPermissions,
191         com.liferay.portal.theme.ThemeDisplay themeDisplay)
192         throws com.liferay.portal.PortalException,
193             com.liferay.portal.SystemException;
194 
195     public com.liferay.portlet.messageboards.model.MBMessage addMessage(
196         java.lang.String uuid, long userId, java.lang.String userName,
197         long categoryId, long threadId, long parentMessageId,
198         java.lang.String subject, java.lang.String body,
199         java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
200         boolean anonymous, double priority, java.lang.String[] tagsEntries,
201         javax.portlet.PortletPreferences prefs,
202         java.lang.Boolean addCommunityPermissions,
203         java.lang.Boolean addGuestPermissions,
204         java.lang.String[] communityPermissions,
205         java.lang.String[] guestPermissions,
206         com.liferay.portal.theme.ThemeDisplay themeDisplay)
207         throws com.liferay.portal.PortalException,
208             com.liferay.portal.SystemException;
209 
210     public void addMessageResources(long messageId,
211         boolean addCommunityPermissions, boolean addGuestPermissions)
212         throws com.liferay.portal.PortalException,
213             com.liferay.portal.SystemException;
214 
215     public void addMessageResources(
216         com.liferay.portlet.messageboards.model.MBMessage message,
217         boolean addCommunityPermissions, boolean addGuestPermissions)
218         throws com.liferay.portal.PortalException,
219             com.liferay.portal.SystemException;
220 
221     public void addMessageResources(long messageId,
222         java.lang.String[] communityPermissions,
223         java.lang.String[] guestPermissions)
224         throws com.liferay.portal.PortalException,
225             com.liferay.portal.SystemException;
226 
227     public void addMessageResources(
228         com.liferay.portlet.messageboards.model.MBMessage message,
229         java.lang.String[] communityPermissions,
230         java.lang.String[] guestPermissions)
231         throws com.liferay.portal.PortalException,
232             com.liferay.portal.SystemException;
233 
234     public void deleteDiscussionMessage(long messageId)
235         throws com.liferay.portal.PortalException,
236             com.liferay.portal.SystemException;
237 
238     public void deleteDiscussionMessages(java.lang.String className,
239         long classPK)
240         throws com.liferay.portal.PortalException,
241             com.liferay.portal.SystemException;
242 
243     public void deleteMessage(long messageId)
244         throws com.liferay.portal.PortalException,
245             com.liferay.portal.SystemException;
246 
247     public void deleteMessage(
248         com.liferay.portlet.messageboards.model.MBMessage message)
249         throws com.liferay.portal.PortalException,
250             com.liferay.portal.SystemException;
251 
252     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
253     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getCategoryMessages(
254         long categoryId, int start, int end)
255         throws com.liferay.portal.SystemException;
256 
257     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
258     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getCategoryMessages(
259         long categoryId, int start, int end,
260         com.liferay.portal.kernel.util.OrderByComparator obc)
261         throws com.liferay.portal.SystemException;
262 
263     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
264     public int getCategoryMessagesCount(long categoryId)
265         throws com.liferay.portal.SystemException;
266 
267     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
268     public int getCategoriesMessagesCount(java.util.List<Long> categoryIds)
269         throws com.liferay.portal.SystemException;
270 
271     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
272     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getCompanyMessages(
273         long companyId, int start, int end)
274         throws com.liferay.portal.SystemException;
275 
276     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
277     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getCompanyMessages(
278         long companyId, int start, int end,
279         com.liferay.portal.kernel.util.OrderByComparator obc)
280         throws com.liferay.portal.SystemException;
281 
282     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
283     public int getCompanyMessagesCount(long companyId)
284         throws com.liferay.portal.SystemException;
285 
286     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
287     public com.liferay.portlet.messageboards.model.MBMessageDisplay getDiscussionMessageDisplay(
288         long userId, java.lang.String className, long classPK)
289         throws com.liferay.portal.PortalException,
290             com.liferay.portal.SystemException;
291 
292     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
293     public com.liferay.portlet.messageboards.model.MBMessageDisplay getDiscussionMessageDisplay(
294         long userId, java.lang.String className, long classPK,
295         java.lang.String threadView)
296         throws com.liferay.portal.PortalException,
297             com.liferay.portal.SystemException;
298 
299     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
300     public int getDiscussionMessagesCount(long classNameId, long classPK)
301         throws com.liferay.portal.SystemException;
302 
303     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
304     public java.util.List<com.liferay.portlet.messageboards.model.MBDiscussion> getDiscussions(
305         java.lang.String className) throws com.liferay.portal.SystemException;
306 
307     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
308     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getGroupMessages(
309         long groupId, int start, int end)
310         throws com.liferay.portal.SystemException;
311 
312     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
313     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getGroupMessages(
314         long groupId, int start, int end,
315         com.liferay.portal.kernel.util.OrderByComparator obc)
316         throws com.liferay.portal.SystemException;
317 
318     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
319     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getGroupMessages(
320         long groupId, long userId, int start, int end)
321         throws com.liferay.portal.SystemException;
322 
323     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
324     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getGroupMessages(
325         long groupId, long userId, int start, int end,
326         com.liferay.portal.kernel.util.OrderByComparator obc)
327         throws com.liferay.portal.SystemException;
328 
329     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
330     public int getGroupMessagesCount(long groupId)
331         throws com.liferay.portal.SystemException;
332 
333     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
334     public int getGroupMessagesCount(long groupId, long userId)
335         throws com.liferay.portal.SystemException;
336 
337     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
338     public com.liferay.portlet.messageboards.model.MBMessage getMessage(
339         long messageId)
340         throws com.liferay.portal.PortalException,
341             com.liferay.portal.SystemException;
342 
343     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
344     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getMessages(
345         java.lang.String className, long classPK)
346         throws com.liferay.portal.SystemException;
347 
348     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
349     public com.liferay.portlet.messageboards.model.MBMessageDisplay getMessageDisplay(
350         long messageId)
351         throws com.liferay.portal.PortalException,
352             com.liferay.portal.SystemException;
353 
354     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
355     public com.liferay.portlet.messageboards.model.MBMessageDisplay getMessageDisplay(
356         long messageId, java.lang.String threadView)
357         throws com.liferay.portal.PortalException,
358             com.liferay.portal.SystemException;
359 
360     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
361     public com.liferay.portlet.messageboards.model.MBMessageDisplay getMessageDisplay(
362         com.liferay.portlet.messageboards.model.MBMessage message)
363         throws com.liferay.portal.PortalException,
364             com.liferay.portal.SystemException;
365 
366     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
367     public com.liferay.portlet.messageboards.model.MBMessageDisplay getMessageDisplay(
368         com.liferay.portlet.messageboards.model.MBMessage message,
369         java.lang.String threadView)
370         throws com.liferay.portal.PortalException,
371             com.liferay.portal.SystemException;
372 
373     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
374     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getNoAssetMessages()
375         throws com.liferay.portal.SystemException;
376 
377     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
378     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getThreadMessages(
379         long threadId) throws com.liferay.portal.SystemException;
380 
381     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
382     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getThreadMessages(
383         long threadId,
384         java.util.Comparator<com.liferay.portlet.messageboards.model.MBMessage> comparator)
385         throws com.liferay.portal.SystemException;
386 
387     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
388     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getThreadMessages(
389         long threadId, int start, int end)
390         throws com.liferay.portal.SystemException;
391 
392     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
393     public int getThreadMessagesCount(long threadId)
394         throws com.liferay.portal.SystemException;
395 
396     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
397     public java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getThreadRepliesMessages(
398         long threadId, int start, int end)
399         throws com.liferay.portal.SystemException;
400 
401     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
402     public void reIndex(long messageId)
403         throws com.liferay.portal.SystemException;
404 
405     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
406     public void reIndex(
407         com.liferay.portlet.messageboards.model.MBMessage message)
408         throws com.liferay.portal.SystemException;
409 
410     public void subscribeMessage(long userId, long messageId)
411         throws com.liferay.portal.PortalException,
412             com.liferay.portal.SystemException;
413 
414     public void unsubscribeMessage(long userId, long messageId)
415         throws com.liferay.portal.PortalException,
416             com.liferay.portal.SystemException;
417 
418     public com.liferay.portlet.messageboards.model.MBMessage updateDiscussionMessage(
419         long userId, long messageId, java.lang.String subject,
420         java.lang.String body)
421         throws com.liferay.portal.PortalException,
422             com.liferay.portal.SystemException;
423 
424     public com.liferay.portlet.messageboards.model.MBMessage updateMessage(
425         long userId, long messageId, java.lang.String subject,
426         java.lang.String body,
427         java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
428         java.util.List<String> existingFiles, double priority,
429         java.lang.String[] tagsEntries, javax.portlet.PortletPreferences prefs,
430         com.liferay.portal.theme.ThemeDisplay themeDisplay)
431         throws com.liferay.portal.PortalException,
432             com.liferay.portal.SystemException;
433 
434     public com.liferay.portlet.messageboards.model.MBMessage updateMessage(
435         long messageId, java.util.Date createDate, java.util.Date modifiedDate)
436         throws com.liferay.portal.PortalException,
437             com.liferay.portal.SystemException;
438 
439     public com.liferay.portlet.messageboards.model.MBMessage updateMessage(
440         long messageId, java.lang.String body)
441         throws com.liferay.portal.PortalException,
442             com.liferay.portal.SystemException;
443 
444     public void updateTagsAsset(long userId,
445         com.liferay.portlet.messageboards.model.MBMessage message,
446         java.lang.String[] tagsEntries)
447         throws com.liferay.portal.PortalException,
448             com.liferay.portal.SystemException;
449 }