Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding static site in /docs directory #79

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
144 changes: 144 additions & 0 deletions docs/2015/03/16/models
Original file line number Diff line number Diff line change
@@ -0,0 +1,144 @@
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="rdfs2html.xsl"?>
<rdf:RDF
xmlns:dcterms="http://purl.org/dc/terms/"
xmlns:ldp="http://www.w3.org/ns/ldp#"
xmlns:ore="http://www.openarchives.org/ore/terms/"
xmlns:owl="http://www.w3.org/2002/07/owl#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
xmlns:pcdm="http://pcdm.org/models#">

<rdf:Description rdf:about="http://pcdm.org/models#">
<dcterms:title xml:lang="en">Portland Common Data Model</dcterms:title>
<dcterms:modified rdf:datatype="http://www.w3.org/2001/XMLSchema#date">2015-03-16</dcterms:modified>
<dcterms:publisher rdf:resource="http://www.duraspace.org/"/>
<rdfs:seeAlso rdf:resource="https://github.com/duraspace/pcdm/wiki"/>
<rdfs:comment xml:lang="en">Ontology for the Portland Common Data Model, intended to underlie a wide array of repository and DAMS applications.</rdfs:comment>
<owl:versionInfo>2015/03/16</owl:versionInfo>
</rdf:Description>

<rdfs:Class rdf:about="http://pcdm.org/models#AdministrativeSet">
<rdfs:label xml:lang="en">Administrative Set</rdfs:label>
<rdfs:comment xml:lang="en">
An Administrative Set is a grouping of resources that an administrative unit is ultimately
responsible for managing. The set itself helps to manage the items within it. An Object
or Collection may be contained by only one AdministrativeSet.
</rdfs:comment>
<rdfs:subClassOf rdf:resource="http://www.w3.org/ns/ldp#Container"/>
<rdfs:isDefinedBy rdf:resource="http://pcdm.org/models#"/>
</rdfs:Class>

<rdfs:Class rdf:about="http://pcdm.org/models#Collection">
<rdfs:label xml:lang="en">Collection</rdfs:label>
<rdfs:comment xml:lang="en">
A Collection is a group of resources. Collections have descriptive metadata, access metadata,
and may links to works and/or collections. By default, member works and collections are an
unordered set, but can be ordered using the ORE Proxy class.
</rdfs:comment>
<rdfs:subClassOf rdf:resource="http://www.openarchives.org/ore/terms/Aggregation"/>
<rdfs:isDefinedBy rdf:resource="http://pcdm.org/models#"/>
</rdfs:Class>

<rdfs:Class rdf:about="http://pcdm.org/models#Object">
<rdfs:label xml:lang="en">Object</rdfs:label>
<rdfs:comment xml:lang="en">
An Object is an intellectual entity, sometimes called a "work", "digital object", etc.
Objects have descriptive metadata, access metadata, may contain files and other Objects as
member "components". Each level of a work is therefore represented by an Object instance,
and is capable of standing on its own, being linked to from Collections and other Objects.
Member Objects can be ordered using the ORE Proxy class.
</rdfs:comment>
<rdfs:subClassOf rdf:resource="http://www.openarchives.org/ore/terms/Aggregation"/>
<rdfs:isDefinedBy rdf:resource="http://pcdm.org/models#"/>
</rdfs:Class>

<rdfs:Class rdf:about="http://pcdm.org/models#File">
<rdfs:label xml:lang="en">File</rdfs:label>
<rdfs:comment xml:lang="en">
A File is a sequence of binary data and is described by some accompanying metadata.
The metadata typically includes at least basic technical metadata (size, content type,
modification date, etc.), but can also include properties related to preservation,
digitization process, provenance, etc. Files MUST be contained by exactly one Object.
</rdfs:comment>
<rdfs:isDefinedBy rdf:resource="http://pcdm.org/models#"/>
</rdfs:Class>

<rdf:Property rdf:about="http://pcdm.org/models#hasFile">
<rdfs:label xml:lang="en">has file</rdfs:label>
<rdfs:comment xml:lang="en">Links to a File contained by this Object.</rdfs:comment>
<rdfs:domain rdf:resource="http://pcdm.org/models#Object"/>
<rdfs:range rdf:resource="http://pcdm.org/models#File"/>
<rdfs:subPropertyOf rdf:resource="http://www.openarchives.org/ore/terms/aggregates"/>
<rdfs:isDefinedBy rdf:resource="http://pcdm.org/models#"/>
</rdf:Property>

