Changeset 23349 for main/trunk/greenstone2/perllib/plugins/ReadXMLFile.pm
- Timestamp:
- 2010-11-26T12:09:53+13:00 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone2/perllib/plugins/ReadXMLFile.pm
r20830 r23349 213 213 $self->{'filename_no_path'} = $filename_no_path; 214 214 $self->{'processor'} = $processor; 215 215 216 # this contains metadata passed in from running metadata_read with other plugins (eg from MetadataXMLPlugin) 216 217 # we are also using it to store up any metadata found during parsing the XML, so that it can be added to the doc obj. … … 368 369 my $self = shift(@_); 369 370 371 my $metadata = $self->{'metadata'}; 372 370 373 # create a new document 371 $self->{'doc_obj'} = new doc ($self->{'filename'}, "indexed_doc", $self->{'file_rename_method'}); 372 $self->{'doc_obj'}->add_utf8_metadata($self->{'doc_obj'}->get_top_section(), "Plugin", "$self->{'plugin_type'}"); 373 $self->set_Source_metadata($self->{'doc_obj'}, $self->{'filename_no_path'}); 374 375 374 my $doc_obj = $self->{'doc_obj'} = new doc ($self->{'filename'}, "indexed_doc", $self->{'file_rename_method'}); 375 376 $doc_obj->add_utf8_metadata($doc_obj->get_top_section(), "Plugin", "$self->{'plugin_type'}"); 377 378 my $filename_no_path = $self->{'filename_no_path'}; 379 my $plugin_filename_encoding = $self->{'filename_encoding'}; 380 my $filename_encoding = $self->deduce_filename_encoding($filename_no_path,$metadata,$plugin_filename_encoding); 381 382 $self->set_Source_metadata($doc_obj, $filename_no_path, $filename_encoding); 383 376 384 # do we want other auto metadata here (see BasePlugin.read_into_doc_obj) 377 385 }
Note:
See TracChangeset
for help on using the changeset viewer.