summaryrefslogtreecommitdiff
path: root/data/domain/headings.osxml
diff options
context:
space:
mode:
authorAndreas Stöckel <astoecke@techfak.uni-bielefeld.de>2015-02-17 23:31:45 +0100
committerAndreas Stöckel <astoecke@techfak.uni-bielefeld.de>2015-02-17 23:31:45 +0100
commitf1d70c71e0444fc49a85459db85c9a6a139f0bd0 (patch)
tree15e12f14b76cb5b28360d0535f88cf7d691c8bc0 /data/domain/headings.osxml
parentbbc8b5a18f8b2f5ec0ae1de6e60c23464bd799b5 (diff)
Copied some domains and typesystems from the testdata folder to the data folder
Diffstat (limited to 'data/domain/headings.osxml')
-rw-r--r--data/domain/headings.osxml33
1 files changed, 33 insertions, 0 deletions
diff --git a/data/domain/headings.osxml b/data/domain/headings.osxml
new file mode 100644
index 0000000..055a204
--- /dev/null
+++ b/data/domain/headings.osxml
@@ -0,0 +1,33 @@
+<?xml version="1.0" standalone="yes"?>
+<domain name="headings">
+
+ <import rel="domain" src="book"/>
+
+ <struct name="heading" cardinality="1" transparent="true">
+ <!-- The parent mechanism is a curious thing. Remind yourself
+ that parent-child-relationship in this sense are mediated
+ by fields. So we must either reference a field that is
+ already there or declare a new one on the fly. -->
+ <parentRef ref="book.book">
+ <field name="heading" isSubtree="true" optional="true"/>
+ </parentRef>
+ <parentRef ref="book.chapter">
+ <field name="heading" isSubtree="true" optional="true"/>
+ </parentRef>
+ <parentRef ref="book.section">
+ <field name="heading" isSubtree="true" optional="true"/>
+ </parentRef>
+ <parentRef ref="book.subsection">
+ <field name="heading" isSubtree="true" optional="true"/>
+ </parentRef>
+ <parentRef ref="book.paragraph">
+ <field name="heading" isSubtree="true" optional="true"/>
+ </parentRef>
+ <!-- regarding its fields we have a problem here. We do not want to
+ declare a new field, because in fact we want to allow every
+ bit of content that a paragraph would allow - also considering
+ possible extensions of paragraph by other domains.
+ So we need to reference the default field of paragraph. -->
+ <fieldRef ref="book.paragraph.$default"/>
+ </struct>
+</domain>