package net.y3n20u.aeszip;

import java.io.File;

import de.idyl.crypto.zip.AesZipFileEncrypter;

public class ExternalEncrypterImpl implements ExternalEncrypter {
	private AesZipFileEncrypter enc;

	@Override
	public void setDestination(String destination) throws Exception {
		enc = new AesZipFileEncrypter(destination);
	}
	
	@Override
	public void archive() throws Exception {
		enc.close();
	}

	@Override
	public void add(String name, File file, String password) throws Exception {
		enc.add(file, name, password);
	}

}
