Skip to content

Commit

Permalink
Fix for exception in default exportClones.
Browse files Browse the repository at this point in the history
  • Loading branch information
dbolotin committed Jan 31, 2017
1 parent 0fcaafd commit c369a10
Showing 1 changed file with 9 additions and 4 deletions.
Expand Up @@ -31,10 +31,6 @@ void validate(GeneFeature[] features) {
if (features.length == 2 && !features[1].contains(features[0]))
throw new IllegalArgumentException(String.format("%s: Base feature %s does not contain relative feature %s",
command, GeneFeature.encode(features[1]), GeneFeature.encode(features[0])));
for (GeneFeature feature : features)
if (feature.getGeneType() == null)
throw new IllegalArgumentException(String.format("%s: Gene feature %s covers several gene types " +
"(not possible to select corresponding alignment)", command, GeneFeature.encode(feature)));

//todo bigfeature nofloating bounds
}
Expand Down Expand Up @@ -92,6 +88,15 @@ static abstract class MutationsExtractor extends WithHeader {
super(command, description, nArgs, hPrefix, sPrefix);
}

@Override
void validate(GeneFeature[] features) {
super.validate(features);
for (GeneFeature feature : features)
if (feature.getGeneType() == null)
throw new IllegalArgumentException(String.format("%s: Gene feature %s covers several gene types " +
"(not possible to select corresponding alignment)", command, GeneFeature.encode(feature)));
}

@Override
protected String extractValue(VDJCObject object, GeneFeature[] parameters) {
GeneFeature smallGeneFeature = parameters[0];
Expand Down

0 comments on commit c369a10

Please sign in to comment.