[Bioperl-guts-l] bioperl-live/Bio/Tools/Run RemoteBlast.pm, 1.21,
1.22
Brian Osborne
bosborne at pub.open-bio.org
Mon Apr 25 21:47:41 EDT 2005
Update of /home/repository/bioperl/bioperl-live/Bio/Tools/Run
In directory pub.open-bio.org:/tmp/cvs-serv30182/Bio/Tools/Run
Modified Files:
RemoteBlast.pm
Log Message:
Add POD, move to scripts/
Index: RemoteBlast.pm
===================================================================
RCS file: /home/repository/bioperl/bioperl-live/Bio/Tools/Run/RemoteBlast.pm,v
retrieving revision 1.21
retrieving revision 1.22
diff -C2 -d -r1.21 -r1.22
*** RemoteBlast.pm 17 Nov 2004 23:54:50 -0000 1.21
--- RemoteBlast.pm 26 Apr 2005 01:47:39 -0000 1.22
***************
*** 196,200 ****
'(Pairwise|(Flat)?QueryAnchored(NoIdentities)?|Tabular)',
# Pairwise, QueryAnchored, QueryAnchoredNoIdentities,
! # FlatQueryAnchored, FlatQueryAnchoredNoIdentities, Tabular
'DESCRIPTIONS' => '\d+', # Positive integer
'ENTREZ_LINKS_NEW_WINDOW' => '(yes|no)', # yes, no
--- 196,200 ----
'(Pairwise|(Flat)?QueryAnchored(NoIdentities)?|Tabular)',
# Pairwise, QueryAnchored, QueryAnchoredNoIdentities,
! # FlatQueryAnchored, FlatQueryAnchoredNoIdentities, Tabular
'DESCRIPTIONS' => '\d+', # Positive integer
'ENTREZ_LINKS_NEW_WINDOW' => '(yes|no)', # yes, no
***************
*** 563,567 ****
$blastobj = new Bio::Tools::BPlite(-file => $tempfile);
} else {
! $blastobj = new Bio::SearchIO( -file => $tempfile,
-format => 'blast');
}
--- 563,567 ----
$blastobj = new Bio::Tools::BPlite(-file => $tempfile);
} else {
! $blastobj = new Bio::SearchIO( -file => $tempfile,
-format => 'blast');
}
***************
*** 571,575 ****
return $blastobj;
} elsif( $size < 500 ) { # search had a problem
! open(ERR, "<$tempfile") or $self->throw("cannot open file $tempfile");
$self->warn(join("", <ERR>));
close ERR;
--- 571,576 ----
return $blastobj;
} elsif( $size < 500 ) { # search had a problem
! open(ERR, "<$tempfile")
! or $self->throw("cannot open file $tempfile");
$self->warn(join("", <ERR>));
close ERR;
***************
*** 622,657 ****
sub _load_input {
! my ($self, $input) = @_;
! if( ! defined $input ) {
$self->throw("Calling remote blast with no input");
- }
- my @seqs;
- if( ! ref $input ) {
- if( -e $input ) {
- my $seqio = new Bio::SeqIO(-format => 'fasta', -file => $input);
- while( my $seq = $seqio->next_seq ) {
- push @seqs, $seq;
- }
- } else {
- $self->throw("Input $input was not a valid filename");
- }
- } elsif( ref($input) =~ /ARRAY/i ) {
- foreach ( @$input ) {
- if( ref($_) && $_->isa('Bio::PrimarySeqI') ) {
- push @seqs, $_;
- } else {
- $self->warn("Trying to add a " . ref($_) .
- " but expected a Bio::PrimarySeqI");
- }
}
! if( ! @seqs) {
! $self->throw("Did not pass in valid input -- no sequence objects found");
}
! } elsif( $input->isa('Bio::PrimarySeqI') ) {
! push @seqs, $input;
! }
! return @seqs;
}
1;
__END__
--- 623,661 ----
sub _load_input {
! my ($self, $input) = @_;
! if( ! defined $input ) {
$self->throw("Calling remote blast with no input");
}
! my @seqs;
! if( ! ref $input ) {
! if( -e $input ) {
! my $seqio = new Bio::SeqIO(-format => 'fasta',
! -file => $input);
! while( my $seq = $seqio->next_seq ) {
! push @seqs, $seq;
! }
! } else {
! $self->throw("Input $input was not a valid filename");
! }
! } elsif( ref($input) =~ /ARRAY/i ) {
! foreach ( @$input ) {
! if( ref($_) && $_->isa('Bio::PrimarySeqI') ) {
! push @seqs, $_;
! } else {
! $self->warn("Trying to add a " . ref($_) .
! " but expected a Bio::PrimarySeqI");
! }
! }
! if( ! @seqs) {
! $self->throw("Did not pass in valid input -- no sequence objects found");
! }
! } elsif( $input->isa('Bio::PrimarySeqI') ) {
! push @seqs, $input;
}
! return @seqs;
}
+
1;
+
__END__
More information about the Bioperl-guts-l
mailing list