]> Lady’s Gitweb - Vocab/commitdiff
Update ⛩📰 书社 to 0.13.3; “simplify” build
authorLady <redacted>
Wed, 1 Jan 2025 19:36:47 +0000 (14:36 -0500)
committerLady <redacted>
Sun, 12 Jan 2025 22:59:51 +0000 (17:59 -0500)
This now uses the official two‐step build mechanism instead of the
old hacked‐together one.

13 files changed:
\9b©ð\9f\93°
DTD
GNUmakefile
data/object_properties/¦is [moved from data/object_properties/is with 100% similarity]
parsers/ontology.xslt [moved from parsers/data/ontology.xslt with 86% similarity]
site/ontology.rdf [new file with mode: 0644]
transforms/cleanup.xslt [moved from transforms/data/cleanup.xslt with 72% similarity]
transforms/infer.xslt [moved from transforms/site/infer.xslt with 98% similarity]
transforms/metadata.xslt [moved from transforms/site/metadata.xslt with 84% similarity]
transforms/rdf.xslt [moved from transforms/data/rdf.xslt with 83% similarity]
transforms/render.xslt [moved from transforms/site/render.xslt with 98% similarity]
transforms/shared.xslt [new file with mode: 0644]
transforms/terms.xslt [moved from transforms/site/terms.xslt with 97% similarity]

index 884130a52be6bfe21e524498385cb6486495b383..5c2f4a2d2c9913196c6092f0f72a8c4ff6e76752 160000 (submodule)
@@ -1 +1 @@
-Subproject commit 884130a52be6bfe21e524498385cb6486495b383
+Subproject commit 5c2f4a2d2c9913196c6092f0f72a8c4ff6e76752
diff --git a/DTD b/DTD
index 577fb9108313afa124f4cf815aff3ed25d10a614..5e9b6fd43d9229d345129f27e0b58b512440eb6f 100644 (file)
--- a/DTD
+++ b/DTD
@@ -1,6 +1,6 @@
 <?xml encoding="UTF-8"?>
 <!--
 <?xml encoding="UTF-8"?>
 <!--
-SPDX-FileCopyrightText: 2024 Lady <https://www.ladys.computer/about/#lady>
+SPDX-FileCopyrightText: 2024, 2025 Lady <https://www.ladys.computer/about/#lady>
 SPDX-License-Identifier: CC0-1.0
 -->
 
 SPDX-License-Identifier: CC0-1.0
 -->
 
index 8714dc4062e3f22c171d344713f74c858c93c946..72bf2926996a29f4d453ec0f6e8d07ad447c6c08 100644 (file)
@@ -1,9 +1,9 @@
-# SPDX-FileCopyrightText: 2023-2024 Lady <https://www.ladys.computer/about/#lady>
+# SPDX-FileCopyrightText: 2023, 2024, 2025 Lady <https://www.ladys.computer/about/#lady>
 # SPDX-License-Identifier: MPL-2.0
 
 SHELL = /bin/sh
 
 # SPDX-License-Identifier: MPL-2.0
 
 SHELL = /bin/sh
 
-# Copyright © 2023–2024 Lady [@ Ladys Computer].
+# Copyright © 2023–2025 Lady [@ Ladys Computer].
 #
 # This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
 # If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
 #
 # This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
 # If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
@@ -19,12 +19,9 @@ TEST := test
 TOUCH := touch
 XARGS := xargs
 
 TOUCH := touch
 XARGS := xargs
 
-DATASRCDIR := data
-SITESRCDIR := site
+DATADIR := data
+SRCDIR := site
 BUILDDIR := build
 BUILDDIR := build
-DATABUILDDIR := build/data
-RDFBUILDDIR := build/rdf
-SITEBUILDDIR := build/site
 BUILDTARGET := .grass
 DESTDIR := public
 
 BUILDTARGET := .grass
 DESTDIR := public
 
@@ -32,56 +29,30 @@ THISDIR := $(patsubst %/,%,$(dir $(lastword $(MAKEFILE_LIST))))
 
 SHUSHE := .⛩📰
 MAKEOPTS := CP='$(CP)' FIND='$(FIND)' GIT='$(GIT)' MKDIR='$(MKDIR)' PRINTF='$(PRINTF)' RM='$(RM)' SED='$(SED)' TEST='$(TEST)' TOUCH='$(TOUCH)' XARGS='$(XARGS)'
 
 SHUSHE := .⛩📰
 MAKEOPTS := CP='$(CP)' FIND='$(FIND)' GIT='$(GIT)' MKDIR='$(MKDIR)' PRINTF='$(PRINTF)' RM='$(RM)' SED='$(SED)' TEST='$(TEST)' TOUCH='$(TOUCH)' XARGS='$(XARGS)'
-
-# Stage 1: Build R·D·F files to build/rdf
-SHUSHEDATAOPTS := $(MAKEOPTS) SRCDIR='$(DATASRCDIR)' INCLUDEDIR='$(DATASRCDIR)' BUILDDIR='$(DATABUILDDIR)' DESTDIR='$(RDFBUILDDIR)' EXTRAPARSERS='$(wildcard $(THISDIR)/parsers/data/*.xslt)' EXTRAPARSERLIBS='$(DATASRCDIR)/ontologies/¦' EXTRAFINDINCLUDERULES='-not '"'"'('"'"' '"'"'('"'"' -name ontologies -o -name profiles '"'"')'"'"' -a -type d -a -prune '"'"')'"'"'' EXTRATRANSFORMS='$(wildcard $(THISDIR)/transforms/data/*.xslt)'
-
-# Stage 2: Build the actual site
-SHUSHESITEOPTS := $(MAKEOPTS) SRCDIR='$(SITESRCDIR)' INCLUDEDIR='$(RDFBUILDDIR)' BUILDDIR='$(SITEBUILDDIR)' DESTDIR='$(DESTDIR)' EXTRAPARSERS='$(wildcard $(THISDIR)/parsers/site/*.xslt)' EXTRATRANSFORMS='$(wildcard $(THISDIR)/transforms/site/*.xslt)'
+SHUSHEOPTS := $(MAKEOPTS) SRCDIR='$(SRCDIR)' DATADIR='$(DATADIR)' BUILDDIR='$(BUILDDIR)' DESTDIR='$(BUILDDIR)/public' EXTRAPARSERS='$(wildcard $(THISDIR)/parsers/*.xslt)' EXTRAPARSERLIBS='$(DATADIR)/ontologies/¦' EXTRATRANSFORMS='$(wildcard $(THISDIR)/transforms/*.xslt)'
 
 YSEME := .👥📤
 
 YSEME := .👥📤
