001: /**
002: * Copyright (c) 2000-2008 Liferay, Inc. All rights reserved.
003: *
004: * Permission is hereby granted, free of charge, to any person obtaining a copy
005: * of this software and associated documentation files (the "Software"), to deal
006: * in the Software without restriction, including without limitation the rights
007: * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
008: * copies of the Software, and to permit persons to whom the Software is
009: * furnished to do so, subject to the following conditions:
010: *
011: * The above copyright notice and this permission notice shall be included in
012: * all copies or substantial portions of the Software.
013: *
014: * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
015: * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
016: * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
017: * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
018: * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
019: * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
020: * SOFTWARE.
021: */package com.liferay.portlet.journal.service;
022:
023: /**
024: * <a href="JournalStructureServiceUtil.java.html"><b><i>View Source</i></b></a>
025: *
026: * <p>
027: * ServiceBuilder generated this class. Modifications in this class will be
028: * overwritten the next time is generated.
029: * </p>
030: *
031: * <p>
032: * This class provides static methods for the
033: * <code>com.liferay.portlet.journal.service.JournalStructureService</code>
034: * bean. The static methods of this class calls the same methods of the bean
035: * instance. It's convenient to be able to just write one line to call a method
036: * on a bean instead of writing a lookup call and a method call.
037: * </p>
038: *
039: * <p>
040: * <code>com.liferay.portlet.journal.service.JournalStructureServiceFactory</code>
041: * is responsible for the lookup of the bean.
042: * </p>
043: *
044: * @author Brian Wing Shun Chan
045: *
046: * @see com.liferay.portlet.journal.service.JournalStructureService
047: * @see com.liferay.portlet.journal.service.JournalStructureServiceFactory
048: *
049: */
050: public class JournalStructureServiceUtil {
051: public static com.liferay.portlet.journal.model.JournalStructure addStructure(
052: java.lang.String structureId, boolean autoStructureId,
053: long plid, java.lang.String name,
054: java.lang.String description, java.lang.String xsd,
055: boolean addCommunityPermissions, boolean addGuestPermissions)
056: throws com.liferay.portal.PortalException,
057: com.liferay.portal.SystemException,
058: java.rmi.RemoteException {
059: JournalStructureService journalStructureService = JournalStructureServiceFactory
060: .getService();
061:
062: return journalStructureService.addStructure(structureId,
063: autoStructureId, plid, name, description, xsd,
064: addCommunityPermissions, addGuestPermissions);
065: }
066:
067: public static com.liferay.portlet.journal.model.JournalStructure addStructure(
068: java.lang.String structureId, boolean autoStructureId,
069: long plid, java.lang.String name,
070: java.lang.String description, java.lang.String xsd,
071: java.lang.String[] communityPermissions,
072: java.lang.String[] guestPermissions)
073: throws com.liferay.portal.PortalException,
074: com.liferay.portal.SystemException,
075: java.rmi.RemoteException {
076: JournalStructureService journalStructureService = JournalStructureServiceFactory
077: .getService();
078:
079: return journalStructureService.addStructure(structureId,
080: autoStructureId, plid, name, description, xsd,
081: communityPermissions, guestPermissions);
082: }
083:
084: public static void deleteStructure(long groupId,
085: java.lang.String structureId)
086: throws com.liferay.portal.PortalException,
087: com.liferay.portal.SystemException,
088: java.rmi.RemoteException {
089: JournalStructureService journalStructureService = JournalStructureServiceFactory
090: .getService();
091:
092: journalStructureService.deleteStructure(groupId, structureId);
093: }
094:
095: public static com.liferay.portlet.journal.model.JournalStructure getStructure(
096: long groupId, java.lang.String structureId)
097: throws com.liferay.portal.PortalException,
098: com.liferay.portal.SystemException,
099: java.rmi.RemoteException {
100: JournalStructureService journalStructureService = JournalStructureServiceFactory
101: .getService();
102:
103: return journalStructureService.getStructure(groupId,
104: structureId);
105: }
106:
107: public static com.liferay.portlet.journal.model.JournalStructure updateStructure(
108: long groupId, java.lang.String structureId,
109: java.lang.String name, java.lang.String description,
110: java.lang.String xsd)
111: throws com.liferay.portal.PortalException,
112: com.liferay.portal.SystemException,
113: java.rmi.RemoteException {
114: JournalStructureService journalStructureService = JournalStructureServiceFactory
115: .getService();
116:
117: return journalStructureService.updateStructure(groupId,
118: structureId, name, description, xsd);
119: }
120: }
|