wiki:IMDI2CMDI

Version 16 (modified by mwindhouwer, 11 years ago) (diff)

--

Responsible for this page: Alexander König?. Last content check: 12-08-2013

back to the CMDI Interoperability overview

IMDI2CMDI

This CMDI transformation converts IMDI metadata documents into valid CMD documents.

From

To

Notes

IMDI IMDI corpus or IMDI session CMD profiles lossy

Status

production


Contact


Contents

  1. IMDI2CMDI
    1. Status
    2. Contact
    3. Contents
    4. Getting the code
    5. Usage information
      1. Technical information
      2. Questions and Answers


Getting the code

  • You can browse the code here
  • Check out from: https://svn.clarin.eu/metadata/trunk/toolkit/xslt/imdi2clarin.xsl

Usage information

This is a version of imdi2clarin.xsl that batch processes a whole directory structure of imdi files, call it from the command line like this:

java -jar saxon8.jar -it main batch-imdi2clarin.xsl

The last template in imdi2clarin.xsl has to be modified to reflect the actual directory name.

Two optional parameters can be provided:

  • collection: a collection name can be specified for each record. This information is extrinsic to the IMDI file, so it is given as an external parameter. Omit this if you are unsure.
  • uri-base: if this optional parameter is defined, the behaviour of this stylesheet changes in the following ways: If no archive handle is available for MdSelfLink, the base URI is inserted there instead. All links (ResourceProxy elements) that contain relative paths are resolved into absolute URIs in the context of the base URI. Omit this if you are unsure.

Technical information

No Saxon specific extensions are used. However, the exact syntax used by a collection() invocation is implementation defined, so might need to be adapted when using another XSLT 2.0 engine then Saxon.

Questions and Answers

If you have a question about the IMDI2CMDI transformation please contact Alexander König?!