<rdf:Property rdf:about="http://pcdm.org/models#fileOf">
<rdfs:label xml:lang="en">is file of</rdfs:label>
<rdfs:comment xml:lang="en">Links from a File to its containing Object.</rdfs:comment>
<rdfs:range rdf:resource="http://pcdm.org/models#Object"/>
<rdfs:domain rdf:resource="http://pcdm.org/models#File"/>
<rdfs:subPropertyOf rdf:resource="http://www.openarchives.org/ore/terms/isAggregatedBy"/>
<rdfs:isDefinedBy rdf:resource="http://pcdm.org/models#"/>
<owl:inverseOf rdf:resource="http://pcdm.org/models#hasFile"/>
</rdf:Property>

<rdf:Property rdf:about="http://pcdm.org/models#hasMember">
<rdfs:label xml:lang="en">has member</rdfs:label>
<rdfs:comment xml:lang="en">Links to a subsidiary Object or Collection. Typically used to link to component parts, such as a book linking to a page.</rdfs:comment>
<rdfs:domain rdf:resource="http://www.openarchives.org/ore/terms/Aggregation"/>
<rdfs:range rdf:resource="http://www.openarchives.org/ore/terms/Aggregation"/>
<rdfs:subPropertyOf rdf:resource="http://www.openarchives.org/ore/terms/aggregates"/>
<rdfs:isDefinedBy rdf:resource="http://pcdm.org/models#"/>
</rdf:Property>

<rdf:Property rdf:about="http://pcdm.org/models#memberOf">
<rdfs:label xml:lang="en">is member of</rdfs:label>
<rdfs:comment xml:lang="en">Links from an Object or Collection to a containing Object or Collection.</rdfs:comment>
<rdfs:range rdf:resource="http://www.openarchives.org/ore/terms/Aggregation"/>
<rdfs:domain rdf:resource="http://www.openarchives.org/ore/terms/Aggregation"/>
<rdfs:subPropertyOf rdf:resource="http://www.openarchives.org/ore/terms/isAggregatedBy"/>
<rdfs:isDefinedBy rdf:resource="http://pcdm.org/models#"/>
<owl:inverseOf rdf:resource="http://pcdm.org/models#hasMember"/>
</rdf:Property>

<rdf:Property rdf:about="http://pcdm.org/models#hasRelatedFile">
<rdfs:label xml:lang="en">has related file</rdfs:label>
<rdfs:comment xml:lang="en">Links to a File which is related to this Object but doesn't directly describe or represent it, such as technical metadata about other files.</rdfs:comment>
<rdfs:domain rdf:resource="http://pcdm.org/models#Object"/>
<rdfs:range rdf:resource="http://pcdm.org/models#File"/>
<rdfs:subPropertyOf rdf:resource="http://www.openarchives.org/ore/terms/aggregates"/>
<rdfs:isDefinedBy rdf:resource="http://pcdm.org/models#"/>
</rdf:Property>

<rdf:Property rdf:about="http://pcdm.org/models#relatedFileOf">
<rdfs:label xml:lang="en">is related file of</rdfs:label>
<rdfs:comment xml:lang="en">Links from a related File to its containing Object.</rdfs:comment>
<rdfs:range rdf:resource="http://pcdm.org/models#Object"/>
<rdfs:domain rdf:resource="http://pcdm.org/models#File"/>
<rdfs:subPropertyOf rdf:resource="http://www.openarchives.org/ore/terms/isAggregatedBy"/>
<rdfs:isDefinedBy rdf:resource="http://pcdm.org/models#"/>
<owl:inverseOf rdf:resource="http://pcdm.org/models#hasRelatedFile"/>
</rdf:Property>

<rdf:Property rdf:about="http://pcdm.org/models#hasRelatedObject">
<rdfs:label xml:lang="en">has related object</rdfs:label>
<rdfs:comment xml:lang="en">Links to a related Object that is not a component part, such as an object representing a donor agreement or policies that govern the resource.</rdfs:comment>
<rdfs:domain rdf:resource="http://www.openarchives.org/ore/terms/Aggregation"/>
<rdfs:range rdf:resource="http://pcdm.org/models#Object"/>
<rdfs:subPropertyOf rdf:resource="http://www.openarchives.org/ore/terms/aggregates"/>
<rdfs:isDefinedBy rdf:resource="http://pcdm.org/models#"/>
</rdf:Property>

