001    /**
002     * Copyright (c) 2000-2010 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    import com.liferay.portal.kernel.annotation.Isolation;
018    import com.liferay.portal.kernel.annotation.Propagation;
019    import com.liferay.portal.kernel.annotation.Transactional;
020    import com.liferay.portal.kernel.exception.PortalException;
021    import com.liferay.portal.kernel.exception.SystemException;
022    
023    /**
024     * <p>
025     * This interface defines the service. The default implementation is
026     * {@link
027     * com.liferay.portal.service.impl.GroupLocalServiceImpl}.
028     * Modify methods in that class and rerun ServiceBuilder to populate this class
029     * and all other generated classes.
030     * </p>
031     *
032     * <p>
033     * This is a local service. Methods of this service will not have security checks based on the propagated JAAS credentials because this service can only be accessed from within the same VM.
034     * </p>
035     *
036     * @author    Brian Wing Shun Chan
037     * @see       GroupLocalServiceUtil
038     * @generated
039     */
040    @Transactional(isolation = Isolation.PORTAL, rollbackFor =  {
041            PortalException.class, SystemException.class})
042    public interface GroupLocalService {
043            public com.liferay.portal.model.Group addGroup(
044                    com.liferay.portal.model.Group group)
045                    throws com.liferay.portal.kernel.exception.SystemException;
046    
047            public com.liferay.portal.model.Group createGroup(long groupId);
048    
049            public void deleteGroup(long groupId)
050                    throws com.liferay.portal.kernel.exception.PortalException,
051                            com.liferay.portal.kernel.exception.SystemException;
052    
053            public void deleteGroup(com.liferay.portal.model.Group group)
054                    throws com.liferay.portal.kernel.exception.SystemException;
055    
056            @SuppressWarnings("unchecked")
057            public java.util.List dynamicQuery(
058                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
059                    throws com.liferay.portal.kernel.exception.SystemException;
060    
061            @SuppressWarnings("unchecked")
062            public java.util.List dynamicQuery(
063                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
064                    int end) throws com.liferay.portal.kernel.exception.SystemException;
065    
066            @SuppressWarnings("unchecked")
067            public java.util.List dynamicQuery(
068                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
069                    int end,
070                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
071                    throws com.liferay.portal.kernel.exception.SystemException;
072    
073            public long dynamicQueryCount(
074                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
075                    throws com.liferay.portal.kernel.exception.SystemException;
076    
077            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
078            public com.liferay.portal.model.Group getGroup(long groupId)
079                    throws com.liferay.portal.kernel.exception.PortalException,
080                            com.liferay.portal.kernel.exception.SystemException;
081    
082            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
083            public java.util.List<com.liferay.portal.model.Group> getGroups(int start,
084                    int end) throws com.liferay.portal.kernel.exception.SystemException;
085    
086            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
087            public int getGroupsCount()
088                    throws com.liferay.portal.kernel.exception.SystemException;
089    
090            public com.liferay.portal.model.Group updateGroup(
091                    com.liferay.portal.model.Group group)
092                    throws com.liferay.portal.kernel.exception.SystemException;
093    
094            public com.liferay.portal.model.Group updateGroup(
095                    com.liferay.portal.model.Group group, boolean merge)
096                    throws com.liferay.portal.kernel.exception.SystemException;
097    
098            public com.liferay.portal.model.Group addGroup(long userId,
099                    java.lang.String className, long classPK, java.lang.String name,
100                    java.lang.String description, int type, java.lang.String friendlyURL,
101                    boolean active, com.liferay.portal.service.ServiceContext serviceContext)
102                    throws com.liferay.portal.kernel.exception.PortalException,
103                            com.liferay.portal.kernel.exception.SystemException;
104    
105            public com.liferay.portal.model.Group addGroup(long userId,
106                    java.lang.String className, long classPK, long liveGroupId,
107                    java.lang.String name, java.lang.String description, int type,
108                    java.lang.String friendlyURL, boolean active,
109                    com.liferay.portal.service.ServiceContext serviceContext)
110                    throws com.liferay.portal.kernel.exception.PortalException,
111                            com.liferay.portal.kernel.exception.SystemException;
112    
113            public void addRoleGroups(long roleId, long[] groupIds)
114                    throws com.liferay.portal.kernel.exception.SystemException;
115    
116            public void addUserGroups(long userId, long[] groupIds)
117                    throws com.liferay.portal.kernel.exception.SystemException;
118    
119            public void checkCompanyGroup(long companyId)
120                    throws com.liferay.portal.kernel.exception.PortalException,
121                            com.liferay.portal.kernel.exception.SystemException;
122    
123            public void checkSystemGroups(long companyId)
124                    throws com.liferay.portal.kernel.exception.PortalException,
125                            com.liferay.portal.kernel.exception.SystemException;
126    
127            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
128            public com.liferay.portal.model.Group getCompanyGroup(long companyId)
129                    throws com.liferay.portal.kernel.exception.PortalException,
130                            com.liferay.portal.kernel.exception.SystemException;
131    
132            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
133            public java.util.List<com.liferay.portal.model.Group> getCompanyGroups(
134                    long companyId, int start, int end)
135                    throws com.liferay.portal.kernel.exception.SystemException;
136    
137            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
138            public int getCompanyGroupsCount(long companyId)
139                    throws com.liferay.portal.kernel.exception.SystemException;
140    
141            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
142            public com.liferay.portal.model.Group getFriendlyURLGroup(long companyId,
143                    java.lang.String friendlyURL)
144                    throws com.liferay.portal.kernel.exception.PortalException,
145                            com.liferay.portal.kernel.exception.SystemException;
146    
147            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
148            public com.liferay.portal.model.Group getGroup(long companyId,
149                    java.lang.String name)
150                    throws com.liferay.portal.kernel.exception.PortalException,
151                            com.liferay.portal.kernel.exception.SystemException;
152    
153            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
154            public java.util.List<com.liferay.portal.model.Group> getGroups(
155                    long[] groupIds)
156                    throws com.liferay.portal.kernel.exception.PortalException,
157                            com.liferay.portal.kernel.exception.SystemException;
158    
159            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
160            public com.liferay.portal.model.Group getLayoutGroup(long companyId,
161                    long plid)
162                    throws com.liferay.portal.kernel.exception.PortalException,
163                            com.liferay.portal.kernel.exception.SystemException;
164    
165            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
166            public com.liferay.portal.model.Group getLayoutPrototypeGroup(
167                    long companyId, long layoutPrototypeId)
168                    throws com.liferay.portal.kernel.exception.PortalException,
169                            com.liferay.portal.kernel.exception.SystemException;
170    
171            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
172            public com.liferay.portal.model.Group getLayoutSetPrototypeGroup(
173                    long companyId, long layoutSetPrototypeId)
174                    throws com.liferay.portal.kernel.exception.PortalException,
175                            com.liferay.portal.kernel.exception.SystemException;
176    
177            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
178            public java.util.List<com.liferay.portal.model.Group> getLiveGroups()
179                    throws com.liferay.portal.kernel.exception.SystemException;
180    
181            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
182            public java.util.List<com.liferay.portal.model.Group> getNoLayoutsGroups(
183                    java.lang.String className, boolean privateLayout, int start, int end)
184                    throws com.liferay.portal.kernel.exception.SystemException;
185    
186            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
187            public java.util.List<com.liferay.portal.model.Group> getNullFriendlyURLGroups()
188                    throws com.liferay.portal.kernel.exception.SystemException;
189    
190            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
191            public com.liferay.portal.model.Group getOrganizationGroup(long companyId,
192                    long organizationId)
193                    throws com.liferay.portal.kernel.exception.PortalException,
194                            com.liferay.portal.kernel.exception.SystemException;
195    
196            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
197            public java.util.List<com.liferay.portal.model.Group> getOrganizationsGroups(
198                    java.util.List<com.liferay.portal.model.Organization> organizations);
199    
200            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
201            public java.util.List<com.liferay.portal.model.Group> getOrganizationsRelatedGroups(
202                    java.util.List<com.liferay.portal.model.Organization> organizations)
203                    throws com.liferay.portal.kernel.exception.SystemException;
204    
205            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
206            public java.util.List<com.liferay.portal.model.Group> getRoleGroups(
207                    long roleId) throws com.liferay.portal.kernel.exception.SystemException;
208    
209            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
210            public com.liferay.portal.model.Group getStagingGroup(long liveGroupId)
211                    throws com.liferay.portal.kernel.exception.PortalException,
212                            com.liferay.portal.kernel.exception.SystemException;
213    
214            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
215            public com.liferay.portal.model.Group getUserGroup(long companyId,
216                    long userId)
217                    throws com.liferay.portal.kernel.exception.PortalException,
218                            com.liferay.portal.kernel.exception.SystemException;
219    
220            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
221            public com.liferay.portal.model.Group getUserGroupGroup(long companyId,
222                    long userGroupId)
223                    throws com.liferay.portal.kernel.exception.PortalException,
224                            com.liferay.portal.kernel.exception.SystemException;
225    
226            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
227            public java.util.List<com.liferay.portal.model.Group> getUserGroups(
228                    long userId)
229                    throws com.liferay.portal.kernel.exception.PortalException,
230                            com.liferay.portal.kernel.exception.SystemException;
231    
232            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
233            public java.util.List<com.liferay.portal.model.Group> getUserGroups(
234                    long userId, boolean inherit)
235                    throws com.liferay.portal.kernel.exception.PortalException,
236                            com.liferay.portal.kernel.exception.SystemException;
237    
238            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
239            public java.util.List<com.liferay.portal.model.Group> getUserGroups(
240                    long userId, int start, int end)
241                    throws com.liferay.portal.kernel.exception.PortalException,
242                            com.liferay.portal.kernel.exception.SystemException;
243    
244            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
245            public java.util.List<com.liferay.portal.model.Group> getUserGroups(
246                    long userId, boolean inherit, int start, int end)
247                    throws com.liferay.portal.kernel.exception.PortalException,
248                            com.liferay.portal.kernel.exception.SystemException;
249    
250            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
251            public java.util.List<com.liferay.portal.model.Group> getUserGroupsGroups(
252                    java.util.List<com.liferay.portal.model.UserGroup> userGroups)
253                    throws com.liferay.portal.kernel.exception.PortalException,
254                            com.liferay.portal.kernel.exception.SystemException;
255    
256            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
257            public java.util.List<com.liferay.portal.model.Group> getUserGroupsRelatedGroups(
258                    java.util.List<com.liferay.portal.model.UserGroup> userGroups)
259                    throws com.liferay.portal.kernel.exception.SystemException;
260    
261            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
262            public java.util.List<com.liferay.portal.model.Group> getUserOrganizationsGroups(
263                    long userId, int start, int end)
264                    throws com.liferay.portal.kernel.exception.PortalException,
265                            com.liferay.portal.kernel.exception.SystemException;
266    
267            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
268            public boolean hasRoleGroup(long roleId, long groupId)
269                    throws com.liferay.portal.kernel.exception.SystemException;
270    
271            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
272            public boolean hasStagingGroup(long liveGroupId)
273                    throws com.liferay.portal.kernel.exception.SystemException;
274    
275            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
276            public boolean hasUserGroup(long userId, long groupId)
277                    throws com.liferay.portal.kernel.exception.SystemException;
278    
279            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
280            public java.util.List<com.liferay.portal.model.Group> search(
281                    long companyId, java.lang.String name, java.lang.String description,
282                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params,
283                    int start, int end)
284                    throws com.liferay.portal.kernel.exception.SystemException;
285    
286            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
287            public java.util.List<com.liferay.portal.model.Group> search(
288                    long companyId, java.lang.String name, java.lang.String description,
289                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params,
290                    int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
291                    throws com.liferay.portal.kernel.exception.SystemException;
292    
293            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
294            public int searchCount(long companyId, java.lang.String name,
295                    java.lang.String description,
296                    java.util.LinkedHashMap<java.lang.String, java.lang.Object> params)
297                    throws com.liferay.portal.kernel.exception.SystemException;
298    
299            public void setRoleGroups(long roleId, long[] groupIds)
300                    throws com.liferay.portal.kernel.exception.SystemException;
301    
302            public void unsetRoleGroups(long roleId, long[] groupIds)
303                    throws com.liferay.portal.kernel.exception.SystemException;
304    
305            public void unsetUserGroups(long userId, long[] groupIds)
306                    throws com.liferay.portal.kernel.exception.SystemException;
307    
308            public void updateAsset(long userId, com.liferay.portal.model.Group group,
309                    long[] assetCategoryIds, java.lang.String[] assetTagNames)
310                    throws com.liferay.portal.kernel.exception.PortalException,
311                            com.liferay.portal.kernel.exception.SystemException;
312    
313            public com.liferay.portal.model.Group updateFriendlyURL(long groupId,
314                    java.lang.String friendlyURL)
315                    throws com.liferay.portal.kernel.exception.PortalException,
316                            com.liferay.portal.kernel.exception.SystemException;
317    
318            public com.liferay.portal.model.Group updateGroup(long groupId,
319                    java.lang.String name, java.lang.String description, int type,
320                    java.lang.String friendlyURL, boolean active,
321                    com.liferay.portal.service.ServiceContext serviceContext)
322                    throws com.liferay.portal.kernel.exception.PortalException,
323                            com.liferay.portal.kernel.exception.SystemException;
324    
325            public com.liferay.portal.model.Group updateGroup(long groupId,
326                    java.lang.String typeSettings)
327                    throws com.liferay.portal.kernel.exception.PortalException,
328                            com.liferay.portal.kernel.exception.SystemException;
329    
330            public com.liferay.portal.model.Group updateWorkflow(long groupId,
331                    boolean workflowEnabled, int workflowStages,
332                    java.lang.String workflowRoleNames)
333                    throws com.liferay.portal.kernel.exception.PortalException,
334                            com.liferay.portal.kernel.exception.SystemException;
335    }