I have some HTML code below, I want to do the following in Java, anyone can help?
For each <table></table>, it will set the array's i position, get the data from each <td></td>, then store it in an array's j position
So finally, I will get a 2D array, e.g. array[i][j]
array[0][0] = Index
array[0][1] = CM MAC
array[0][2] = Uid
array[0][3] = IP
array[0][4] = RX
array[0][5] = TX
array[0][6] = SNR
array[1][0] = 003
array[1][1] = 000CE52A7788
array[1][2] = Upstream 1
array[1][3] = 10.113.184.32
array[1][4] = -7.1
array[1][5] = 59.3
array[1][6] = 36.1
etc
<HTML>
<HEAD> <TITLE>CMTS ABE0C0508BSR Monitor</TITLE> </HEAD>
<H1><CENTER>ABE0C0508BSR</H1></CENTER><HR>
<PRE>
<center>
<table border='0' width='70%'>
<tr bgcolor='#F7EDA6' FONT="courier">
<td width='8%' align='center'>Index</td>
<td width='20%' align='center'>CM MAC</td>
<td width='20%' align='center'>Uid</td>
<td width='22%' align='center'>IP</td>
<td width='10%' align='center'>RX</td>
<td width='10%' align='center'>TX</td>
<td width='10%' align='center'>SNR</td>
</tr>
</table>
<table border='0' width='70%'>
<tr bgcolor='#b4b4b4'>
<td width='8%' align='center'>0003</td>
<td width='20%' align='center'>000CE52A7788</td>
<td width='20%' align='center'>Upstream 1</td>
<td width='22%' align='center'>10.113.184.32</td>
<td width='10%' align='center'>-7.1</td>
<td width='10%' align='center'>59.3</td>
<td width='10%' align='center'>36.1</td>
</tr>
</table>
<table border='0' width='70%'>
<tr bgcolor='#b4b4b4'>
<td width='8%' align='center'>0005</td>
<td width='20%' align='center'>000E5CE42AF2</td>
<td width='20%' align='center'>Upstream 0</td>
<td width='22%' align='center'>10.113.184.86</td>
<td width='10%' align='center'>-2.1</td>
<td width='10%' align='center'>58.5</td>
<td width='10%' align='center'>36.2</td>
</tr>
</table>
Select all Open in new window