- Timestamp:
- 2010-10-26T15:33:45+13:00 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone2/perllib/plugins/DirectoryPlugin.pm
r23171 r23212 336 336 my ($pluginfo, $base_dir, $file, $block_hash, 337 337 $extrametakeys, $extrametadata, $extrametafile, 338 $processor, $ maxdocs, $gli) = @_;338 $processor, $gli, $aux) = @_; 339 339 340 340 return undef; … … 379 379 # Recur over directory contents. 380 380 my (@dir, $subfile); 381 my $count = 0;382 381 383 382 print $outhandle "DirectoryPlugin read: getting directory $dirname\n" if ($verbosity > 2); … … 433 432 } 434 433 } 435 # apply metadata pass for each of the files in the directory 434 # apply metadata pass for each of the files in the directory -- ignore 435 # maxdocs here 436 436 my $num_files = scalar(@dir); 437 437 for (my $i = 0; $i < scalar(@dir); $i++) { 438 438 my $subfile = $dir[$i]; 439 439 my $this_file_base_dir = $base_dir; 440 last if ($maxdocs != -1 && $count >= $maxdocs);441 440 next if ($subfile =~ m/^\.\.?$/); 442 441 my $file_subfile = &util::filename_cat($file, $subfile); … … 450 449 print $outhandle "DirectoryPlugin metadata recurring: $subfile\n" if ($verbosity > 2); 451 450 452 $count +=&plugin::metadata_read ($pluginfo, $this_file_base_dir,453 454 455 456 $processor, $maxdocs, $gli);451 &plugin::metadata_read ($pluginfo, $this_file_base_dir, 452 $file_subfile,$block_hash, 453 \@extrametakeys, \%extrametadata, 454 \%extrametafile, 455 $processor, $gli); 457 456 $additionalmetadata = 1; 458 457 } … … 485 484 486 485 # import each of the files in the directory 487 $count=0;486 my $count=0; 488 487 for (my $i = 0; $i <= scalar(@dir); $i++) { 489 488 # When every file in the directory has been done, pause for a moment (figuratively!)
Note:
See TracChangeset
for help on using the changeset viewer.