public class JDrawLine extends JApplet
private int startX = 10;
private int endX = 150;
private int startY = 150;
private int endY = 250;
private class LineDrawer extends JComponent
protected void paintComponent(Graphics g)
g.drawLine(startX, startY, endX, endY);
public void init()
setLayout(new BorderLayout()); //In case you want to add additional components
add(new LineDrawer(), BorderLayout.CENTER);
I have a Masters in computer science. I can answer questions on core J2SE, swing and graphics. Please no questions about JSP or J2ME.
I have experience in Core Java, good background in Java swing/gui, some experience with JNI, Java reflection.
Some experience in bio-informatics.
Basics in c++ and c#
Washington State University
MS in Computer Science from Washington State University and a BS in Mathematics and Computer Science from Central Washington University.