datatypes xsd = "http://www.w3.org/2001/XMLSchema-datatypes" start = document document = element document { head, body } head = element head { element organization { "ISO" | "ISO/IEC" } & element document-type { "International Standard" | "Technical Report" | "Guide" | "Publicly Available Specification" | "Technical Specification" | "International Standardized Profile" } & element stage { "preparatory" | "committee" | finalCommittee | "enquiry" | "approval" | "publication" } & element tc-number { positive-integer } & element tc-name { text } & (element sc-number { positive-integer } & element sc-name { text })? & element wg-number { positive-integer }? & element serial-number { positive-integer }? & element draft-number { positive-integer }? & element document-number { positive-integer } & element part-number { non-negative-integer }? & element document-language { "E" | "F" } & element secretariat { text } & element date { xsd:date } & element title { element introductory { text }?, element main { text }, element complementary { text }? } } positive-integer = xsd:token { pattern = "[1-9][0-9]*" } non-negative-integer = xsd:token { pattern = "[1-9][0-9]*" } | "0" body = foreword, introduction?, scope, normative-references?, terms-and-definitions?, titled-clause+, annex*, bibliography? foreword = element foreword { p* & part-list? } part-list = element part-list { element part { element number { non-negative-integer }, element title { text } }+ } title = element title { title-content } title-content = (text | element code { title-content })* clause-content = (titled-clause, titled-clause+) | untitled-clause-content untitled-clause-content = (untitled-clause, untitled-clause+) | block+ introduction = element introduction { block+ } scope = element scope { block+ } normative-references = element normative-references { p*, referenced-document+ } referenced-document = element referenced-document { id, element abbrev { text }, element title { text }, element field { text }*, element url { xsd:anyURI } } # boilerplate generated automatically # need markup for supplementary sources of terms and definitions terms-and-definitions = element terms-and-definitions {p*, terms-and-definitions-content } terms-and-definitions-content = (term-and-definition | element clause { title, terms-and-definitions-content })+ term-and-definition = element term-and-definition { element term { text }, element term { attribute status { text }?, text }*, element definition { attribute subject-field { text }?, text }, (example | note)* }+ titled-clause = element clause { id, title, clause-content } untitled-clause = element clause { id, untitled-clause-content } annex = element annex { id, attribute normative { "true" | "false" }, title, clause-content } bibliography = element bibliography { referenced-document+ } block = p | ol | ul | example | note | pre | notation-list | ed ed = element ed { block+ } p = element p { inline } ol = element ol { element li { id, block+ }+ } ul = element ul { element li { block+ }+ } example = element example { (p|pre)+ } note = element note { p+ } notation-list = element notation-list { element notation-item { element notation { inline | symbol }, element notation-definition { p } }+ } pre = element pre { pre-content } pre-content = (text | element symbol {pre-content} | element var { pre-content })* inline = (text | element code {text | symbol} |b|i|var { inline } | fig | ref | firstterm | foot | strong )* foot = element foot { inline } fig = element fig { attribute ent { xsd:NMTOKEN } | ( attribute id { xsd:ID }?, attribute ent { xsd:NMTOKEN }, element caption { text } ) | attribute idref { xsd:IDREF } } ref = internal-refs | xref # "This part of ISO/IEC" # "This International Standard" internal-refs = element This { text } | element this { text } xref = element Xref { attribute to { xsd:IDREF } } | element xref { attribute to { xsd:IDREF } } id = attribute id { xsd:ID }? firstterm = element firstterm { text } strong = element strong { text }