1
14
15 package com.liferay.portlet.wiki.service;
16
17 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
18
19
39 public class WikiPageLocalServiceUtil {
40 public static com.liferay.portlet.wiki.model.WikiPage addWikiPage(
41 com.liferay.portlet.wiki.model.WikiPage wikiPage)
42 throws com.liferay.portal.kernel.exception.SystemException {
43 return getService().addWikiPage(wikiPage);
44 }
45
46 public static com.liferay.portlet.wiki.model.WikiPage createWikiPage(
47 long pageId) {
48 return getService().createWikiPage(pageId);
49 }
50
51 public static void deleteWikiPage(long pageId)
52 throws com.liferay.portal.kernel.exception.PortalException,
53 com.liferay.portal.kernel.exception.SystemException {
54 getService().deleteWikiPage(pageId);
55 }
56
57 public static void deleteWikiPage(
58 com.liferay.portlet.wiki.model.WikiPage wikiPage)
59 throws com.liferay.portal.kernel.exception.SystemException {
60 getService().deleteWikiPage(wikiPage);
61 }
62
63 @SuppressWarnings("unchecked")
64 public static java.util.List dynamicQuery(
65 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
66 throws com.liferay.portal.kernel.exception.SystemException {
67 return getService().dynamicQuery(dynamicQuery);
68 }
69
70 @SuppressWarnings("unchecked")
71 public static java.util.List dynamicQuery(
72 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
73 int end) throws com.liferay.portal.kernel.exception.SystemException {
74 return getService().dynamicQuery(dynamicQuery, start, end);
75 }
76
77 @SuppressWarnings("unchecked")
78 public static java.util.List dynamicQuery(
79 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
80 int end,
81 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
82 throws com.liferay.portal.kernel.exception.SystemException {
83 return getService()
84 .dynamicQuery(dynamicQuery, start, end, orderByComparator);
85 }
86
87 public static long dynamicQueryCount(
88 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
89 throws com.liferay.portal.kernel.exception.SystemException {
90 return getService().dynamicQueryCount(dynamicQuery);
91 }
92
93 public static com.liferay.portlet.wiki.model.WikiPage getWikiPage(
94 long pageId)
95 throws com.liferay.portal.kernel.exception.PortalException,
96 com.liferay.portal.kernel.exception.SystemException {
97 return getService().getWikiPage(pageId);
98 }
99
100 public static com.liferay.portlet.wiki.model.WikiPage getWikiPageByUuidAndGroupId(
101 java.lang.String uuid, long groupId)
102 throws com.liferay.portal.kernel.exception.PortalException,
103 com.liferay.portal.kernel.exception.SystemException {
104 return getService().getWikiPageByUuidAndGroupId(uuid, groupId);
105 }
106
107 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getWikiPages(
108 int start, int end)
109 throws com.liferay.portal.kernel.exception.SystemException {
110 return getService().getWikiPages(start, end);
111 }
112
113 public static int getWikiPagesCount()
114 throws com.liferay.portal.kernel.exception.SystemException {
115 return getService().getWikiPagesCount();
116 }
117
118 public static com.liferay.portlet.wiki.model.WikiPage updateWikiPage(
119 com.liferay.portlet.wiki.model.WikiPage wikiPage)
120 throws com.liferay.portal.kernel.exception.SystemException {
121 return getService().updateWikiPage(wikiPage);
122 }
123
124 public static com.liferay.portlet.wiki.model.WikiPage updateWikiPage(
125 com.liferay.portlet.wiki.model.WikiPage wikiPage, boolean merge)
126 throws com.liferay.portal.kernel.exception.SystemException {
127 return getService().updateWikiPage(wikiPage, merge);
128 }
129
130 public static com.liferay.portlet.wiki.model.WikiPage addPage(long userId,
131 long nodeId, java.lang.String title, java.lang.String content,
132 java.lang.String summary, boolean minorEdit,
133 com.liferay.portal.service.ServiceContext serviceContext)
134 throws com.liferay.portal.kernel.exception.PortalException,
135 com.liferay.portal.kernel.exception.SystemException {
136 return getService()
137 .addPage(userId, nodeId, title, content, summary, minorEdit,
138 serviceContext);
139 }
140
141 public static com.liferay.portlet.wiki.model.WikiPage addPage(
142 java.lang.String uuid, long userId, long nodeId,
143 java.lang.String title, double version, java.lang.String content,
144 java.lang.String summary, boolean minorEdit, java.lang.String format,
145 boolean head, java.lang.String parentTitle,
146 java.lang.String redirectTitle,
147 com.liferay.portal.service.ServiceContext serviceContext)
148 throws com.liferay.portal.kernel.exception.PortalException,
149 com.liferay.portal.kernel.exception.SystemException {
150 return getService()
151 .addPage(uuid, userId, nodeId, title, version, content,
152 summary, minorEdit, format, head, parentTitle, redirectTitle,
153 serviceContext);
154 }
155
156 public static void addPageAttachment(long companyId,
157 java.lang.String dirName, java.util.Date modifiedDate,
158 java.lang.String fileName, java.io.InputStream inputStream)
159 throws com.liferay.portal.kernel.exception.PortalException,
160 com.liferay.portal.kernel.exception.SystemException {
161 getService()
162 .addPageAttachment(companyId, dirName, modifiedDate, fileName,
163 inputStream);
164 }
165
166 public static void addPageAttachments(long nodeId, java.lang.String title,
167 java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<java.lang.String, byte[]>> files)
168 throws com.liferay.portal.kernel.exception.PortalException,
169 com.liferay.portal.kernel.exception.SystemException {
170 getService().addPageAttachments(nodeId, title, files);
171 }
172
173 public static void addPageResources(long nodeId, java.lang.String title,
174 boolean addCommunityPermissions, boolean addGuestPermissions)
175 throws com.liferay.portal.kernel.exception.PortalException,
176 com.liferay.portal.kernel.exception.SystemException {
177 getService()
178 .addPageResources(nodeId, title, addCommunityPermissions,
179 addGuestPermissions);
180 }
181
182 public static void addPageResources(
183 com.liferay.portlet.wiki.model.WikiPage page,
184 boolean addCommunityPermissions, boolean addGuestPermissions)
185 throws com.liferay.portal.kernel.exception.PortalException,
186 com.liferay.portal.kernel.exception.SystemException {
187 getService()
188 .addPageResources(page, addCommunityPermissions, addGuestPermissions);
189 }
190
191 public static void addPageResources(long nodeId, java.lang.String title,
192 java.lang.String[] communityPermissions,
193 java.lang.String[] guestPermissions)
194 throws com.liferay.portal.kernel.exception.PortalException,
195 com.liferay.portal.kernel.exception.SystemException {
196 getService()
197 .addPageResources(nodeId, title, communityPermissions,
198 guestPermissions);
199 }
200
201 public static void addPageResources(
202 com.liferay.portlet.wiki.model.WikiPage page,
203 java.lang.String[] communityPermissions,
204 java.lang.String[] guestPermissions)
205 throws com.liferay.portal.kernel.exception.PortalException,
206 com.liferay.portal.kernel.exception.SystemException {
207 getService()
208 .addPageResources(page, communityPermissions, guestPermissions);
209 }
210
211 public static void changeParent(long userId, long nodeId,
212 java.lang.String title, java.lang.String newParentTitle,
213 com.liferay.portal.service.ServiceContext serviceContext)
214 throws com.liferay.portal.kernel.exception.PortalException,
215 com.liferay.portal.kernel.exception.SystemException {
216 getService()
217 .changeParent(userId, nodeId, title, newParentTitle, serviceContext);
218 }
219
220 public static void deletePage(long nodeId, java.lang.String title)
221 throws com.liferay.portal.kernel.exception.PortalException,
222 com.liferay.portal.kernel.exception.SystemException {
223 getService().deletePage(nodeId, title);
224 }
225
226 public static void deletePage(com.liferay.portlet.wiki.model.WikiPage page)
227 throws com.liferay.portal.kernel.exception.PortalException,
228 com.liferay.portal.kernel.exception.SystemException {
229 getService().deletePage(page);
230 }
231
232 public static void deletePageAttachment(long nodeId,
233 java.lang.String title, java.lang.String fileName)
234 throws com.liferay.portal.kernel.exception.PortalException,
235 com.liferay.portal.kernel.exception.SystemException {
236 getService().deletePageAttachment(nodeId, title, fileName);
237 }
238
239 public static void deletePages(long nodeId)
240 throws com.liferay.portal.kernel.exception.PortalException,
241 com.liferay.portal.kernel.exception.SystemException {
242 getService().deletePages(nodeId);
243 }
244
245 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getChildren(
246 long nodeId, boolean head, java.lang.String parentTitle)
247 throws com.liferay.portal.kernel.exception.SystemException {
248 return getService().getChildren(nodeId, head, parentTitle);
249 }
250
251 public static com.liferay.portlet.wiki.model.WikiPage getDraftPage(
252 long nodeId, java.lang.String title)
253 throws com.liferay.portal.kernel.exception.PortalException,
254 com.liferay.portal.kernel.exception.SystemException {
255 return getService().getDraftPage(nodeId, title);
256 }
257
258 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getDraftPages(
259 long userId, long nodeId, int start, int end)
260 throws com.liferay.portal.kernel.exception.SystemException {
261 return getService().getDraftPages(userId, nodeId, start, end);
262 }
263
264 public static int getDraftPagesCount(long userId, long nodeId)
265 throws com.liferay.portal.kernel.exception.SystemException {
266 return getService().getDraftPagesCount(userId, nodeId);
267 }
268
269 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getIncomingLinks(
270 long nodeId, java.lang.String title)
271 throws com.liferay.portal.kernel.exception.PortalException,
272 com.liferay.portal.kernel.exception.SystemException {
273 return getService().getIncomingLinks(nodeId, title);
274 }
275
276 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getNoAssetPages()
277 throws com.liferay.portal.kernel.exception.SystemException {
278 return getService().getNoAssetPages();
279 }
280
281 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getOrphans(
282 long nodeId)
283 throws com.liferay.portal.kernel.exception.PortalException,
284 com.liferay.portal.kernel.exception.SystemException {
285 return getService().getOrphans(nodeId);
286 }
287
288 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getOutgoingLinks(
289 long nodeId, java.lang.String title)
290 throws com.liferay.portal.kernel.exception.PortalException,
291 com.liferay.portal.kernel.exception.SystemException {
292 return getService().getOutgoingLinks(nodeId, title);
293 }
294
295 public static com.liferay.portlet.wiki.model.WikiPage getPage(
296 long resourcePrimKey)
297 throws com.liferay.portal.kernel.exception.PortalException,
298 com.liferay.portal.kernel.exception.SystemException {
299 return getService().getPage(resourcePrimKey);
300 }
301
302 public static com.liferay.portlet.wiki.model.WikiPage getPage(long nodeId,
303 java.lang.String title)
304 throws com.liferay.portal.kernel.exception.PortalException,
305 com.liferay.portal.kernel.exception.SystemException {
306 return getService().getPage(nodeId, title);
307 }
308
309 public static com.liferay.portlet.wiki.model.WikiPage getPage(long nodeId,
310 java.lang.String title, boolean head)
311 throws com.liferay.portal.kernel.exception.PortalException,
312 com.liferay.portal.kernel.exception.SystemException {
313 return getService().getPage(nodeId, title, head);
314 }
315
316 public static com.liferay.portlet.wiki.model.WikiPage getPage(long nodeId,
317 java.lang.String title, double version)
318 throws com.liferay.portal.kernel.exception.PortalException,
319 com.liferay.portal.kernel.exception.SystemException {
320 return getService().getPage(nodeId, title, version);
321 }
322
323 public static com.liferay.portlet.wiki.model.WikiPageDisplay getPageDisplay(
324 long nodeId, java.lang.String title,
325 javax.portlet.PortletURL viewPageURL,
326 javax.portlet.PortletURL editPageURL,
327 java.lang.String attachmentURLPrefix)
328 throws com.liferay.portal.kernel.exception.PortalException,
329 com.liferay.portal.kernel.exception.SystemException {
330 return getService()
331 .getPageDisplay(nodeId, title, viewPageURL, editPageURL,
332 attachmentURLPrefix);
333 }
334
335 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getPages(
336 long nodeId, int start, int end)
337 throws com.liferay.portal.kernel.exception.SystemException {
338 return getService().getPages(nodeId, start, end);
339 }
340
341 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getPages(
342 java.lang.String format)
343 throws com.liferay.portal.kernel.exception.SystemException {
344 return getService().getPages(format);
345 }
346
347 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getPages(
348 long nodeId, java.lang.String title, int start, int end)
349 throws com.liferay.portal.kernel.exception.SystemException {
350 return getService().getPages(nodeId, title, start, end);
351 }
352
353 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getPages(
354 long nodeId, java.lang.String title, int start, int end,
355 com.liferay.portal.kernel.util.OrderByComparator obc)
356 throws com.liferay.portal.kernel.exception.SystemException {
357 return getService().getPages(nodeId, title, start, end, obc);
358 }
359
360 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getPages(
361 long nodeId, boolean head, int start, int end)
362 throws com.liferay.portal.kernel.exception.SystemException {
363 return getService().getPages(nodeId, head, start, end);
364 }
365
366 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getPages(
367 long resourcePrimKey, long nodeId, int status)
368 throws com.liferay.portal.kernel.exception.SystemException {
369 return getService().getPages(resourcePrimKey, nodeId, status);
370 }
371
372 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getPages(
373 long nodeId, java.lang.String title, boolean head, int start, int end)
374 throws com.liferay.portal.kernel.exception.SystemException {
375 return getService().getPages(nodeId, title, head, start, end);
376 }
377
378 public static int getPagesCount(long nodeId)
379 throws com.liferay.portal.kernel.exception.SystemException {
380 return getService().getPagesCount(nodeId);
381 }
382
383 public static int getPagesCount(long nodeId, java.lang.String title)
384 throws com.liferay.portal.kernel.exception.SystemException {
385 return getService().getPagesCount(nodeId, title);
386 }
387
388 public static int getPagesCount(long nodeId, boolean head)
389 throws com.liferay.portal.kernel.exception.SystemException {
390 return getService().getPagesCount(nodeId, head);
391 }
392
393 public static int getPagesCount(long nodeId, java.lang.String title,
394 boolean head)
395 throws com.liferay.portal.kernel.exception.SystemException {
396 return getService().getPagesCount(nodeId, title, head);
397 }
398
399 public static int getPagesCount(java.lang.String format)
400 throws com.liferay.portal.kernel.exception.SystemException {
401 return getService().getPagesCount(format);
402 }
403
404 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getRecentChanges(
405 long nodeId, int start, int end)
406 throws com.liferay.portal.kernel.exception.SystemException {
407 return getService().getRecentChanges(nodeId, start, end);
408 }
409
410 public static int getRecentChangesCount(long nodeId)
411 throws com.liferay.portal.kernel.exception.SystemException {
412 return getService().getRecentChangesCount(nodeId);
413 }
414
415 public static boolean hasDraftPage(long nodeId, java.lang.String title)
416 throws com.liferay.portal.kernel.exception.SystemException {
417 return getService().hasDraftPage(nodeId, title);
418 }
419
420 public static void movePage(long userId, long nodeId,
421 java.lang.String title, java.lang.String newTitle,
422 com.liferay.portal.service.ServiceContext serviceContext)
423 throws com.liferay.portal.kernel.exception.PortalException,
424 com.liferay.portal.kernel.exception.SystemException {
425 getService().movePage(userId, nodeId, title, newTitle, serviceContext);
426 }
427
428 public static void movePage(long userId, long nodeId,
429 java.lang.String title, java.lang.String newTitle, boolean strict,
430 com.liferay.portal.service.ServiceContext serviceContext)
431 throws com.liferay.portal.kernel.exception.PortalException,
432 com.liferay.portal.kernel.exception.SystemException {
433 getService()
434 .movePage(userId, nodeId, title, newTitle, strict, serviceContext);
435 }
436
437 public static com.liferay.portlet.wiki.model.WikiPage revertPage(
438 long userId, long nodeId, java.lang.String title, double version,
439 com.liferay.portal.service.ServiceContext serviceContext)
440 throws com.liferay.portal.kernel.exception.PortalException,
441 com.liferay.portal.kernel.exception.SystemException {
442 return getService()
443 .revertPage(userId, nodeId, title, version, serviceContext);
444 }
445
446 public static void subscribePage(long userId, long nodeId,
447 java.lang.String title)
448 throws com.liferay.portal.kernel.exception.PortalException,
449 com.liferay.portal.kernel.exception.SystemException {
450 getService().subscribePage(userId, nodeId, title);
451 }
452
453 public static void unsubscribePage(long userId, long nodeId,
454 java.lang.String title)
455 throws com.liferay.portal.kernel.exception.PortalException,
456 com.liferay.portal.kernel.exception.SystemException {
457 getService().unsubscribePage(userId, nodeId, title);
458 }
459
460 public static void updateAsset(long userId,
461 com.liferay.portlet.wiki.model.WikiPage page, long[] assetCategoryIds,
462 java.lang.String[] assetTagNames)
463 throws com.liferay.portal.kernel.exception.PortalException,
464 com.liferay.portal.kernel.exception.SystemException {
465 getService().updateAsset(userId, page, assetCategoryIds, assetTagNames);
466 }
467
468 public static com.liferay.portlet.wiki.model.WikiPage updatePage(
469 long userId, long nodeId, java.lang.String title, double version,
470 java.lang.String content, java.lang.String summary, boolean minorEdit,
471 java.lang.String format, java.lang.String parentTitle,
472 java.lang.String redirectTitle,
473 com.liferay.portal.service.ServiceContext serviceContext)
474 throws com.liferay.portal.kernel.exception.PortalException,
475 com.liferay.portal.kernel.exception.SystemException {
476 return getService()
477 .updatePage(userId, nodeId, title, version, content,
478 summary, minorEdit, format, parentTitle, redirectTitle,
479 serviceContext);
480 }
481
482 public static com.liferay.portlet.wiki.model.WikiPage updateStatus(
483 long userId, long resourcePrimKey, int status,
484 com.liferay.portal.service.ServiceContext serviceContext)
485 throws com.liferay.portal.kernel.exception.PortalException,
486 com.liferay.portal.kernel.exception.SystemException {
487 return getService()
488 .updateStatus(userId, resourcePrimKey, status, serviceContext);
489 }
490
491 public static com.liferay.portlet.wiki.model.WikiPage updateStatus(
492 long userId, com.liferay.portlet.wiki.model.WikiPage page, int status,
493 com.liferay.portal.service.ServiceContext serviceContext)
494 throws com.liferay.portal.kernel.exception.PortalException,
495 com.liferay.portal.kernel.exception.SystemException {
496 return getService().updateStatus(userId, page, status, serviceContext);
497 }
498
499 public static void validateTitle(java.lang.String title)
500 throws com.liferay.portal.kernel.exception.PortalException {
501 getService().validateTitle(title);
502 }
503
504 public static WikiPageLocalService getService() {
505 if (_service == null) {
506 _service = (WikiPageLocalService)PortalBeanLocatorUtil.locate(WikiPageLocalService.class.getName());
507 }
508
509 return _service;
510 }
511
512 public void setService(WikiPageLocalService service) {
513 _service = service;
514 }
515
516 private static WikiPageLocalService _service;
517 }