001    /**
002     * Copyright (c) 2000-2012 Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portal.service;
016    
017    /**
018     * <p>
019     * This class is a wrapper for {@link UserGroupService}.
020     * </p>
021     *
022     * @author    Brian Wing Shun Chan
023     * @see       UserGroupService
024     * @generated
025     */
026    public class UserGroupServiceWrapper implements UserGroupService,
027            ServiceWrapper<UserGroupService> {
028            public UserGroupServiceWrapper(UserGroupService userGroupService) {
029                    _userGroupService = userGroupService;
030            }
031    
032            /**
033            * Adds the user groups to the group.
034            *
035            * @param groupId the primary key of the group
036            * @param userGroupIds the primary keys of the user groups
037            * @throws PortalException if a group or user group with the primary key
038            could not be found, or if the user did not have permission to
039            assign group members
040            * @throws SystemException if a system exception occurred
041            */
042            public void addGroupUserGroups(long groupId, long[] userGroupIds)
043                    throws com.liferay.portal.kernel.exception.PortalException,
044                            com.liferay.portal.kernel.exception.SystemException {
045                    _userGroupService.addGroupUserGroups(groupId, userGroupIds);
046            }
047    
048            /**
049            * Adds the user groups to the team
050            *
051            * @param teamId the primary key of the team
052            * @param userGroupIds the primary keys of the user groups
053            * @throws PortalException if a team or user group with the primary key
054            could not be found, or if the user did not have permission to
055            assign team members
056            * @throws SystemException if a system exception occurred
057            */
058            public void addTeamUserGroups(long teamId, long[] userGroupIds)
059                    throws com.liferay.portal.kernel.exception.PortalException,
060                            com.liferay.portal.kernel.exception.SystemException {
061                    _userGroupService.addTeamUserGroups(teamId, userGroupIds);
062            }
063    
064            /**
065            * Adds a user group.
066            *
067            * <p>
068            * This method handles the creation and bookkeeping of the user group,
069            * including its resources, metadata, and internal data structures.
070            * </p>
071            *
072            * @param name the user group's name
073            * @param description the user group's description
074            * @return the user group
075            * @throws PortalException if the user group's information was invalid or if
076            the user did not have permission to add the user group
077            * @throws SystemException if a system exception occurred
078            */
079            public com.liferay.portal.model.UserGroup addUserGroup(
080                    java.lang.String name, java.lang.String description)
081                    throws com.liferay.portal.kernel.exception.PortalException,
082                            com.liferay.portal.kernel.exception.SystemException {
083                    return _userGroupService.addUserGroup(name, description);
084            }
085    
086            /**
087            * Deletes the user group.
088            *
089            * @param userGroupId the primary key of the user group
090            * @throws PortalException if a user group with the primary key could not be
091            found, if the user did not have permission to delete the user
092            group, or if the user group had a workflow in approved status
093            * @throws SystemException if a system exception occurred
094            */
095            public void deleteUserGroup(long userGroupId)
096                    throws com.liferay.portal.kernel.exception.PortalException,
097                            com.liferay.portal.kernel.exception.SystemException {
098                    _userGroupService.deleteUserGroup(userGroupId);
099            }
100    
101            /**
102            * Returns the user group with the primary key.
103            *
104            * @param userGroupId the primary key of the user group
105            * @return Returns the user group with the primary key
106            * @throws PortalException if a user group with the primary key could not be
107            found or if the user did not have permission to view the user
108            group
109            * @throws SystemException if a system exception occurred
110            */
111            public com.liferay.portal.model.UserGroup getUserGroup(long userGroupId)
112                    throws com.liferay.portal.kernel.exception.PortalException,
113                            com.liferay.portal.kernel.exception.SystemException {
114                    return _userGroupService.getUserGroup(userGroupId);
115            }
116    
117            /**
118            * Returns the user group with the name.
119            *
120            * @param name the user group's name
121            * @return Returns the user group with the name
122            * @throws PortalException if a user group with the name could not be found
123            or if the user did not have permission to view the user group
124            * @throws SystemException if a system exception occurred
125            */
126            public com.liferay.portal.model.UserGroup getUserGroup(
127                    java.lang.String name)
128                    throws com.liferay.portal.kernel.exception.PortalException,
129                            com.liferay.portal.kernel.exception.SystemException {
130                    return _userGroupService.getUserGroup(name);
131            }
132    
133            /**
134            * Returns all the user groups to which the user belongs.
135            *
136            * @param userId the primary key of the user
137            * @return the user groups to which the user belongs
138            * @throws SystemException if a system exception occurred
139            */
140            public java.util.List<com.liferay.portal.model.UserGroup> getUserUserGroups(
141                    long userId) throws com.liferay.portal.kernel.exception.SystemException {
142                    return _userGroupService.getUserUserGroups(userId);
143            }
144    
145            /**
146            * Removes the user groups from the group.
147            *
148            * @param groupId the primary key of the group
149            * @param userGroupIds the primary keys of the user groups
150            * @throws PortalException if the user did not have permission to assign
151            group members
152            * @throws SystemException if a system exception occurred
153            */
154            public void unsetGroupUserGroups(long groupId, long[] userGroupIds)
155                    throws com.liferay.portal.kernel.exception.PortalException,
156                            com.liferay.portal.kernel.exception.SystemException {
157                    _userGroupService.unsetGroupUserGroups(groupId, userGroupIds);
158            }
159    
160            /**
161            * Removes the user groups from the team.
162            *
163            * @param teamId the primary key of the team
164            * @param userGroupIds the primary keys of the user groups
165            * @throws PortalException if the user did not have permission to assign
166            team members
167            * @throws SystemException if a system exception occurred
168            */
169            public void unsetTeamUserGroups(long teamId, long[] userGroupIds)
170                    throws com.liferay.portal.kernel.exception.PortalException,
171                            com.liferay.portal.kernel.exception.SystemException {
172                    _userGroupService.unsetTeamUserGroups(teamId, userGroupIds);
173            }
174    
175            /**
176            * Updates the user group.
177            *
178            * @param userGroupId the primary key of the user group
179            * @param name the user group's name
180            * @param description the the user group's description
181            * @return the user group
182            * @throws PortalException if a user group with the primary key was not
183            found, if the new information was invalid, or if the user did not
184            have permission to update the user group information
185            * @throws SystemException if a system exception occurred
186            */
187            public com.liferay.portal.model.UserGroup updateUserGroup(
188                    long userGroupId, java.lang.String name, java.lang.String description)
189                    throws com.liferay.portal.kernel.exception.PortalException,
190                            com.liferay.portal.kernel.exception.SystemException {
191                    return _userGroupService.updateUserGroup(userGroupId, name, description);
192            }
193    
194            /**
195             * @deprecated Renamed to {@link #getWrappedService}
196             */
197            public UserGroupService getWrappedUserGroupService() {
198                    return _userGroupService;
199            }
200    
201            /**
202             * @deprecated Renamed to {@link #setWrappedService}
203             */
204            public void setWrappedUserGroupService(UserGroupService userGroupService) {
205                    _userGroupService = userGroupService;
206            }
207    
208            public UserGroupService getWrappedService() {
209                    return _userGroupService;
210            }
211    
212            public void setWrappedService(UserGroupService userGroupService) {
213                    _userGroupService = userGroupService;
214            }
215    
216            private UserGroupService _userGroupService;
217    }