[tei-council] invalid examples allowed in Guidelines?

Sebastian Rahtz sebastian.rahtz at oucs.ox.ac.uk
Tue Jan 11 11:28:43 EST 2011


On 11 Jan 2011, at 16:20, Laurent Romary wrote:

> Very good. Wait until I file the ticket, then :-}
> 

I am not implying that this gives us an implementation, by the way;
it does confirm the concept, however, and  shows how we could
solve the problem in the future.

to see how this works in practice, consider this extracted example:

<egXML xmlns="http://www.tei-c.org/ns/Examples"><TEI>
  <teiHeader> <!-- .... --> </teiHeader>
    <front>
<!-- front matter of copy text, if any, goes here -->
    </front>
    <body>
<!-- body of copy text goes here -->
    </body>
    <back>
<!-- back matter of copy text, if any, goes here -->
    </back>
 </TEI>
</egXML>


If I do a normal validation, I am told

/home/rahtz/TEI/Sourceforge/trunk/P5/foo.xml:2:41: error: element "teiHeader" incomplete; missing required element "fileDesc"
/home/rahtz/TEI/Sourceforge/trunk/P5/foo.xml:3:12: error: element "front" not allowed here; expected element "facsimile", "fsdDecl" or "text"
/home/rahtz/TEI/Sourceforge/trunk/P5/foo.xml:6:11: error: element "body" not allowed here; expected element "facsimile", "fsdDecl" or "text"
/home/rahtz/TEI/Sourceforge/trunk/P5/foo.xml:8:12: error: element "body" incomplete; expected element "ab", "addSpan", "alt", "altGrp", "anchor", "argument", "bibl", "biblFull", "biblStruct", "byline", "camera", "caption", "castList", "cb", "certainty", "cit", "classRef", "classSpec", "damageSpan", "dateline", "delSpan", "desc", "div", "div1", "divGen", "docAuthor", "docDate", "eTree", "eg", "egXML", "elementRef", "elementSpec", "entry", "entryFree", "epigraph", "fLib", "figure", "floatingText", "forest", "forestGrp", "fs", "fvLib", "fw", "gap", "gb", "graph", "head", "incident", "index", "interp", "interpGrp", "join", "joinGrp", "kinesic", "l", "label", "lb", "lg", "link", "linkGrp", "list", "listBibl", "listEvent", "listNym", "listOrg", "listPerson", "listPlace", "listRef", "listWit", "macroRef", "macroSpec", "meeting", "milestone", "moduleRef", "moduleSpec", "move", "msDesc", "note", "opener", "p", "pause", "pb", "precision", "q", "quote", "respons", "said", "salute", "schemaSpec", "shift", "sound", "sp", "space", "span", "spanGrp", "specGrp", "specGrpRef", "stage", "superEntry", "table", "tech", "timeline", "tree", "u", "view", "vocal", "witDetail" or "writing"
/home/rahtz/TEI/Sourceforge/trunk/P5/foo.xml:9:11: error: element "back" not allowed here; expected element "facsimile", "fsdDecl" or "text"
/home/rahtz/TEI/Sourceforge/trunk/P5/foo.xml:12:8: error: element "TEI" incomplete; expected element "facsimile", "fsdDecl" or "text"


but with jing's -f option, I get just

rahtz at rahtz:~/TEI/Sourceforge/trunk/P5$ jing -f p5odds-examples.rng foo.xml
/home/rahtz/TEI/Sourceforge/trunk/P5/foo.xml:3:12: error: element "front" not allowed here; expected the element end-tag or element "facsimile", "fsdDecl" or "text"
/home/rahtz/TEI/Sourceforge/trunk/P5/foo.xml:6:11: error: element "body" not allowed here; expected the element end-tag or element "facsimile", "fsdDecl" or "text"
/home/rahtz/TEI/Sourceforge/trunk/P5/foo.xml:9:11: error: element "back" not allowed here; expected the element end-tag or element "facsimile", "fsdDecl" or "text"

ie it detects the missing <text> but goes no further.

This is exactly the result we want.

--
Sebastian Rahtz      
 Information and Support Group Manager
Oxford University Computing Services
13 Banbury Road, Oxford OX2 6NN. Phone +44 1865 283431

Sólo le pido a Dios
que el futuro no me sea indiferente



More information about the tei-council mailing list