<rdf:Property rdf:about="http://pcdm.org/models#relatedObjectOf">
<rdfs:label xml:lang="en">is related object of</rdfs:label>
<rdfs:comment xml:lang="en">Links from an Object to a Object or Collection that it is related to.</rdfs:comment>
<rdfs:range rdf:resource="http://www.openarchives.org/ore/terms/Aggregation"/>
<rdfs:domain rdf:resource="http://pcdm.org/models#Object"/>
<rdfs:subPropertyOf rdf:resource="http://www.openarchives.org/ore/terms/isAggregatedBy"/>
<rdfs:isDefinedBy rdf:resource="http://pcdm.org/models#"/>
<owl:inverseOf rdf:resource="http://pcdm.org/models#hasRelatedObject"/>
</rdf:Property>

</rdf:RDF>
162 changes: 162 additions & 0 deletions docs/2015/03/16/rdfs2html.xsl
Original file line number Diff line number Diff line change
@@ -0,0 +1,162 @@
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
xmlns:owl="http://www.w3.org/2002/07/owl#"
xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:dcterms="http://purl.org/dc/terms/"
xmlns:ldp="http://www.w3.org/ns/ldp#"
xmlns:ore="http://www.openarchives.org/ore/terms/"
xmlns:pcdm="http://pcdm.org/models">
<xsl:output method="html"/>
<xsl:variable name="about" select="/rdf:RDF/rdf:Description[1]/@rdf:about"/>
<xsl:variable name="title" select="/rdf:RDF/rdf:Description[1]/dcterms:title"/>
<xsl:variable name="comment" select="/rdf:RDF/rdf:Description[1]/rdfs:comment"/>
<xsl:variable name="modified" select="/rdf:RDF/rdf:Description[1]/dcterms:modified"/>
<xsl:variable name="publisher" select="/rdf:RDF/rdf:Description[1]/dcterms:publisher/@rdf:resource"/>
<xsl:variable name="seeAlso" select="/rdf:RDF/rdf:Description[1]/rdfs:seeAlso/@rdf:resource"/>
<xsl:variable name="versionInfo" select="/rdf:RDF/rdf:Description/owl:versionInfo"/>


<xsl:template match="/">
<html>
<head>
<title><xsl:value-of select="$title"/></title>
<style>
h4 { margin-bottom: 0.25em; }
body { font-family: sans-serif; }
.about { font-family: monospace; margin-left: 1em; }
.label { margin-left: 1em; font-style:italic; }
.comment { margin-left: 1em; }
.property { margin-left: 1em; }
.modified { margin-left: 1em; }
.published { margin-left: 1em; }
.seealso { margin-left: 1em; }
.version { margin-left: 1em; }
</style>
</head>
<body>
<h1><xsl:value-of select="$title"/></h1>
<div class="about"><xsl:value-of select="$about"/></div>
<div class="comment"><xsl:value-of select="$comment"/></div>
<div class="modified">Modified: <xsl:value-of select="$modified"/></div>
<div class="published">Published by: <a href="{$publisher}"><xsl:value-of select="$publisher"/></a></div>
<xsl:if test="not($versionInfo = '')">
<div class="version">Version Info: <xsl:value-of select="$versionInfo" /></div>
</xsl:if>
<xsl:if test="$seeAlso != ''">
<div class="seealso">See Also: <a href="{$seeAlso}"><xsl:value-of select="$seeAlso"/></a></div>
</xsl:if>

<!-- table of contents -->
<div class="table-of-contents">
<h2>Table of Contents</h2>
<xsl:for-each select="/rdf:RDF/rdfs:Class">
<xsl:sort select="@rdf:about"/>
<xsl:if test="position() = 1"><h3>Classes</h3></xsl:if>
<xsl:call-template name="toc-entry"/>
</xsl:for-each>
<xsl:for-each select="/rdf:RDF/rdf:Property">
<xsl:sort select="@rdf:about"/>
<xsl:if test="position() = 1"><h3>Properties</h3></xsl:if>
<xsl:call-template name="toc-entry"/>
</xsl:for-each>
</div>

