1
19
20 package com.liferay.portlet.wiki.service;
21
22
23
44 public class WikiPageServiceUtil {
45 public static com.liferay.portlet.wiki.model.WikiPage addPage(long nodeId,
46 java.lang.String title, java.lang.String content,
47 java.lang.String summary, boolean minorEdit,
48 javax.portlet.PortletPreferences prefs,
49 com.liferay.portal.theme.ThemeDisplay themeDisplay)
50 throws com.liferay.portal.PortalException,
51 com.liferay.portal.SystemException, java.rmi.RemoteException {
52 return getService()
53 .addPage(nodeId, title, content, summary, minorEdit, prefs,
54 themeDisplay);
55 }
56
57 public static void addPageAttachments(long nodeId, java.lang.String title,
58 java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<String, byte[]>> files)
59 throws com.liferay.portal.PortalException,
60 com.liferay.portal.SystemException, java.rmi.RemoteException {
61 getService().addPageAttachments(nodeId, title, files);
62 }
63
64 public static void changeParent(long nodeId, java.lang.String title,
65 java.lang.String newParentTitle,
66 javax.portlet.PortletPreferences prefs,
67 com.liferay.portal.theme.ThemeDisplay themeDisplay)
68 throws com.liferay.portal.PortalException,
69 com.liferay.portal.SystemException, java.rmi.RemoteException {
70 getService()
71 .changeParent(nodeId, title, newParentTitle, prefs, themeDisplay);
72 }
73
74 public static void deletePage(long nodeId, java.lang.String title)
75 throws com.liferay.portal.PortalException,
76 com.liferay.portal.SystemException, java.rmi.RemoteException {
77 getService().deletePage(nodeId, title);
78 }
79
80 public static void deletePageAttachment(long nodeId,
81 java.lang.String title, java.lang.String fileName)
82 throws com.liferay.portal.PortalException,
83 com.liferay.portal.SystemException, java.rmi.RemoteException {
84 getService().deletePageAttachment(nodeId, title, fileName);
85 }
86
87 public static java.util.List<com.liferay.portlet.wiki.model.WikiPage> getNodePages(
88 long nodeId, int max)
89 throws com.liferay.portal.PortalException,
90 com.liferay.portal.SystemException, java.rmi.RemoteException {
91 return getService().getNodePages(nodeId, max);
92 }
93
94 public static java.lang.String getNodePagesRSS(long nodeId, int max,
95 java.lang.String type, double version, java.lang.String displayStyle,
96 java.lang.String feedURL, java.lang.String entryURL)
97 throws com.liferay.portal.PortalException,
98 com.liferay.portal.SystemException, java.rmi.RemoteException {
99 return getService()
100 .getNodePagesRSS(nodeId, max, type, version, displayStyle,
101 feedURL, entryURL);
102 }
103
104 public static com.liferay.portlet.wiki.model.WikiPage getPage(long nodeId,
105 java.lang.String title)
106 throws com.liferay.portal.PortalException,
107 com.liferay.portal.SystemException, java.rmi.RemoteException {
108 return getService().getPage(nodeId, title);
109 }
110
111 public static com.liferay.portlet.wiki.model.WikiPage getPage(long nodeId,
112 java.lang.String title, double version)
113 throws com.liferay.portal.PortalException,
114 com.liferay.portal.SystemException, java.rmi.RemoteException {
115 return getService().getPage(nodeId, title, version);
116 }
117
118 public static java.lang.String getPagesRSS(long companyId, long nodeId,
119 java.lang.String title, int max, java.lang.String type, double version,
120 java.lang.String displayStyle, java.lang.String feedURL,
121 java.lang.String entryURL, java.util.Locale locale)
122 throws com.liferay.portal.PortalException,
123 com.liferay.portal.SystemException, java.rmi.RemoteException {
124 return getService()
125 .getPagesRSS(companyId, nodeId, title, max, type, version,
126 displayStyle, feedURL, entryURL, locale);
127 }
128
129 public static void movePage(long nodeId, java.lang.String title,
130 java.lang.String newTitle, javax.portlet.PortletPreferences prefs,
131 com.liferay.portal.theme.ThemeDisplay themeDisplay)
132 throws com.liferay.portal.PortalException,
133 com.liferay.portal.SystemException, java.rmi.RemoteException {
134 getService().movePage(nodeId, title, newTitle, prefs, themeDisplay);
135 }
136
137 public static com.liferay.portlet.wiki.model.WikiPage revertPage(
138 long nodeId, java.lang.String title, double version,
139 javax.portlet.PortletPreferences prefs,
140 com.liferay.portal.theme.ThemeDisplay themeDisplay)
141 throws com.liferay.portal.PortalException,
142 com.liferay.portal.SystemException, java.rmi.RemoteException {
143 return getService()
144 .revertPage(nodeId, title, version, prefs, themeDisplay);
145 }
146
147 public static void subscribePage(long nodeId, java.lang.String title)
148 throws com.liferay.portal.PortalException,
149 com.liferay.portal.SystemException, java.rmi.RemoteException {
150 getService().subscribePage(nodeId, title);
151 }
152
153 public static void unsubscribePage(long nodeId, java.lang.String title)
154 throws com.liferay.portal.PortalException,
155 com.liferay.portal.SystemException, java.rmi.RemoteException {
156 getService().unsubscribePage(nodeId, title);
157 }
158
159 public static com.liferay.portlet.wiki.model.WikiPage updatePage(
160 long nodeId, java.lang.String title, double version,
161 java.lang.String content, java.lang.String summary, boolean minorEdit,
162 java.lang.String format, java.lang.String parentTitle,
163 java.lang.String redirectTitle, java.lang.String[] tagsEntries,
164 javax.portlet.PortletPreferences prefs,
165 com.liferay.portal.theme.ThemeDisplay themeDisplay)
166 throws com.liferay.portal.PortalException,
167 com.liferay.portal.SystemException, java.rmi.RemoteException {
168 return getService()
169 .updatePage(nodeId, title, version, content, summary,
170 minorEdit, format, parentTitle, redirectTitle, tagsEntries, prefs,
171 themeDisplay);
172 }
173
174 public static WikiPageService getService() {
175 if (_service == null) {
176 throw new RuntimeException("WikiPageService is not set");
177 }
178
179 return _service;
180 }
181
182 public void setService(WikiPageService service) {
183 _service = service;
184 }
185
186 private static WikiPageService _service;
187 }