« lib/Bio/MUST/Drivers/Hmmer/Model/Temporary.pm
↑ Summary
lib/Bio/MUST/Drivers/Blast/Database/Temporary.pm »
| 1 | package Bio::MUST::Drivers::Utils; | ||||||||||||||||||||
| 2 | # ABSTRACT: Utility functions for drivers | ||||||||||||||||||||
| 3 | 8 | $Bio::MUST::Drivers::Utils::VERSION = '0.252830'; | |||||||||||||||||||
| 4 | 8 | ▶ | use strict; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 5 | 8 | ▶ | use warnings; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 6 | 8 | ▶ | use autodie; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 7 | 8 | ▶ | use feature qw(say); | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 8 | |||||||||||||||||||||
| 9 | 8 | ▶ | use Exporter::Easy ( | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 10 | 8 | OK => [ qw(stringify_args) ], | |||||||||||||||||||
| 11 | 8 | ); | |||||||||||||||||||
| 12 | |||||||||||||||||||||
| 13 | |||||||||||||||||||||
| 14 | # TODO: add function for redirecting to /dev/null | ||||||||||||||||||||
| 15 | |||||||||||||||||||||
| 16 | 0 | ▶ | sub stringify_args { | ||||||||||||||||||
|
Subroutine
stringify_args: not called CC=3 SCAR=24.8
Pod
undocumented
| |||||||||||||||||||||
| 17 | 0 | ▶ | my $args = shift // {}; | ||||||||||||||||||
|
Condition0%0/2
shift() // {}
MC/DC0%0/1
shift() // {}
shift()
Truth table0%0/2
A
A= shift()
| |||||||||||||||||||||
| 18 | |||||||||||||||||||||
| 19 | my @cli_args = map { # concat opts with args and | ||||||||||||||||||||
| 20 | 0 | ▶ | join q{ }, $_, ( $args->{$_} // () ) # append boolean flags without | ||||||||||||||||||
|
Condition0%0/3
$args->{$_} // ()
MC/DC0%0/2
$args->{$_} // ()
$args->{$_}
()
Truth table0%0/3
A // B
A= $args->{$_}B= ()
| |||||||||||||||||||||
| 21 | 0 | } keys %{$args}; # adding extra whitespace | |||||||||||||||||||
| 22 | 0 | my $args_str = join q{ }, @cli_args; | |||||||||||||||||||
| 23 | |||||||||||||||||||||
| 24 | 0 | return $args_str; | |||||||||||||||||||
| 25 | } | ||||||||||||||||||||
| 26 | |||||||||||||||||||||
| 27 | 8 | 1; | |||||||||||||||||||
| 28 | |||||||||||||||||||||
| 29 | __END__ | ||||||||||||||||||||