-YSEMEOPTS := $(MAKEOPTS) BUILDTARGET='.grass' DESTDIR='$(DESTDIR)' SERVERPATH='lady/vocab'
+YSEMEOPTS := $(MAKEOPTS) BUILDTARGET='$(BUILDTARGET)' DESTDIR='$(DESTDIR)' SERVERPATH='lady/vocab'
 
 
-xmls := $(wildcard $(DATASRCDIR)/*/*)
+xmls := $(wildcard $(DATADIR)/*/*)
 
 # ━ § Call out to ⛩📰 书社 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
 
 install : $(SHUSHE)/GNUmakefile build
 
 # ━ § Call out to ⛩📰 书社 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
 
 install : $(SHUSHE)/GNUmakefile build
-       @for publicfile in $(patsubst %,"%",$(wildcard $(DESTDIR)/*)); do if $(GIT) check-ignore -q "$$publicfile"; then $(RM) -rf "$$publicfile"; fi; done
-       @for target in $$($(MAKE) -s -f '$<' listout QUIET=1 $(SHUSHEDATAOPTS)); do $(PRINTF) '%s\n' "$$target" | $(SED) 's/¦/:/g' | $(XARGS) $(PRINTF) 'Copying </%s>…\n' >&2; $(PRINTF) '%s\n' "$$target" | $(SED) 's:^:$(DESTDIR)/:;s/¦/:/g' | $(XARGS) $(CP) '$(RDFBUILDDIR)/'"$$target"; done
-       @for target in $$($(MAKE) -s -f '$<' listout QUIET=1 $(SHUSHESITEOPTS)); do for dir in $$($(FIND) "$(SITEBUILDDIR)/public/$$target" -not -name '.*' -and -type d); do if $(TEST) '!' -d "$(DESTDIR)/$$dir"; then $(PRINTF) '%s\n' "$$dir" | $(SED) 's:$(SITEBUILDDIR)/public/:$(DESTDIR)/:' | $(XARGS) $(MKDIR) -p; fi; done; for file in $$($(FIND) "$(SITEBUILDDIR)/public/$$target" -not '(' -name '.*' -or -type d ')'); do $(PRINTF) '%s\n' "$$file" | $(SED) 's:$(SITEBUILDDIR)/public/:/:;s:/_\(.*\)_\(\..*\)$$:/(\1)\2:g;s/¦/:/g' | $(XARGS) $(PRINTF) 'Copying <%s>…\n' >&2; $(PRINTF) '%s\n' "$$file" | $(SED) 's:$(SITEBUILDDIR)/public/:$(DESTDIR)/:;s:/_\(.*\)_\(\..*\)$$:/(\1)\2:g;s/¦/:/g' | $(XARGS) $(CP) "$$file"; done; done
+       @for publicfile in $(patsubst %,"%",$(shell $(FIND) '$(DESTDIR)'/*)); do if $(GIT) check-ignore -q "$$publicfile"; then $(RM) -R -f "$$publicfile"; fi; done
+       @for dir in $$($(FIND) '$(BUILDDIR)/public' -type d | $(SED) 's:$(BUILDDIR)/public/::'); do if $(TEST) '!' -d "$(DESTDIR)/$$dir"; then $(MKDIR) -p "$(DESTDIR)/$$dir"; fi; done
+       @for file in $$($(FIND) '$(BUILDDIR)/public' -type f | $(SED) 's:$(BUILDDIR)/public/::'); do $(PRINTF) '%s\n' "$$file" | $(SED) 's:/_\(.*\)_\(\..*\)$$:/(\1)\2:g;s/¦/:/g' | $(XARGS) $(PRINTF) 'Copying <%s>…\n' >&2; $(PRINTF) '%s\n' "$$file" | $(SED) 's:^:$(DESTDIR)/:;s:/_\(.*\)_\(\..*\)$$:/(\1)\2:g;s/¦/:/g' | $(XARGS) $(CP) "$(BUILDDIR)/public/$$file"; done
        $(TOUCH) '$(BUILDTARGET)'
 
 build : $(SHUSHE)/GNUmakefile
        $(TOUCH) '$(BUILDTARGET)'
 
 build : $(SHUSHE)/GNUmakefile
-       @$(RM) -rf '$(RDFBUILDDIR)/profiles'
-       @$(MAKE) -f '$<' install $(SHUSHEDATAOPTS)
-       @$(MAKE) -f '$<' $(SHUSHESITEOPTS)
-
-clean : $(SHUSHE)/GNUmakefile
-       @$(MAKE) -f '$<' $@ $(SHUSHEDATAOPTS)
-       @$(RM) -rf '$(RDFBUILDDIR)'
-       @$(MAKE) -f '$<' $@ $(SHUSHESITEOPTS)
-
-list listout : $(SHUSHE)/GNUmakefile
-       @$(RM) -rf '$(RDFBUILDDIR)/profiles'
-       @$(MAKE) -f '$<' install $(SHUSHEDATAOPTS)
-       @$(MAKE) -f '$<' $@ $(SHUSHESITEOPTS)
-
-$(BUILDDIR)/data/% : $(SHUSHE)/GNUmakefile FORCE
-       @$(MAKE) -f '$<' $@ $(SHUSHEDATAOPTS)
-
-$(BUILDDIR)/rdf/% : $(SHUSHE)/GNUmakefile FORCE
-       @$(MAKE) -f '$<' $@ $(SHUSHEDATAOPTS)
-
-$(BUILDDIR)/site/% : $(SHUSHE)/GNUmakefile FORCE
-       @$(RM) -rf '$(RDFBUILDDIR)/profiles'
-       @$(MAKE) -f '$<' install $(SHUSHEDATAOPTS)
-       @$(MAKE) -f '$<' $@ $(SHUSHESITEOPTS)
-
-$(DESTDIR)/% : $(SHUSHE)/GNUmakefile FORCE
-       @$(RM) -rf '$(RDFBUILDDIR)/profiles'
-       @$(MAKE) -f '$<' install $(SHUSHEDATAOPTS)
-       @$(MAKE) -f '$<' $@ $(SHUSHESITEOPTS)
+       @$(RM) -R -f '$(BUILDDIR)/public'
+       @$(MAKE) -f '$<' install $(SHUSHEOPTS)
+
+clean list listout : $(SHUSHE)/GNUmakefile
+       @$(MAKE) -f '$<' $@ $(SHUSHEOPTS)
+
+$(BUILDDIR)/% : $(SHUSHE)/GNUmakefile FORCE
+       @$(MAKE) -f '$<' $@ $(SHUSHEOPTS)
 
 # ━ § Call out to 👥📤 Yseme ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
 
 
 # ━ § Call out to 👥📤 Yseme ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
 
similarity index 86%
rename from parsers/data/ontology.xslt
rename to parsers/ontology.xslt
index b5d7bf249c1e4dfd3874b8f205d1c1167512e8e0..bd5d7b729566a9af581ba2c6a62ea22cc7e0bda5 100644 (file)
@@ -1,10 +1,10 @@
 <?xml version="1.0"?>
 <!--
 <?xml version="1.0"?>
 <!--
-SPDX-FileCopyrightText: 2024 Lady <https://www.ladys.computer/about/#lady>
+SPDX-FileCopyrightText: 2024, 2025 Lady <https://www.ladys.computer/about/#lady>
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
-© 2024 Lady [@ Ladys Computer].
+© 2024–2025 Lady [@ Ladys Computer].
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
@@ -34,7 +34,7 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
        exclude-result-prefixes="Vocab"
        version="1.0"
 >
        exclude-result-prefixes="Vocab"
        version="1.0"
 >
-       <书社:id>urn:fdc:vocab.ladys.computer:20240731:parsers:data:ontology.xslt</书社:id>
+       <书社:id>urn:fdc:vocab.ladys.computer:20240731:parsers:ontology.xslt</书社:id>
        <template name="Vocab:local-name">
                <choose>
                        <when test="substring-after($IDENTIFIER, '/')=''"/>
        <template name="Vocab:local-name">
                <choose>
                        <when test="substring-after($IDENTIFIER, '/')=''"/>
@@ -59,7 +59,7 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
        </template>
        <template name="Vocab:prefix">
                <param name="unprefixed" select="''"/>
        </template>
        <template name="Vocab:prefix">
                <param name="unprefixed" select="''"/>
-               <variable name="namespace" select="document('../../data/ontologies/%C2%A6')/Ontology/declare/namespace[starts-with($unprefixed, string())][1]"/>
+               <variable name="namespace" select="document('../data/ontologies/%C2%A6')/Ontology/declare/namespace[starts-with($unprefixed, string())][1]"/>
                <choose>
                        <when test="not($namespace)">
                                <value-of select="$unprefixed"/>
                <choose>
                        <when test="not($namespace)">
                                <value-of select="$unprefixed"/>
@@ -76,14 +76,14 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
                <variable name="prefix" select="substring-before($prefixed, ':')"/>
                <choose>
                        <when test="not(contains($prefixed, ':'))">
                <variable name="prefix" select="substring-before($prefixed, ':')"/>
                <choose>
                        <when test="not(contains($prefixed, ':'))">
-                               <value-of select="document('../../data/ontologies/%C2%A6')/Ontology/declare/prefix[string()='']/following-sibling::namespace"/>
+                               <value-of select="document('../data/ontologies/%C2%A6')/Ontology/declare/prefix[string()='']/following-sibling::namespace"/>
                                <value-of select="$prefixed"/>
                        </when>
                                <value-of select="$prefixed"/>
                        </when>
-                       <when test="not(document('../../data/ontologies/%C2%A6')/Ontology/declare/prefix[string()=$prefix])">
+                       <when test="not(document('../data/ontologies/%C2%A6')/Ontology/declare/prefix[string()=$prefix])">
                                <value-of select="$prefixed"/>
                        </when>
                        <otherwise>
                                <value-of select="$prefixed"/>
                        </when>
                        <otherwise>
-                               <value-of select="document('../../data/ontologies/%C2%A6')/Ontology/declare/prefix[string()=$prefix]/following-sibling::namespace"/>
+                               <value-of select="document('../data/ontologies/%C2%A6')/Ontology/declare/prefix[string()=$prefix]/following-sibling::namespace"/>
                                <value-of select="substring-after($prefixed, ':')"/>
                        </otherwise>
                </choose>
                                <value-of select="substring-after($prefixed, ':')"/>
                        </otherwise>
                </choose>
@@ -110,51 +110,29 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
                <variable name="local-name">
                        <call-template name="Vocab:local-name"/>
                </variable>
                <variable name="local-name">
                        <call-template name="Vocab:local-name"/>
                </variable>
-               <element name="rdf:RDF">
-                       <attribute name="书社:destination">
-                               <choose>
-                                       <when test="$local-name=''">
-                                               <text>ontology</text>
-                                       </when>
-                                       <otherwise>
-                                               <value-of select="translate($local-name, ':', '¦')"/>
-                                       </otherwise>
-                               </choose>
-                               <text>.rdf</text>
-                       </attribute>
-                       <attribute name="xml:base">
-                               <call-template name="Vocab:unprefix"/>
-                       </attribute>
-                       <!--
-                       The ontology element is “manually” created by the parser in order to provide dynamic control over its name·spaces, as X·S·L·T provides no mechanism for creating name·space nodes.
+               <!--
+               The ontology element is “manually” created by the parser in order to provide dynamic control over its name·spaces, as X·S·L·T provides no mechanism for creating name·space nodes.
 
 
-                       (Technically, name·space nodes can be created with the `@namespace´ property on `<xslt:element>´, but the resulting prefix is, ⅌ the specification text, implementation‐specific.)
-                       -->
-                       <text disable-output-escaping="yes">&lt;owl:Ontology</text>
-                       <for-each select="declare">
-                               <text disable-output-escaping="yes"> xmlns</text>
-                               <if test="string(prefix)!=''">
-                                       <text disable-output-escaping="yes">:</text>
-                               </if>
-                               <value-of select="prefix"/>
-                               <text disable-output-escaping="yes">=&quot;</text>
-                               <value-of select="namespace"/>
-                               <text disable-output-escaping="yes">&quot;</text>
-                       </for-each>
-                       <text disable-output-escaping="yes"> rdf:about=&quot;</text>
-                       <call-template name="Vocab:unprefix">
-                               <with-param name="prefixed" select="$local-name"/>
-                       </call-template>
-                       <text disable-output-escaping="yes">&quot;&gt;</text>
-                       &continue;
-                       <text disable-output-escaping="yes">&lt;/owl:Ontology&gt;</text>
-                       <书社:link xlink:href="about:shushe?include=classes/" xlink:show="embed"/>
-                       <书社:link xlink:href="about:shushe?include=datatypes/" xlink:show="embed"/>
-                       <书社:link xlink:href="about:shushe?include=annotation_properties/" xlink:show="embed"/>
-                       <书社:link xlink:href="about:shushe?include=object_properties/" xlink:show="embed"/>
-                       <书社:link xlink:href="about:shushe?include=datatype_properties/" xlink:show="embed"/>
-                       <书社:link xlink:href="about:shushe?include=named_individuals/" xlink:show="embed"/>
-               </element>
+               (Technically, name·space nodes can be created with the `@namespace´ property on `<xslt:element>´, but the resulting prefix is, ⅌ the specification text, implementation‐specific.)
+               -->
+               <text disable-output-escaping="yes">&lt;owl:Ontology</text>
+               <for-each select="declare">
+                       <text disable-output-escaping="yes"> xmlns</text>
+                       <if test="string(prefix)!=''">
+                               <text disable-output-escaping="yes">:</text>
+                       </if>
+                       <value-of select="prefix"/>
+                       <text disable-output-escaping="yes">=&quot;</text>
+                       <value-of select="namespace"/>
+                       <text disable-output-escaping="yes">&quot;</text>
+               </for-each>
+               <text disable-output-escaping="yes"> rdf:about=&quot;</text>
+               <call-template name="Vocab:unprefix">
+                       <with-param name="prefixed" select="$local-name"/>
+               </call-template>
+               <text disable-output-escaping="yes">&quot;&gt;</text>
+               &continue;
+               <text disable-output-escaping="yes">&lt;/owl:Ontology&gt;</text>
        </template>
        <template match="SpecificResource" priority="2">
                <choose>
        </template>
        <template match="SpecificResource" priority="2">
                <choose>
@@ -380,7 +358,7 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
                </choose>
        </template>
        <template match="DatatypeProperty/@functional|ObjectProperty/@functional|ObjectProperty/@inverseFunctional|ObjectProperty/@reflexive|ObjectProperty/@irreflexive|ObjectProperty/@symmetric|ObjectProperty/@asymmetric|ObjectProperty/@transitive" priority="2"/>
                </choose>
        </template>
        <template match="DatatypeProperty/@functional|ObjectProperty/@functional|ObjectProperty/@inverseFunctional|ObjectProperty/@reflexive|ObjectProperty/@irreflexive|ObjectProperty/@symmetric|ObjectProperty/@asymmetric|ObjectProperty/@transitive" priority="2"/>
-       <template match="@*[namespace-uri()='']" priority="1">
+       <template match="*[namespace-uri()='']/@*[namespace-uri()='']" priority="1">
                <message terminate="yes">
                        <text>Error: Unrecognized attribute in null namespace: @</text>
                        <value-of select="local-name()"/>
                <message terminate="yes">
                        <text>Error: Unrecognized attribute in null namespace: @</text>
                        <value-of select="local-name()"/>
@@ -688,17 +666,22 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
                        </if>
                </element>
        </template>
                        </if>
                </element>
        </template>
-       <template match="text()[ancestor::cell or ancestor::p]" priority="1">
+       <template match="*[namespace-uri()='']/text()[ancestor::cell or ancestor::p]" priority="1">
                <variable name="normalized" select="normalize-space()"/>
                <variable name="normalized" select="normalize-space()"/>
-               <if test="$normalized!=''">
-                       <if test="preceding-sibling::* and normalize-space(substring(., 1, 1))=''">
-                               <text> </text>
-                       </if>
-                       <value-of select="$normalized"/>
-                       <if test="following-sibling::* and normalize-space(substring(., string-length(), 1))=''">
+               <choose>
+                       <when test="$normalized!=''">
+                               <if test="preceding-sibling::* and normalize-space(substring(., 1, 1))=''">
+                                       <text> </text>
+                               </if>
+                               <value-of select="$normalized"/>
+                               <if test="following-sibling::* and normalize-space(substring(., string-length(), 1))=''">
+                                       <text> </text>
+                               </if>
+                       </when>
+                       <when test="preceding-sibling::node()[position()=1 and self::*] and following-sibling::node()[position()=1 and self::*]">
                                <text> </text>
                                <text> </text>
-                       </if>
-               </if>
+                       </when>
+               </choose>
        </template>
        </template>
-       <template match="text()[not(ancestor::cell or ancestor::p) and normalize-space()='']" priority="1"/>
+       <template match="*[namespace-uri()='']/text()[not(ancestor::cell or ancestor::p) and normalize-space()='']" priority="1"/>
 </transform>
 </transform>
diff --git a/site/ontology.rdf b/site/ontology.rdf
new file mode 100644 (file)
index 0000000..169fc1d
--- /dev/null
@@ -0,0 +1,18 @@
+<?xml version="1.0"?>
+<!--
+SPDX-FileCopyrightText: 2025 Lady <https://www.ladys.computer/about/#lady>
+SPDX-License-Identifier: CC0-1.0
+-->
+<rdf:RDF
+       xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+       xmlns:xlink="http://www.w3.org/1999/xlink"
+       xmlns:书社="urn:fdc:ladys.computer:20231231:Shu1She4"
+>
+       <书社:link xlink:href="about:shushe?include=ontologies/" xlink:show="embed"/>
+       <书社:link xlink:href="about:shushe?include=classes/" xlink:show="embed"/>
+       <书社:link xlink:href="about:shushe?include=datatypes/" xlink:show="embed"/>
+       <书社:link xlink:href="about:shushe?include=annotation_properties/" xlink:show="embed"/>
+       <书社:link xlink:href="about:shushe?include=object_properties/" xlink:show="embed"/>
+       <书社:link xlink:href="about:shushe?include=datatype_properties/" xlink:show="embed"/>
+       <书社:link xlink:href="about:shushe?include=named_individuals/" xlink:show="embed"/>
+</rdf:RDF>
similarity index 72%
rename from transforms/data/cleanup.xslt
rename to transforms/cleanup.xslt
index 0422f094e15257b09b6672e2a2d98e3bb36d2991..f572d607b32a2091b7f4c2756fc5942338c72cfb 100644 (file)
@@ -1,10 +1,10 @@
 <?xml version="1.0"?>
 <!--
 <?xml version="1.0"?>
 <!--
-SPDX-FileCopyrightText: 2024 Lady <https://www.ladys.computer/about/#lady>
+SPDX-FileCopyrightText: 2024, 2025 Lady <https://www.ladys.computer/about/#lady>
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
-© 2024 Lady [@ Ladys Computer].
+© 2024–2025 Lady [@ Ladys Computer].
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
@@ -22,7 +22,7 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
        version="1.0"
 >
        <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:cleanup.xslt</书社:id>
        version="1.0"
 >
        <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:cleanup.xslt</书社:id>
-       <template match="/rdf:RDF" mode="书社:apply">
+       <template match="/rdf:RDF" mode="书社:finalize">
                <variable name="fragment">
                        <书社:raw-text>
                                <text>&lt;?xml version="1.0"?></text>
                <variable name="fragment">
                        <书社:raw-text>
                                <text>&lt;?xml version="1.0"?></text>
@@ -31,15 +31,15 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
                                                <for-each select="owl:Ontology/namespace::*">
                                                        <copy/>
                                                </for-each>
                                                <for-each select="owl:Ontology/namespace::*">
                                                        <copy/>
                                                </for-each>
-                                               <apply-templates mode="书社:apply"/>
+                                               <apply-templates mode="书社:finalize"/>
                                        </element>
                                </element>
                        </书社:raw-text>
                </variable>
                                        </element>
                                </element>
                        </书社:raw-text>
                </variable>
-               <apply-templates select="exsl:node-set($fragment)" mode="书社:apply"/>
+               <apply-templates select="exsl:node-set($fragment)" mode="书社:finalize"/>
        </template>
        </template>
-       <template match="/rdf:RDF//@xlink:*|/rdf:RDF//@书社:*|/rdf:RDF//书社:*|/rdf:RDF//text()[not(ancestor::html:*/ancestor::rdf:RDF) and normalize-space()='']|/rdf:RDF//comment()" mode="书社:apply" priority="10"/>
-       <template match="/rdf:RDF//text()[not(ancestor::html:*/ancestor::rdf:RDF) and normalize-space()!='']" mode="书社:apply" priority="10">
+       <template match="/rdf:RDF//@xlink:*|/rdf:RDF//@书社:*|/rdf:RDF//书社:*|/rdf:RDF//text()[not(ancestor::html:*) and normalize-space()='']|/rdf:RDF//comment()" mode="书社:finalize" priority="10"/>
+       <template match="/rdf:RDF//text()[not(ancestor::html:*) and normalize-space()!='']" mode="书社:finalize" priority="10">
                <value-of select="normalize-space()"/>
        </template>
 </transform>
                <value-of select="normalize-space()"/>
        </template>
 </transform>
