Still many things to be fixed and one stylesheet (of Andrea) not committed.
But it is a new beginning...
</tr>
<tr>
<td>
- View its metadata
+ <script>
+ var url = unescape(getParam('url'));
+ var getterURL = extractParam(url,'param.getterURL');
+ var CICURI = extractParam(url,'param.CICURI');
+ var RDFURI = "helm:rdf:www.cs.unibo.it/helm/rdf/rdfprova//" + CICURI;
+ if (CICURI.substr(-4,4) == ".ind") {
+ url = setParam(url,"keys","DM%2CRT");
+ url = setParam(url,"xmluri", getterURL + "getxml%3Furi%3D" + CICURI);
+ } else {
+ url = setParam(url,"keys","MC%2CRT");
+ url = setParam(url,"xmluri", getterURL + "resolve%3Furi%3D" + RDFURI);
+ }
+ url =
+ url +
+ "¶m.RDFURI=" + RDFURI ;
+ document.write(
+ '<a target="metadata" href="' + url + '">View its metadata</a>'
+ );
+ </script>
</td>
- <td>(Not implemented, yet. Coming soon.)</td>
+ <td>(Work in progress. Coming soon.)</td>
</tr>
<tr>
<td>
if (cicflags != "NO" || type == "theory") {
annotations = mode_list[4];
}
- url = processorURL + "apply?xmluri=" + escape(getterURL + "getxml?uri=" + uri) + "&keys=" + keys + "¶m.CICURI=" + uri + "¶m.naturalLanguage=" + naturalLanguage + "¶m.annotations=" + annotations;
+ url = processorURL + "apply?xmluri=" + escape(getterURL + "getxml?uri=" + uri) + "&keys=" + keys + "¶m.CICURI=" + uri + "¶m.naturalLanguage=" + naturalLanguage + "¶m.annotations=" + annotations + "¶m.topurl=" + top.topurl;
}
if (output == "raw")
--- /dev/null
+<?xml version="1.0"?>
+
+<xsl:stylesheet version="1.0"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns:subst="http://www.cs.unibo.it/helm/subst">
+
+<xsl:output
+ method="xml"
+ encoding="iso-8859-1"
+ media-type="text/html"
+ doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
+ doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" />
+
+<xsl:param name="RDFURI" select="''"/>
+
+<!-- BUG UWOBO -->
+<xsl:include href="http://phd.cs.unibo.it/helm/xslt/metadataLib.xsl"/>
+
+<xsl:variable name="url" select="concat($getterURL,'resolve?uri=')"/>
+
+<xsl:template match="InductiveDefinition">
+ <xsl:for-each select="InductiveType">
+ <xsl:variable name="RDFURIInductiveType" select="concat($RDFURI,',',position())"/>
+ <xsl:apply-templates select="document(concat($url,$RDFURIInductiveType))" mode="makelink">
+ <xsl:with-param name="name" select="@name"/>
+ <xsl:with-param name="RDFURI" select="$RDFURIInductiveType"/>
+ </xsl:apply-templates>
+ <xsl:for-each select="Constructor">
+ <xsl:variable name="RDFURIConstructor" select="concat($RDFURIInductiveType,',',position())"/>
+ <xsl:apply-templates select="document(concat($url,$RDFURIConstructor))" mode="makelink">
+ <xsl:with-param name="name" select="@name"/>
+ <xsl:with-param name="RDFURI" select="$RDFURIConstructor"/>
+ </xsl:apply-templates>
+ </xsl:for-each>
+ </xsl:for-each>
+</xsl:template>
+
+</xsl:stylesheet>
--- /dev/null
+<?xml version="1.0"?>
+
+<xsl:stylesheet version="1.0"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns:subst="http://www.cs.unibo.it/helm/subst">
+
+<xsl:output
+ method="xml"
+ encoding="iso-8859-1"
+ media-type="text/html"
+ doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
+ doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" />
+
+<xsl:param name="RDFURI" select="''"/>
+
+<!-- BUG UWOBO -->
+<xsl:include href="http://phd.cs.unibo.it/helm/xslt/metadataLib.xsl"/>
+
+<xsl:template match="unresolved|url">
+ <xsl:apply-templates mode="makelink" select=".">
+ <xsl:with-param name="name" select="$CICURI"/>
+ <xsl:with-param name="RDFURI" select="$RDFURI"/>
+ </xsl:apply-templates>
+</xsl:template>
+
+</xsl:stylesheet>
--- /dev/null
+<?xml version="1.0"?>
+
+<xsl:stylesheet version="1.0"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns:subst="http://www.cs.unibo.it/helm/subst">
+
+<xsl:param name="CICURI" select="''"/>
+<xsl:param name="getterURL" select="''"/>
+
+<xsl:template match="/">
+ <html>
+ <head>
+ <subst:script language="JavaScript" src="/javascript/defaults.js"/>
+ <subst:script language="JavaScript" src="/javascript/utils.js"/>
+ <subst:script language="JavaScript" src="/javascript/control.js"/>
+ <title>Metadata of <xsl:value-of select="$CICURI"/></title>
+ </head>
+ <body bgColor="white">
+ <h1>Metadata of <xsl:value-of select="$CICURI"/></h1>
+ <xsl:apply-templates select="*"/>
+ </body>
+ </html>
+</xsl:template>
+
+<xsl:template match="/" mode="makelink">
+ <xsl:param name="name" select="''"/>
+ <xsl:param name="RDFURI" select="''"/>
+ <xsl:apply-templates select="*" mode="makelink">
+ <xsl:with-param name="name" select="$name"/>
+ <xsl:with-param name="RDFURI" select="$RDFURI"/>
+ </xsl:apply-templates>
+</xsl:template>
+
+<xsl:template match="unresolved" mode="makelink">
+ <xsl:param name="name" select="''"/>
+ <p>
+ Object <xsl:value-of select="$name"/> is never referenced in other objects
+ </p>
+</xsl:template>
+
+<xsl:template match="url" mode="makelink">
+ <xsl:param name="name" select="''"/>
+ <xsl:param name="RDFURI" select="''"/>
+ <p>
+ <script>
+ var name = "<xsl:value-of select="$name"/>";
+ var RDFURI = "<xsl:value-of select="$RDFURI"/>";
+ var getterURL = "<xsl:value-of select="$getterURL"/>";
+<![CDATA[
+ //url = setParam(url,"keys",getCICMathMLKeys());
+ var url = setParam(location.href,"keys","mth");
+ url = setParam(url,"xmluri", getterURL + "getxml%3Furi%3D" + RDFURI);
+ document.write('<a href="' + url + '">View the objects depending on ' + name + '.</a>');
+]]>
+ </script>
+ </p>
+</xsl:template>
+
+</xsl:stylesheet>
<option value="L2H,http://phd.cs.unibo.it/helm/xslt/ls2html.xsl,false">Getter LS ==> HTML</option>
<option value="GP,http://phd.cs.unibo.it/helm/xslt/getParam.xsl,false">Get Param</option>
<option value="RT,http://phd.cs.unibo.it/helm/xslt/resolve_topurl.xsl,false">Logic-sheet to substitute the interface URL</option>
+ <option value="DM,http://phd.cs.unibo.it/helm/xslt/demultiplexMutual.xsl,false">Stylesheet to create the link to the metadata for inductive types</option>
+ <option value="MC,http://phd.cs.unibo.it/helm/xslt/metadataControl.xsl,false">Stylesheet to create the link to the metadata for constants and variables</option>
</select>
</form>
</td>