/*
 * Created on 13.12.2004
 *
 * TODO To change the template for this generated file go to
 * Window - Preferences - Java - Code Style - Code Templates
 */
package utilities;

import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.OutputStream;
import java.io.PrintStream;

/**
 * @author Tamer
 *
 * TODO To change the template for this generated type comment go to
 * Window - Preferences - Java - Code Style - Code Templates
 */
public class Logger extends OutputStream {
	String filename;
	PrintStream w;
	public Logger(String filename) throws IOException
	{		
		try{
			File f = new File(filename);
			f.createNewFile();
			w = new PrintStream(new FileOutputStream(f));
		}catch(FileNotFoundException e){
			System.out.println();
		}
		
	}
	
	/* (non-Javadoc)
	 * @see java.io.OutputStream#write(int)
	 */
	public void write(int arg0) throws IOException {
		w.write(arg0);
	}
	public void println(String s){
		w.println(s);
	}
	
}