similarity index 98%
rename from transforms/site/infer.xslt
rename to transforms/infer.xslt
index 38ad449a893b531d3f209d9d7a8a170578b614d0..056e57a7d8b0b4d8ec52dfc1da5c5f0787f1bcb7 100644 (file)
@@ -1,15 +1,14 @@
 <?xml version="1.0"?>
 <!--
 <?xml version="1.0"?>
 <!--
-SPDX-FileCopyrightText: 2024 Lady <https://www.ladys.computer/about/#lady>
+SPDX-FileCopyrightText: 2024, 2025 Lady <https://www.ladys.computer/about/#lady>
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
-© 2024 Lady [@ Ladys Computer].
+© 2024–2025 Lady [@ Ladys Computer].
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
 -->
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
 -->
-
 <transform
        xmlns="http://www.w3.org/1999/XSL/Transform"
        xmlns:Vocab="urn:fdc:vocab.ladys.computer:20240731:ns"
 <transform
        xmlns="http://www.w3.org/1999/XSL/Transform"
        xmlns:Vocab="urn:fdc:vocab.ladys.computer:20240731:ns"
@@ -24,7 +23,7 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
        extension-element-prefixes="exsl exslfunc"
        version="1.0"
 >
        extension-element-prefixes="exsl exslfunc"
        version="1.0"
 >
