Fixed bug where read traversals would fail with an exception when not called with a genome_region (-L) argument. From TraversalEngine, line 455, looks like Mark intended an invariant where the list of locations is 0 length if not specified. Made GenomeLoc code compliant with that.
git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@230 348d0f76-0448-11de-a6fe-93d51630548a
This commit is contained in:
parent
e812cfbf55
commit
7fda409f4e
|
|
@ -252,7 +252,7 @@ public class GenomeLoc implements Comparable<GenomeLoc> {
|
|||
* @return true if we are past the last location to process
|
||||
*/
|
||||
public static boolean pastFinalLocation(GenomeLoc curr, ArrayList<GenomeLoc> locs) {
|
||||
if ( locs == null )
|
||||
if ( locs.size() == 0 )
|
||||
return false;
|
||||
else {
|
||||
GenomeLoc last = locs.get(locs.size() - 1);
|
||||
|
|
@ -268,7 +268,7 @@ public class GenomeLoc implements Comparable<GenomeLoc> {
|
|||
* @return true if we should process GenomeLoc curr, otherwise false
|
||||
*/
|
||||
public static boolean inLocations(GenomeLoc curr, ArrayList<GenomeLoc> locs) {
|
||||
if (locs == null) {
|
||||
if ( locs.size() == 0 ) {
|
||||
return true;
|
||||
} else {
|
||||
for ( GenomeLoc loc : locs ) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue