This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
the following is an example of a left fold xslt | |
java -jar /Applications/depify-1.0/deps/xmlcalabash/calabash.jar -isource=test.xml -istylesheets=test1.xsl -istylesheets=test2.xsl -oresult=- xslt-fold.xpl | |
<p:declare-step version="1.0" | |
xmlns:p="http://www.w3.org/ns/xproc" | |
xmlns:c="http://www.w3.org/ns/xproc-step" | |
xmlns:ex="http://www.example.com" | |
name="main"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
xquery version "3.1"; | |
(: | |
Receive payloads from BitBucket.org POST hooks with eXist | |
Prerequisites: | |
1. A post-January 2015 build of the develop branch of eXist, which adds support | |
for XQuery 3.1's JSON parsing and serialization features. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml-stylesheet type="text/xsl" href="http://localhost:8080/exist/apps/xsltforms/xsltforms.xsl"?><?css-conversion no?><?xsltforms-options debug="yes"?><?xml-model href="http://www.oxygenxml.com/1999/xhtml/xhtml-xforms.nvdl" schematypens="http://purl.oclc.org/dsdl/nvdl/ns/structure/1.0"?> | |
<html | |
xmlns="http://www.w3.org/1999/xhtml" | |
xmlns:bf="http://bibframe.org/vocab/" | |
xmlns:cwb="http://libserv6.princeton.edu/cwb/" | |
xmlns:ev="http://www.w3.org/2001/xml-events" | |
xmlns:xf="http://www.w3.org/2002/xforms" | |
xmlns:xs="http://www.w3.org/2001/XMLSchema"> | |
<head> | |
<meta |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Load incremental changes since the last load. This script maintains a | |
# hidden file that keeps track of this information. | |
# | |
# UTILS | |
DATE="/bin/date" | |
CURL="/usr/bin/curl" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
xquery version "3.1"; | |
(: parse tweets using XQuery 3.1's JSON support | |
: see http://www.w3.org/TR/xpath-functions-31/#json | |
: sample JSON from https://dev.twitter.com/rest/reference/get/statuses/user_timeline | |
:) | |
let $json := json-doc('/db/user_timeline.json') | |
let $tweets := $json?* | |
return |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
xquery version "3.0"; | |
(:~ An implementation of facet:count as described in "Case 1: Simple facet based on existing attribute" | |
of the EXPath Facet Spec. Depends on eXist's util:eval() function to handle dynamic path expressions. | |
@see http://expath.org/spec/facet/20151225#case-1-simple-facet-based-on-existing-attribute | |
:) | |
import module namespace util="http://exist-db.org/xquery/util"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
xquery version "3.0"; | |
declare namespace tei="http://www.tei-c.org/ns/1.0"; | |
import module namespace ner="http://exist-db.org/xquery/stanford-ner"; | |
let $classifier := xs:anyURI("/db/apps/stanford-ner/resources/classifiers/english.muc.7class.distsim.crf.ser.gz") | |
for $node in fn:doc("/shakespeare/WT.xml")//tei:ab | |
let $line := | |
<line>{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
xquery version "1.0" encoding "UTF-8"; | |
(: This file was generated on Sat Feb 13, 2016 20:32 (UTC-05) by REx v5.35 which is Copyright (c) 1979-2015 by Gunther Rademacher <grd@gmx.net> :) | |
(: REx command line: turtle.ebnf -faster -xquery -tree :) | |
(:~ | |
: The parser that was generated for the turtle grammar. | |
:) | |
module namespace p="turtle"; | |
declare default function namespace "http://www.w3.org/2005/xpath-functions"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml-stylesheet href="../build/xsltforms.xsl" type="text/xsl"?><?xsltforms-options debug="no"?><?css-conversion no?><?xml-model href="http://www.oxygenxml.com/1999/xhtml/xhtml-xforms.nvdl" schematypens="http://purl.oclc.org/dsdl/nvdl/ns/structure/1.0"?> | |
<html | |
xmlns="http://www.w3.org/1999/xhtml" | |
xmlns:cwb="http://example.org/cwb/" | |
xmlns:ev="http://www.w3.org/2001/xml-events" | |
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" | |
xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" | |
xmlns:xf="http://www.w3.org/2002/xforms" | |
xmlns:xi="http://www.w3.org/2001/XInclude" | |
xmlns:xs="http://www.w3.org/2001/XMLSchema" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
xquery version "3.1"; | |
declare function local:get_facet ($books as element()*, $path as xs:string ) as element()? | |
{ | |
<binding>{ | |
for $book in $books | |
let $fld := $book/*[name()=$path] | |
group by $f := $fld |
OlderNewer