Question related to XML import

The user guide mentions the requirement of an omnimark.lib and catalog.xml file with an entry for the DTD/Schema, how do I creates these two files. Adidtionally if the XML being imported is a DITA XML then how can I configure its DTD?

Parents
  • In general people do not go through the trouble of setting up the DTD/Schema environment on their XPP system, unless there is a very specific reason you want to set it up. In which case people simply strip the DTD declaration from the incoming file using something simple like xychange.
    Composition does not gain anything from having access to the DTD.

    A specific reason why you want to set up the DTD/Schema environment could be that you do elaborate editing inside XPP and you want to be able to validate the instance. In that case you will need to set up:
    -either the omnimark lib file
    or
    -either change the DTD declaration in the incoming XML instance so that it points to valid SYSTEM path on your XPP system (and do the same for any entities that are used in the DTD).

    In case you want to set up the omnimark.lib file, just copy the sample omnimark.lib file from $XYV_EXECS/distr/sys/ml to $XYVV_EXECS/sys/ml and edit to include the necessary entries

    A specific reason for setting up the transformation environment is that you want to include text or file entities at import. In that case you will have to rename the catalog.tmpl file you find in the $XYV_EXECS/sys/ml folder to catalog.xml and add your entries. The samples given in the template file are pretty clear so you should not have any trouble with this. Note that the catalog.xml file is only used by the V2 engines so you will have to use V2 stylesheets for your transformation and use either the -xsl2 or -xslauto option when transforming at import.
    Note that when you parse during the transformation your output and transformed file will no longer include the DTD declaration as an XSLT stylesheet can not pick up a DTD declaration.

    This last things means that you can not parse during import AND parse inside the xyview unless you add the DTD declaration yourself somewhere in the input stream.

    More info about all of this can be found in the excellent documentation XML/SGML reference - chapter 1
Reply
  • In general people do not go through the trouble of setting up the DTD/Schema environment on their XPP system, unless there is a very specific reason you want to set it up. In which case people simply strip the DTD declaration from the incoming file using something simple like xychange.
    Composition does not gain anything from having access to the DTD.

    A specific reason why you want to set up the DTD/Schema environment could be that you do elaborate editing inside XPP and you want to be able to validate the instance. In that case you will need to set up:
    -either the omnimark lib file
    or
    -either change the DTD declaration in the incoming XML instance so that it points to valid SYSTEM path on your XPP system (and do the same for any entities that are used in the DTD).

    In case you want to set up the omnimark.lib file, just copy the sample omnimark.lib file from $XYV_EXECS/distr/sys/ml to $XYVV_EXECS/sys/ml and edit to include the necessary entries

    A specific reason for setting up the transformation environment is that you want to include text or file entities at import. In that case you will have to rename the catalog.tmpl file you find in the $XYV_EXECS/sys/ml folder to catalog.xml and add your entries. The samples given in the template file are pretty clear so you should not have any trouble with this. Note that the catalog.xml file is only used by the V2 engines so you will have to use V2 stylesheets for your transformation and use either the -xsl2 or -xslauto option when transforming at import.
    Note that when you parse during the transformation your output and transformed file will no longer include the DTD declaration as an XSLT stylesheet can not pick up a DTD declaration.

    This last things means that you can not parse during import AND parse inside the xyview unless you add the DTD declaration yourself somewhere in the input stream.

    More info about all of this can be found in the excellent documentation XML/SGML reference - chapter 1
Children
No Data