1   /**
2    * Copyright (c) 2000-2009 Liferay, Inc. All rights reserved.
3    *
4    *
5    *
6    *
7    * The contents of this file are subject to the terms of the Liferay Enterprise
8    * Subscription License ("License"). You may not use this file except in
9    * compliance with the License. You can obtain a copy of the License by
10   * contacting Liferay, Inc. See the License for the specific language governing
11   * permissions and limitations under the License, including but not limited to
12   * distribution rights of the Software.
13   *
14   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15   * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16   * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17   * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18   * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19   * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20   * SOFTWARE.
21   */
22  
23  package com.liferay.portlet.wiki.service;
24  
25  
26  /**
27   * <a href="WikiNodeLocalServiceUtil.java.html"><b><i>View Source</i></b></a>
28   *
29   * <p>
30   * ServiceBuilder generated this class. Modifications in this class will be
31   * overwritten the next time is generated.
32   * </p>
33   *
34   * <p>
35   * This class provides static methods for the
36   * {@link WikiNodeLocalService} bean. The static methods of
37   * this class calls the same methods of the bean instance. It's convenient to be
38   * able to just write one line to call a method on a bean instead of writing a
39   * lookup call and a method call.
40   * </p>
41   *
42   * @author    Brian Wing Shun Chan
43   * @see       WikiNodeLocalService
44   * @generated
45   */
46  public class WikiNodeLocalServiceUtil {
47      public static com.liferay.portlet.wiki.model.WikiNode addWikiNode(
48          com.liferay.portlet.wiki.model.WikiNode wikiNode)
49          throws com.liferay.portal.SystemException {
50          return getService().addWikiNode(wikiNode);
51      }
52  
53      public static com.liferay.portlet.wiki.model.WikiNode createWikiNode(
54          long nodeId) {
55          return getService().createWikiNode(nodeId);
56      }
57  
58      public static void deleteWikiNode(long nodeId)
59          throws com.liferay.portal.PortalException,
60              com.liferay.portal.SystemException {
61          getService().deleteWikiNode(nodeId);
62      }
63  
64      public static void deleteWikiNode(
65          com.liferay.portlet.wiki.model.WikiNode wikiNode)
66          throws com.liferay.portal.SystemException {
67          getService().deleteWikiNode(wikiNode);
68      }
69  
70      public static java.util.List<Object> dynamicQuery(
71          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
72          throws com.liferay.portal.SystemException {
73          return getService().dynamicQuery(dynamicQuery);
74      }
75  
76      public static java.util.List<Object> dynamicQuery(
77          com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
78          int end) throws com.liferay.portal.SystemException {
79          return getService().dynamicQuery(dynamicQuery, start, end);
80      }
81  
82      public static com.liferay.portlet.wiki.model.WikiNode getWikiNode(
83          long nodeId)
84          throws com.liferay.portal.PortalException,
85              com.liferay.portal.SystemException {
86          return getService().getWikiNode(nodeId);
87      }
88  
89      public static java.util.List<com.liferay.portlet.wiki.model.WikiNode> getWikiNodes(
90          int start, int end) throws com.liferay.portal.SystemException {
91          return getService().getWikiNodes(start, end);
92      }
93  
94      public static int getWikiNodesCount()
95          throws com.liferay.portal.SystemException {
96          return getService().getWikiNodesCount();
97      }
98  
99      public static com.liferay.portlet.wiki.model.WikiNode updateWikiNode(
100         com.liferay.portlet.wiki.model.WikiNode wikiNode)
101         throws com.liferay.portal.SystemException {
102         return getService().updateWikiNode(wikiNode);
103     }
104 
105     public static com.liferay.portlet.wiki.model.WikiNode updateWikiNode(
106         com.liferay.portlet.wiki.model.WikiNode wikiNode, boolean merge)
107         throws com.liferay.portal.SystemException {
108         return getService().updateWikiNode(wikiNode, merge);
109     }
110 
111     public static com.liferay.portlet.wiki.model.WikiNode addNode(long userId,
112         java.lang.String name, java.lang.String description,
113         com.liferay.portal.service.ServiceContext serviceContext)
114         throws com.liferay.portal.PortalException,
115             com.liferay.portal.SystemException {
116         return getService().addNode(userId, name, description, serviceContext);
117     }
118 
119     public static com.liferay.portlet.wiki.model.WikiNode addNode(
120         java.lang.String uuid, long userId, java.lang.String name,
121         java.lang.String description,
122         com.liferay.portal.service.ServiceContext serviceContext)
123         throws com.liferay.portal.PortalException,
124             com.liferay.portal.SystemException {
125         return getService()
126                    .addNode(uuid, userId, name, description, serviceContext);
127     }
128 
129     public static void addNodeResources(long nodeId,
130         boolean addCommunityPermissions, boolean addGuestPermissions)
131         throws com.liferay.portal.PortalException,
132             com.liferay.portal.SystemException {
133         getService()
134             .addNodeResources(nodeId, addCommunityPermissions,
135             addGuestPermissions);
136     }
137 
138     public static void addNodeResources(
139         com.liferay.portlet.wiki.model.WikiNode node,
140         boolean addCommunityPermissions, boolean addGuestPermissions)
141         throws com.liferay.portal.PortalException,
142             com.liferay.portal.SystemException {
143         getService()
144             .addNodeResources(node, addCommunityPermissions, addGuestPermissions);
145     }
146 
147     public static void addNodeResources(long nodeId,
148         java.lang.String[] communityPermissions,
149         java.lang.String[] guestPermissions)
150         throws com.liferay.portal.PortalException,
151             com.liferay.portal.SystemException {
152         getService()
153             .addNodeResources(nodeId, communityPermissions, guestPermissions);
154     }
155 
156     public static void addNodeResources(
157         com.liferay.portlet.wiki.model.WikiNode node,
158         java.lang.String[] communityPermissions,
159         java.lang.String[] guestPermissions)
160         throws com.liferay.portal.PortalException,
161             com.liferay.portal.SystemException {
162         getService()
163             .addNodeResources(node, communityPermissions, guestPermissions);
164     }
165 
166     public static void deleteNode(long nodeId)
167         throws com.liferay.portal.PortalException,
168             com.liferay.portal.SystemException {
169         getService().deleteNode(nodeId);
170     }
171 
172     public static void deleteNode(com.liferay.portlet.wiki.model.WikiNode node)
173         throws com.liferay.portal.PortalException,
174             com.liferay.portal.SystemException {
175         getService().deleteNode(node);
176     }
177 
178     public static void deleteNodes(long groupId)
179         throws com.liferay.portal.PortalException,
180             com.liferay.portal.SystemException {
181         getService().deleteNodes(groupId);
182     }
183 
184     public static com.liferay.portlet.wiki.model.WikiNode getNode(long nodeId)
185         throws com.liferay.portal.PortalException,
186             com.liferay.portal.SystemException {
187         return getService().getNode(nodeId);
188     }
189 
190     public static com.liferay.portlet.wiki.model.WikiNode getNode(
191         long groupId, java.lang.String nodeName)
192         throws com.liferay.portal.PortalException,
193             com.liferay.portal.SystemException {
194         return getService().getNode(groupId, nodeName);
195     }
196 
197     public static java.util.List<com.liferay.portlet.wiki.model.WikiNode> getNodes(
198         long groupId) throws com.liferay.portal.SystemException {
199         return getService().getNodes(groupId);
200     }
201 
202     public static java.util.List<com.liferay.portlet.wiki.model.WikiNode> getNodes(
203         long groupId, int start, int end)
204         throws com.liferay.portal.SystemException {
205         return getService().getNodes(groupId, start, end);
206     }
207 
208     public static int getNodesCount(long groupId)
209         throws com.liferay.portal.SystemException {
210         return getService().getNodesCount(groupId);
211     }
212 
213     public static void importPages(long userId, long nodeId,
214         java.lang.String importer, java.io.File[] files,
215         java.util.Map<String, String[]> options)
216         throws com.liferay.portal.PortalException,
217             com.liferay.portal.SystemException {
218         getService().importPages(userId, nodeId, importer, files, options);
219     }
220 
221     public static void reIndex(java.lang.String[] ids)
222         throws com.liferay.portal.SystemException {
223         getService().reIndex(ids);
224     }
225 
226     public static com.liferay.portal.kernel.search.Hits search(long companyId,
227         long groupId, long userId, long[] nodeIds, java.lang.String keywords,
228         int start, int end) throws com.liferay.portal.SystemException {
229         return getService()
230                    .search(companyId, groupId, userId, nodeIds, keywords,
231             start, end);
232     }
233 
234     public static void subscribeNode(long userId, long nodeId)
235         throws com.liferay.portal.PortalException,
236             com.liferay.portal.SystemException {
237         getService().subscribeNode(userId, nodeId);
238     }
239 
240     public static void unsubscribeNode(long userId, long nodeId)
241         throws com.liferay.portal.PortalException,
242             com.liferay.portal.SystemException {
243         getService().unsubscribeNode(userId, nodeId);
244     }
245 
246     public static com.liferay.portlet.wiki.model.WikiNode updateNode(
247         long nodeId, java.lang.String name, java.lang.String description)
248         throws com.liferay.portal.PortalException,
249             com.liferay.portal.SystemException {
250         return getService().updateNode(nodeId, name, description);
251     }
252 
253     public static WikiNodeLocalService getService() {
254         if (_service == null) {
255             throw new RuntimeException("WikiNodeLocalService is not set");
256         }
257 
258         return _service;
259     }
260 
261     public void setService(WikiNodeLocalService service) {
262         _service = service;
263     }
264 
265     private static WikiNodeLocalService _service;
266 }