Changeset 1411
- Timestamp:
- 2000-08-16T18:07:29+12:00 (24 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gsdl/perllib/plugins/BasPlug.pm
r1396 r1411 34 34 use doc; 35 35 use diagnostics; 36 use DateExtract; 36 37 37 38 sub print_general_usage { … … 84 85 my $self = {}; 85 86 my $encodings = "^(iso_8859_1|Latin1|ascii|gb|iso_8859_6|windows_1256|Arabic|utf8|unicode)\$"; 86 87 my $year = (localtime)[5]+1900; 87 88 # general options available to all plugins 88 89 if (!parsargv::parse(\@_, … … 93 94 q^markup_acronyms^, \$self->{'markup_acronyms'}, 94 95 q^extract_language^, \$self->{'extract_language'}, 96 q^date_extract^, \$self->{'date_extract'}, 97 "maximum_date/\\d{4}/$year", \$self->{'max_year'}, 98 q^no_bibliography^, \$self->{'no_biblio'}, 99 "maximum_century/-?\\d{1,2}( ?B\\.C\\.E\\.)?/-1", 100 \$self->{'max_century'}, 95 101 "allow_extra_options")) { 96 102 97 103 print STDERR "\nThe $plugin_name plugin uses an incorrect general option (general options are those\n"; 98 104 print STDERR "available to all plugins). Check your collect.cfg configuration file.\n"; … … 329 335 } 330 336 } 337 338 if($self->{'date_extract'}) { 339 my $thissection = $doc_obj->get_top_section(); 340 while (defined $thissection) { 341 342 my $text = $doc_obj->get_text($thissection); 343 &DateExtract::get_date_metadata($text, $doc_obj, 344 $thissection, 345 $self->{'no_biblio'}, 346 $self->{'max_year'}, 347 $self->{'max_century'}); 348 $thissection = $doc_obj->get_next_section ($thissection); 349 } 350 } 331 351 332 352 if ($self->{'extract_language'}) {
Note:
See TracChangeset
for help on using the changeset viewer.