Ignore:
Timestamp:
2001-04-03T14:33:03+12:00 (23 years ago)
Author:
davidb
Message:

GML file syntax altered to be XML compliant. This basically meant
turning attribute lists of metadata names (which in Greenstone can
appear multiple times within a tag) into tag names themselves, which
are then explicitly stated in a <metadata>...</metadata> block.

Newly built collection will use the new syntactic form, however the
GMLPlug file is backwards compatible and so will still import in
files in the older GML format.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/perllib/docsave.pm

    r2224 r2267  
    5353    $self->{'groupsize'} = $groupsize;
    5454    $self->{'gs_count'} = 0;
    55    
     55
     56    # keep an associate array of all metavalues used by collection to
     57    # help generate the XML DTD
     58    $self->{'dtd_metadata'} = {};
     59
    5660    $self->{'outhandle'} = STDERR;
    5761    $self->{'outhandle'} = $outhandle if defined $outhandle;
    58    
    5962    # set a default for the archive directory
    6063    $self->{'archive_dir'} = &util::filename_cat ($ENV{'GSDLCOLLECTDIR'}, "archives");
     
    113116
    114117    # save this document
    115     $doc_obj->output_section('docsave::OUTDOC', $doc_obj->get_top_section());
     118    $doc_obj->output_section('docsave::OUTDOC',
     119                 $doc_obj->get_top_section(),
     120                 $self->{'collection'},
     121                 $self->{'dtd_metadata'},0);
     122
    116123    close OUTDOC;
    117124
     
    184191
    185192    # save this document
    186     $doc_obj->output_section('docsave::OUTDOC', $doc_obj->get_top_section());
     193    $doc_obj->output_section('docsave::OUTDOC',
     194                 $doc_obj->get_top_section(),
     195                 $self->{'collection'},
     196                 $self->{'dtd_metadata'},0);
    187197
    188198    $self->{'gs_count'}++;
Note: See TracChangeset for help on using the changeset viewer.