1
14
15 package com.liferay.portlet.wiki.service;
16
17 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
18 import com.liferay.portal.kernel.util.MethodCache;
19 import com.liferay.portal.kernel.util.ReferenceRegistry;
20
21
41 public class WikiNodeServiceUtil {
42 public static com.liferay.portlet.wiki.model.WikiNode addNode(
43 java.lang.String name, java.lang.String description,
44 com.liferay.portal.service.ServiceContext serviceContext)
45 throws com.liferay.portal.PortalException,
46 com.liferay.portal.SystemException {
47 return getService().addNode(name, description, serviceContext);
48 }
49
50 public static void deleteNode(long nodeId)
51 throws com.liferay.portal.PortalException,
52 com.liferay.portal.SystemException {
53 getService().deleteNode(nodeId);
54 }
55
56 public static com.liferay.portlet.wiki.model.WikiNode getNode(long nodeId)
57 throws com.liferay.portal.PortalException,
58 com.liferay.portal.SystemException {
59 return getService().getNode(nodeId);
60 }
61
62 public static com.liferay.portlet.wiki.model.WikiNode getNode(
63 long groupId, java.lang.String name)
64 throws com.liferay.portal.PortalException,
65 com.liferay.portal.SystemException {
66 return getService().getNode(groupId, name);
67 }
68
69 public static void importPages(long nodeId, java.lang.String importer,
70 java.io.File[] files,
71 java.util.Map<java.lang.String, java.lang.String[]> options)
72 throws com.liferay.portal.PortalException,
73 com.liferay.portal.SystemException {
74 getService().importPages(nodeId, importer, files, options);
75 }
76
77 public static void subscribeNode(long nodeId)
78 throws com.liferay.portal.PortalException,
79 com.liferay.portal.SystemException {
80 getService().subscribeNode(nodeId);
81 }
82
83 public static void unsubscribeNode(long nodeId)
84 throws com.liferay.portal.PortalException,
85 com.liferay.portal.SystemException {
86 getService().unsubscribeNode(nodeId);
87 }
88
89
92 public static com.liferay.portlet.wiki.model.WikiNode updateNode(
93 long nodeId, java.lang.String name, java.lang.String description)
94 throws com.liferay.portal.PortalException,
95 com.liferay.portal.SystemException {
96 return getService().updateNode(nodeId, name, description);
97 }
98
99 public static com.liferay.portlet.wiki.model.WikiNode updateNode(
100 long nodeId, java.lang.String name, java.lang.String description,
101 com.liferay.portal.service.ServiceContext serviceContext)
102 throws com.liferay.portal.PortalException,
103 com.liferay.portal.SystemException {
104 return getService().updateNode(nodeId, name, description, serviceContext);
105 }
106
107 public static WikiNodeService getService() {
108 if (_service == null) {
109 _service = (WikiNodeService)PortalBeanLocatorUtil.locate(WikiNodeService.class.getName());
110
111 ReferenceRegistry.registerReference(WikiNodeServiceUtil.class,
112 "_service");
113 MethodCache.remove(WikiNodeService.class);
114 }
115
116 return _service;
117 }
118
119 public void setService(WikiNodeService service) {
120 MethodCache.remove(WikiNodeService.class);
121
122 _service = service;
123
124 ReferenceRegistry.registerReference(WikiNodeServiceUtil.class,
125 "_service");
126 MethodCache.remove(WikiNodeService.class);
127 }
128
129 private static WikiNodeService _service;
130 }