-       <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:site:infer.xslt</书社:id>
+       <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:infer.xslt</书社:id>
        <key name="Vocab:equivalent-class" match="owl:Class|owl:Restriction|rdfs:Datatype" use="owl:equivalentClass/@rdf:resource"/>
        <key name="Vocab:equivalent-property" match="owl:AnnotationProperty|owl:DatatypeProperty|owl:ObjectProperty" use="owl:equivalentProperty/@rdf:resource"/>
        <key name="Vocab:equivalent-individual" match="owl:NamedIndividual" use="owl:sameAs/@rdf:resource"/>
        <key name="Vocab:equivalent-class" match="owl:Class|owl:Restriction|rdfs:Datatype" use="owl:equivalentClass/@rdf:resource"/>
        <key name="Vocab:equivalent-property" match="owl:AnnotationProperty|owl:DatatypeProperty|owl:ObjectProperty" use="owl:equivalentProperty/@rdf:resource"/>
        <key name="Vocab:equivalent-individual" match="owl:NamedIndividual" use="owl:sameAs/@rdf:resource"/>
similarity index 84%
rename from transforms/site/metadata.xslt
rename to transforms/metadata.xslt
index 92f6135aa4443fa837263e2de4f5a6c6aa55c72c..495a7ee88a9874e7675f5d6e56d70b8dc04d3498 100644 (file)
@@ -1,10 +1,10 @@
 <?xml version="1.0"?>
 <!--
 <?xml version="1.0"?>
 <!--
