Skip to content

Commit

Permalink
Merge pull request #2618 from TEIC/sydb_2617_table_of_modules
Browse files Browse the repository at this point in the history
table of modules — re-generated based on new utility
  • Loading branch information
GusRiva authored Dec 10, 2024
2 parents 1929cdf + 0b8e5e2 commit d69f1fb
Show file tree
Hide file tree
Showing 2 changed files with 166 additions and 115 deletions.
234 changes: 119 additions & 115 deletions P5/Source/Guidelines/en/ST-Infrastructure.xml
Original file line number Diff line number Diff line change
Expand Up @@ -72,121 +72,125 @@ with others.--></p>
grouping together a number of associated element declarations. In the simple case, a TEI
schema is made by combining together a small number of modules, as further described in
section <ptr target="#STIN"/> below.</p>
<p>The following table lists the modules defined by the current release of these Guidelines:
<!-- table can be re-autogenerated from modules.xsl LB 20-xii-05 -->
<p>The following table lists the modules defined by the current release of these Guidelines:
<table xml:id="tab-mods">
<row role="label">
<cell>Module name</cell>
<cell>Formal public identifier</cell>
<cell>Where defined</cell>
</row>
<row>
<cell>analysis</cell>
<cell>Analysis and Interpretation</cell>
<cell><ptr target="#AI"/></cell>
</row>
<row>
<cell>certainty</cell>
<cell>Certainty and Uncertainty</cell>
<cell><ptr target="#CE"/></cell>
</row>
<row>
<cell>core</cell>
<cell>Common Core</cell>
<cell><ptr target="#CO"/></cell>
</row>
<row>
<cell>corpus</cell>
<cell>Metadata for Language Corpora</cell>
<cell><ptr target="#CC"/></cell>
</row>
<!--<row><cell>declarefs</cell><cell>Feature System Declaration</cell><cell><ptr target="#FD"/></cell></row>-->
<row>
<cell>dictionaries</cell>
<cell>Print Dictionaries</cell>
<cell><ptr target="#DI"/></cell>
</row>
<row>
<cell>drama</cell>
<cell>Performance Texts</cell>
<cell><ptr target="#DR"/></cell>
</row>
<row>
<cell>figures</cell>
<cell>Tables, Formulae, Figures</cell>
<cell><ptr target="#FT"/></cell>
</row>
<row>
<cell>gaiji</cell>
<cell>Character and Glyph Documentation</cell>
<cell><ptr target="#WD"/></cell>
</row>
<row>
<cell>header</cell>
<cell>Common Metadata</cell>
<cell><ptr target="#HD"/></cell>
</row>
<row>
<cell>iso-fs</cell>
<cell>Feature Structures</cell>
<cell><ptr target="#FS"/></cell>
</row>
<row>
<cell>linking</cell>
<cell>Linking, Segmentation, and Alignment</cell>
<cell><ptr target="#SA"/></cell>
</row>
<row>
<cell>msdescription</cell>
<cell>Manuscript Description</cell>
<cell><ptr target="#MS"/></cell>
</row>
<row>
<cell>namesdates</cell>
<cell>Names, Dates, People, and Places</cell>
<cell><ptr target="#ND"/></cell>
</row>
<row>
<cell>nets</cell>
<cell>Graphs, Networks, and Trees</cell>
<cell><ptr target="#GD"/></cell>
</row>
<row>
<cell>spoken</cell>
<cell>Transcribed Speech</cell>
<cell><ptr target="#TS"/></cell>
</row>
<row>
<cell>tagdocs</cell>
<cell>Documentation Elements</cell>
<cell><ptr target="#TD"/></cell>
</row>
<row>
<cell>tei</cell>
<cell>TEI Infrastructure</cell>
<cell><ptr target="#ST"/></cell>
</row>
<!--row><cell>terminology</cell><cell>terminology</cell><cell><ptr target="#TE"/></cell></row-->
<row>
<cell>textcrit</cell>
<cell>Text Criticism</cell>
<cell><ptr target="#TC"/></cell>
</row>
<row>
<cell>textstructure</cell>
<cell>Default Text Structure</cell>
<cell><ptr target="#DS"/></cell>
</row>
<row>
<cell>transcr</cell>
<cell>Transcription of Primary Sources</cell>
<cell><ptr target="#PH"/></cell>
</row>
<row>
<cell>verse</cell>
<cell>Verse</cell>
<cell><ptr target="#VE"/></cell>
</row>
<!-- following table generated by P5/Utilities/generate_module_table.xsl at 2024-11-16T16:54:39-05:00 -->
<!-- based on P5 Version 4.9.0a. Last updated on 9th November 2024, revision 28371d145 -->
<row role="label">
<cell>Module name</cell>
<cell>Where defined</cell>
<cell>Formal public identifier</cell>
</row>
<row>
<cell>tei</cell>
<cell><ptr target="#ST"/></cell>
<cell>TEI Infrastructure</cell>
</row>
<row>
<cell>header</cell>
<cell><ptr target="#HD"/></cell>
<cell>Common Metadata</cell>
</row>
<row>
<cell>core</cell>
<cell><ptr target="#CO"/></cell>
<cell>Common Core</cell>
</row>
<row>
<cell>textstructure</cell>
<cell><ptr target="#DS"/></cell>
<cell>Default Text Structure</cell>
</row>
<row>
<cell>gaiji</cell>
<cell><ptr target="#WD"/></cell>
<cell>Character and Glyph Documentation</cell>
</row>
<row>
<cell>verse</cell>
<cell><ptr target="#VE"/></cell>
<cell>Verse</cell>
</row>
<row>
<cell>drama</cell>
<cell><ptr target="#DR"/></cell>
<cell>Performance Texts</cell>
</row>
<row>
<cell>spoken</cell>
<cell><ptr target="#TS"/></cell>
<cell>Transcribed Speech</cell>
</row>
<row>
<cell>cmc</cell>
<cell><ptr target="#CMC"/></cell>
<cell>TEI-CMC</cell>
</row>
<row>
<cell>dictionaries</cell>
<cell><ptr target="#DI"/></cell>
<cell>Dictionaries</cell>
</row>
<row>
<cell>msdescription</cell>
<cell><ptr target="#MS"/></cell>
<cell>Manuscript Description</cell>
</row>
<row>
<cell>transcr</cell>
<cell><ptr target="#PH"/></cell>
<cell>Transcription of Primary Sources</cell>
</row>
<row>
<cell>textcrit</cell>
<cell><ptr target="#TC"/></cell>
<cell>Text Criticism</cell>
</row>
<row>
<cell>namesdates</cell>
<cell><ptr target="#ND"/></cell>
<cell>Names, dates, persons and places</cell>
</row>
<row>
<cell>figures</cell>
<cell><ptr target="#FT"/></cell>
<cell>Tables, Formulæ, Notated Music, Figures</cell>
</row>
<row>
<cell>corpus</cell>
<cell><ptr target="#CC"/></cell>
<cell>Metadata for Language Corpora</cell>
</row>
<row>
<cell>linking</cell>
<cell><ptr target="#SA"/></cell>
<cell>Linking, Segmentation, and Alignment</cell>
</row>
<row>
<cell>analysis</cell>
<cell><ptr target="#AI"/></cell>
<cell>Analysis and Interpretation</cell>
</row>
<row>
<cell>iso-fs</cell>
<cell><ptr target="#FS"/></cell>
<cell>Feature Structures</cell>
</row>
<row>
<cell>nets</cell>
<cell><ptr target="#GD"/></cell>
<cell>Graphs, networks, and trees</cell>
</row>
<row>
<cell>certainty</cell>
<cell><ptr target="#CE"/></cell>
<cell>Certainty and Uncertainty</cell>
</row>
<row>
<cell>tagdocs</cell>
<cell><ptr target="#TD"/></cell>
<cell>Documentation Elements</cell>
</row>
</table>
</p>
<p>For each module listed above, the corresponding chapter gives a full description of the
Expand Down Expand Up @@ -1424,4 +1428,4 @@ entities in the XML DTD fragments.--></p>
similarly predeclares a number of patterns with null (<soCalled>notAllowed</soCalled>) values.
These issues are further discussed in chapter <ptr target="#IM"/>.</p>
</div>
</div>
</div>
47 changes: 47 additions & 0 deletions P5/Utilities/generate_module_table.xsl
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
<?xml version="1.0" encoding="UTF-8"?>

