Java Reference
In-Depth Information
Figure 11.1: Links Between Sites
��������
���������
���������
���������
���������
���������
���������
���������
���������
Our website is site A. You can see that we have three inbound links, from sites B, C, and
D. Site B and C have no links of their own, so they are not valued terribly high by a search
engine. Site D, on the other hand, has five links of its own. As a result, site D is far more valu-
able of a link to Site A than both Site B and Site C.
This is why this recipe returns how many links each inbound link has. The inbound link
with the higher number, and therefore more links, is more valuable.
A very useful technique is to run this recipe for a competitor's web site. You will quickly
see which links are most valuable to your competitor. You can then see about getting links
from those sites to your site as well.
Listing 11.4 shows this recipe.
Listing 11.4: Scanning for Links (ScanLinks.java)
package com.heatonresearch.httprecipes.ch11.recipe1;
import com.google.soap.search.*;
import java.util.*;
Search WWH ::




Custom Search