-SPDX-FileCopyrightText: 2024 Lady <https://www.ladys.computer/about/#lady>
+SPDX-FileCopyrightText: 2024, 2025 Lady <https://www.ladys.computer/about/#lady>
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
-© 2024 Lady [@ Ladys Computer].
+© 2024–2025 Lady [@ Ladys Computer].
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
@@ -15,8 +15,8 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
        xmlns:书社="urn:fdc:ladys.computer:20231231:Shu1She4"
        version="1.0"
 >
        xmlns:书社="urn:fdc:ladys.computer:20231231:Shu1She4"
        version="1.0"
 >
-       <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:site:metadata.xslt</书社:id>
-       <template match="书社:id[string()='urn:fdc:vocab.ladys.computer:20240731:transforms:site:metadata.xslt']" mode="书社:metadata">
+       <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:metadata.xslt</书社:id>
+       <template match="书社:id[string()='urn:fdc:vocab.ladys.computer:20240731:transforms:metadata.xslt']" mode="书社:metadata">
                <element name="html:meta">
                        <attribute name="name">
                                <text>viewport</text>
                <element name="html:meta">
                        <attribute name="name">
                                <text>viewport</text>
similarity index 83%
rename from transforms/data/rdf.xslt
rename to transforms/rdf.xslt
index 420dfda3507eef2c00c09095a326e46cba1d0a2c..528f4fb04d65c930f97930fe11751b8942714ee1 100644 (file)
@@ -1,10 +1,10 @@
 <?xml version="1.0"?>
 <!--
 <?xml version="1.0"?>
 <!--
