Ignore:
Timestamp:
2005-07-19T16:27:51+12:00 (19 years ago)
Author:
kjdon
Message:

added 'use strict' to all plugins, and made modifications (mostly adding 'my') to make them compile

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/perllib/plugins/ISISPlug.pm

    r10218 r10254  
    3131use SplitPlug;
    3232
     33use strict;
     34no strict 'refs'; # allow filehandles to be variables and viceversa
    3335
    3436# ISISPlug is a sub-class of SplitPlug.
    3537sub BEGIN {
    36     @ISA = ('SplitPlug');
     38    @ISISPlug::ISA = ('SplitPlug');
    3739}
    3840
     
    155157    my $outhandle = $self->{'outhandle'};
    156158
     159    my $cursection = $doc_obj->get_top_section();
    157160    my $subfield_separator = $self->{'subfield_separator'};
    158161    my $entry_separator = $self->{'entry_separator'};
     
    164167
    165168    # Process each line of the ISIS record, one at a time
    166     foreach $line (split(/\n/, $$textref)) {
     169    foreach my $line (split(/\n/, $$textref)) {
    167170    $line =~ /^tag=(.*) data=(.+)$/;
    168171    my $rawtagname = $1;
     
    173176    # Metadata field names: title case, then remove spaces
    174177    my $tagname = "";
    175     foreach $word (split(/\s+/, $rawtagname)) {
     178    foreach my $word (split(/\s+/, $rawtagname)) {
    176179        substr($word, 0, 1) =~ tr/a-z/A-Z/;
    177180        $tagname .= $word;
     
    183186    # Handle each piece of metadata ('%' separated)
    184187    my $completetagvalue = "";
    185     foreach $rawtagvalue (split(/%/, $rawtagdata)) {
     188    foreach my $rawtagvalue (split(/%/, $rawtagdata)) {
    186189        $completetagvalue .= $entry_separator unless ($completetagvalue eq "");
    187190
     
    255258
    256259    my $amongstdefinitions = 0;
    257     foreach $fdtfileline (<FDT_FILE>) {
     260    foreach my $fdtfileline (<FDT_FILE>) {
    258261    $fdtfileline =~ s/(\s*)$//;  # Remove any nasty spaces at the end of the lines
    259262
Note: See TracChangeset for help on using the changeset viewer.