1
19
20 package com.liferay.portlet.messageboards.service;
21
22
23
44 public class MBMessageLocalServiceUtil {
45 public static com.liferay.portlet.messageboards.model.MBMessage addMBMessage(
46 com.liferay.portlet.messageboards.model.MBMessage mbMessage)
47 throws com.liferay.portal.SystemException {
48 return getService().addMBMessage(mbMessage);
49 }
50
51 public static com.liferay.portlet.messageboards.model.MBMessage createMBMessage(
52 long messageId) {
53 return getService().createMBMessage(messageId);
54 }
55
56 public static void deleteMBMessage(long messageId)
57 throws com.liferay.portal.PortalException,
58 com.liferay.portal.SystemException {
59 getService().deleteMBMessage(messageId);
60 }
61
62 public static void deleteMBMessage(
63 com.liferay.portlet.messageboards.model.MBMessage mbMessage)
64 throws com.liferay.portal.SystemException {
65 getService().deleteMBMessage(mbMessage);
66 }
67
68 public static java.util.List<Object> dynamicQuery(
69 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
70 throws com.liferay.portal.SystemException {
71 return getService().dynamicQuery(dynamicQuery);
72 }
73
74 public static java.util.List<Object> dynamicQuery(
75 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
76 int end) throws com.liferay.portal.SystemException {
77 return getService().dynamicQuery(dynamicQuery, start, end);
78 }
79
80 public static com.liferay.portlet.messageboards.model.MBMessage getMBMessage(
81 long messageId)
82 throws com.liferay.portal.PortalException,
83 com.liferay.portal.SystemException {
84 return getService().getMBMessage(messageId);
85 }
86
87 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getMBMessages(
88 int start, int end) throws com.liferay.portal.SystemException {
89 return getService().getMBMessages(start, end);
90 }
91
92 public static int getMBMessagesCount()
93 throws com.liferay.portal.SystemException {
94 return getService().getMBMessagesCount();
95 }
96
97 public static com.liferay.portlet.messageboards.model.MBMessage updateMBMessage(
98 com.liferay.portlet.messageboards.model.MBMessage mbMessage)
99 throws com.liferay.portal.SystemException {
100 return getService().updateMBMessage(mbMessage);
101 }
102
103 public static com.liferay.portlet.messageboards.model.MBMessage updateMBMessage(
104 com.liferay.portlet.messageboards.model.MBMessage mbMessage,
105 boolean merge) throws com.liferay.portal.SystemException {
106 return getService().updateMBMessage(mbMessage, merge);
107 }
108
109 public static com.liferay.portlet.messageboards.model.MBMessage addDiscussionMessage(
110 long userId, java.lang.String userName, java.lang.String className,
111 long classPK)
112 throws com.liferay.portal.PortalException,
113 com.liferay.portal.SystemException {
114 return getService()
115 .addDiscussionMessage(userId, userName, className, classPK);
116 }
117
118 public static com.liferay.portlet.messageboards.model.MBMessage addDiscussionMessage(
119 long userId, java.lang.String userName, long groupId,
120 java.lang.String className, long classPK, long threadId,
121 long parentMessageId, java.lang.String subject, java.lang.String body)
122 throws com.liferay.portal.PortalException,
123 com.liferay.portal.SystemException {
124 return getService()
125 .addDiscussionMessage(userId, userName, groupId, className,
126 classPK, threadId, parentMessageId, subject, body);
127 }
128
129 public static com.liferay.portlet.messageboards.model.MBMessage addDiscussionMessage(
130 long userId, java.lang.String userName, long groupId,
131 java.lang.String className, long classPK, long threadId,
132 long parentMessageId, java.lang.String subject, java.lang.String body,
133 com.liferay.portal.theme.ThemeDisplay themeDisplay)
134 throws com.liferay.portal.PortalException,
135 com.liferay.portal.SystemException {
136 return getService()
137 .addDiscussionMessage(userId, userName, groupId, className,
138 classPK, threadId, parentMessageId, subject, body, themeDisplay);
139 }
140
141 public static com.liferay.portlet.messageboards.model.MBMessage addMessage(
142 long userId, java.lang.String userName, long categoryId,
143 java.lang.String subject, java.lang.String body,
144 java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
145 boolean anonymous, double priority, java.lang.String[] tagsEntries,
146 javax.portlet.PortletPreferences prefs,
147 boolean addCommunityPermissions, boolean addGuestPermissions,
148 com.liferay.portal.theme.ThemeDisplay themeDisplay)
149 throws com.liferay.portal.PortalException,
150 com.liferay.portal.SystemException {
151 return getService()
152 .addMessage(userId, userName, categoryId, subject, body,
153 files, anonymous, priority, tagsEntries, prefs,
154 addCommunityPermissions, addGuestPermissions, themeDisplay);
155 }
156
157 public static com.liferay.portlet.messageboards.model.MBMessage addMessage(
158 long userId, java.lang.String userName, long categoryId,
159 java.lang.String subject, java.lang.String body,
160 java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
161 boolean anonymous, double priority, java.lang.String[] tagsEntries,
162 javax.portlet.PortletPreferences prefs,
163 java.lang.String[] communityPermissions,
164 java.lang.String[] guestPermissions,
165 com.liferay.portal.theme.ThemeDisplay themeDisplay)
166 throws com.liferay.portal.PortalException,
167 com.liferay.portal.SystemException {
168 return getService()
169 .addMessage(userId, userName, categoryId, subject, body,
170 files, anonymous, priority, tagsEntries, prefs,
171 communityPermissions, guestPermissions, themeDisplay);
172 }
173
174 public static com.liferay.portlet.messageboards.model.MBMessage addMessage(
175 long userId, java.lang.String userName, long categoryId,
176 java.lang.String subject, java.lang.String body,
177 java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
178 boolean anonymous, double priority, java.lang.String[] tagsEntries,
179 javax.portlet.PortletPreferences prefs,
180 java.lang.Boolean addCommunityPermissions,
181 java.lang.Boolean addGuestPermissions,
182 java.lang.String[] communityPermissions,
183 java.lang.String[] guestPermissions,
184 com.liferay.portal.theme.ThemeDisplay themeDisplay)
185 throws com.liferay.portal.PortalException,
186 com.liferay.portal.SystemException {
187 return getService()
188 .addMessage(userId, userName, categoryId, subject, body,
189 files, anonymous, priority, tagsEntries, prefs,
190 addCommunityPermissions, addGuestPermissions, communityPermissions,
191 guestPermissions, themeDisplay);
192 }
193
194 public static com.liferay.portlet.messageboards.model.MBMessage addMessage(
195 long userId, java.lang.String userName, long categoryId, long threadId,
196 long parentMessageId, java.lang.String subject, java.lang.String body,
197 java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
198 boolean anonymous, double priority, java.lang.String[] tagsEntries,
199 javax.portlet.PortletPreferences prefs,
200 boolean addCommunityPermissions, boolean addGuestPermissions,
201 com.liferay.portal.theme.ThemeDisplay themeDisplay)
202 throws com.liferay.portal.PortalException,
203 com.liferay.portal.SystemException {
204 return getService()
205 .addMessage(userId, userName, categoryId, threadId,
206 parentMessageId, subject, body, files, anonymous, priority,
207 tagsEntries, prefs, addCommunityPermissions, addGuestPermissions,
208 themeDisplay);
209 }
210
211 public static com.liferay.portlet.messageboards.model.MBMessage addMessage(
212 long userId, java.lang.String userName, long categoryId, long threadId,
213 long parentMessageId, java.lang.String subject, java.lang.String body,
214 java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
215 boolean anonymous, double priority, java.lang.String[] tagsEntries,
216 javax.portlet.PortletPreferences prefs,
217 java.lang.String[] communityPermissions,
218 java.lang.String[] guestPermissions,
219 com.liferay.portal.theme.ThemeDisplay themeDisplay)
220 throws com.liferay.portal.PortalException,
221 com.liferay.portal.SystemException {
222 return getService()
223 .addMessage(userId, userName, categoryId, threadId,
224 parentMessageId, subject, body, files, anonymous, priority,
225 tagsEntries, prefs, communityPermissions, guestPermissions,
226 themeDisplay);
227 }
228
229 public static com.liferay.portlet.messageboards.model.MBMessage addMessage(
230 java.lang.String uuid, long userId, java.lang.String userName,
231 long categoryId, long threadId, long parentMessageId,
232 java.lang.String subject, java.lang.String body,
233 java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
234 boolean anonymous, double priority, java.lang.String[] tagsEntries,
235 javax.portlet.PortletPreferences prefs,
236 boolean addCommunityPermissions, boolean addGuestPermissions,
237 com.liferay.portal.theme.ThemeDisplay themeDisplay)
238 throws com.liferay.portal.PortalException,
239 com.liferay.portal.SystemException {
240 return getService()
241 .addMessage(uuid, userId, userName, categoryId, threadId,
242 parentMessageId, subject, body, files, anonymous, priority,
243 tagsEntries, prefs, addCommunityPermissions, addGuestPermissions,
244 themeDisplay);
245 }
246
247 public static com.liferay.portlet.messageboards.model.MBMessage addMessage(
248 java.lang.String uuid, long userId, java.lang.String userName,
249 long categoryId, long threadId, long parentMessageId,
250 java.lang.String subject, java.lang.String body,
251 java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
252 boolean anonymous, double priority, java.lang.String[] tagsEntries,
253 javax.portlet.PortletPreferences prefs,
254 java.lang.Boolean addCommunityPermissions,
255 java.lang.Boolean addGuestPermissions,
256 java.lang.String[] communityPermissions,
257 java.lang.String[] guestPermissions,
258 com.liferay.portal.theme.ThemeDisplay themeDisplay)
259 throws com.liferay.portal.PortalException,
260 com.liferay.portal.SystemException {
261 return getService()
262 .addMessage(uuid, userId, userName, categoryId, threadId,
263 parentMessageId, subject, body, files, anonymous, priority,
264 tagsEntries, prefs, addCommunityPermissions, addGuestPermissions,
265 communityPermissions, guestPermissions, themeDisplay);
266 }
267
268 public static void addMessageResources(long messageId,
269 boolean addCommunityPermissions, boolean addGuestPermissions)
270 throws com.liferay.portal.PortalException,
271 com.liferay.portal.SystemException {
272 getService()
273 .addMessageResources(messageId, addCommunityPermissions,
274 addGuestPermissions);
275 }
276
277 public static void addMessageResources(
278 com.liferay.portlet.messageboards.model.MBMessage message,
279 boolean addCommunityPermissions, boolean addGuestPermissions)
280 throws com.liferay.portal.PortalException,
281 com.liferay.portal.SystemException {
282 getService()
283 .addMessageResources(message, addCommunityPermissions,
284 addGuestPermissions);
285 }
286
287 public static void addMessageResources(long messageId,
288 java.lang.String[] communityPermissions,
289 java.lang.String[] guestPermissions)
290 throws com.liferay.portal.PortalException,
291 com.liferay.portal.SystemException {
292 getService()
293 .addMessageResources(messageId, communityPermissions,
294 guestPermissions);
295 }
296
297 public static void addMessageResources(
298 com.liferay.portlet.messageboards.model.MBMessage message,
299 java.lang.String[] communityPermissions,
300 java.lang.String[] guestPermissions)
301 throws com.liferay.portal.PortalException,
302 com.liferay.portal.SystemException {
303 getService()
304 .addMessageResources(message, communityPermissions, guestPermissions);
305 }
306
307 public static void deleteDiscussionMessage(long messageId)
308 throws com.liferay.portal.PortalException,
309 com.liferay.portal.SystemException {
310 getService().deleteDiscussionMessage(messageId);
311 }
312
313 public static void deleteDiscussionMessages(java.lang.String className,
314 long classPK)
315 throws com.liferay.portal.PortalException,
316 com.liferay.portal.SystemException {
317 getService().deleteDiscussionMessages(className, classPK);
318 }
319
320 public static void deleteMessage(long messageId)
321 throws com.liferay.portal.PortalException,
322 com.liferay.portal.SystemException {
323 getService().deleteMessage(messageId);
324 }
325
326 public static void deleteMessage(
327 com.liferay.portlet.messageboards.model.MBMessage message)
328 throws com.liferay.portal.PortalException,
329 com.liferay.portal.SystemException {
330 getService().deleteMessage(message);
331 }
332
333 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getCategoryMessages(
334 long categoryId, int start, int end)
335 throws com.liferay.portal.SystemException {
336 return getService().getCategoryMessages(categoryId, start, end);
337 }
338
339 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getCategoryMessages(
340 long categoryId, int start, int end,
341 com.liferay.portal.kernel.util.OrderByComparator obc)
342 throws com.liferay.portal.SystemException {
343 return getService().getCategoryMessages(categoryId, start, end, obc);
344 }
345
346 public static int getCategoryMessagesCount(long categoryId)
347 throws com.liferay.portal.SystemException {
348 return getService().getCategoryMessagesCount(categoryId);
349 }
350
351 public static int getCategoriesMessagesCount(
352 java.util.List<Long> categoryIds)
353 throws com.liferay.portal.SystemException {
354 return getService().getCategoriesMessagesCount(categoryIds);
355 }
356
357 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getCompanyMessages(
358 long companyId, int start, int end)
359 throws com.liferay.portal.SystemException {
360 return getService().getCompanyMessages(companyId, start, end);
361 }
362
363 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getCompanyMessages(
364 long companyId, int start, int end,
365 com.liferay.portal.kernel.util.OrderByComparator obc)
366 throws com.liferay.portal.SystemException {
367 return getService().getCompanyMessages(companyId, start, end, obc);
368 }
369
370 public static int getCompanyMessagesCount(long companyId)
371 throws com.liferay.portal.SystemException {
372 return getService().getCompanyMessagesCount(companyId);
373 }
374
375 public static com.liferay.portlet.messageboards.model.MBMessageDisplay getDiscussionMessageDisplay(
376 long userId, java.lang.String className, long classPK)
377 throws com.liferay.portal.PortalException,
378 com.liferay.portal.SystemException {
379 return getService()
380 .getDiscussionMessageDisplay(userId, className, classPK);
381 }
382
383 public static com.liferay.portlet.messageboards.model.MBMessageDisplay getDiscussionMessageDisplay(
384 long userId, java.lang.String className, long classPK,
385 java.lang.String threadView)
386 throws com.liferay.portal.PortalException,
387 com.liferay.portal.SystemException {
388 return getService()
389 .getDiscussionMessageDisplay(userId, className, classPK,
390 threadView);
391 }
392
393 public static int getDiscussionMessagesCount(long classNameId, long classPK)
394 throws com.liferay.portal.SystemException {
395 return getService().getDiscussionMessagesCount(classNameId, classPK);
396 }
397
398 public static java.util.List<com.liferay.portlet.messageboards.model.MBDiscussion> getDiscussions(
399 java.lang.String className) throws com.liferay.portal.SystemException {
400 return getService().getDiscussions(className);
401 }
402
403 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getGroupMessages(
404 long groupId, int start, int end)
405 throws com.liferay.portal.SystemException {
406 return getService().getGroupMessages(groupId, start, end);
407 }
408
409 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getGroupMessages(
410 long groupId, int start, int end,
411 com.liferay.portal.kernel.util.OrderByComparator obc)
412 throws com.liferay.portal.SystemException {
413 return getService().getGroupMessages(groupId, start, end, obc);
414 }
415
416 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getGroupMessages(
417 long groupId, long userId, int start, int end)
418 throws com.liferay.portal.SystemException {
419 return getService().getGroupMessages(groupId, userId, start, end);
420 }
421
422 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getGroupMessages(
423 long groupId, long userId, int start, int end,
424 com.liferay.portal.kernel.util.OrderByComparator obc)
425 throws com.liferay.portal.SystemException {
426 return getService().getGroupMessages(groupId, userId, start, end, obc);
427 }
428
429 public static int getGroupMessagesCount(long groupId)
430 throws com.liferay.portal.SystemException {
431 return getService().getGroupMessagesCount(groupId);
432 }
433
434 public static int getGroupMessagesCount(long groupId, long userId)
435 throws com.liferay.portal.SystemException {
436 return getService().getGroupMessagesCount(groupId, userId);
437 }
438
439 public static com.liferay.portlet.messageboards.model.MBMessage getMessage(
440 long messageId)
441 throws com.liferay.portal.PortalException,
442 com.liferay.portal.SystemException {
443 return getService().getMessage(messageId);
444 }
445
446 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getMessages(
447 java.lang.String className, long classPK)
448 throws com.liferay.portal.SystemException {
449 return getService().getMessages(className, classPK);
450 }
451
452 public static com.liferay.portlet.messageboards.model.MBMessageDisplay getMessageDisplay(
453 long messageId)
454 throws com.liferay.portal.PortalException,
455 com.liferay.portal.SystemException {
456 return getService().getMessageDisplay(messageId);
457 }
458
459 public static com.liferay.portlet.messageboards.model.MBMessageDisplay getMessageDisplay(
460 long messageId, java.lang.String threadView)
461 throws com.liferay.portal.PortalException,
462 com.liferay.portal.SystemException {
463 return getService().getMessageDisplay(messageId, threadView);
464 }
465
466 public static com.liferay.portlet.messageboards.model.MBMessageDisplay getMessageDisplay(
467 com.liferay.portlet.messageboards.model.MBMessage message)
468 throws com.liferay.portal.PortalException,
469 com.liferay.portal.SystemException {
470 return getService().getMessageDisplay(message);
471 }
472
473 public static com.liferay.portlet.messageboards.model.MBMessageDisplay getMessageDisplay(
474 com.liferay.portlet.messageboards.model.MBMessage message,
475 java.lang.String threadView)
476 throws com.liferay.portal.PortalException,
477 com.liferay.portal.SystemException {
478 return getService().getMessageDisplay(message, threadView);
479 }
480
481 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getNoAssetMessages()
482 throws com.liferay.portal.SystemException {
483 return getService().getNoAssetMessages();
484 }
485
486 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getThreadMessages(
487 long threadId) throws com.liferay.portal.SystemException {
488 return getService().getThreadMessages(threadId);
489 }
490
491 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getThreadMessages(
492 long threadId,
493 java.util.Comparator<com.liferay.portlet.messageboards.model.MBMessage> comparator)
494 throws com.liferay.portal.SystemException {
495 return getService().getThreadMessages(threadId, comparator);
496 }
497
498 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getThreadMessages(
499 long threadId, int start, int end)
500 throws com.liferay.portal.SystemException {
501 return getService().getThreadMessages(threadId, start, end);
502 }
503
504 public static int getThreadMessagesCount(long threadId)
505 throws com.liferay.portal.SystemException {
506 return getService().getThreadMessagesCount(threadId);
507 }
508
509 public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getThreadRepliesMessages(
510 long threadId, int start, int end)
511 throws com.liferay.portal.SystemException {
512 return getService().getThreadRepliesMessages(threadId, start, end);
513 }
514
515 public static void reIndex(long messageId)
516 throws com.liferay.portal.SystemException {
517 getService().reIndex(messageId);
518 }
519
520 public static void reIndex(
521 com.liferay.portlet.messageboards.model.MBMessage message)
522 throws com.liferay.portal.SystemException {
523 getService().reIndex(message);
524 }
525
526 public static void subscribeMessage(long userId, long messageId)
527 throws com.liferay.portal.PortalException,
528 com.liferay.portal.SystemException {
529 getService().subscribeMessage(userId, messageId);
530 }
531
532 public static void unsubscribeMessage(long userId, long messageId)
533 throws com.liferay.portal.PortalException,
534 com.liferay.portal.SystemException {
535 getService().unsubscribeMessage(userId, messageId);
536 }
537
538 public static com.liferay.portlet.messageboards.model.MBMessage updateDiscussionMessage(
539 long userId, long messageId, java.lang.String subject,
540 java.lang.String body)
541 throws com.liferay.portal.PortalException,
542 com.liferay.portal.SystemException {
543 return getService()
544 .updateDiscussionMessage(userId, messageId, subject, body);
545 }
546
547 public static com.liferay.portlet.messageboards.model.MBMessage updateMessage(
548 long userId, long messageId, java.lang.String subject,
549 java.lang.String body,
550 java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files,
551 java.util.List<String> existingFiles, double priority,
552 java.lang.String[] tagsEntries, javax.portlet.PortletPreferences prefs,
553 com.liferay.portal.theme.ThemeDisplay themeDisplay)
554 throws com.liferay.portal.PortalException,
555 com.liferay.portal.SystemException {
556 return getService()
557 .updateMessage(userId, messageId, subject, body, files,
558 existingFiles, priority, tagsEntries, prefs, themeDisplay);
559 }
560
561 public static com.liferay.portlet.messageboards.model.MBMessage updateMessage(
562 long messageId, java.util.Date createDate, java.util.Date modifiedDate)
563 throws com.liferay.portal.PortalException,
564 com.liferay.portal.SystemException {
565 return getService().updateMessage(messageId, createDate, modifiedDate);
566 }
567
568 public static com.liferay.portlet.messageboards.model.MBMessage updateMessage(
569 long messageId, java.lang.String body)
570 throws com.liferay.portal.PortalException,
571 com.liferay.portal.SystemException {
572 return getService().updateMessage(messageId, body);
573 }
574
575 public static void updateTagsAsset(long userId,
576 com.liferay.portlet.messageboards.model.MBMessage message,
577 java.lang.String[] tagsEntries)
578 throws com.liferay.portal.PortalException,
579 com.liferay.portal.SystemException {
580 getService().updateTagsAsset(userId, message, tagsEntries);
581 }
582
583 public static MBMessageLocalService getService() {
584 if (_service == null) {
585 throw new RuntimeException("MBMessageLocalService is not set");
586 }
587
588 return _service;
589 }
590
591 public void setService(MBMessageLocalService service) {
592 _service = service;
593 }
594
595 private static MBMessageLocalService _service;
596 }