Code example for PrintWriter

Methods: flush, printf

0
		this.errstream = new PrintWriter(errstream);
	} 
	 
	public void info(String message)
	{ 
		infostream.printf("%s : [INFO: %s] %s\n", (new Date()).toString(), className, message);
		infostream.flush();
	} 
	 
	public void err(String message)
	{ 
		errstream.printf("%s : [ERR: %s] %s\n", (new Date()).toString(), className, message);
		errstream.flush();
	} 
	 
	public void warn(String message)
	{ 
		infostream.printf("%s : [WARN: %s] %s\n", (new Date()).toString(), className, message);
		infostream.flush();
	}