001
014
015 package com.liferay.portlet.messageboards.service;
016
017 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018 import com.liferay.portal.kernel.util.MethodCache;
019 import com.liferay.portal.kernel.util.ReferenceRegistry;
020
021
034 public class MBCategoryLocalServiceUtil {
035
040
041
048 public static com.liferay.portlet.messageboards.model.MBCategory addMBCategory(
049 com.liferay.portlet.messageboards.model.MBCategory mbCategory)
050 throws com.liferay.portal.kernel.exception.SystemException {
051 return getService().addMBCategory(mbCategory);
052 }
053
054
060 public static com.liferay.portlet.messageboards.model.MBCategory createMBCategory(
061 long categoryId) {
062 return getService().createMBCategory(categoryId);
063 }
064
065
072 public static void deleteMBCategory(long categoryId)
073 throws com.liferay.portal.kernel.exception.PortalException,
074 com.liferay.portal.kernel.exception.SystemException {
075 getService().deleteMBCategory(categoryId);
076 }
077
078
084 public static void deleteMBCategory(
085 com.liferay.portlet.messageboards.model.MBCategory mbCategory)
086 throws com.liferay.portal.kernel.exception.SystemException {
087 getService().deleteMBCategory(mbCategory);
088 }
089
090
097 @SuppressWarnings("rawtypes")
098 public static java.util.List dynamicQuery(
099 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
100 throws com.liferay.portal.kernel.exception.SystemException {
101 return getService().dynamicQuery(dynamicQuery);
102 }
103
104
117 @SuppressWarnings("rawtypes")
118 public static java.util.List dynamicQuery(
119 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
120 int end) throws com.liferay.portal.kernel.exception.SystemException {
121 return getService().dynamicQuery(dynamicQuery, start, end);
122 }
123
124
138 @SuppressWarnings("rawtypes")
139 public static java.util.List dynamicQuery(
140 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
141 int end,
142 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
143 throws com.liferay.portal.kernel.exception.SystemException {
144 return getService()
145 .dynamicQuery(dynamicQuery, start, end, orderByComparator);
146 }
147
148
155 public static long dynamicQueryCount(
156 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
157 throws com.liferay.portal.kernel.exception.SystemException {
158 return getService().dynamicQueryCount(dynamicQuery);
159 }
160
161 public static com.liferay.portlet.messageboards.model.MBCategory fetchMBCategory(
162 long categoryId)
163 throws com.liferay.portal.kernel.exception.SystemException {
164 return getService().fetchMBCategory(categoryId);
165 }
166
167
175 public static com.liferay.portlet.messageboards.model.MBCategory getMBCategory(
176 long categoryId)
177 throws com.liferay.portal.kernel.exception.PortalException,
178 com.liferay.portal.kernel.exception.SystemException {
179 return getService().getMBCategory(categoryId);
180 }
181
182 public static com.liferay.portal.model.PersistedModel getPersistedModel(
183 java.io.Serializable primaryKeyObj)
184 throws com.liferay.portal.kernel.exception.PortalException,
185 com.liferay.portal.kernel.exception.SystemException {
186 return getService().getPersistedModel(primaryKeyObj);
187 }
188
189
198 public static com.liferay.portlet.messageboards.model.MBCategory getMBCategoryByUuidAndGroupId(
199 java.lang.String uuid, long groupId)
200 throws com.liferay.portal.kernel.exception.PortalException,
201 com.liferay.portal.kernel.exception.SystemException {
202 return getService().getMBCategoryByUuidAndGroupId(uuid, groupId);
203 }
204
205
217 public static java.util.List<com.liferay.portlet.messageboards.model.MBCategory> getMBCategories(
218 int start, int end)
219 throws com.liferay.portal.kernel.exception.SystemException {
220 return getService().getMBCategories(start, end);
221 }
222
223
229 public static int getMBCategoriesCount()
230 throws com.liferay.portal.kernel.exception.SystemException {
231 return getService().getMBCategoriesCount();
232 }
233
234
241 public static com.liferay.portlet.messageboards.model.MBCategory updateMBCategory(
242 com.liferay.portlet.messageboards.model.MBCategory mbCategory)
243 throws com.liferay.portal.kernel.exception.SystemException {
244 return getService().updateMBCategory(mbCategory);
245 }
246
247
255 public static com.liferay.portlet.messageboards.model.MBCategory updateMBCategory(
256 com.liferay.portlet.messageboards.model.MBCategory mbCategory,
257 boolean merge)
258 throws com.liferay.portal.kernel.exception.SystemException {
259 return getService().updateMBCategory(mbCategory, merge);
260 }
261
262
267 public static java.lang.String getBeanIdentifier() {
268 return getService().getBeanIdentifier();
269 }
270
271
276 public static void setBeanIdentifier(java.lang.String beanIdentifier) {
277 getService().setBeanIdentifier(beanIdentifier);
278 }
279
280 public static com.liferay.portlet.messageboards.model.MBCategory addCategory(
281 long userId, long parentCategoryId, java.lang.String name,
282 java.lang.String description, java.lang.String displayStyle,
283 java.lang.String emailAddress, java.lang.String inProtocol,
284 java.lang.String inServerName, int inServerPort, boolean inUseSSL,
285 java.lang.String inUserName, java.lang.String inPassword,
286 int inReadInterval, java.lang.String outEmailAddress,
287 boolean outCustom, java.lang.String outServerName, int outServerPort,
288 boolean outUseSSL, java.lang.String outUserName,
289 java.lang.String outPassword, boolean allowAnonymous,
290 boolean mailingListActive,
291 com.liferay.portal.service.ServiceContext serviceContext)
292 throws com.liferay.portal.kernel.exception.PortalException,
293 com.liferay.portal.kernel.exception.SystemException {
294 return getService()
295 .addCategory(userId, parentCategoryId, name, description,
296 displayStyle, emailAddress, inProtocol, inServerName, inServerPort,
297 inUseSSL, inUserName, inPassword, inReadInterval, outEmailAddress,
298 outCustom, outServerName, outServerPort, outUseSSL, outUserName,
299 outPassword, allowAnonymous, mailingListActive, serviceContext);
300 }
301
302 public static void addCategoryResources(long categoryId,
303 boolean addGroupPermissions, boolean addGuestPermissions)
304 throws com.liferay.portal.kernel.exception.PortalException,
305 com.liferay.portal.kernel.exception.SystemException {
306 getService()
307 .addCategoryResources(categoryId, addGroupPermissions,
308 addGuestPermissions);
309 }
310
311 public static void addCategoryResources(long categoryId,
312 java.lang.String[] groupPermissions, java.lang.String[] guestPermissions)
313 throws com.liferay.portal.kernel.exception.PortalException,
314 com.liferay.portal.kernel.exception.SystemException {
315 getService()
316 .addCategoryResources(categoryId, groupPermissions, guestPermissions);
317 }
318
319 public static void addCategoryResources(
320 com.liferay.portlet.messageboards.model.MBCategory category,
321 boolean addGroupPermissions, boolean addGuestPermissions)
322 throws com.liferay.portal.kernel.exception.PortalException,
323 com.liferay.portal.kernel.exception.SystemException {
324 getService()
325 .addCategoryResources(category, addGroupPermissions,
326 addGuestPermissions);
327 }
328
329 public static void addCategoryResources(
330 com.liferay.portlet.messageboards.model.MBCategory category,
331 java.lang.String[] groupPermissions, java.lang.String[] guestPermissions)
332 throws com.liferay.portal.kernel.exception.PortalException,
333 com.liferay.portal.kernel.exception.SystemException {
334 getService()
335 .addCategoryResources(category, groupPermissions, guestPermissions);
336 }
337
338 public static void deleteCategories(long groupId)
339 throws com.liferay.portal.kernel.exception.PortalException,
340 com.liferay.portal.kernel.exception.SystemException {
341 getService().deleteCategories(groupId);
342 }
343
344 public static void deleteCategory(long categoryId)
345 throws com.liferay.portal.kernel.exception.PortalException,
346 com.liferay.portal.kernel.exception.SystemException {
347 getService().deleteCategory(categoryId);
348 }
349
350 public static void deleteCategory(
351 com.liferay.portlet.messageboards.model.MBCategory category)
352 throws com.liferay.portal.kernel.exception.PortalException,
353 com.liferay.portal.kernel.exception.SystemException {
354 getService().deleteCategory(category);
355 }
356
357 public static java.util.List<com.liferay.portlet.messageboards.model.MBCategory> getCategories(
358 long groupId)
359 throws com.liferay.portal.kernel.exception.SystemException {
360 return getService().getCategories(groupId);
361 }
362
363 public static java.util.List<com.liferay.portlet.messageboards.model.MBCategory> getCategories(
364 long groupId, long parentCategoryId, int start, int end)
365 throws com.liferay.portal.kernel.exception.SystemException {
366 return getService().getCategories(groupId, parentCategoryId, start, end);
367 }
368
369 public static java.util.List<com.liferay.portlet.messageboards.model.MBCategory> getCategories(
370 long groupId, long[] parentCategoryIds, int start, int end)
371 throws com.liferay.portal.kernel.exception.SystemException {
372 return getService().getCategories(groupId, parentCategoryIds, start, end);
373 }
374
375 public static int getCategoriesCount(long groupId)
376 throws com.liferay.portal.kernel.exception.SystemException {
377 return getService().getCategoriesCount(groupId);
378 }
379
380 public static int getCategoriesCount(long groupId, long parentCategoryId)
381 throws com.liferay.portal.kernel.exception.SystemException {
382 return getService().getCategoriesCount(groupId, parentCategoryId);
383 }
384
385 public static int getCategoriesCount(long groupId, long[] parentCategoryIds)
386 throws com.liferay.portal.kernel.exception.SystemException {
387 return getService().getCategoriesCount(groupId, parentCategoryIds);
388 }
389
390 public static com.liferay.portlet.messageboards.model.MBCategory getCategory(
391 long categoryId)
392 throws com.liferay.portal.kernel.exception.PortalException,
393 com.liferay.portal.kernel.exception.SystemException {
394 return getService().getCategory(categoryId);
395 }
396
397 public static java.util.List<com.liferay.portlet.messageboards.model.MBCategory> getCompanyCategories(
398 long companyId, int start, int end)
399 throws com.liferay.portal.kernel.exception.SystemException {
400 return getService().getCompanyCategories(companyId, start, end);
401 }
402
403 public static int getCompanyCategoriesCount(long companyId)
404 throws com.liferay.portal.kernel.exception.SystemException {
405 return getService().getCompanyCategoriesCount(companyId);
406 }
407
408 public static java.util.List<java.lang.Long> getSubcategoryIds(
409 java.util.List<java.lang.Long> categoryIds, long groupId,
410 long categoryId)
411 throws com.liferay.portal.kernel.exception.SystemException {
412 return getService().getSubcategoryIds(categoryIds, groupId, categoryId);
413 }
414
415 public static java.util.List<com.liferay.portlet.messageboards.model.MBCategory> getSubscribedCategories(
416 long groupId, long userId, int start, int end)
417 throws com.liferay.portal.kernel.exception.SystemException {
418 return getService().getSubscribedCategories(groupId, userId, start, end);
419 }
420
421 public static int getSubscribedCategoriesCount(long groupId, long userId)
422 throws com.liferay.portal.kernel.exception.SystemException {
423 return getService().getSubscribedCategoriesCount(groupId, userId);
424 }
425
426 public static void subscribeCategory(long userId, long groupId,
427 long categoryId)
428 throws com.liferay.portal.kernel.exception.PortalException,
429 com.liferay.portal.kernel.exception.SystemException {
430 getService().subscribeCategory(userId, groupId, categoryId);
431 }
432
433 public static void unsubscribeCategory(long userId, long groupId,
434 long categoryId)
435 throws com.liferay.portal.kernel.exception.PortalException,
436 com.liferay.portal.kernel.exception.SystemException {
437 getService().unsubscribeCategory(userId, groupId, categoryId);
438 }
439
440 public static com.liferay.portlet.messageboards.model.MBCategory updateCategory(
441 long categoryId, long parentCategoryId, java.lang.String name,
442 java.lang.String description, java.lang.String displayStyle,
443 java.lang.String emailAddress, java.lang.String inProtocol,
444 java.lang.String inServerName, int inServerPort, boolean inUseSSL,
445 java.lang.String inUserName, java.lang.String inPassword,
446 int inReadInterval, java.lang.String outEmailAddress,
447 boolean outCustom, java.lang.String outServerName, int outServerPort,
448 boolean outUseSSL, java.lang.String outUserName,
449 java.lang.String outPassword, boolean allowAnonymous,
450 boolean mailingListActive, boolean mergeWithParentCategory,
451 com.liferay.portal.service.ServiceContext serviceContext)
452 throws com.liferay.portal.kernel.exception.PortalException,
453 com.liferay.portal.kernel.exception.SystemException {
454 return getService()
455 .updateCategory(categoryId, parentCategoryId, name,
456 description, displayStyle, emailAddress, inProtocol, inServerName,
457 inServerPort, inUseSSL, inUserName, inPassword, inReadInterval,
458 outEmailAddress, outCustom, outServerName, outServerPort,
459 outUseSSL, outUserName, outPassword, allowAnonymous,
460 mailingListActive, mergeWithParentCategory, serviceContext);
461 }
462
463 public static MBCategoryLocalService getService() {
464 if (_service == null) {
465 _service = (MBCategoryLocalService)PortalBeanLocatorUtil.locate(MBCategoryLocalService.class.getName());
466
467 ReferenceRegistry.registerReference(MBCategoryLocalServiceUtil.class,
468 "_service");
469 MethodCache.remove(MBCategoryLocalService.class);
470 }
471
472 return _service;
473 }
474
475 public void setService(MBCategoryLocalService service) {
476 MethodCache.remove(MBCategoryLocalService.class);
477
478 _service = service;
479
480 ReferenceRegistry.registerReference(MBCategoryLocalServiceUtil.class,
481 "_service");
482 MethodCache.remove(MBCategoryLocalService.class);
483 }
484
485 private static MBCategoryLocalService _service;
486 }