一道很好的java练习题

WWJ1118 2006-03-09 03:28:26
Use the following as a hint:

public class Strathzilla extends JFrame {
public Strathzilla(String urlAsString) throws Exception {
JEditorPane htmlRenderer = new JEditorPane();
getContentPane().add(htmlRenderer);
setVisible(true);
setSize(300,200);
htmlRenderer.setContentType("text/html"); // retrieve page htmlRenderer.setText(page); // rest of your code
}

要求:
Convert the GET web page retrieval code into a mini web browser by instead of printing out the retrived html, injecting it into a JEditorPane

Create a Java program that retrieves and prints out a webpage using the GET method. Pass in the required URL via command line arguement.
...全文
430 10 打赏 收藏 转发到动态 举报
写回复
用AI写文章
10 条回复
切换为时间正序
请发表友善的回复…
发表回复
aaa2003gf 2006-03-13
  • 打赏
  • 举报
回复
GUI中使用WEB
chw8219 2006-03-13
  • 打赏
  • 举报
回复
不会,顶一下!
pingpingx 2006-03-13
  • 打赏
  • 举报
回复
我也不太明白
xb8254 2006-03-13
  • 打赏
  • 举报
回复
up
Loveflys 2006-03-13
  • 打赏
  • 举报
回复
把窗体作成html?
kuzhu 2006-03-10
  • 打赏
  • 举报
回复
什么意思,用java做一个web browser?
pingpingx 2006-03-10
  • 打赏
  • 举报
回复
up
juror 2006-03-10
  • 打赏
  • 举报
回复
serverlet?
zhao_417 2006-03-10
  • 打赏
  • 举报
回复
不会
需要加强
zx2002027 2006-03-09
  • 打赏
  • 举报
回复
UP

62,614

社区成员

发帖
与我相关
我的任务
社区描述
Java 2 Standard Edition
社区管理员
  • Java SE
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