[Bio] / Sprout / FeatureSproutLoader.pm Repository:
ViewVC logotype

Diff of /Sprout/FeatureSproutLoader.pm

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

revision 1.3, Thu Oct 2 16:32:42 2008 UTC revision 1.4, Thu Oct 9 17:23:54 2008 UTC
# Line 90  Line 90 
90  sub Generate {  sub Generate {
91      # Get the parameters.      # Get the parameters.
92      my ($self) = @_;      my ($self) = @_;
     # Get the section ID.  
     my $genomeID = $self->section();  
93      # Get the sprout object.      # Get the sprout object.
94      my $sprout = $self->db();      my $sprout = $self->db();
95      # Get the FIG object.      # Get the FIG object.
# Line 102  Line 100 
100      my $stemmer = $sprout->GetStemmer();      my $stemmer = $sprout->GetStemmer();
101      # Only proceed if this is not the global section.      # Only proceed if this is not the global section.
102      if (! $self->global()) {      if (! $self->global()) {
103            # Get the section ID.
104            my $genomeID = $self->section();
105          # Get the maximum sequence size. We need this later for splitting up the          # Get the maximum sequence size. We need this later for splitting up the
106          # locations.          # locations.
107          my $chunkSize = $sprout->MaxSegment();          my $chunkSize = $sprout->MaxSegment();
# Line 118  Line 118 
118          # Loop through the features.          # Loop through the features.
119          for my $featureTuple (@featureTuples) {          for my $featureTuple (@featureTuples) {
120              # Split the tuple.              # Split the tuple.
121              my ($featureID, $locations, undef, $type, $minloc, $maxloc, $assignment, $user, $quality) = @{$featureTuple};              my ($featureID, $locations, $aliases, $type, $minloc, $maxloc, $assignment, $user, $quality) = @{$featureTuple};
122              # Make sure this feature is active.              # Make sure this feature is active.
123              if (! $fig->is_deleted_fid($featureID)) {              if (! $fig->is_deleted_fid($featureID)) {
124                  # Handle missing assignments.                  # Handle missing assignments.
# Line 141  Line 141 
141                  my @keywords = ($genomeID, $featureID, $fig->genus_species($genomeID),                  my @keywords = ($genomeID, $featureID, $fig->genus_species($genomeID),
142                                  $fig->taxonomy_of($genomeID));                                  $fig->taxonomy_of($genomeID));
143                  # Create the aliases.                  # Create the aliases.
144                  for my $alias ($fig->feature_aliases($featureID)) {                  for my $alias (split /,/, $aliases) {
145                      # Connect this alias to this feature and make an Alias record for it.                      # Connect this alias to this feature and make an Alias record for it.
146                      $self->Put('IsAliasOf', 'from-link' => $alias, 'to-link' => $featureID);                      $self->Put('IsAliasOf', 'from-link' => $alias, 'to-link' => $featureID);
147                      $self->Put('FeatureAlias', id => $alias);                      $self->Put('FeatureAlias', id => $alias);

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.4

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3