/*-------------------------------------------------------------------------*/
/**
 [Project ]: 프레임웍 기반 그룹웨어 시제품 개발
 
 [Date] : 1999. 9. 3
 [Source file]: com/etri/groupware/mail/MailSender.java
 [Vesion] : 1.0
 */
/*--------------------------------------------------------------------------*/


package com.etri.groupware.mail;


import javax.mail.*;
import com.etri.groupware.*;


public interface ReceiveMailServerManagerInterface {
    
	
	public void connect(String host,   String id,  String password) throws Exception; 
	public void disconnect() throws Exception;
 
    public Message[] receiveMail() throws Exception; 
    public Message[] receiveMail( String srcFolder) throws Exception;
    public Message[] receiveMail( String srcFolder,  int fromIndex,  int endIndex) throws Exception; 
	
	public ResultStatus addMail(String srcFolder, Message m) throws Exception;
	public ResultStatus addMail(String srcFolder, Message[] m) throws Exception;
	
	public ResultStatus removeMail(String srcFolder, int mailNumber ) throws Exception;
	public ResultStatus removeMail(String srcFolder, int fromIndex, int endIndex) throws Exception ;
	
	public ResultStatus copyMail(String srcFolder, String dstFolder, int mailNumber) throws Exception ;
	public ResultStatus copyMail(String srcFolder, String dstFolder, int fromIndex, int endIndex) throws Exception ;
	
	public ResultStatus moveMail(String srcFolder, String dstFolder , int mailNumber ) throws Exception;
	public ResultStatus moveMail(String srcFolder, String dstFolder , int fromIndex, int endIndex ) throws Exception ;
	
	public Message[] searchMail( String srcFolder, SearchData searchData) throws Exception;
		
    public void setDebug( boolean state);
}