1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * This library is free software; you can redistribute it and/or modify it under
5    * the terms of the GNU Lesser General Public License as published by the Free
6    * Software Foundation; either version 2.1 of the License, or (at your option)
7    * any later version.
8    *
9    * This library is distributed in the hope that it will be useful, but WITHOUT
10   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11   * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
12   * details.
13   */
14  
15  package com.liferay.mail.service;
16  
17  import com.liferay.mail.model.Filter;
18  import com.liferay.portal.kernel.annotation.Transactional;
19  import com.liferay.portal.kernel.exception.PortalException;
20  import com.liferay.portal.kernel.exception.SystemException;
21  import com.liferay.portal.kernel.mail.MailMessage;
22  
23  import java.util.List;
24  
25  import javax.mail.Session;
26  
27  @Transactional(rollbackFor = {PortalException.class, SystemException.class})
28  /**
29   * <a href="MailService.java.html"><b><i>View Source</i></b></a>
30   *
31   * @author Brian Wing Shun Chan
32   */
33  public interface MailService {
34  
35      public void addForward(
36          long companyId, long userId, List<Filter> filters,
37          List<String> emailAddresses, boolean leaveCopy);
38  
39      public void addUser(
40          long companyId, long userId, String password, String firstName,
41          String middleName, String lastName, String emailAddress);
42  
43      public void addVacationMessage(
44          long companyId, long userId, String emailAddress,
45          String vacationMessage);
46  
47      public void clearSession();
48  
49      public void deleteEmailAddress(long companyId, long userId);
50  
51      public void deleteUser(long companyId, long userId);
52  
53      public Session getSession() throws SystemException;
54  
55      public void sendEmail(MailMessage mailMessage);
56  
57      public void updateBlocked(
58          long companyId, long userId, List<String> blocked);
59  
60      public void updateEmailAddress(
61          long companyId, long userId, String emailAddress);
62  
63      public void updatePassword(long companyId, long userId, String password);
64  
65  }