IssueID #937: added xsd schema for lexonomy format
This commit is contained in:
parent
ff5a1cc3de
commit
51a0f3cc22
222
resources/schema/lexonomy.xsd
Normal file
222
resources/schema/lexonomy.xsd
Normal file
|
@ -0,0 +1,222 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
|
||||||
|
<xsd:import namespace="http://www.w3.org/XML/1998/namespace"
|
||||||
|
schemaLocation="http://www.w3.org/2001/xml.xsd" />
|
||||||
|
|
||||||
|
<xsd:complexType name="headwordType">
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="lemma"/>
|
||||||
|
<xsd:element name="homonymy" minOccurs="0">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="feature" maxOccurs="unbounded">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:simpleContent>
|
||||||
|
<xsd:extension base="xsd:string">
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required"/>
|
||||||
|
</xsd:extension>
|
||||||
|
</xsd:simpleContent>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:complexType name="lexical_unitType">
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="lexeme" minOccurs="0" maxOccurs="unbounded">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:simpleContent>
|
||||||
|
<xsd:extension base="xsd:string">
|
||||||
|
<xsd:attribute name="lexical_unit_lexeme_id" type="xsd:int" use="required"/>
|
||||||
|
</xsd:extension>
|
||||||
|
</xsd:simpleContent>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="id" type="xsd:int" use="required"/>
|
||||||
|
<xsd:attribute name="type" type="xsd:string" use="required"/>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:simpleType name="categoryType">
|
||||||
|
<!-- The closed set of expected categories. -->
|
||||||
|
<xsd:restriction base="xsd:string">
|
||||||
|
<xsd:enumeration value="samostalnik"/>
|
||||||
|
<xsd:enumeration value="glagol"/>
|
||||||
|
<xsd:enumeration value="pridevnik"/>
|
||||||
|
<xsd:enumeration value="prislov"/>
|
||||||
|
<xsd:enumeration value="zaimek"/>
|
||||||
|
<xsd:enumeration value="števnik"/>
|
||||||
|
<xsd:enumeration value="predlog"/>
|
||||||
|
<xsd:enumeration value="veznik"/>
|
||||||
|
<xsd:enumeration value="členek"/>
|
||||||
|
<xsd:enumeration value="medmet"/>
|
||||||
|
<xsd:enumeration value="okrajšava"/>
|
||||||
|
<xsd:enumeration value="neuvrščeno"/>
|
||||||
|
</xsd:restriction>
|
||||||
|
</xsd:simpleType>
|
||||||
|
|
||||||
|
<xsd:complexType name="grammarType">
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="category" type="categoryType"/>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:complexType name="measureListType">
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="measure" minOccurs="0" maxOccurs="unbounded">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:simpleContent>
|
||||||
|
<xsd:extension base="xsd:decimal">
|
||||||
|
<xsd:attribute name="type" type="xsd:string" use="required"/>
|
||||||
|
<xsd:attribute name="source" type="xsd:string" use="required"/>
|
||||||
|
</xsd:extension>
|
||||||
|
</xsd:simpleContent>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:complexType name="variantListType">
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="variant" minOccurs="0" maxOccurs="unbounded">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:simpleContent>
|
||||||
|
<xsd:extension base="xsd:string">
|
||||||
|
<xsd:attribute name="lexical_unit_id" type="xsd:int" use="required"/>
|
||||||
|
</xsd:extension>
|
||||||
|
</xsd:simpleContent>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:complexType name="labelListType">
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="label" minOccurs="0" maxOccurs="unbounded">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:simpleContent>
|
||||||
|
<xsd:extension base="xsd:string">
|
||||||
|
<xsd:attribute name="type" type="xsd:string" use="required"/>
|
||||||
|
</xsd:extension>
|
||||||
|
</xsd:simpleContent>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:complexType name="definitionListType">
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="definition" minOccurs="0" maxOccurs="unbounded">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:simpleContent>
|
||||||
|
<xsd:extension base="xsd:string">
|
||||||
|
<xsd:attribute name="type" type="xsd:string"/>
|
||||||
|
</xsd:extension>
|
||||||
|
</xsd:simpleContent>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:complexType name="translationType">
|
||||||
|
<xsd:simpleContent>
|
||||||
|
<xsd:extension base="xsd:string">
|
||||||
|
<xsd:attribute name="targetLang" type="xsd:string" use="required"/>
|
||||||
|
</xsd:extension>
|
||||||
|
</xsd:simpleContent>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:complexType name="translationContainerType">
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="labelList" type="labelListType"/>
|
||||||
|
<xsd:element name="translation" type="translationType"/>
|
||||||
|
<xsd:element name="explanation" type="xsd:string" minOccurs="0"/>
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="cluster" type="xsd:int" use="optional"/>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:complexType name="translationContainerListType">
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="translationContainer" type="translationContainerType" minOccurs="0" maxOccurs="unbounded"/>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:complexType name="exampleType" mixed="true">
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="h" type="xsd:string"/>
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="corpus_id" type="xsd:int" use="required"/>
|
||||||
|
<xsd:attribute name="modified" type="xsd:string" use="required"/>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:complexType name="exampleContainerType">
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="example" type="exampleType"/>
|
||||||
|
<xsd:element name="translationContainer" type="translationContainerType"/>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:complexType name="exampleContainerListType">
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="exampleContainer" type="exampleContainerType" minOccurs="0" maxOccurs="unbounded"/>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
|
||||||
|
<xsd:element name="dictionary">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
|
||||||
|
<xsd:element name="entry">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
|
||||||
|
<xsd:element name="head">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="status" type="xsd:string"/>
|
||||||
|
<xsd:element name="headword" type="headwordType"/>
|
||||||
|
<xsd:element name="lexical_unit" type="lexical_unitType"/>
|
||||||
|
<xsd:element name="grammar" type="grammarType"/>
|
||||||
|
<xsd:element name="measureList" type="measureListType"/>
|
||||||
|
<xsd:element name="variantList" type="variantListType"/>
|
||||||
|
<xsd:element name="labelList" type="labelListType"/>
|
||||||
|
<xsd:element name="comment" type="xsd:string"/>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
|
||||||
|
<xsd:element name="body">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="senseList">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="sense" maxOccurs="unbounded">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="labelList" type="labelListType"/>
|
||||||
|
<xsd:element name="definitionList" type="definitionListType"/>
|
||||||
|
<xsd:element name="translationContainerList" type="translationContainerListType"/>
|
||||||
|
<xsd:element name="exampleContainerList" type="exampleContainerListType"/>
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="id" type="xsd:int" use="required"/>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
|
||||||
|
</xsd:sequence>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
|
||||||
|
</xsd:schema>
|
Loading…
Reference in New Issue
Block a user