[Biojava-l] SimpleAssembly.subList()

Thomas Down td2@sanger.ac.uk
Wed, 4 Apr 2001 16:14:04 +0100


On Wed, Apr 04, 2001 at 04:46:15PM +1200, Schreiber, Mark wrote:
> Hi -
> 
> 
> There may be a problem with the subList method of SimpleAssembly. Seems to
> give ArrayIndexOutOfBoundsExceptions. I will look into this tommorrow unless
> someone else can attain fame and glory by finding it first (Hint Hint ;-) )

Okay, there was a little bug in SimpleAssembly which was causing
NullPointerExceptions when the start of the requested list fell
in a gap in the assembly.

I'm going to refactor SimpleAssembly (which is there mainly
as an example, really) to use AssembledSymbolList behind the
scenes (AssembledSymbolList in turn started out life as a cut
and paste of SimpleAssembly -- bad, bad, idea...).  AssembledSymbolList
is used for assembly in the DAS client and the biojava-ensembl
bridge, and it seems to have had this bug fixed at some point
in the past, but it lives on in SimpleAssembly.

I haven't been able to reproduce ArrayIndexOutOfBoundsException,
though.  If you can produce a test case, please let me know.

   Thomas.

PS. I've added a range of subList tests to the seq.SimpleAssemblyTest
demo.