You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jena.apache.org by an...@apache.org on 2018/11/01 20:04:03 UTC
[3/8] jena git commit: SPARQLer web pages
SPARQLer web pages
Project: http://git-wip-us.apache.org/repos/asf/jena/repo
Commit: http://git-wip-us.apache.org/repos/asf/jena/commit/b78f5182
Tree: http://git-wip-us.apache.org/repos/asf/jena/tree/b78f5182
Diff: http://git-wip-us.apache.org/repos/asf/jena/diff/b78f5182
Branch: refs/heads/master
Commit: b78f5182bccda2194e5539a116f9619cc2921517
Parents: 59d1c0d
Author: Andy Seaborne <an...@apache.org>
Authored: Fri Oct 26 14:42:37 2018 +0100
Committer: Andy Seaborne <an...@apache.org>
Committed: Sat Oct 27 16:36:39 2018 +0100
----------------------------------------------------------------------
jena-fuseki2/jena-fuseki-main/pom.xml | 34 +++-
.../jena-fuseki-main/sparqler/data/books.ttl | 47 +++++
.../jena-fuseki-main/sparqler/data/empty.nt | 1 +
.../sparqler/log4j-foreground.properties | 46 +++++
.../sparqler/log4j-server.properties | 46 +++++
.../sparqler/pages/crossdomain.xml | 3 +
.../sparqler/pages/data-validator.html | 65 +++++++
.../jena-fuseki-main/sparqler/pages/fuseki.css | 148 +++++++++++++++
.../jena-fuseki-main/sparqler/pages/index.html | 87 +++++++++
.../sparqler/pages/iri-validator.html | 39 ++++
.../sparqler/pages/query-validator.html | 71 +++++++
.../jena-fuseki-main/sparqler/pages/query.html | 80 ++++++++
.../jena-fuseki-main/sparqler/pages/robots.txt | 2 +
.../jena-fuseki-main/sparqler/pages/sparql.html | 68 +++++++
.../sparqler/pages/update-validator.html | 63 +++++++
.../sparqler/pages/validator.html | 52 ++++++
.../sparqler/pages/xml-to-html-links.xsl | 183 ++++++++++++++++++
.../sparqler/pages/xml-to-html-plain.xsl | 187 +++++++++++++++++++
.../sparqler/pages/xml-to-html.xsl | 187 +++++++++++++++++++
.../jena-fuseki-main/sparqler/run-sparqler | 63 +++++++
20 files changed, 1471 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/pom.xml
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/pom.xml b/jena-fuseki2/jena-fuseki-main/pom.xml
index 61ff7de..4b5dd2d 100644
--- a/jena-fuseki2/jena-fuseki-main/pom.xml
+++ b/jena-fuseki2/jena-fuseki-main/pom.xml
@@ -104,7 +104,39 @@
<build>
<plugins>
-
+ <plugin>
+ <groupId>org.apache.rat</groupId>
+ <artifactId>apache-rat-plugin</artifactId>
+ <!--<version>0.12</version>-->
+ <executions>
+ <execution>
+ <id>rat-checks</id>
+ <phase>validate</phase>
+ <goals>
+ <goal>check</goal>
+ </goals>
+ </execution>
+ </executions>
+ <configuration>
+ <excludes>
+ <exclude>**/.project</exclude>
+ <exclude>**/.settings/**</exclude>
+ <exclude>**/.classpath</exclude>
+ <exclude>**/README.*</exclude>
+ <exclude>**/META-INF/services/*</exclude>
+ <exclude>**/dependency-reduced-pom.xml</exclude>
+
+ <exclude>fuseki.classpath</exclude>
+ <exclude>testing/**/*.ttl</exclude>
+ <exclude>testing/**/*.txt</exclude>
+ <exclude>sparqler/data/empty.nt</exclude>
+ <exclude>sparqler/pages/robots.txt</exclude>
+ <exclude>sparqler/pages/crossdomain.xml</exclude>
+
+ </excludes>
+ </configuration>
+ </plugin>
+
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/data/books.ttl
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/data/books.ttl b/jena-fuseki2/jena-fuseki-main/sparqler/data/books.ttl
new file mode 100644
index 0000000..6cba231
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/data/books.ttl
@@ -0,0 +1,47 @@
+## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
+
+PREFIX dc: <http://purl.org/dc/elements/1.1/>
+PREFIX vcard: <http://www.w3.org/2001/vcard-rdf/3.0#>
+PREFIX ns: <http://example.org/ns#>
+
+PREFIX : <http://example.org/book/>
+
+# This data is intentionaly irregular (e.g. different ways to
+# record the book creator) as if the information is either an
+# aggregation or was created at different times.
+
+:book1
+ dc:title "Harry Potter and the Philosopher's Stone" ;
+ dc:creator "J.K. Rowling" ;
+ .
+
+:book2
+ dc:title "Harry Potter and the Chamber of Secrets" ;
+ dc:creator _:a .
+
+:book3
+ dc:title "Harry Potter and the Prisoner Of Azkaban" ;
+ dc:creator _:a .
+
+:book4
+ dc:title "Harry Potter and the Goblet of Fire" .
+
+:book5
+ dc:title "Harry Potter and the Order of the Phoenix";
+ dc:creator "J.K. Rowling" ;
+ .
+
+:book6
+ dc:title "Harry Potter and the Half-Blood Prince";
+ dc:creator "J.K. Rowling" .
+
+:book7
+ dc:title "Harry Potter and the Deathly Hallows" ;
+ dc:creator "J.K. Rowling" .
+_:a
+ vcard:FN "J.K. Rowling" ;
+ vcard:N
+ [ vcard:Family "Rowling" ;
+ vcard:Given "Joanna"
+ ]
+ .
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/data/empty.nt
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/data/empty.nt b/jena-fuseki2/jena-fuseki-main/sparqler/data/empty.nt
new file mode 100644
index 0000000..739dd79
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/data/empty.nt
@@ -0,0 +1 @@
+# This is empty (except for this line!).
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/log4j-foreground.properties
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/log4j-foreground.properties b/jena-fuseki2/jena-fuseki-main/sparqler/log4j-foreground.properties
new file mode 100755
index 0000000..85db29f
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/log4j-foreground.properties
@@ -0,0 +1,46 @@
+## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
+
+log4j.rootLogger=INFO, stdlog
+#log4j.rootLogger=INFO, fileout
+
+log4j.appender.stdlog=org.apache.log4j.ConsoleAppender
+## log4j.appender.stdlog.target=System.err
+log4j.appender.stdlog.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdlog.layout.ConversionPattern=%d{HH:mm:ss} %-5p %-20c{1} :: %m%n
+
+# File logging, with roll over.
+log4j.appender.FusekiFileLog=org.apache.log4j.DailyRollingFileAppender
+log4j.appender.FusekiFileLog.DatePattern='.'yyyy-MM-dd
+log4j.appender.FusekiFileLog.File=fuseki-log
+log4j.appender.FusekiFileLog.layout=org.apache.log4j.PatternLayout
+log4j.appender.FusekiFileLog.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss}%d{HH:mm:ss} %-5p %-20c{1} :: %m%n
+
+# File logging - one file.
+log4j.appender.fileout=org.apache.log4j.FileAppender
+log4j.appender.fileout.File=log.joseki
+log4j.appender.fileout.layout=org.apache.log4j.PatternLayout
+log4j.appender.fileout.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss} %-5p %-20c{1} :: %m%n
+
+# Jetty - Fuseki catches Jetty errors and reports them.
+log4j.logger.org.eclipse.jetty=FATAL
+
+## # Execution logging
+## log4j.logger.com.hp.hpl.jena.arq.info=INFO
+## log4j.logger.com.hp.hpl.jena.arq.exec=INFO
+
+# Everything else in Jena
+log4j.logger.com.hp.hpl.jena=WARN
+log4j.logger.org.apache.jena=WARN
+log4j.logger.org.openjena=WARN
+log4j.logger.org.openjena.riot=WARN
+
+# Joseki server
+log4j.logger.org.joseki=INFO
+
+# Fuseki
+# Server log.
+log4j.logger.org.apache.jena.fuseki.Server=INFO
+# Request log.
+log4j.logger.org.apache.jena.fuseki.Fuseki=INFO
+# Internal logs
+log4j.logger.org.apache.jena.fuseki=INFO
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/log4j-server.properties
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/log4j-server.properties b/jena-fuseki2/jena-fuseki-main/sparqler/log4j-server.properties
new file mode 100755
index 0000000..a214d86
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/log4j-server.properties
@@ -0,0 +1,46 @@
+## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
+
+#log4j.rootLogger=INFO, stdlog
+log4j.rootLogger=INFO, fileout
+
+log4j.appender.stdlog=org.apache.log4j.ConsoleAppender
+## log4j.appender.stdlog.target=System.err
+log4j.appender.stdlog.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdlog.layout.ConversionPattern=%d{HH:mm:ss} %-5p %-20c{1} :: %m%n
+
+# File logging, with roll over.
+log4j.appender.FusekiFileLog=org.apache.log4j.DailyRollingFileAppender
+log4j.appender.FusekiFileLog.DatePattern='.'yyyy-MM-dd
+log4j.appender.FusekiFileLog.File=fuseki.log
+log4j.appender.FusekiFileLog.layout=org.apache.log4j.PatternLayout
+log4j.appender.FusekiFileLog.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss}%d{HH:mm:ss} %-5p %-20c{1} :: %m%n
+
+# File logging - one file.
+log4j.appender.fileout=org.apache.log4j.FileAppender
+log4j.appender.fileout.File=log.fuseki
+log4j.appender.fileout.layout=org.apache.log4j.PatternLayout
+log4j.appender.fileout.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss} %-5p %-20c{1} :: %m%n
+
+# Jetty - Fuseki catches Jetty errors and reports them.
+log4j.logger.org.eclipse.jetty=FATAL
+
+## # Execution logging
+## log4j.logger.com.hp.hpl.jena.arq.info=INFO
+## log4j.logger.com.hp.hpl.jena.arq.exec=INFO
+
+# Everything else in Jena
+log4j.logger.com.hp.hpl.jena=WARN
+log4j.logger.org.apache.jena=WARN
+log4j.logger.org.openjena=WARN
+log4j.logger.org.openjena.riot=WARN
+
+# Joseki server
+log4j.logger.org.joseki=INFO
+
+# Fuseki
+# Server log.
+log4j.logger.org.apache.jena.fuseki.Server=INFO
+# Request log.
+log4j.logger.org.apache.jena.fuseki.Fuseki=INFO
+# Internal logs
+log4j.logger.org.apache.jena.fuseki=INFO
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/crossdomain.xml
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/crossdomain.xml b/jena-fuseki2/jena-fuseki-main/sparqler/pages/crossdomain.xml
new file mode 100755
index 0000000..c1e814f
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/crossdomain.xml
@@ -0,0 +1,3 @@
+<cross-domain-policy>
+<allow-access-from domain="*"/>
+</cross-domain-policy>
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/data-validator.html
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/data-validator.html b/jena-fuseki2/jena-fuseki-main/sparqler/pages/data-validator.html
new file mode 100755
index 0000000..bc28420
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/data-validator.html
@@ -0,0 +1,65 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head><title>SPARQLer Data Validator</title>
+ <link rel="stylesheet" type="text/css" href="fuseki.css" />
+ </head>
+ <body>
+ <h1>SPARQLer Data Validator</h1>
+ <div class="moreindent">
+ <form action="validate/data" method="post" accept-charset="UTF-8" >
+ <textarea name="data" cols="70" rows="30">
+# Prefixes for Turtle or TriG - these can be edited or removed.
+@base <http://example.org/base/> .
+@prefix : <http://example.org/> .
+@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
+@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
+@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
+@prefix owl: <http://www.w3.org/2002/07/owl#> .
+
+
+</textarea>
+<br/>
+Input syntax:
+<input type="radio" name="languageSyntax" value="Turtle" checked="checked"/>Turtle
+<input type="radio" name="languageSyntax" value="TriG"/>TriG
+<input type="radio" name="languageSyntax" value="N-Triples"/>N-Triples
+<input type="radio" name="languageSyntax" value="N-Quads"/>N-Quad
+ <br/>
+ <!--
+Output syntax:
+ <input type="checkbox" name="outputFormat" value="sparql" checked="checked"/>SPARQL
+ <input type="checkbox" name="outputFormat" value="algebra"/>SPARQL algebra
+ <input type="checkbox" name="outputFormat" value="quads"/>SPARQL algebra (quads)
+ <br/>
+
+ Line numbers:
+ <input type="radio" name="linenumbers" value="true" checked="checked"/>Yes
+ <input type="radio" name="linenumbers" value="false"/>No
+ <br/>
+ -->
+ <input type="submit" value="Validate RDF Data" />
+ </form>
+ <hr/>
+Parsing provided by <a href="http://jena.apache.org/documentation/io/">Jena/RIOT</a>.
+Questions to
+<href="mailto:users@jena.apache.org?s=[Data Validator]: ">users@jena</a>
+(include full details of input).
+ </div>
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/fuseki.css
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/fuseki.css b/jena-fuseki2/jena-fuseki-main/sparqler/pages/fuseki.css
new file mode 100755
index 0000000..e3e5763
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/fuseki.css
@@ -0,0 +1,148 @@
+/**
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+body {
+ font-family: Verdana, Arial, Helvetica, sans-serif ;
+ font-size: 10pt ;
+ line-height: 18pt ;
+ color: black;
+ background: white ;
+ margin: 0 ;
+}
+
+textarea { background-color: #F0F0F0 ; }
+
+p { margin-left: 2% ; margin-right: 2% ; }
+
+.warning { color: #FF0000 ; }
+.error { color: #FF0000 ; font-weight: bold; }
+
+/* Makes lists a little tighter
+li { line-height: 14pt ; }
+*/
+
+table {
+ font-family: Verdana, Arial, sans-serif ;
+ font-size: 10pt ;
+ border-collapse: collapse;
+ border: 1px solid black ;
+ cellspacing: 0 ;
+ cellpadding: 0
+}
+
+td {
+ border: 1px solid #808080 ;
+ empty-cells: show;
+ padding: 5 ;
+ spacing: 0 ;
+ vertical-align:top;
+ text-align:center
+}
+
+
+th {
+ border: 1px solid #808080 ;
+ empty-cells: show;
+ padding: 5 ;
+ vertical-align:top;
+ text-align:center
+}
+
+.box
+{ margin-left : 5% ;
+ margin-right : 5% ;
+ border: solid ;
+ border-width: thin;
+ background-color: #F0F0F0;
+ padding: 2mm;
+ page-break-inside: avoid ;
+}
+
+.noindent { margin-left: -5% ; margin-right: -5%; }
+.moreindent { margin-left: 5% ; margin-right: 5%; }
+
+
+/* Use this for the document title as displayed on the page at the top. */
+
+
+h1 {
+ text-align:center ;
+ font-size: 14pt;
+ line-height: 24pt ;
+ font-weight: bold;
+ color:#000;
+ background:#CADFF4;
+ padding: 0 ;
+ margin: 0 ;
+ padding-left: 1ex;
+ padding-right: 1ex;
+ text-align:center;
+}
+
+h2 {
+ font-size: 12pt;
+ line-height: 16pt ;
+ font-size: 110%;
+ font-weight: bold;
+ color: #003399;
+ background:#CADFF4;
+ margin-bottom:5px;
+ padding-left: 1ex;
+ padding-right: 1ex;
+}
+
+h3, h4, h5 {
+ font-size: 100%;
+ font-weight: bold;
+ margin-bottom:3px;
+}
+
+ul { list-style-type: disc }
+dt { font-weight: bold }
+
+/* Change background/foreground colour on hover */
+
+A:link { color: rgb(0, 0, 255) } /* for unvisited links */
+A:hover { color: rgb(255, 0, 0) } /* when mouse is over link */
+
+/* No extra space between paragraphs : inherits from body */
+pre {
+ font-family: monospace;
+ font-size: 10pt ;
+ line-height: 14pt ;
+ margin-top: 1 ;
+ margin-bottom: 1 ;
+ margin-left: 5ex ;
+ }
+
+/* Some general utility definitions */
+.centered {
+ text-align: center;
+}
+
+.caption {
+ text-align: center;
+ font-size: smaller;
+}
+
+code {
+ font-size: 10pt;
+}
+
+.footnote {
+ font-size: smaller;
+ border-top: thin solid gray;
+}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/index.html
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/index.html b/jena-fuseki2/jena-fuseki-main/sparqler/pages/index.html
new file mode 100755
index 0000000..dd17323
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/index.html
@@ -0,0 +1,87 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+ <head>
+ <title>SPARQLer - An RDF Query Server</title>
+ <link rel="stylesheet" type="text/css" href="fuseki.css" />
+ </head>
+<body>
+ <h1>SPARQLer</h1>
+
+ <p> </p>
+
+ <h2>Validators</h2>
+ <ul>
+ <li><a href="query-validator.html">SPARQL query validator</a></li>
+ <li><a href="update-validator.html">SPARQL update validator</a></li>
+ <li><a href="data-validator.html">RDF data validator</a></li>
+ <li><a href="iri-validator.html">IRI validator</a></li>
+ </ul>
+
+ <h2>Query</h2>
+
+ <ul>
+ <li><a href="sparql.html">General purpose SPARQL processor</a></li>
+ </ul>
+
+ <h2>SPARQL Services</h2>
+
+ <p>The general SPARQL query service is accessed directly using the SPARQL
+ protocol at URL <tt>/sparql</tt></p>
+
+ <h2>Links to SPARQL 1.1 Specifications</h2>
+
+ <p>The full set of SPARQL specification is:</p>
+
+ <ul>
+ <li><a href="http://www.w3.org/TR/sparql11-query/"
+ >SPARQL Query language</a></li>
+ <li><a href="http://www.w3.org/TR/sparql11-update/"
+ >SPARQL Update</a></li>
+ <li><a href="http://www.w3.org/TR/sparql11-protocol/"
+ >SPARQL Protocol</a></li>
+ <li><a href="http://www.w3.org/TR/sparql11-http-rdf-update/"
+ >SPARQL Graph Store Protocol</a></li>
+ <li>SPARQL Result formats
+ <ul>
+ <li><a href="http://www.w3.org/TR//sparql11-results-json/"
+ >SPARQL Query Results JSON Format</a></li>
+ <li><a href="http://www.w3.org/TR/sparql11-results-csv-tsv/"
+ >SPARQL Query Results CSV and TSV Formats</a></li>
+ <li><a href="http://www.w3.org/TR/rdf-sparql-XMLres/"
+ >SPARQL Query Results XML Format</a></li>
+ </ul>
+ <li><a href="http://www.w3.org/TR/sparql11-service-description/"
+ >SPARQL Service Description</a></li>
+ <li><a href="http://www.w3.org/TR/sparql11-federated-query/"
+ >SPARQL Federated Query</a></li>
+ <li><a href="http://www.w3.org/TR/sparql11-entailment/"
+ >SPARQL Entailment Regimes</a></li>
+ </ul>
+
+ <hr/>
+
+ <p>This server is running
+ <a href="https://jena.apache.org/documentation/fuseki2/fuseki-main.html">Apache Jena Fuseki</a>.</p>
+
+</body>
+</html>
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/iri-validator.html
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/iri-validator.html b/jena-fuseki2/jena-fuseki-main/sparqler/pages/iri-validator.html
new file mode 100755
index 0000000..ad55941
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/iri-validator.html
@@ -0,0 +1,39 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head><title>SPARQLer Query Validator</title>
+
+ <link rel="stylesheet" type="text/css" href="fuseki.css" />
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
+ </head>
+ <body>
+ <h1>SPARQLer IRI Validator</h1>
+
+ <div class="moreindent">
+
+ <form action="validate/iri" accept-charset="UTF-8">
+ <p>
+ <textarea name="iri" cols="70" rows="2"></textarea>
+
+ <input type="submit" value="Validate IRI" />
+ </p>
+ </form>
+ <hr/>
+ </div>
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/query-validator.html
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/query-validator.html b/jena-fuseki2/jena-fuseki-main/sparqler/pages/query-validator.html
new file mode 100755
index 0000000..f910650
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/query-validator.html
@@ -0,0 +1,71 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head><title>SPARQLer Query Validator</title>
+
+ <link rel="stylesheet" type="text/css" href="fuseki.css" />
+
+ </head>
+ <body>
+ <h1>SPARQLer Query Validator</h1>
+
+ <div class="moreindent">
+
+ <form action="validate/query" method="post" accept-charset="UTF-8">
+ <p>
+ <textarea name="query" cols="70" rows="30">
+PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
+PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
+PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
+PREFIX owl: <http://www.w3.org/2002/07/owl#>
+PREFIX fn: <http://www.w3.org/2005/xpath-functions#>
+PREFIX apf: <http://jena.hpl.hp.com/ARQ/property#>
+PREFIX dc: <http://purl.org/dc/elements/1.1/>
+
+SELECT ?book ?title
+WHERE
+ { ?book dc:title ?title }</textarea>
+<br/>
+ Input syntax:<br/>
+ <input type="radio" name="languageSyntax" value="SPARQL" checked="checked"/>SPARQL
+ <input type="radio" name="languageSyntax" value="ARQ"/>SPARQL extended syntax
+ <br/>
+ <br/>
+Output:<br/>
+ <input type="checkbox" name="outputFormat" value="sparql" checked="checked"/>SPARQL<br/>
+ <input type="checkbox" name="outputFormat" value="algebra"/>SPARQL algebra<br/>
+ <input type="checkbox" name="outputFormat" value="quads"/>SPARQL algebra (quads)<br/>
+ <input type="checkbox" name="outputFormat" value="opt"/>SPARQL algebra
+(general optimizations)<br/>
+ <input type="checkbox" name="outputFormat" value="optquads"/>SPARQL algebra
+(quads, general optimizations)<br/>
+ <br/>
+ Line numbers:
+ <input type="radio" name="linenumbers" value="true" checked="checked"/>Yes
+ <input type="radio" name="linenumbers" value="false"/>No
+ <br/>
+
+
+ <input type="submit" value="Validate SPARQL Query" />
+ </p>
+ </form>
+
+ <hr/>
+ </div>
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/query.html
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/query.html b/jena-fuseki2/jena-fuseki-main/sparqler/pages/query.html
new file mode 100755
index 0000000..d61d4fb
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/query.html
@@ -0,0 +1,80 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head><title>SPARQLer</title>
+ <link rel="stylesheet" type="text/css" href="fuseki.css" />
+ </head>
+
+ <body>
+ <h1>SPARQLer - An RDF Query Demo</h1>
+ <p>Example queries (or edit and write your own!). All the text boxes invoke the same "books" service - they just get initialised with different examples.</p>
+ <hr/>
+
+ <div class="moreindent">
+
+ <form action="books/sparql" method="get">
+ <p>SELECT - get variables (apply XSLT stylesheet)</p>
+ <p><textarea name="query" cols="70" rows="15">
+PREFIX books: <http://example.org/book/>
+PREFIX dc: <http://purl.org/dc/elements/1.1/>
+SELECT ?book ?title
+WHERE
+ { ?book dc:title ?title }</textarea>
+ <br/>
+
+ Output: <select name="output">
+ <option value="json">JSON</option>
+ <option value="xml">XML</option>
+ <option value="text">Text</option>
+ <option value="csv">CSV</option>
+ <option value="tsv">TSV</option>
+ </select>
+ <br/>
+ XSLT style sheet (blank for none):
+ <input name="stylesheet" size="20" value="/xml-to-html.xsl" />
+ <br/>
+ <input type="checkbox" name="force-accept" value="text/plain"/>
+ Force the accept header to <tt>text/plain</tt> regardless
+ <br/>
+
+ <input type="submit" value="Get Results" />
+ </p>
+ </form>
+
+ <hr/>
+
+ <form action="books/sparql">
+ <p>CONSTRUCT - return a graph</p>
+ <p><textarea name="query" cols="70" rows="10">
+PREFIX dc: <http://purl.org/dc/elements/1.1/>
+CONSTRUCT { $book dc:title $title }
+WHERE
+ { $book dc:title $title }
+ </textarea>
+ <br/>
+ <input type="submit" value="Get Results" />
+ </p>
+ </form>
+ <hr/>
+ </div>
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/robots.txt
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/robots.txt b/jena-fuseki2/jena-fuseki-main/sparqler/pages/robots.txt
new file mode 100755
index 0000000..1f53798
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/robots.txt
@@ -0,0 +1,2 @@
+User-agent: *
+Disallow: /
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/sparql.html
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/sparql.html b/jena-fuseki2/jena-fuseki-main/sparqler/pages/sparql.html
new file mode 100755
index 0000000..c9df10e
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/sparql.html
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head><title>SPARQLer</title>
+ <link rel="stylesheet" type="text/css" href="/fuseki.css" />
+ </head>
+
+ <body>
+ <h1>SPARQLer - General purpose processor</h1>
+
+ <div class="moreindent">
+
+ <form action="sparql" method="get">
+ <p>General SPARQL query : input query, set any options and press "Get Results"</p>
+ <p>
+ <textarea style="background-color: #F0F0F0;" name="query" cols="70" rows="20"></textarea>
+ <br/>
+ Target graph URI (or use <code>FROM</code> in the query)
+ <input name="default-graph-uri" size="25" value="" />
+ <br/>
+ If no dataset is provided, the query will execute agains an empty one.<br/>
+ The query can contain use <code>VALUES</code> to set some variables.
+ <br/>
+ <br/>
+ Output: <select name="output">
+ <option value="json">JSON</option>
+ <option value="xml">XML</option>
+ <option value="text">Text</option>
+ <option value="csv">CSV</option>
+ <option value="tsv">TSV</option>
+ </select>
+ <br/>
+ XSLT style sheet (blank for none):
+ <input name="stylesheet" size="20" value="/xml-to-html.xsl" />
+ <br/>
+ <input type="checkbox" name="force-accept" value="text/plain"/>
+ Force the accept header to <tt>text/plain</tt> regardless
+ <br/>
+ <br/>
+ <input type="submit" value="Get Results" />
+
+ </p>
+ </form>
+ </div>
+
+ <hr/>
+
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/update-validator.html
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/update-validator.html b/jena-fuseki2/jena-fuseki-main/sparqler/pages/update-validator.html
new file mode 100755
index 0000000..a0ff581
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/update-validator.html
@@ -0,0 +1,63 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head><title>SPARQLer Update Validator</title>
+
+ <link rel="stylesheet" type="text/css" href="fuseki.css" />
+
+ </head>
+ <body>
+ <h1>SPARQLer Update Validator</h1>
+
+ <div class="moreindent">
+
+
+ <form action="validate/update" method="post" accept-charset="UTF-8">
+ <textarea name="update" cols="70" rows="30">
+PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
+PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
+PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
+PREFIX owl: <http://www.w3.org/2002/07/owl#>
+PREFIX fn: <http://www.w3.org/2005/xpath-functions#>
+PREFIX apf: <http://jena.hpl.hp.com/ARQ/property#>
+
+</textarea>
+<br/>
+ Input syntax:
+ <input type="radio" name="languageSyntax" value="SPARQL" checked="checked"/>SPARQL
+ <input type="radio" name="languageSyntax" value="ARQ"/>SPARQL extended syntax
+ <br/>
+<!--
+Output syntax:
+ <input type="checkbox" name="outputFormat" value="sparql" checked="checked"/>SPARQL
+ <input type="checkbox" name="outputFormat" value="algebra"/>SPARQL algebra
+ <input type="checkbox" name="outputFormat" value="quads"/>SPARQL algebra (quads)
+ <br/>
+-->
+ Line numbers:
+ <input type="radio" name="linenumbers" value="true" checked="checked"/>Yes
+ <input type="radio" name="linenumbers" value="false"/>No
+ <br/>
+
+ <input type="submit" value="Validate SPARQL Update" />
+ </form>
+
+ <hr/>
+ </div>
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/validator.html
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/validator.html b/jena-fuseki2/jena-fuseki-main/sparqler/pages/validator.html
new file mode 100755
index 0000000..48faf6c
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/validator.html
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+ <head>
+ <title>SPARQL Query Validator</title>
+ <link rel="stylesheet" type="text/css" href="fuseki.css" />
+ <meta http-equiv="refresh" content="5;url=http://sparql.org/query-validator.html">
+ </head>
+<body>
+ <h1>SPARQLer</h1>
+
+ <p>
+The SPARQL query validator page has moved to
+<a href="http://sparql.org/query-validator.html">http://sparql.org/query-validator.html</a>.
+You should be redirected there in a few seconds.
+</p>
+
+ <h2>Validators</h2>
+ <ul>
+ <li><a href="query-validator.html">SPARQL query validator</a></li>
+ <li><a href="update-validator.html">SPARQL update validator</a></li>
+ <li><a href="data-validator.html">RDF data validator</a></li>
+ <li><a href="iri-validator.html">IRI validator</a></li>
+ </ul>
+
+ <hr/>
+
+ <p>This server is running
+ <a href="http://jena.apache.org/documentation/serving_data/index.html"
+ >Apache Jena Fuseki</a>.</p>
+
+</body>
+</html>
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/xml-to-html-links.xsl
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/xml-to-html-links.xsl b/jena-fuseki2/jena-fuseki-main/sparqler/pages/xml-to-html-links.xsl
new file mode 100755
index 0000000..9e0a450
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/xml-to-html-links.xsl
@@ -0,0 +1,183 @@
+<?xml version="1.0"?>
+
+<!--
+
+XSLT script to format SPARQL Query Results XML Format into xhtml
+
+Copyright © 2004, 2005 World Wide Web Consortium, (Massachusetts
+Institute of Technology, European Research Consortium for
+Informatics and Mathematics, Keio University). All Rights
+Reserved. This work is distributed under the W3C® Software
+License [1] in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or
+FITNESS FOR A PARTICULAR PURPOSE.
+
+[1] http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
+
+Version 1 : Dave Beckett (DAWG)
+Version 2 : Jeen Broekstra (DAWG)
+Customization for SPARQler: Andy Seaborne
+URIs as hrefs in results : Bob DuCharme & Andy Seaborne
+
+> - <xsl:for-each select="//res:head/res:variable">
+> + <xsl:for-each select="/res:sparql/res:head/res:variable">
+
+-->
+
+<xsl:stylesheet version="1.0"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:res="http://www.w3.org/2005/sparql-results#"
+ xmlns:fn="http://www.w3.org/2005/xpath-functions"
+ exclude-result-prefixes="res xsl">
+
+ <!--
+ <xsl:output
+ method="html"
+ media-type="text/html"
+ doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN"
+ indent="yes"
+ encoding="UTF-8"/>
+ -->
+
+ <!-- or this? -->
+
+ <xsl:output
+ method="xml"
+ indent="yes"
+ encoding="UTF-8"
+ doctype-public="-//W3C//DTD XHTML 1.0 Strict//EN"
+ doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"
+ omit-xml-declaration="no" />
+
+ <xsl:template match="res:link">
+ <p>Link to <xsl:value-of select="@href"/></p>
+ </xsl:template>
+
+ <xsl:template name="header">
+ <div>
+ <h2>Header</h2>
+ <xsl:apply-templates select="res:head/res:link"/>
+ </div>
+ </xsl:template>
+
+ <xsl:template name="boolean-result">
+ <div>
+ <p>ASK => <xsl:value-of select="res:boolean"/></p>
+ </div>
+ </xsl:template>
+
+
+ <xsl:template name="vb-result">
+ <div>
+ <table>
+ <xsl:text>
+ </xsl:text>
+ <tr>
+ <xsl:for-each select="res:head/res:variable">
+ <th><xsl:value-of select="@name"/></th>
+ </xsl:for-each>
+ </tr>
+ <xsl:text>
+ </xsl:text>
+ <xsl:for-each select="res:results/res:result">
+ <tr>
+ <xsl:apply-templates select="."/>
+ </tr>
+ </xsl:for-each>
+ </table>
+ </div>
+ </xsl:template>
+
+ <xsl:template match="res:result">
+ <xsl:variable name="current" select="."/>
+ <xsl:for-each select="/res:sparql/res:head/res:variable">
+ <xsl:variable name="name" select="@name"/>
+ <td>
+ <xsl:choose>
+ <xsl:when test="$current/res:binding[@name=$name]">
+ <!-- apply template for the correct value type (bnode, uri, literal) -->
+ <xsl:apply-templates select="$current/res:binding[@name=$name]"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <!-- no binding available for this variable in this solution -->
+ </xsl:otherwise>
+ </xsl:choose>
+ </td>
+ </xsl:for-each>
+ </xsl:template>
+
+ <xsl:template match="res:bnode">
+ <xsl:text>_:</xsl:text>
+ <xsl:value-of select="text()"/>
+ </xsl:template>
+
+ <xsl:template match="res:uri">
+ <!-- Roughly: SELECT ($uri AS ?subject) ?predicate ?object { $uri ?predicate ?object } -->
+ <!-- XSLT 2.0
+ <xsl:variable name="x"><xsl:value-of select="fn:encode-for-uri(.)"/></xsl:variable>
+ -->
+ <xsl:variable name="x"><xsl:value-of select="."/></xsl:variable>
+ <!--
+ <xsl:variable name="query">SELECT%20%28%3C<xsl:value-of select="."/>%3E%20AS%20%3Fsubject%29%20%3Fpredicate%20%3Fobject%20%7B%3C<xsl:value-of select="."/>%3E%20%3Fpredicate%20%3Fobject%20%7D</xsl:variable>
+ -->
+ <xsl:variable name="query">SELECT%20%28%3C<xsl:value-of select="$x"/>%3E%20AS%20%3Fsubject%29%20%3Fpredicate%20%3Fobject%20%7B%3C<xsl:value-of select="$x"/>%3E%20%3Fpredicate%20%3Fobject%20%7D</xsl:variable>
+ <xsl:text><</xsl:text>
+ <a href="?query={$query}&output=xml&stylesheet=%2Fxml-to-html.xsl">
+ <xsl:value-of select="."/>
+ </a>
+ <xsl:text>></xsl:text>
+ </xsl:template>
+
+ <xsl:template match="res:literal[@datatype]">
+ <!-- datatyped literal value -->
+ "<xsl:value-of select="."/>"^^<<xsl:value-of select="@datatype"/>>
+ </xsl:template>
+
+ <xsl:template match="res:literal[@lang]">
+ <!-- datatyped literal value -->
+ "<xsl:value-of select="."/>"<xsl:value-of select="@xml:lang"/>
+ </xsl:template>
+
+ <xsl:template match="res:sparql">
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+ <head>
+ <title>SPARQLer Query Results</title>
+ <style>
+ <![CDATA[
+ h1 { font-size: 150% ; }
+ h2 { font-size: 125% ; }
+ table { border-collapse: collapse ; border: 1px solid black ; }
+ td, th
+ { border: 1px solid black ;
+ padding-left:0.5em; padding-right: 0.5em;
+ padding-top:0.2ex ; padding-bottom:0.2ex
+ }
+ ]]>
+ </style>
+ </head>
+ <body>
+
+
+ <h1>SPARQLer Query Results</h1>
+
+ <xsl:if test="res:head/res:link">
+ <xsl:call-template name="header"/>
+ </xsl:if>
+
+ <xsl:choose>
+ <xsl:when test="res:boolean">
+ <xsl:call-template name="boolean-result" />
+ </xsl:when>
+
+ <xsl:when test="res:results">
+ <xsl:call-template name="vb-result" />
+ </xsl:when>
+
+ </xsl:choose>
+
+
+ </body>
+ </html>
+ </xsl:template>
+</xsl:stylesheet>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/xml-to-html-plain.xsl
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/xml-to-html-plain.xsl b/jena-fuseki2/jena-fuseki-main/sparqler/pages/xml-to-html-plain.xsl
new file mode 100755
index 0000000..1878ab0
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/xml-to-html-plain.xsl
@@ -0,0 +1,187 @@
+<?xml version="1.0"?>
+
+<!--
+
+XSLT script to format SPARQL Query Results XML Format into xhtml
+
+Copyright © 2004, 2005 World Wide Web Consortium, (Massachusetts
+Institute of Technology, European Research Consortium for
+Informatics and Mathematics, Keio University). All Rights
+Reserved. This work is distributed under the W3C® Software
+License [1] in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or
+FITNESS FOR A PARTICULAR PURPOSE.
+
+[1] http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
+
+Version 1 : Dave Beckett (DAWG)
+Version 2 : Jeen Broekstra (DAWG)
+Customization for SPARQler: Andy Seaborne
+Fix:
+
+> - <xsl:for-each select="//res:head/res:variable">
+> + <xsl:for-each select="/res:sparql/res:head/res:variable">
+
+-->
+
+<xsl:stylesheet version="1.0"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:res="http://www.w3.org/2005/sparql-results#"
+ exclude-result-prefixes="res xsl">
+
+ <!--
+ <xsl:output
+ method="html"
+ media-type="text/html"
+ doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN"
+ indent="yes"
+ encoding="UTF-8"/>
+ -->
+
+ <!-- or this? -->
+
+ <xsl:output
+ method="xml"
+ indent="yes"
+ encoding="UTF-8"
+ doctype-public="-//W3C//DTD XHTML 1.0 Strict//EN"
+ doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"
+ omit-xml-declaration="no" />
+
+
+ <xsl:template name="header">
+ <div>
+ <h2>Header</h2>
+ <xsl:for-each select="res:head/res:link">
+ <p>Link to <xsl:value-of select="@href"/></p>
+ </xsl:for-each>
+ </div>
+ </xsl:template>
+
+ <xsl:template name="boolean-result">
+ <div>
+ <!--
+ <h2>Boolean Result</h2>
+ -->
+ <p>ASK => <xsl:value-of select="res:boolean"/></p>
+ </div>
+ </xsl:template>
+
+
+ <xsl:template name="vb-result">
+ <div>
+ <!--
+ <h2>Variable Bindings Result</h2>
+ <p>Ordered: <xsl:value-of select="res:results/@ordered"/></p>
+ <p>Distinct: <xsl:value-of select="res:results/@distinct"/></p>
+ -->
+
+ <table>
+ <xsl:text>
+ </xsl:text>
+ <tr>
+ <xsl:for-each select="res:head/res:variable">
+ <th><xsl:value-of select="@name"/></th>
+ </xsl:for-each>
+ </tr>
+ <xsl:text>
+ </xsl:text>
+ <xsl:for-each select="res:results/res:result">
+ <tr>
+ <xsl:apply-templates select="."/>
+ </tr>
+ </xsl:for-each>
+ </table>
+ </div>
+ </xsl:template>
+
+ <xsl:template match="res:result">
+ <xsl:variable name="current" select="."/>
+ <xsl:for-each select="/res:sparql/res:head/res:variable">
+ <xsl:variable name="name" select="@name"/>
+ <td>
+ <xsl:choose>
+ <xsl:when test="$current/res:binding[@name=$name]">
+ <!-- apply template for the correct value type (bnode, uri, literal) -->
+ <xsl:apply-templates select="$current/res:binding[@name=$name]"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <!-- no binding available for this variable in this solution -->
+ </xsl:otherwise>
+ </xsl:choose>
+ </td>
+ </xsl:for-each>
+ </xsl:template>
+
+ <xsl:template match="res:bnode">
+ <xsl:text>_:</xsl:text>
+ <xsl:value-of select="text()"/>
+ </xsl:template>
+
+ <xsl:template match="res:uri">
+ <xsl:variable name="uri" select="text()"/>
+ <xsl:text><</xsl:text>
+ <xsl:value-of select="$uri"/>
+ <xsl:text>></xsl:text>
+ </xsl:template>
+
+ <xsl:template match="res:literal">
+ <xsl:text>"</xsl:text>
+ <xsl:value-of select="text()"/>
+ <xsl:text>"</xsl:text>
+
+ <xsl:choose>
+ <xsl:when test="@datatype">
+ <!-- datatyped literal value -->
+ ^^<<xsl:value-of select="@datatype"/>>
+ </xsl:when>
+ <xsl:when test="@xml:lang">
+ <!-- lang-string -->
+ @<xsl:value-of select="@xml:lang"/>
+ </xsl:when>
+ </xsl:choose>
+ </xsl:template>
+
+ <xsl:template match="res:sparql">
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+ <head>
+ <title>SPARQLer Query Results</title>
+ <style>
+ <![CDATA[
+ h1 { font-size: 150% ; }
+ h2 { font-size: 125% ; }
+ table { border-collapse: collapse ; border: 1px solid black ; }
+ td, th
+ { border: 1px solid black ;
+ padding-left:0.5em; padding-right: 0.5em;
+ padding-top:0.2ex ; padding-bottom:0.2ex
+ }
+ ]]>
+ </style>
+ </head>
+ <body>
+
+
+ <h1>SPARQLer Query Results</h1>
+
+ <xsl:if test="res:head/res:link">
+ <xsl:call-template name="header"/>
+ </xsl:if>
+
+ <xsl:choose>
+ <xsl:when test="res:boolean">
+ <xsl:call-template name="boolean-result" />
+ </xsl:when>
+
+ <xsl:when test="res:results">
+ <xsl:call-template name="vb-result" />
+ </xsl:when>
+
+ </xsl:choose>
+
+
+ </body>
+ </html>
+ </xsl:template>
+</xsl:stylesheet>
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/pages/xml-to-html.xsl
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/pages/xml-to-html.xsl b/jena-fuseki2/jena-fuseki-main/sparqler/pages/xml-to-html.xsl
new file mode 100755
index 0000000..1878ab0
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/pages/xml-to-html.xsl
@@ -0,0 +1,187 @@
+<?xml version="1.0"?>
+
+<!--
+
+XSLT script to format SPARQL Query Results XML Format into xhtml
+
+Copyright © 2004, 2005 World Wide Web Consortium, (Massachusetts
+Institute of Technology, European Research Consortium for
+Informatics and Mathematics, Keio University). All Rights
+Reserved. This work is distributed under the W3C® Software
+License [1] in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or
+FITNESS FOR A PARTICULAR PURPOSE.
+
+[1] http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
+
+Version 1 : Dave Beckett (DAWG)
+Version 2 : Jeen Broekstra (DAWG)
+Customization for SPARQler: Andy Seaborne
+Fix:
+
+> - <xsl:for-each select="//res:head/res:variable">
+> + <xsl:for-each select="/res:sparql/res:head/res:variable">
+
+-->
+
+<xsl:stylesheet version="1.0"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:res="http://www.w3.org/2005/sparql-results#"
+ exclude-result-prefixes="res xsl">
+
+ <!--
+ <xsl:output
+ method="html"
+ media-type="text/html"
+ doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN"
+ indent="yes"
+ encoding="UTF-8"/>
+ -->
+
+ <!-- or this? -->
+
+ <xsl:output
+ method="xml"
+ indent="yes"
+ encoding="UTF-8"
+ doctype-public="-//W3C//DTD XHTML 1.0 Strict//EN"
+ doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"
+ omit-xml-declaration="no" />
+
+
+ <xsl:template name="header">
+ <div>
+ <h2>Header</h2>
+ <xsl:for-each select="res:head/res:link">
+ <p>Link to <xsl:value-of select="@href"/></p>
+ </xsl:for-each>
+ </div>
+ </xsl:template>
+
+ <xsl:template name="boolean-result">
+ <div>
+ <!--
+ <h2>Boolean Result</h2>
+ -->
+ <p>ASK => <xsl:value-of select="res:boolean"/></p>
+ </div>
+ </xsl:template>
+
+
+ <xsl:template name="vb-result">
+ <div>
+ <!--
+ <h2>Variable Bindings Result</h2>
+ <p>Ordered: <xsl:value-of select="res:results/@ordered"/></p>
+ <p>Distinct: <xsl:value-of select="res:results/@distinct"/></p>
+ -->
+
+ <table>
+ <xsl:text>
+ </xsl:text>
+ <tr>
+ <xsl:for-each select="res:head/res:variable">
+ <th><xsl:value-of select="@name"/></th>
+ </xsl:for-each>
+ </tr>
+ <xsl:text>
+ </xsl:text>
+ <xsl:for-each select="res:results/res:result">
+ <tr>
+ <xsl:apply-templates select="."/>
+ </tr>
+ </xsl:for-each>
+ </table>
+ </div>
+ </xsl:template>
+
+ <xsl:template match="res:result">
+ <xsl:variable name="current" select="."/>
+ <xsl:for-each select="/res:sparql/res:head/res:variable">
+ <xsl:variable name="name" select="@name"/>
+ <td>
+ <xsl:choose>
+ <xsl:when test="$current/res:binding[@name=$name]">
+ <!-- apply template for the correct value type (bnode, uri, literal) -->
+ <xsl:apply-templates select="$current/res:binding[@name=$name]"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <!-- no binding available for this variable in this solution -->
+ </xsl:otherwise>
+ </xsl:choose>
+ </td>
+ </xsl:for-each>
+ </xsl:template>
+
+ <xsl:template match="res:bnode">
+ <xsl:text>_:</xsl:text>
+ <xsl:value-of select="text()"/>
+ </xsl:template>
+
+ <xsl:template match="res:uri">
+ <xsl:variable name="uri" select="text()"/>
+ <xsl:text><</xsl:text>
+ <xsl:value-of select="$uri"/>
+ <xsl:text>></xsl:text>
+ </xsl:template>
+
+ <xsl:template match="res:literal">
+ <xsl:text>"</xsl:text>
+ <xsl:value-of select="text()"/>
+ <xsl:text>"</xsl:text>
+
+ <xsl:choose>
+ <xsl:when test="@datatype">
+ <!-- datatyped literal value -->
+ ^^<<xsl:value-of select="@datatype"/>>
+ </xsl:when>
+ <xsl:when test="@xml:lang">
+ <!-- lang-string -->
+ @<xsl:value-of select="@xml:lang"/>
+ </xsl:when>
+ </xsl:choose>
+ </xsl:template>
+
+ <xsl:template match="res:sparql">
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+ <head>
+ <title>SPARQLer Query Results</title>
+ <style>
+ <![CDATA[
+ h1 { font-size: 150% ; }
+ h2 { font-size: 125% ; }
+ table { border-collapse: collapse ; border: 1px solid black ; }
+ td, th
+ { border: 1px solid black ;
+ padding-left:0.5em; padding-right: 0.5em;
+ padding-top:0.2ex ; padding-bottom:0.2ex
+ }
+ ]]>
+ </style>
+ </head>
+ <body>
+
+
+ <h1>SPARQLer Query Results</h1>
+
+ <xsl:if test="res:head/res:link">
+ <xsl:call-template name="header"/>
+ </xsl:if>
+
+ <xsl:choose>
+ <xsl:when test="res:boolean">
+ <xsl:call-template name="boolean-result" />
+ </xsl:when>
+
+ <xsl:when test="res:results">
+ <xsl:call-template name="vb-result" />
+ </xsl:when>
+
+ </xsl:choose>
+
+
+ </body>
+ </html>
+ </xsl:template>
+</xsl:stylesheet>
http://git-wip-us.apache.org/repos/asf/jena/blob/b78f5182/jena-fuseki2/jena-fuseki-main/sparqler/run-sparqler
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-main/sparqler/run-sparqler b/jena-fuseki2/jena-fuseki-main/sparqler/run-sparqler
new file mode 100755
index 0000000..0d69faf
--- /dev/null
+++ b/jena-fuseki2/jena-fuseki-main/sparqler/run-sparqler
@@ -0,0 +1,63 @@
+#!/bin/bash
+## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
+
+## Configuration
+SPARQLER_PAGES="${SPARQLER_PAGES:-pages/}"
+SPARQLER_DATA="${SPARQLER_DATA:-file:data/books.ttl}"
+SPARQLER_DS="${SPARQLER_DS:-/books}"
+
+## Development
+FUSEKI_JAR1="$(echo jena-fuseki-basic-*-server.jar)"
+## Deployment
+FUSEKI_JAR2="fuseki-basic.jar"
+FUSEKI_JAR3=""
+
+# Choose which jar to run
+[[ -e $FUSEKI_JAR3 ]] && FUSEKI_JAR=$FUSEKI_JAR3
+[[ -e $FUSEKI_JAR2 ]] && FUSEKI_JAR=$FUSEKI_JAR2
+[[ -e $FUSEKI_JAR1 ]] && FUSEKI_JAR=$FUSEKI_JAR1
+
+if [ ! -e "$FUSEKI_JAR" ]
+then
+ echo "Can't find the Fuseki jar file: $FUSEKI_JAR" 1>&2
+ exit 1
+fi
+
+BACKGROUND=${BACKGROUND:-1}
+if [ "$BACKGROUND" = 0 ]
+then
+ LOGCONFIG=${LOGCONFIG:-file:log4j-foreground.properties}
+else
+ LOGCONFIG=${LOGCONFIG:-file:log4j-server.properties}
+fi
+
+export FUSEKI_LOG="-Dlog4j.configuration=${LOGCONFIG}"
+export JVM_ARGS="${JVM_ARGS:--Xmx1200M}"
+
+## SPARQLER_ARGS="--base $SPARQLER_PAGES --file=$SPARQLER_DATA $SPARQLER_DS"
+##
+## if [[ $1 == "--help" ]]
+## then
+## echo "$0"
+## echo "SPARQLER_PAGES = $SPARQLER_PAGES"
+## echo "SPARQLER_DATA = $SPARQLER_DATA"
+## echo "SPARQLER_DS = $SPARQLER_DS"
+## exit 0
+## fi
+
+SPARQLER_ARGS="--sparqler $SPARQLER_PAGES"
+
+set --
+
+if [ "$BACKGROUND" = 0 ]
+then
+ # Run in the foreground
+ exec java $JVM_ARGS $FUSEKI_LOG -jar "$FUSEKI_JAR" $SPARQLER_ARGS
+else
+ # Run in the background
+ # Linux / nohup
+ nohup java $JVM_ARGS $FUSEKI_LOG -jar "$FUSEKI_JAR" $SPARQLER_ARGS > nohup.log 2>&1 &
+ # Process ID ... of the script.
+ PROC=$!
+ echo "Server process = $PROC"
+fi