Skip to content

Commit

Permalink
Work on issue #6: constrain some attribute value lists.
Browse files Browse the repository at this point in the history
  • Loading branch information
martindholmes committed Dec 29, 2024
1 parent 78ea707 commit ee9c1bc
Show file tree
Hide file tree
Showing 2 changed files with 73 additions and 5 deletions.
30 changes: 30 additions & 0 deletions tei/bbti.odd
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,36 @@
</valItem>
</valList>
</attDef>
<attDef ident="subtype" mode="delete"/>
</attList>
</elementSpec>

<elementSpec ident="org" mode="change">
<attList>
<attDef ident="xml:id" mode="change" usage="req"/>
</attList>
</elementSpec>

<elementSpec ident="category" mode="change">
<attList>
<attDef ident="xml:id" mode="change" usage="req"/>
</attList>
</elementSpec>

<elementSpec ident="bibl" mode="change">
<attList>
<attDef ident="type" mode="change">
<valList type="closed" mode="add">
<valItem ident="publication">
<gloss>Contains publication information as part of a parent
<gi>bibl</gi> element</gloss>
</valItem>
<valItem ident="source">
<gloss>(One of) the sources from which the information
in this record was gleaned</gloss>
</valItem>
</valList>
</attDef>
</attList>
</elementSpec>
</schemaSpec>
Expand Down
48 changes: 43 additions & 5 deletions tei/bbti.rng
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
xmlns:xlink="http://www.w3.org/1999/xlink"
datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes"
ns="http://www.tei-c.org/ns/1.0"><!--
Schema generated from ODD source 2024-12-29T01:58:07Z. .
Schema generated from ODD source 2024-12-29T02:04:38Z. .
TEI Edition: P5 Version 4.9.0a. Last updated on 27th December 2024, revision cd15f1132
TEI Edition Location: https://www.tei-c.org/Vault/P5/4.9.0a/
Expand Down Expand Up @@ -2752,7 +2752,20 @@ Sample values include: 1] main; 2] sub (subordinate); 3] alt (alternate); 4] sho
<ref name="att.global.attributes"/>
<ref name="att.declarable.attributes"/>
<ref name="att.docStatus.attributes"/>
<ref name="att.typed.attributes"/>
<ref name="att.typed.attribute.subtype"/>
<optional>
<attribute name="type">
<a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">characterizes the element in some sense, using any convenient classification scheme or typology.</a:documentation>
<choice>
<value>publication</value>
<a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(Contains publication information as part of a parent
bibl element) </a:documentation>
<value>source</value>
<a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">((One of) the sources from which the information
in this record was gleaned) </a:documentation>
</choice>
</attribute>
</optional>
<empty/>
</element>
</define>
Expand Down Expand Up @@ -2872,7 +2885,6 @@ Sample values include: 1] main; 2] sub (subordinate); 3] alt (alternate); 4] sho
</zeroOrMore>
<ref name="att.global.attributes"/>
<ref name="att.datable.attributes"/>
<ref name="att.typed.attribute.subtype"/>
<optional>
<attribute name="type">
<a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">categorizes the identifier, for example as an ISBN, Social Security number, etc.</a:documentation>
Expand Down Expand Up @@ -3035,8 +3047,21 @@ Sample values include: 1] main; 2] sub (subordinate); 3] alt (alternate); 4] sho
<ref name="category"/>
</zeroOrMore>
</group>
<ref name="att.global.attributes"/>
<ref name="att.global.attribute.n"/>
<ref name="att.global.attribute.xmllang"/>
<ref name="att.global.attribute.xmlbase"/>
<ref name="att.global.attribute.xmlspace"/>
<ref name="att.global.linking.attribute.corresp"/>
<ref name="att.global.rendition.attribute.style"/>
<ref name="att.global.rendition.attribute.rendition"/>
<ref name="att.global.responsibility.attribute.cert"/>
<ref name="att.global.responsibility.attribute.resp"/>
<ref name="att.global.source.attribute.source"/>
<ref name="att.datcat.attributes"/>
<attribute name="xml:id">
<a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(identifier) provides a unique identifier for the element bearing the attribute.</a:documentation>
<data type="ID"/>
</attribute>
<empty/>
</element>
</define>
Expand Down Expand Up @@ -3629,8 +3654,21 @@ Sample values include: 1] main; 2] sub (subordinate); 3] alt (alternate); 4] sho
<ref name="model.personLike"/>
</zeroOrMore>
</group>
<ref name="att.global.attributes"/>
<ref name="att.global.attribute.n"/>
<ref name="att.global.attribute.xmllang"/>
<ref name="att.global.attribute.xmlbase"/>
<ref name="att.global.attribute.xmlspace"/>
<ref name="att.global.linking.attribute.corresp"/>
<ref name="att.global.rendition.attribute.style"/>
<ref name="att.global.rendition.attribute.rendition"/>
<ref name="att.global.responsibility.attribute.cert"/>
<ref name="att.global.responsibility.attribute.resp"/>
<ref name="att.global.source.attribute.source"/>
<ref name="att.typed.attributes"/>
<attribute name="xml:id">
<a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(identifier) provides a unique identifier for the element bearing the attribute.</a:documentation>
<data type="ID"/>
</attribute>
<optional>
<attribute name="role">
<a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">specifies a primary role or classification for the organization.</a:documentation>
Expand Down

0 comments on commit ee9c1bc

Please sign in to comment.