<!-- class list -->
<div class="contents">
<h2>Entity Definitions</h2>
<xsl:for-each select="/rdf:RDF/rdfs:Class">
<xsl:sort select="@rdf:about"/>
<xsl:if test="position() = 1"><h3>Classes</h3></xsl:if>
<xsl:call-template name="main-entry"/>
</xsl:for-each>

<!-- properties list -->
<xsl:for-each select="/rdf:RDF/rdf:Property">
<xsl:sort select="@rdf:about"/>
<xsl:if test="position() = 1"><h3>Properties</h3></xsl:if>
<xsl:call-template name="main-entry"/>
</xsl:for-each>
</div>
</body>
</html>
</xsl:template>
<xsl:template name="display-uri">
<xsl:param name="label"/>
<xsl:param name="uri"/>
<xsl:variable name="name">
<xsl:choose>
<xsl:when test="/*/namespace::*[starts-with($uri,.)]">
<xsl:for-each select="/*/namespace::*">
<xsl:if test="starts-with($uri,.)">
<xsl:value-of select="name()"/>:<xsl:value-of select="substring-after($uri,.)"/>
</xsl:if>
</xsl:for-each>
</xsl:when>
<xsl:otherwise><xsl:value-of select="$uri"/></xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:if test="$uri != ''">
<li><xsl:value-of select="$label"/><xsl:text>: </xsl:text>
<a href="{$uri}"><xsl:value-of select="$name"/></a>
</li>
</xsl:if>
</xsl:template>
<xsl:template name="toc-entry">
<xsl:variable name="id">
<xsl:value-of select="substring-after(@rdf:about,$about)"/>
</xsl:variable>
<xsl:if test="$id != ''">
<a href="#{$id}"><xsl:value-of select="$id"/></a>
<xsl:text> </xsl:text>
</xsl:if>
</xsl:template>
<xsl:template name="main-entry">
<xsl:variable name="id">
<xsl:value-of select="substring-after(@rdf:about,$about)"/>
</xsl:variable>
<xsl:if test="$id != ''">
<h4 id="{$id}"><xsl:value-of select="$id"/></h4>
<ul>
<li>Label: <xsl:value-of select="rdfs:label"/></li>
<xsl:if test="rdfs:comment != ''">
<li>Comment: <xsl:value-of select="rdfs:comment"/></li>
</xsl:if>
<xsl:if test="rdfs:subClassOf/@rdf:resource">
<xsl:call-template name="display-uri">
<xsl:with-param name="label">Subclass of</xsl:with-param>
<xsl:with-param name="uri" select="rdfs:subClassOf/@rdf:resource"/>
</xsl:call-template>
</xsl:if>
<xsl:if test="rdfs:subPropertyOf/@rdf:resource">
<xsl:call-template name="display-uri">
<xsl:with-param name="label">Subproperty of</xsl:with-param>
<xsl:with-param name="uri" select="rdfs:subPropertyOf/@rdf:resource"/>
</xsl:call-template>
</xsl:if>
<xsl:if test="rdfs:domain/@rdf:resource">
<xsl:call-template name="display-uri">
<xsl:with-param name="label">Domain</xsl:with-param>
<xsl:with-param name="uri" select="rdfs:domain/@rdf:resource"/>
</xsl:call-template>
</xsl:if>
<xsl:if test="rdfs:range/@rdf:resource">
<xsl:call-template name="display-uri">
<xsl:with-param name="label">Range</xsl:with-param>
<xsl:with-param name="uri" select="rdfs:range/@rdf:resource"/>
</xsl:call-template>
</xsl:if>
<xsl:if test="owl:inverseOf/@rdf:resource">
<xsl:call-template name="display-uri">
<xsl:with-param name="label">Inverse of</xsl:with-param>
<xsl:with-param name="uri" select="owl:inverseOf/@rdf:resource"/>
</xsl:call-template>
</xsl:if>
<xsl:if test="rdfs:isDefinedBy/@rdf:resource">
<li>Is defined by: <a href="{rdfs:isDefinedBy/@rdf:resource}"><xsl:value-of select="rdfs:isDefinedBy/@rdf:resource"/></a></li>
</xsl:if>
</ul>
</xsl:if>
</xsl:template>
</xsl:stylesheet>
1 change: 1 addition & 0 deletions docs/2015/05/12/assets
Loading