package exploringjava.contenthandlers.application;
import java.net.*;
import java.io.*;
import java.util.Date;
import java.awt.*;
public class x_foo extends ContentHandler {
public Object getContent(URLConnection uc) throws IOException {
System.err.println("Foo!");
URL url = getClass().getResource("foo.gif");
System.err.println("Foo2!");
Image img = Toolkit.getDefaultToolkit().getImage(url);
System.err.println("Foo3!");
System.err.println(img);
System.err.println("Foo4!");
return img;
}
}
|