-SPDX-FileCopyrightText: 2024 Lady <https://www.ladys.computer/about/#lady>
+SPDX-FileCopyrightText: 2024, 2025 Lady <https://www.ladys.computer/about/#lady>
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
-© 2024 Lady [@ Ladys Computer].
+© 2024–2025 Lady [@ Ladys Computer].
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
@@ -22,26 +22,17 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
        exclude-result-prefixes="Vocab Vocabvocab"
        version="1.0"
 >
        exclude-result-prefixes="Vocab Vocabvocab"
        version="1.0"
 >
-       <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:data:rdf.xslt</书社:id>
+       <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:rdf.xslt</书社:id>
        <key name="Vocab:name" match="owl:AnnotationProperty|owl:Class|owl:DatatypeProperty|owl:NamedIndividual|owl:ObjectProperty|rdfs:Datatype" use="@rdf:about|owl:sameAs/@rdf:resource"/>
        <key name="Vocab:name" match="owl:AnnotationProperty|owl:Class|owl:DatatypeProperty|owl:NamedIndividual|owl:ObjectProperty|rdfs:Datatype" use="@rdf:about|owl:sameAs/@rdf:resource"/>
-       <template name="Vocab:base">
-               <value-of select="//rdf:RDF//owl:Ontology/shacl:declare/shacl:namespace[preceding-sibling::shacl:prefix='']"/>
-       </template>
-       <template name="Vocab:prefix">
-               <param name="unprefixed" select="''"/>
-               <variable name="namespace" select="//rdf:RDF//owl:Ontology/shacl:declare/shacl:namespace[starts-with($unprefixed, string()) and string(preceding-sibling::shacl:prefix)!=''][1]"/>
-               <choose>
-                       <when test="not($namespace)">
-                               <value-of select="$unprefixed"/>
-                       </when>
-                       <otherwise>
-                               <value-of select="$namespace/preceding-sibling::shacl:prefix"/>
-                               <text>:</text>
-                               <value-of select="substring-after($unprefixed, $namespace)"/>
-                       </otherwise>
-               </choose>
+       <template match="/rdf:RDF" priority="2">
+               <copy>
+                       <attribute name="xml:base">
+                               <call-template name="Vocab:base"/>
+                       </attribute>
+                       <apply-templates select="@*[not(local-name()='base' and namespace-uri()='http://www.w3.org/XML/1998/namespace')]|node()"/>
+               </copy>
        </template>
        </template>
