package aalg.crypto;

import java.io.IOException;
import java.io.OutputStream;

public interface IStreamEncryptor extends IOutputStreamFilter {
	/**
	 * Initializes encryption.
	 * @param cipherTextStream stream for encrypted data
	 * @throws IOException 
	 */
	public void initialize(final OutputStream cipherTextStream) throws IOException;
	
	/**
	 * Finishes encryption, same as closing plaintext stream.
	 * Closes also cipherTextStream.
	 * @throws IOException 
	 */
	public void finish() throws IOException;
}
