1
14
15 package com.liferay.portlet.messageboards.service;
16
17 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
18
19
39 public class MBCategoryLocalServiceUtil {
40 public static com.liferay.portlet.messageboards.model.MBCategory addMBCategory(
41 com.liferay.portlet.messageboards.model.MBCategory mbCategory)
42 throws com.liferay.portal.SystemException {
43 return getService().addMBCategory(mbCategory);
44 }
45
46 public static com.liferay.portlet.messageboards.model.MBCategory createMBCategory(
47 long categoryId) {
48 return getService().createMBCategory(categoryId);
49 }
50
51 public static void deleteMBCategory(long categoryId)
52 throws com.liferay.portal.PortalException,
53 com.liferay.portal.SystemException {
54 getService().deleteMBCategory(categoryId);
55 }
56
57 public static void deleteMBCategory(
58 com.liferay.portlet.messageboards.model.MBCategory mbCategory)
59 throws com.liferay.portal.SystemException {
60 getService().deleteMBCategory(mbCategory);
61 }
62
63 public static java.util.List<Object> dynamicQuery(
64 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
65 throws com.liferay.portal.SystemException {
66 return getService().dynamicQuery(dynamicQuery);
67 }
68
69 public static java.util.List<Object> dynamicQuery(
70 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
71 int end) throws com.liferay.portal.SystemException {
72 return getService().dynamicQuery(dynamicQuery, start, end);
73 }
74
75 public static com.liferay.portlet.messageboards.model.MBCategory getMBCategory(
76 long categoryId)
77 throws com.liferay.portal.PortalException,
78 com.liferay.portal.SystemException {
79 return getService().getMBCategory(categoryId);
80 }
81
82 public static java.util.List<com.liferay.portlet.messageboards.model.MBCategory> getMBCategories(
83 int start, int end) throws com.liferay.portal.SystemException {
84 return getService().getMBCategories(start, end);
85 }
86
87 public static int getMBCategoriesCount()
88 throws com.liferay.portal.SystemException {
89 return getService().getMBCategoriesCount();
90 }
91
92 public static com.liferay.portlet.messageboards.model.MBCategory updateMBCategory(
93 com.liferay.portlet.messageboards.model.MBCategory mbCategory)
94 throws com.liferay.portal.SystemException {
95 return getService().updateMBCategory(mbCategory);
96 }
97
98 public static com.liferay.portlet.messageboards.model.MBCategory updateMBCategory(
99 com.liferay.portlet.messageboards.model.MBCategory mbCategory,
100 boolean merge) throws com.liferay.portal.SystemException {
101 return getService().updateMBCategory(mbCategory, merge);
102 }
103
104 public static com.liferay.portlet.messageboards.model.MBCategory addCategory(
105 long userId, long plid, long parentCategoryId, java.lang.String name,
106 java.lang.String description, boolean addCommunityPermissions,
107 boolean addGuestPermissions)
108 throws com.liferay.portal.PortalException,
109 com.liferay.portal.SystemException {
110 return getService()
111 .addCategory(userId, plid, parentCategoryId, name,
112 description, addCommunityPermissions, addGuestPermissions);
113 }
114
115 public static com.liferay.portlet.messageboards.model.MBCategory addCategory(
116 long userId, long plid, long parentCategoryId, java.lang.String name,
117 java.lang.String description, java.lang.String[] communityPermissions,
118 java.lang.String[] guestPermissions)
119 throws com.liferay.portal.PortalException,
120 com.liferay.portal.SystemException {
121 return getService()
122 .addCategory(userId, plid, parentCategoryId, name,
123 description, communityPermissions, guestPermissions);
124 }
125
126 public static com.liferay.portlet.messageboards.model.MBCategory addCategory(
127 java.lang.String uuid, long userId, long plid, long parentCategoryId,
128 java.lang.String name, java.lang.String description,
129 boolean addCommunityPermissions, boolean addGuestPermissions)
130 throws com.liferay.portal.PortalException,
131 com.liferay.portal.SystemException {
132 return getService()
133 .addCategory(uuid, userId, plid, parentCategoryId, name,
134 description, addCommunityPermissions, addGuestPermissions);
135 }
136
137 public static com.liferay.portlet.messageboards.model.MBCategory addCategory(
138 java.lang.String uuid, long userId, long plid, long parentCategoryId,
139 java.lang.String name, java.lang.String description,
140 java.lang.Boolean addCommunityPermissions,
141 java.lang.Boolean addGuestPermissions,
142 java.lang.String[] communityPermissions,
143 java.lang.String[] guestPermissions)
144 throws com.liferay.portal.PortalException,
145 com.liferay.portal.SystemException {
146 return getService()
147 .addCategory(uuid, userId, plid, parentCategoryId, name,
148 description, addCommunityPermissions, addGuestPermissions,
149 communityPermissions, guestPermissions);
150 }
151
152 public static void addCategoryResources(long categoryId,
153 boolean addCommunityPermissions, boolean addGuestPermissions)
154 throws com.liferay.portal.PortalException,
155 com.liferay.portal.SystemException {
156 getService()
157 .addCategoryResources(categoryId, addCommunityPermissions,
158 addGuestPermissions);
159 }
160
161 public static void addCategoryResources(long categoryId,
162 java.lang.String[] communityPermissions,
163 java.lang.String[] guestPermissions)
164 throws com.liferay.portal.PortalException,
165 com.liferay.portal.SystemException {
166 getService()
167 .addCategoryResources(categoryId, communityPermissions,
168 guestPermissions);
169 }
170
171 public static void addCategoryResources(
172 com.liferay.portlet.messageboards.model.MBCategory category,
173 boolean addCommunityPermissions, boolean addGuestPermissions)
174 throws com.liferay.portal.PortalException,
175 com.liferay.portal.SystemException {
176 getService()
177 .addCategoryResources(category, addCommunityPermissions,
178 addGuestPermissions);
179 }
180
181 public static void addCategoryResources(
182 com.liferay.portlet.messageboards.model.MBCategory category,
183 java.lang.String[] communityPermissions,
184 java.lang.String[] guestPermissions)
185 throws com.liferay.portal.PortalException,
186 com.liferay.portal.SystemException {
187 getService()
188 .addCategoryResources(category, communityPermissions,
189 guestPermissions);
190 }
191
192 public static void deleteCategories(long groupId)
193 throws com.liferay.portal.PortalException,
194 com.liferay.portal.SystemException {
195 getService().deleteCategories(groupId);
196 }
197
198 public static void deleteCategory(long categoryId)
199 throws com.liferay.portal.PortalException,
200 com.liferay.portal.SystemException {
201 getService().deleteCategory(categoryId);
202 }
203
204 public static void deleteCategory(
205 com.liferay.portlet.messageboards.model.MBCategory category)
206 throws com.liferay.portal.PortalException,
207 com.liferay.portal.SystemException {
208 getService().deleteCategory(category);
209 }
210
211 public static java.util.List<com.liferay.portlet.messageboards.model.MBCategory> getCategories(
212 long groupId) throws com.liferay.portal.SystemException {
213 return getService().getCategories(groupId);
214 }
215
216 public static java.util.List<com.liferay.portlet.messageboards.model.MBCategory> getCategories(
217 long groupId, long parentCategoryId)
218 throws com.liferay.portal.SystemException {
219 return getService().getCategories(groupId, parentCategoryId);
220 }
221
222 public static java.util.List<com.liferay.portlet.messageboards.model.MBCategory> getCategories(
223 long groupId, long parentCategoryId, int start, int end)
224 throws com.liferay.portal.SystemException {
225 return getService().getCategories(groupId, parentCategoryId, start, end);
226 }
227
228 public static int getCategoriesCount(long groupId)
229 throws com.liferay.portal.SystemException {
230 return getService().getCategoriesCount(groupId);
231 }
232
233 public static int getCategoriesCount(long groupId, long parentCategoryId)
234 throws com.liferay.portal.SystemException {
235 return getService().getCategoriesCount(groupId, parentCategoryId);
236 }
237
238 public static com.liferay.portlet.messageboards.model.MBCategory getCategory(
239 long categoryId)
240 throws com.liferay.portal.PortalException,
241 com.liferay.portal.SystemException {
242 return getService().getCategory(categoryId);
243 }
244
245 public static void getSubcategoryIds(java.util.List<Long> categoryIds,
246 long groupId, long categoryId)
247 throws com.liferay.portal.SystemException {
248 getService().getSubcategoryIds(categoryIds, groupId, categoryId);
249 }
250
251 public static java.util.List<com.liferay.portlet.messageboards.model.MBCategory> getSubscribedCategories(
252 long groupId, long userId, int start, int end)
253 throws com.liferay.portal.SystemException {
254 return getService().getSubscribedCategories(groupId, userId, start, end);
255 }
256
257 public static int getSubscribedCategoriesCount(long groupId, long userId)
258 throws com.liferay.portal.SystemException {
259 return getService().getSubscribedCategoriesCount(groupId, userId);
260 }
261
262 public static com.liferay.portlet.messageboards.model.MBCategory getSystemCategory()
263 throws com.liferay.portal.SystemException {
264 return getService().getSystemCategory();
265 }
266
267 public static void reIndex(java.lang.String[] ids)
268 throws com.liferay.portal.SystemException {
269 getService().reIndex(ids);
270 }
271
272 public static com.liferay.portal.kernel.search.Hits search(long companyId,
273 long groupId, long[] categoryIds, long threadId,
274 java.lang.String keywords, int start, int end)
275 throws com.liferay.portal.SystemException {
276 return getService()
277 .search(companyId, groupId, categoryIds, threadId, keywords,
278 start, end);
279 }
280
281 public static void subscribeCategory(long userId, long categoryId)
282 throws com.liferay.portal.PortalException,
283 com.liferay.portal.SystemException {
284 getService().subscribeCategory(userId, categoryId);
285 }
286
287 public static void unsubscribeCategory(long userId, long categoryId)
288 throws com.liferay.portal.PortalException,
289 com.liferay.portal.SystemException {
290 getService().unsubscribeCategory(userId, categoryId);
291 }
292
293 public static com.liferay.portlet.messageboards.model.MBCategory updateCategory(
294 long categoryId, long parentCategoryId, java.lang.String name,
295 java.lang.String description, boolean mergeWithParentCategory)
296 throws com.liferay.portal.PortalException,
297 com.liferay.portal.SystemException {
298 return getService()
299 .updateCategory(categoryId, parentCategoryId, name,
300 description, mergeWithParentCategory);
301 }
302
303 public static MBCategoryLocalService getService() {
304 if (_service == null) {
305 _service = (MBCategoryLocalService)PortalBeanLocatorUtil.locate(MBCategoryLocalService.class.getName());
306 }
307
308 return _service;
309 }
310
311 public void setService(MBCategoryLocalService service) {
312 _service = service;
313 }
314
315 private static MBCategoryLocalService _service;
316 }