[Bio] / FigKernelPackages / Subsystem.pm Repository:
ViewVC logotype

Diff of /FigKernelPackages/Subsystem.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.47, Sat Feb 26 11:01:13 2005 UTC revision 1.48, Sat Mar 12 20:30:38 2005 UTC
# Line 1348  Line 1348 
1348      }      }
1349  }  }
1350    
1351    =pod
1352    
1353    =head2 load_row_subsets_by_kv
1354    
1355    Load a row subset based on a key/value pair. This will take a single key/value pair and only show that subset
1356    
1357    It is just a modification of load_row_subsets to deal with kv pairs
1358    
1359    This takes a required argument: the key that the genome must have, and a second optional argument, the value that key must hold.
1360    
1361    =cut
1362    
1363    sub load_row_subsets_by_kv {
1364     my ($self, $key, $want) = @_;
1365     my($id,$members,$pair);
1366     my $keep;
1367     foreach my $genome (@{$self->{genome}}) {
1368      my ($value, $url)=$self->{fig}->get_attributes($genome, $key);
1369      next if (!$value);
1370      next if ($want && $value ne $want);
1371      push @$keep, $genome;
1372     }
1373     $self->{row_subset_members}->{$key}=$keep;
1374    }
1375    
1376  =pod  =pod
1377    

Legend:
Removed from v.1.47  
changed lines
  Added in v.1.48

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3