1   /**
2    * Copyright (c) 2000-2007 Liferay, Inc. All rights reserved.
3    *
4    * Permission is hereby granted, free of charge, to any person obtaining a copy
5    * of this software and associated documentation files (the "Software"), to deal
6    * in the Software without restriction, including without limitation the rights
7    * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8    * copies of the Software, and to permit persons to whom the Software is
9    * furnished to do so, subject to the following conditions:
10   *
11   * The above copyright notice and this permission notice shall be included in
12   * all copies or substantial portions 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.portal.service;
24  
25  /**
26   * <a href="UserLocalService.java.html"><b><i>View Source</i></b></a>
27   *
28   * <p>
29   * ServiceBuilder generated this class. Modifications in this class will be overwritten
30   * the next time is generated.
31   * </p>
32   *
33   * <p>
34   * This interface defines the service. The default implementation is <code>com.liferay.portal.service.impl.UserLocalServiceImpl</code>.
35   * Modify methods in that class and rerun ServiceBuilder to populate this class
36   * and all other generated classes.
37   * </p>
38   *
39   * <p>
40   * This is a local service. Methods of this service will not have security checks
41   * based on the propagated JAAS credentials because this service can only be accessed
42   * from within the same VM.
43   * </p>
44   *
45   * @author Brian Wing Shun Chan
46   *
47   * @see com.liferay.portal.service.UserServiceFactory
48   * @see com.liferay.portal.service.UserServiceUtil
49   *
50   */
51  public interface UserLocalService {
52      public com.liferay.portal.model.User addUser(
53          com.liferay.portal.model.User model)
54          throws com.liferay.portal.SystemException;
55  
56      public java.util.List dynamicQuery(
57          com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer)
58          throws com.liferay.portal.SystemException;
59  
60      public java.util.List dynamicQuery(
61          com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer,
62          int begin, int end) throws com.liferay.portal.SystemException;
63  
64      public com.liferay.portal.model.User updateUser(
65          com.liferay.portal.model.User model)
66          throws com.liferay.portal.SystemException;
67  
68      public void addGroupUsers(long groupId, long[] userIds)
69          throws com.liferay.portal.SystemException, 
70              com.liferay.portal.PortalException;
71  
72      public void addPasswordPolicyUsers(long passwordPolicyId, long[] userIds)
73          throws com.liferay.portal.SystemException, 
74              com.liferay.portal.PortalException;
75  
76      public void addRoleUsers(long roleId, long[] userIds)
77          throws com.liferay.portal.SystemException, 
78              com.liferay.portal.PortalException;
79  
80      public void addUserGroupUsers(long userGroupId, long[] userIds)
81          throws com.liferay.portal.SystemException, 
82              com.liferay.portal.PortalException;
83  
84      public com.liferay.portal.model.User addUser(long creatorUserId,
85          long companyId, boolean autoPassword, java.lang.String password1,
86          java.lang.String password2, boolean autoScreenName,
87          java.lang.String screenName, java.lang.String emailAddress,
88          java.util.Locale locale, java.lang.String firstName,
89          java.lang.String middleName, java.lang.String lastName, int prefixId,
90          int suffixId, boolean male, int birthdayMonth, int birthdayDay,
91          int birthdayYear, java.lang.String jobTitle, long organizationId,
92          long locationId, boolean sendEmail)
93          throws com.liferay.portal.SystemException, 
94              com.liferay.portal.PortalException;
95  
96      public int authenticateByEmailAddress(long companyId,
97          java.lang.String emailAddress, java.lang.String password,
98          java.util.Map headerMap, java.util.Map parameterMap)
99          throws com.liferay.portal.SystemException, 
100             com.liferay.portal.PortalException;
101 
102     public int authenticateByScreenName(long companyId,
103         java.lang.String screenName, java.lang.String password,
104         java.util.Map headerMap, java.util.Map parameterMap)
105         throws com.liferay.portal.SystemException, 
106             com.liferay.portal.PortalException;
107 
108     public int authenticateByUserId(long companyId, long userId,
109         java.lang.String password, java.util.Map headerMap,
110         java.util.Map parameterMap)
111         throws com.liferay.portal.SystemException, 
112             com.liferay.portal.PortalException;
113 
114     public boolean authenticateForJAAS(long userId, java.lang.String encPwd)
115         throws com.liferay.portal.SystemException, 
116             com.liferay.portal.PortalException;
117 
118     public void checkLockout(com.liferay.portal.model.User user)
119         throws com.liferay.portal.SystemException, 
120             com.liferay.portal.PortalException;
121 
122     public void checkLoginFailure(com.liferay.portal.model.User user)
123         throws com.liferay.portal.SystemException, 
124             com.liferay.portal.PortalException;
125 
126     public void checkLoginFailureByEmailAddress(long companyId,
127         java.lang.String emailAddress)
128         throws com.liferay.portal.SystemException, 
129             com.liferay.portal.PortalException;
130 
131     public void checkLoginFailureById(long userId)
132         throws com.liferay.portal.SystemException, 
133             com.liferay.portal.PortalException;
134 
135     public void checkLoginFailureByScreenName(long companyId,
136         java.lang.String screenName)
137         throws com.liferay.portal.SystemException, 
138             com.liferay.portal.PortalException;
139 
140     public void checkPasswordExpired(com.liferay.portal.model.User user)
141         throws com.liferay.portal.SystemException, 
142             com.liferay.portal.PortalException;
143 
144     public void clearUserGroupUsers(long userGroupId)
145         throws com.liferay.portal.SystemException, 
146             com.liferay.portal.PortalException;
147 
148     public com.liferay.portal.kernel.util.KeyValuePair decryptUserId(
149         long companyId, java.lang.String name, java.lang.String password)
150         throws com.liferay.portal.SystemException, 
151             com.liferay.portal.PortalException;
152 
153     public void deletePasswordPolicyUser(long passwordPolicyId, long userId)
154         throws com.liferay.portal.SystemException, 
155             com.liferay.portal.PortalException;
156 
157     public void deleteRoleUser(long roleId, long userId)
158         throws com.liferay.portal.SystemException, 
159             com.liferay.portal.PortalException;
160 
161     public void deleteUser(long userId)
162         throws com.liferay.portal.SystemException, 
163             com.liferay.portal.PortalException;
164 
165     public java.lang.String encryptUserId(java.lang.String name)
166         throws com.liferay.portal.SystemException, 
167             com.liferay.portal.PortalException;
168 
169     public com.liferay.portal.model.User getDefaultUser(long companyId)
170         throws com.liferay.portal.SystemException, 
171             com.liferay.portal.PortalException;
172 
173     public long getDefaultUserId(long companyId)
174         throws com.liferay.portal.SystemException, 
175             com.liferay.portal.PortalException;
176 
177     public java.util.List getGroupUsers(long groupId)
178         throws com.liferay.portal.SystemException, 
179             com.liferay.portal.PortalException;
180 
181     public java.util.List getPermissionUsers(long companyId, long groupId,
182         java.lang.String name, java.lang.String primKey,
183         java.lang.String actionId, java.lang.String firstName,
184         java.lang.String middleName, java.lang.String lastName,
185         java.lang.String emailAddress, boolean andOperator, int begin, int end)
186         throws com.liferay.portal.SystemException, 
187             com.liferay.portal.PortalException;
188 
189     public int getPermissionUsersCount(long companyId, long groupId,
190         java.lang.String name, java.lang.String primKey,
191         java.lang.String actionId, java.lang.String firstName,
192         java.lang.String middleName, java.lang.String lastName,
193         java.lang.String emailAddress, boolean andOperator)
194         throws com.liferay.portal.SystemException, 
195             com.liferay.portal.PortalException;
196 
197     public java.util.List getRoleUsers(long roleId)
198         throws com.liferay.portal.SystemException, 
199             com.liferay.portal.PortalException;
200 
201     public java.util.List getUserGroupUsers(long userGroupId)
202         throws com.liferay.portal.SystemException, 
203             com.liferay.portal.PortalException;
204 
205     public com.liferay.portal.model.User getUserByContactId(long contactId)
206         throws com.liferay.portal.SystemException, 
207             com.liferay.portal.PortalException;
208 
209     public com.liferay.portal.model.User getUserByEmailAddress(long companyId,
210         java.lang.String emailAddress)
211         throws com.liferay.portal.SystemException, 
212             com.liferay.portal.PortalException;
213 
214     public com.liferay.portal.model.User getUserById(long userId)
215         throws com.liferay.portal.SystemException, 
216             com.liferay.portal.PortalException;
217 
218     public com.liferay.portal.model.User getUserById(long companyId, long userId)
219         throws com.liferay.portal.SystemException, 
220             com.liferay.portal.PortalException;
221 
222     public com.liferay.portal.model.User getUserByPortraitId(long portraitId)
223         throws com.liferay.portal.SystemException, 
224             com.liferay.portal.PortalException;
225 
226     public com.liferay.portal.model.User getUserByScreenName(long companyId,
227         java.lang.String screenName)
228         throws com.liferay.portal.SystemException, 
229             com.liferay.portal.PortalException;
230 
231     public long getUserIdByEmailAddress(long companyId,
232         java.lang.String emailAddress)
233         throws com.liferay.portal.SystemException, 
234             com.liferay.portal.PortalException;
235 
236     public long getUserIdByScreenName(long companyId,
237         java.lang.String screenName)
238         throws com.liferay.portal.SystemException, 
239             com.liferay.portal.PortalException;
240 
241     public boolean hasGroupUser(long groupId, long userId)
242         throws com.liferay.portal.SystemException, 
243             com.liferay.portal.PortalException;
244 
245     public boolean hasPasswordPolicyUser(long passwordPolicyId, long userId)
246         throws com.liferay.portal.SystemException, 
247             com.liferay.portal.PortalException;
248 
249     public boolean hasRoleUser(long roleId, long userId)
250         throws com.liferay.portal.SystemException, 
251             com.liferay.portal.PortalException;
252 
253     public boolean hasUserGroupUser(long userGroupId, long userId)
254         throws com.liferay.portal.SystemException, 
255             com.liferay.portal.PortalException;
256 
257     public boolean isPasswordExpired(com.liferay.portal.model.User user)
258         throws com.liferay.portal.SystemException, 
259             com.liferay.portal.PortalException;
260 
261     public boolean isPasswordExpiringSoon(com.liferay.portal.model.User user)
262         throws com.liferay.portal.SystemException, 
263             com.liferay.portal.PortalException;
264 
265     public java.util.List search(long companyId, java.lang.String keywords,
266         java.lang.Boolean active, java.util.LinkedHashMap params, int begin,
267         int end, com.liferay.portal.kernel.util.OrderByComparator obc)
268         throws com.liferay.portal.SystemException;
269 
270     public java.util.List search(long companyId, java.lang.String firstName,
271         java.lang.String middleName, java.lang.String lastName,
272         java.lang.String screenName, java.lang.String emailAddress,
273         java.lang.Boolean active, java.util.LinkedHashMap params,
274         boolean andSearch, int begin, int end,
275         com.liferay.portal.kernel.util.OrderByComparator obc)
276         throws com.liferay.portal.SystemException;
277 
278     public int searchCount(long companyId, java.lang.String keywords,
279         java.lang.Boolean active, java.util.LinkedHashMap params)
280         throws com.liferay.portal.SystemException;
281 
282     public int searchCount(long companyId, java.lang.String firstName,
283         java.lang.String middleName, java.lang.String lastName,
284         java.lang.String screenName, java.lang.String emailAddress,
285         java.lang.Boolean active, java.util.LinkedHashMap params,
286         boolean andSearch) throws com.liferay.portal.SystemException;
287 
288     public void sendPassword(long companyId, java.lang.String emailAddress,
289         java.lang.String remoteAddr, java.lang.String remoteHost,
290         java.lang.String userAgent)
291         throws com.liferay.portal.SystemException, 
292             com.liferay.portal.PortalException;
293 
294     public void setGroupUsers(long groupId, long[] userIds)
295         throws com.liferay.portal.SystemException, 
296             com.liferay.portal.PortalException;
297 
298     public void setRoleUsers(long roleId, long[] userIds)
299         throws com.liferay.portal.SystemException, 
300             com.liferay.portal.PortalException;
301 
302     public void setUserGroupUsers(long userGroupId, long[] userIds)
303         throws com.liferay.portal.SystemException, 
304             com.liferay.portal.PortalException;
305 
306     public void unsetGroupUsers(long groupId, long[] userIds)
307         throws com.liferay.portal.SystemException, 
308             com.liferay.portal.PortalException;
309 
310     public void unsetPasswordPolicyUsers(long passwordPolicyId, long[] userIds)
311         throws com.liferay.portal.SystemException, 
312             com.liferay.portal.PortalException;
313 
314     public void unsetRoleUsers(long roleId, long[] userIds)
315         throws com.liferay.portal.SystemException, 
316             com.liferay.portal.PortalException;
317 
318     public void unsetUserGroupUsers(long userGroupId, long[] userIds)
319         throws com.liferay.portal.SystemException, 
320             com.liferay.portal.PortalException;
321 
322     public com.liferay.portal.model.User updateActive(long userId,
323         boolean active)
324         throws com.liferay.portal.SystemException, 
325             com.liferay.portal.PortalException;
326 
327     public com.liferay.portal.model.User updateAgreedToTermsOfUse(long userId,
328         boolean agreedToTermsOfUse)
329         throws com.liferay.portal.SystemException, 
330             com.liferay.portal.PortalException;
331 
332     public com.liferay.portal.model.User updateCreateDate(long userId,
333         java.util.Date createDate)
334         throws com.liferay.portal.SystemException, 
335             com.liferay.portal.PortalException;
336 
337     public com.liferay.portal.model.User updateLastLogin(long userId,
338         java.lang.String loginIP)
339         throws com.liferay.portal.SystemException, 
340             com.liferay.portal.PortalException;
341 
342     public com.liferay.portal.model.User updateLockout(
343         com.liferay.portal.model.User user, boolean lockout)
344         throws com.liferay.portal.SystemException, 
345             com.liferay.portal.PortalException;
346 
347     public com.liferay.portal.model.User updateLockoutByEmailAddress(
348         long companyId, java.lang.String emailAddress, boolean lockout)
349         throws com.liferay.portal.SystemException, 
350             com.liferay.portal.PortalException;
351 
352     public com.liferay.portal.model.User updateLockoutById(long userId,
353         boolean lockout)
354         throws com.liferay.portal.SystemException, 
355             com.liferay.portal.PortalException;
356 
357     public com.liferay.portal.model.User updateLockoutByScreenName(
358         long companyId, java.lang.String screenName, boolean lockout)
359         throws com.liferay.portal.SystemException, 
360             com.liferay.portal.PortalException;
361 
362     public com.liferay.portal.model.User updateModifiedDate(long userId,
363         java.util.Date modifiedDate)
364         throws com.liferay.portal.SystemException, 
365             com.liferay.portal.PortalException;
366 
367     public void updateOrganizations(long userId, long organizationId,
368         long locationId)
369         throws com.liferay.portal.SystemException, 
370             com.liferay.portal.PortalException;
371 
372     public com.liferay.portal.model.User updatePassword(long userId,
373         java.lang.String password1, java.lang.String password2,
374         boolean passwordReset)
375         throws com.liferay.portal.SystemException, 
376             com.liferay.portal.PortalException;
377 
378     public com.liferay.portal.model.User updatePassword(long userId,
379         java.lang.String password1, java.lang.String password2,
380         boolean passwordReset, boolean silentUpdate)
381         throws com.liferay.portal.SystemException, 
382             com.liferay.portal.PortalException;
383 
384     public com.liferay.portal.model.User updatePasswordManually(long userId,
385         java.lang.String password, boolean passwordEncrypted,
386         boolean passwordReset, java.util.Date passwordModifiedDate)
387         throws com.liferay.portal.SystemException, 
388             com.liferay.portal.PortalException;
389 
390     public void updatePasswordReset(long userId, boolean passwordReset)
391         throws com.liferay.portal.SystemException, 
392             com.liferay.portal.PortalException;
393 
394     public void updatePortrait(long userId, byte[] bytes)
395         throws com.liferay.portal.SystemException, 
396             com.liferay.portal.PortalException;
397 
398     public com.liferay.portal.model.User updateUser(long userId,
399         java.lang.String password, java.lang.String screenName,
400         java.lang.String emailAddress, java.lang.String languageId,
401         java.lang.String timeZoneId, java.lang.String greeting,
402         java.lang.String comments, java.lang.String firstName,
403         java.lang.String middleName, java.lang.String lastName, int prefixId,
404         int suffixId, boolean male, int birthdayMonth, int birthdayDay,
405         int birthdayYear, java.lang.String smsSn, java.lang.String aimSn,
406         java.lang.String icqSn, java.lang.String jabberSn,
407         java.lang.String msnSn, java.lang.String skypeSn,
408         java.lang.String ymSn, java.lang.String jobTitle, long organizationId,
409         long locationId)
410         throws com.liferay.portal.SystemException, 
411             com.liferay.portal.PortalException;
412 }