Subversion-Projekte lars-tiefland.cienc

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
5 lars 1
<!doctype html>
2
<title>CodeMirror: SPARQL mode</title>
3
<meta charset="utf-8" />
4
<link rel=stylesheet href="../../doc/docs.css">
5
<link rel="stylesheet" href="../../lib/codemirror.css">
6
<script src="../../lib/codemirror.js"></script>
7
<script src="../../addon/edit/matchbrackets.js"></script>
8
<script src="sparql.js"></script>
9
<style>
10
    .CodeMirror {
11
        border-top: 1px solid black;
12
        border-bottom: 1px solid black;
13
    }
14
</style>
15
<div id=nav>
16
    <a href="http://codemirror.net">
17
        <h1>CodeMirror</h1>
18
        <img id=logo src="../../doc/logo.png">
19
    </a>
20
    <ul>
21
        <li>
22
            <a href="../../index.html">Home</a>
23
            <li>
24
                <a href="../../doc/manual.html">Manual</a>
25
                <li>
26
                    <a href="https://github.com/codemirror/codemirror">Code</a>
27
    </ul>
28
    <ul>
29
        <li>
30
            <a href="../index.html">Language modes</a>
31
            <li>
32
                <a class=active href="#">SPARQL</a>
33
    </ul>
34
</div>
35
<article>
36
    <h2>SPARQL mode</h2>
37
    <form>
38
        <textarea id="code" name="code"> PREFIX a: &lt;http://www.w3.org/2000/10/annotation-ns#> PREFIX dc: &lt;http://purl.org/dc/elements/1.1/> PREFIX foaf: &lt;http://xmlns.com/foaf/0.1/> PREFIX rdfs: &lt;http://www.w3.org/2000/01/rdf-schema#> # Comment! SELECT ?given ?family WHERE
39
            { { ?annot a:annotates &lt;http://www.w3.org/TR/rdf-sparql-query/> . ?annot dc:creator ?c . OPTIONAL {?c foaf:givenName ?given ; foaf:familyName ?family } } UNION { ?c !foaf:knows/foaf:knows? ?thing. ?thing rdfs } MINUS { ?thing rdfs:label
40
            "剛柔流"@jp } FILTER isBlank(?c) } </textarea>
41
    </form>
42
    <script>
43
        var editor = CodeMirror.fromTextArea(document.getElementById("code"),
44
        {
45
            mode: "application/sparql-query",
46
            matchBrackets: true
47
        });
48
    </script>
49
    <p>
50
        <strong>MIME types defined:</strong> <code>application/sparql-query</code>.</p>
51
</article>