-       <template match="rdf:RDF/*[@rdf:about and Vocabvocab:superClassOf]" priority="2">
+       <template match="/rdf:RDF/*[@rdf:about and Vocabvocab:superClassOf]" priority="2">
                <copy>
                        <apply-templates select="@*|node()[not(self::Vocabvocab:superClassOf)]"/>
                </copy>
                <copy>
                        <apply-templates select="@*|node()[not(self::Vocabvocab:superClassOf)]"/>
                </copy>
@@ -56,7 +47,7 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
                        </copy>
                </for-each>
        </template>
                        </copy>
                </for-each>
        </template>
-       <template match="@rdf:resource" priority="2">
+       <template match="/rdf:RDF//@rdf:resource" priority="2">
                <variable name="base-iri">
                        <call-template name="Vocab:base"/>
                </variable>
                <variable name="base-iri">
                        <call-template name="Vocab:base"/>
                </variable>
@@ -94,7 +85,7 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
                        </choose>
                </attribute>
        </template>
                        </choose>
                </attribute>
        </template>
-       <template match="html:a" priority="1">
+       <template match="/rdf:RDF//html:a" priority="1">
                <variable name="base-prefix">
                        <call-template name="Vocab:prefix">
                                <with-param name="unprefixed">
                <variable name="base-prefix">
                        <call-template name="Vocab:prefix">
                                <with-param name="unprefixed">
@@ -183,13 +174,13 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
                        </choose>
                </copy>
        </template>
                        </choose>
                </copy>
        </template>
-       <template match="html:a/@href[starts-with(., '#footnote-')]">
+       <template match="/rdf:RDF//html:a/@href[starts-with(., '#footnote-')]">
                <attribute name="href">
                        <text>#footnote-</text>
                        <value-of select="generate-id(ancestor::rdfs:comment//@id[string()=substring-after(current(), '#')])"/>
                </attribute>
        </template>
                <attribute name="href">
                        <text>#footnote-</text>
                        <value-of select="generate-id(ancestor::rdfs:comment//@id[string()=substring-after(current(), '#')])"/>
                </attribute>
        </template>
-       <template match="html:*/@id[starts-with(., 'footnote-')]" priority="1">
+       <template match="/rdf:RDF//html:*/@id[starts-with(., 'footnote-')]" priority="1">
                <attribute name="id">
                        <text>footnote-</text>
                        <value-of select="generate-id()"/>
                <attribute name="id">
                        <text>footnote-</text>
                        <value-of select="generate-id()"/>
similarity index 98%
rename from transforms/site/render.xslt
rename to transforms/render.xslt
index a0b50dfa0d9c98405867da33fea553427deea78f..40ff0a79f0db990c4f5ed4aa9a1ed0d5249f4ee2 100644 (file)
@@ -1,10 +1,10 @@
 <?xml version="1.0"?>
 <!--
 <?xml version="1.0"?>
 <!--
-SPDX-FileCopyrightText: 2024 Lady <https://www.ladys.computer/about/#lady>
+SPDX-FileCopyrightText: 2024, 2025 Lady <https://www.ladys.computer/about/#lady>
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
-© 2024 Lady [@ Ladys Computer].
+© 2024–2025 Lady [@ Ladys Computer].
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
@@ -24,7 +24,7 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
        exclude-result-prefixes="Vocab Vocabvocab"
        version="1.0"
 >
        exclude-result-prefixes="Vocab Vocabvocab"
        version="1.0"
 >
-       <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:site:render.xslt</书社:id>
+       <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:render.xslt</书社:id>
        <template name="Vocab:more-info">
                <element name="html:span">
                        &en;
        <template name="Vocab:more-info">
                <element name="html:span">
                        &en;
diff --git a/transforms/shared.xslt b/transforms/shared.xslt
new file mode 100644 (file)
index 0000000..d59cbdc
--- /dev/null
@@ -0,0 +1,41 @@
+<?xml version="1.0"?>
+<!--
+SPDX-FileCopyrightText: 2024, 2025 Lady <https://www.ladys.computer/about/#lady>
+SPDX-License-Identifier: MPL-2.0
+-->
+<!--
+© 2024–2025 Lady [@ Ladys Computer].
+
+This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
+If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
+-->
+
+<transform
+       xmlns="http://www.w3.org/1999/XSL/Transform"
+       xmlns:Vocab="urn:fdc:vocab.ladys.computer:20240731:ns"
+       xmlns:owl="http://www.w3.org/2002/07/owl#"
+       xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+       xmlns:shacl="http://www.w3.org/ns/shacl#"
+       xmlns:书社="urn:fdc:ladys.computer:20231231:Shu1She4"
+       exclude-result-prefixes="Vocab"
+       version="1.0"
+>
+       <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:shared.xslt</书社:id>
+       <template name="Vocab:base">
+               <value-of select="//rdf:RDF//owl:Ontology/shacl:declare/shacl:namespace[preceding-sibling::shacl:prefix='']"/>
+       </template>
+       <template name="Vocab:prefix">
+               <param name="unprefixed" select="''"/>
+               <variable name="namespace" select="//rdf:RDF//owl:Ontology/shacl:declare/shacl:namespace[starts-with($unprefixed, string()) and string(preceding-sibling::shacl:prefix)!=''][1]"/>
+               <choose>
+                       <when test="not($namespace)">
+                               <value-of select="$unprefixed"/>
+                       </when>
+                       <otherwise>
+                               <value-of select="$namespace/preceding-sibling::shacl:prefix"/>
+                               <text>:</text>
+                               <value-of select="substring-after($unprefixed, $namespace)"/>
+                       </otherwise>
+               </choose>
+       </template>
+</transform>
similarity index 97%
rename from transforms/site/terms.xslt
rename to transforms/terms.xslt
index 640d1bec0ac659d6c1ecd6e0c0a4aebc0a6b2889..2fa8e538efc2cf868b6070a95eb0f0035bb86840 100644 (file)
@@ -1,10 +1,10 @@
 <?xml version="1.0"?>
 <!--
 <?xml version="1.0"?>
 <!--
