Bio-BLAST
view release on metacpan or search on metacpan
lib/Bio/BLAST/Database.pm view on Meta::CPAN
#add seqid indexes if called for
$self->indexed_seqs ? qw/sd si/ : (),
);
#add protein/nucleotide prefix to extensions
my $norp = $self->type eq 'protein' ? '.p' : '.n';
$_ = $norp.$_ foreach @necessary_extensions;
#deal with large, split databases
if( $self->is_split ) {
#if the database is split, add all of the fragment numbers to
#the extensions we have to have
#maximum index number of all fragments present
my $max_frag_num = 0 + max( map { /\.(\d{2,3})\.[np]\w\w$/ ? $1 : 0 } @files);
#make extensions with all of the necessary fragment numbers
@necessary_extensions = map { my $ext = $_;
map {sprintf(".%02d$ext",$_)} (0..$max_frag_num)
} @necessary_extensions;
#also remember that we have to have an alias file for split dbs
push @necessary_extensions, $norp.'al';
}
#now that we have our list of all the file extensions we need to have,
#check if they are actually there
my $ffbn = $self->full_file_basename;
return all {
( run in 1.410 second using v1.01-cache-2.11-cpan-364913b4093 )