← Index
Performance Profile   « block view • line view • sub view »
For /wise/base/deliv/dev/bin/getfix
  Run on Thu May 20 15:30:03 2010
Reported on Thu May 20 16:25:34 2010

File/wise/base/deliv/dev/lib/perl/WISE/DB/FrameIndex/Scan.pm
Statements Executed11
Total Time0.000544 seconds

Subroutines — ordered by exclusive time
Calls P F Exclusive
Time
Inclusive
Time
Subroutine
00000WISE::DB::FrameIndex::Scan::BEGIN
00000WISE::DB::FrameIndex::Scan::qa_factors

LineStmts.Exclusive
Time
Avg.Code
1package WISE::DB::FrameIndex::Scan;
2# $Id: Scan.pm 7412 2010-02-20 01:58:56Z heidi $
3
4100$VERSION = 1.2;
5100$ID = '$Id: Scan.pm 7412 2010-02-20 01:58:56Z heidi $';
6
730.000390.00013use base qw/DBIx::Class/;
# spent 134µs making 1 call to base::import
8
911.5e-51.5e-5__PACKAGE__->load_components(qw/Core/);
# spent 41.7ms making 1 call to Class::C3::Componentised::load_components
1012.4e-52.4e-5__PACKAGE__->table('scans');
# spent 707µs making 1 call to DBIx::Class::ResultSourceProxy::Table::table
11
1214.4e-54.4e-5__PACKAGE__->add_columns(
# spent 3.38ms making 1 call to DBIx::Class::ResultSourceProxy::add_columns
13
14 # primary identifiers
15 scan => {data_type => 'text', is_nullable => 0},
16 scan_start_utc => {data_type => 'text', is_nullable => 1},
17
18 # pipeline processing
19 pipe_status => {data_type => 'integer', is_nullable => 1}, # scanframe pipeline return code
20 pipe_dir => {data_type => 'text', is_nullable => 1}, # full path to pipeline directory
21 pipe_run_time => {data_type => 'integer', is_nullable => 1},
22
23 multiscan_status => { data_type => 'integer', is_nullable => 1}, # multiscan pipeline return code
24 multiscan_run_time => { data_type => 'integer', is_nullable => 1},
25
26 archive_status => {data_type => 'integer', is_nullable => 1}, # archive pipeline return code
27 archive_dir => {data_type => 'text', is_nullable => 1},
28 archive_run_time => {data_type => 'integer', is_nullable => 1}, # time of last archive pipeline run
29
30 anneal_time => {data_type => 'text', is_nullable => 1}, # time of last anneal
31 anneal_dt => {data_type => 'real', is_nullable => 1}, # time since last anneal
32
33 # qa info
34 qa_score => {data_type => 'integer', is_nullable => 1 },
35 qa_factors => {data_type => 'text', is_nullable => 1 , accessor => '_qa_factors'},
36 qa_status => {data_type => 'text', is_nullable => 1 },
37 qa_reviewer => {data_type => 'text', is_nullable => 1, default_value => 'unassigned' },
38 qa_notes => {data_type => 'text', is_nullable => 1 },
39
40 );
41
4213.2e-53.2e-5__PACKAGE__->set_primary_key(qw/scan/);
# spent 203µs making 1 call to DBIx::Class::ResultSourceProxy::set_primary_key
43
4411.7e-51.7e-5__PACKAGE__->has_many( frames => 'WISE::DB::FrameIndex::Frame' );
# spent 13.9ms making 1 call to DBIx::Class::Relationship::HasMany::has_many
45
46
47# accessor for the qa_factors field, which is a text string packed with key=val, entries
48sub qa_factors {
49 my ($self, $value, $attr) = @_;
50
51 my $overwrite = exists $attr->{overwrite} ? $attr->{overwrite} : 0;
52 my $append = exists $attr->{append} ? $attr->{append} : ! $overwrite;
53
54 die __PACKAGE__."->qa_factors() can't overwrite and append" if($overwrite && $append);
55
56 my %current = ();
57 my $factors_string = $self->_qa_factors || "";
58 %current = split(/[=,]/, $factors_string) unless $overwrite;
59
60 if(defined $value) {
61 if(ref($value) eq 'HASH' ) {
62 my $flat = "";
63 my %merged = (%current, %$value);
64 while ( my ($k, $v) = each %merged ) {
65 $flat .= "$k=$v,";
66 }
67 $flat =~ s/,$//;
68 $self->_qa_factors($flat);
69 } else {
70 die __PACKAGE__."->qa_factors() expects hash ref as input";
71 }
72 }
73
74 return split( /[=,]/, ($self->_qa_factors || ""));
75}
76
7712.4e-52.4e-51;