-SPDX-FileCopyrightText: 2024 Lady <https://www.ladys.computer/about/#lady>
+SPDX-FileCopyrightText: 2024, 2025 Lady <https://www.ladys.computer/about/#lady>
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
 SPDX-License-Identifier: MPL-2.0
 -->
 <!--
-© 2024 Lady [@ Ladys Computer].
+© 2024–2025 Lady [@ Ladys Computer].
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
 
 This Source Code Form is subject to the terms of the Mozilla Public License, v 2.0.
 If a copy of the M·P·L was not distributed with this file, You can obtain one at <https://mozilla.org/MPL/2.0/>.
@@ -15,7 +15,6 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
 <transform
        xmlns="http://www.w3.org/1999/XSL/Transform"
        xmlns:Vocab="urn:fdc:vocab.ladys.computer:20240731:ns"
 <transform
        xmlns="http://www.w3.org/1999/XSL/Transform"
        xmlns:Vocab="urn:fdc:vocab.ladys.computer:20240731:ns"
-       xmlns:Vocabvocab="urn:fdc:vocab.ladys.computer:20240731:vocab:"
        xmlns:anno="http://www.w3.org/ns/oa#"
        xmlns:html="http://www.w3.org/1999/xhtml"
        xmlns:owl="http://www.w3.org/2002/07/owl#"
        xmlns:anno="http://www.w3.org/ns/oa#"
        xmlns:html="http://www.w3.org/1999/xhtml"
        xmlns:owl="http://www.w3.org/2002/07/owl#"
@@ -25,18 +24,15 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
        xmlns:skos="http://www.w3.org/2004/02/skos/core#"
        xmlns:vocabstatus="http://www.w3.org/2003/06/sw-vocab-status/ns#"
        xmlns:书社="urn:fdc:ladys.computer:20231231:Shu1She4"
        xmlns:skos="http://www.w3.org/2004/02/skos/core#"
        xmlns:vocabstatus="http://www.w3.org/2003/06/sw-vocab-status/ns#"
        xmlns:书社="urn:fdc:ladys.computer:20231231:Shu1She4"
-       exclude-result-prefixes="Vocab Vocabvocab"
+       exclude-result-prefixes="Vocab"
        version="1.0"
 >
        version="1.0"
 >
-       <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:site:terms.xslt</书社:id>
+       <书社:id>urn:fdc:vocab.ladys.computer:20240731:transforms:terms.xslt</书社:id>
        <key name="Vocab:named-class" match="owl:Class|rdfs:Datatype" use="@rdf:about"/>
        <key name="Vocab:named-property" match="owl:AnnotationProperty|owl:DatatypeProperty|owl:ObjectProperty" use="@rdf:about"/>
        <key name="Vocab:named-individual" match="owl:NamedIndividual" use="@rdf:about|owl:sameAs/@rdf:resource"/>
        <key name="Vocab:subclass" match="owl:Class|owl:Restriction" use="rdfs:subClassOf/@rdf:resource"/>
        <key name="Vocab:subproperty" match="owl:AnnotationProperty|owl:DatatypeProperty|owl:ObjectProperty" use="rdfs:subPropertyOf/@rdf:resource"/>
        <key name="Vocab:named-class" match="owl:Class|rdfs:Datatype" use="@rdf:about"/>
        <key name="Vocab:named-property" match="owl:AnnotationProperty|owl:DatatypeProperty|owl:ObjectProperty" use="@rdf:about"/>
        <key name="Vocab:named-individual" match="owl:NamedIndividual" use="@rdf:about|owl:sameAs/@rdf:resource"/>
        <key name="Vocab:subclass" match="owl:Class|owl:Restriction" use="rdfs:subClassOf/@rdf:resource"/>
        <key name="Vocab:subproperty" match="owl:AnnotationProperty|owl:DatatypeProperty|owl:ObjectProperty" use="rdfs:subPropertyOf/@rdf:resource"/>
-       <template name="Vocab:base">
-               <value-of select="//rdf:RDF//owl:Ontology/shacl:declare/shacl:namespace[preceding-sibling::shacl:prefix='']"/>
-       </template>
        <template name="Vocab:link-to">
                <param name="resource"/>
                <param name="kind" select="'individual'"/>
        <template name="Vocab:link-to">
                <param name="resource"/>
                <param name="kind" select="'individual'"/>
@@ -224,20 +220,6 @@ If a copy of the M·P·L was not distributed with this file, You can obtain one
                        </element>
                </if>
        </template>
                        </element>
                </if>
        </template>
-       <template name="Vocab:prefix">
-               <param name="unprefixed" select="''"/>
-               <variable name="namespace" select="//rdf:RDF//owl:Ontology/shacl:declare/shacl:namespace[starts-with($unprefixed, string()) and string(preceding-sibling::shacl:prefix)!=''][1]"/>
-               <choose>
-                       <when test="not($namespace)">
-                               <value-of select="$unprefixed"/>
-                       </when>
-                       <otherwise>
-                               <value-of select="$namespace/preceding-sibling::shacl:prefix"/>
-                               <text>:</text>
-                               <value-of select="substring-after($unprefixed, $namespace)"/>
-                       </otherwise>
-               </choose>
-       </template>
        <template match="/书社:archive">
                <variable name="base-iri">
                        <call-template name="Vocab:base"/>
        <template match="/书社:archive">
                <variable name="base-iri">
                        <call-template name="Vocab:base"/>
This page took 0.093246 seconds and 4 git commands to generate.