{
buffer.readLock();
for(int i = 0; i < selection.length; i++)
{
Selection s = selection[i];
if(s instanceof Selection.Rect)
{
for(int j = s.getStartLine();
j <= s.getEndLine(); j++)
{
resultCount += doHyperSearch(buffer,
s.getStart(buffer,j),
s.getEnd(buffer,j));
}
}
else
{
resultCount += doHyperSearch(buffer,
s.getStart(),s.getEnd());
}
}
}
finally
{