从一个网页中获取所有的超链接
|
/** import java.io.*; /** | |
|
public class HrefMatch // open reader for URL // read contents into string buffer // search for all occurrences of pattern while (matcher.find()) java HrefMatch http://www.128kj.com | |
本文介绍了一个Java程序,用于从指定的网页中提取所有超链接。该程序使用正则表达式来匹配HTML中的<a>标签,并从中抽取链接地址。

4404

被折叠的 条评论
为什么被折叠?



