1 /*
2 * Copyright (c) 2004-2007 Creative Sphere Limited.
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Eclipse Public License v1.0
5 * which accompanies this distribution, and is available at
6 * http://www.eclipse.org/legal/epl-v10.html
7 *
8 * Contributors:
9 *
10 * Creative Sphere - initial API and implementation
11 *
12 */
13 package org.abstracthorizon.mercury.imap.util;
14
15 import org.abstracthorizon.mercury.imap.IMAPSession;
16
17 import java.io.IOException;
18
19 import javax.mail.MessagingException;
20 import javax.mail.internet.MimeMessage;
21
22 /**
23 * An interface used in processing sequence of messages
24 *
25 * @author Daniel Sendula
26 */
27 public interface MessageProcessor {
28
29 /**
30 * Method that processes mail
31 * @param session imap session
32 * @param m message
33 * @throws IOException
34 * @throws MessagingException
35 */
36 public void process(IMAPSession session, MimeMessage m) throws IOException, MessagingException;
37
38 }