<!--
generate_module_table.xsl
Written 2024-11-16 by Syd Bauman, based in part on modules.xsl,
itself written 2004-10-06 by Arno Mittelbach <[email protected]>.
Copyleft 2024 by Syd Bauman and the Text Encoding Initiative Consortium.
Read in TEI P5, write out an TEI table listing the modules. The table is
intended to be inserted into the Guidelines in section #STMA.
Written to help address TEI issue 2617 <https://github.com/TEIC/TEI/issues/2617>.
-->

<xsl:stylesheet version="3.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns="http://www.tei-c.org/ns/1.0"
xmlns:tei="http://www.tei-c.org/ns/1.0"
xpath-default-namespace="http://www.tei-c.org/ns/1.0"
expand-text="yes">

<xsl:output method="xml" indent="yes"/>

<xsl:template match="/">
<xsl:comment> following table generated by {static-base-uri()} at {current-dateTime()} </xsl:comment>
<xsl:comment> based on {normalize-space(/*/teiHeader/fileDesc/editionStmt)} </xsl:comment>
<table xml:id="tab-mods">
<row role="label">
<cell>Module name</cell>
<cell>Where defined</cell>
<cell>Formal public identifier</cell>
</row>
<xsl:apply-templates select="//tei:moduleSpec">
<!-- The default sort order, document order, should get these in order by chapter # -->
</xsl:apply-templates>
</table>
</xsl:template>

<xsl:template match="tei:moduleSpec" as="element(tei:row)">
<row>
<cell>{@ident}</cell>
<cell><ptr target="#{ancestor::tei:div[@xml:id][last()]/@xml:id}"/></cell>
<cell>{tei:idno[ @type eq 'FPI']}</cell>
</row>
</xsl:template>

</xsl:stylesheet>

0 comments on commit d69f1fb

Please sign in to comment.