/usr/share/doc/libdata-stag-perl/homepage/script-docs/stag-autoschema.html is in libdata-stag-perl 0.14-2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 | <HTML>
<HEAD>
<TITLE>stag-autoschema</TITLE>
<LINK REV="made" HREF="mailto:feedback@suse.de">
</HEAD>
<BODY>
<A NAME="__index__"></A>
<!-- INDEX BEGIN -->
<UL>
<LI><A HREF="#name">NAME</A></LI>
<LI><A HREF="#synopsis">SYNOPSIS</A></LI>
<LI><A HREF="#description">DESCRIPTION</A></LI>
<LI><A HREF="#arguments">ARGUMENTS</A></LI>
<LI><A HREF="#limitations">LIMITATIONS</A></LI>
</UL>
<!-- INDEX END -->
<HR>
<P>
<H1><A NAME="name">NAME</A></H1>
<P>stag-autoschema.pl - writes the implicit stag-schema for a stag file</P>
<P>
<HR>
<H1><A NAME="synopsis">SYNOPSIS</A></H1>
<PRE>
stag-autoschema.pl -w sxpr sample-data.xml</PRE>
<P>
<HR>
<H1><A NAME="description">DESCRIPTION</A></H1>
<P>Takes a stag compatible file (xml, sxpr, itext), or a file in any
format plus a parser, and writes out the implicit underlying stag-schema</P>
<P>stag-schema should look relatively self-explanatory.</P>
<P>Here is an example stag-schema, shown in sxpr syntax:</P>
<PRE>
(db
(person*
(name "s"
(address+
(address_type "s")
(street "s")
(street2? "s")
(city "s")
(zip? "s")))))</PRE>
<P>The database db contains zero or more persons, each person has a
mandatory name and at least one address.</P>
<P>The cardinality mnemonics are as follows:</P>
<DL>
<DT><STRONG><A NAME="item_%2B">+</A></STRONG><BR>
<DD>
1 or more
<P></P>
<DT><STRONG><A NAME="item_%3F">?</A></STRONG><BR>
<DD>
0 or one
<P></P>
<LI>
0 or more
<P></P></DL>
<P>The default cardinality is 1</P>
<P>
<HR>
<H1><A NAME="arguments">ARGUMENTS</A></H1>
<DL>
<DT><STRONG><A NAME="item_%2Dp%7Cparser_FORMAT">-p|parser FORMAT</A></STRONG><BR>
<DD>
FORMAT is one of xml, sxpr or itext, or the name of a perl module
<P>xml assumed as default</P>
<P></P>
<DT><STRONG><A NAME="item_%2Ddtd">-dtd</A></STRONG><BR>
<DD>
exports schema as DTD
<P></P>
<DT><STRONG><A NAME="item_%2Dw%7Cwriter_FORMAT">-w|writer FORMAT</A></STRONG><BR>
<DD>
FORMAT is one of xml, sxpr or itext, or the name of a perl module, OR DTD
<P>The default is sxpr</P>
<P>note that stag schemas exported as xml will be invalid xml, due to the
use of symbols *, +, ? in the node names</P>
<P></P></DL>
<P>
<HR>
<H1><A NAME="limitations">LIMITATIONS</A></H1>
<P>not event based - memory usage becomes exhorbitant on large files;
prepare a small sample beforehand</P>
</BODY>
</HTML>
|