Skip to content
Snippets Groups Projects
Commit ebe70467 authored by Sebastien's avatar Sebastien
Browse files

Add tools to generate automatically java unl class from schema.ttl rdf shema of unl

parent 1d8649c7
No related branches found
No related tags found
No related merge requests found
Showing
with 1082 additions and 0 deletions
@echo off
@rem Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
if "%JENAROOT%" == "" goto :rootNotSet
set JENA_HOME=%JENAROOT%
:rootNotSet
if NOT "%JENA_HOME%" == "" goto :okHome
echo JENA_HOME not set
exit /B
:okHome
set JENA_CP=%JENA_HOME%\lib\*;
set LOGGING=file:%JENA_HOME%/jena-log4j.properties
@rem JVM_ARGS comes from the environment.
java %JVM_ARGS% -Dlog4j.configuration="%LOGGING%" -cp "%JENA_CP%" tdb.tdbquery %*
exit /B
@echo off
@rem Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
if "%JENAROOT%" == "" goto :rootNotSet
set JENA_HOME=%JENAROOT%
:rootNotSet
if NOT "%JENA_HOME%" == "" goto :okHome
echo JENA_HOME not set
exit /B
:okHome
set JENA_CP=%JENA_HOME%\lib\*;
set LOGGING=file:%JENA_HOME%/jena-log4j.properties
@rem JVM_ARGS comes from the environment.
java %JVM_ARGS% -Dlog4j.configuration="%LOGGING%" -cp "%JENA_CP%" tdb.tdbstats %*
exit /B
@echo off
@rem Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
if "%JENAROOT%" == "" goto :rootNotSet
set JENA_HOME=%JENAROOT%
:rootNotSet
if NOT "%JENA_HOME%" == "" goto :okHome
echo JENA_HOME not set
exit /B
:okHome
set JENA_CP=%JENA_HOME%\lib\*;
set LOGGING=file:%JENA_HOME%/jena-log4j.properties
@rem JVM_ARGS comes from the environment.
java %JVM_ARGS% -Dlog4j.configuration="%LOGGING%" -cp "%JENA_CP%" tdb.tdbupdate %*
exit /B
@echo off
@rem Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
if "%JENAROOT%" == "" goto :rootNotSet
set JENA_HOME=%JENAROOT%
:rootNotSet
if NOT "%JENA_HOME%" == "" goto :okHome
echo JENA_HOME not set
exit /B
:okHome
set JENA_CP=%JENA_HOME%\lib\*;
set LOGGING=file:%JENA_HOME%/jena-log4j.properties
@rem JVM_ARGS comes from the environment.
java %JVM_ARGS% -Dlog4j.configuration="%LOGGING%" -cp "%JENA_CP%" riotcmd.trig %*
exit /B
@echo off
@rem Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
if "%JENAROOT%" == "" goto :rootNotSet
set JENA_HOME=%JENAROOT%
:rootNotSet
if NOT "%JENA_HOME%" == "" goto :okHome
echo JENA_HOME not set
exit /B
:okHome
set JENA_CP=%JENA_HOME%\lib\*;
set LOGGING=file:%JENA_HOME%/jena-log4j.properties
@rem JVM_ARGS comes from the environment.
java %JVM_ARGS% -Dlog4j.configuration="%LOGGING%" -cp "%JENA_CP%" riotcmd.turtle %*
exit /B
@echo off
@rem Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
if "%JENAROOT%" == "" goto :rootNotSet
set JENA_HOME=%JENAROOT%
:rootNotSet
if NOT "%JENA_HOME%" == "" goto :okHome
echo JENA_HOME not set
exit /B
:okHome
set JENA_CP=%JENA_HOME%\lib\*;
set LOGGING=file:%JENA_HOME%/jena-log4j.properties
@rem JVM_ARGS comes from the environment.
java %JVM_ARGS% -Dlog4j.configuration="%LOGGING%" -cp "%JENA_CP%" arq.uparse %*
exit /B
@echo off
@rem Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
if "%JENAROOT%" == "" goto :rootNotSet
set JENA_HOME=%JENAROOT%
:rootNotSet
if NOT "%JENA_HOME%" == "" goto :okHome
echo JENA_HOME not set
exit /B
:okHome
set JENA_CP=%JENA_HOME%\lib\*;
set LOGGING=file:%JENA_HOME%/jena-log4j.properties
@rem JVM_ARGS comes from the environment.
java %JVM_ARGS% -Dlog4j.configuration="%LOGGING%" -cp "%JENA_CP%" arq.update %*
exit /B
@echo off
@rem Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
if "%JENAROOT%" == "" goto :rootNotSet
set JENA_HOME=%JENAROOT%
:rootNotSet
if NOT "%JENA_HOME%" == "" goto :okHome
echo JENA_HOME not set
exit /B
:okHome
set JENA_CP=%JENA_HOME%\lib\*;
set LOGGING=file:%JENA_HOME%/jena-log4j.properties
@rem JVM_ARGS comes from the environment.
java %JVM_ARGS% -Dlog4j.configuration="%LOGGING%" -cp "%JENA_CP%" riotcmd.utf8 %*
exit /B
@echo off
@rem Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
if "%JENAROOT%" == "" goto :rootNotSet
set JENA_HOME=%JENAROOT%
:rootNotSet
if NOT "%JENA_HOME%" == "" goto :okHome
echo JENA_HOME not set
exit /B
:okHome
set JENA_CP=%JENA_HOME%\lib\*;
set LOGGING=file:%JENA_HOME%/jena-log4j.properties
@rem JVM_ARGS comes from the environment.
java %JVM_ARGS% -Dlog4j.configuration="%LOGGING%" -cp "%JENA_CP%" arq.wwwdec %*
exit /B
@echo off
@rem Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
if "%JENAROOT%" == "" goto :rootNotSet
set JENA_HOME=%JENAROOT%
:rootNotSet
if NOT "%JENA_HOME%" == "" goto :okHome
echo JENA_HOME not set
exit /B
:okHome
set JENA_CP=%JENA_HOME%\lib\*;
set LOGGING=file:%JENA_HOME%/jena-log4j.properties
@rem JVM_ARGS comes from the environment.
java %JVM_ARGS% -Dlog4j.configuration="%LOGGING%" -cp "%JENA_CP%" arq.wwwenc %*
exit /B
#!/bin/sh
## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
resolveLink() {
local NAME=$1
if [ -L "$NAME" ]; then
case "$OSTYPE" in
darwin*|bsd*)
# BSD style readlink behaves differently to GNU readlink
# Have to manually follow links
while [ -L "$NAME" ]; do
NAME=$( cd $NAME && pwd -P ) ;
done
;;
*)
# Assuming standard GNU readlink with -f for
# canonicalize and follow
NAME=$(readlink -f "$NAME")
;;
esac
fi
echo "$NAME"
}
# If JENA_HOME is empty
if [ -z "$JENA_HOME" ]; then
SCRIPT="$0"
# Catch common issue: script has been symlinked
if [ -L "$SCRIPT" ]; then
SCRIPT=$(resolveLink "$0")
# If link is relative
case "$SCRIPT" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
SCRIPT=$( dirname "$0" )/$SCRIPT
;;
esac
fi
# Work out root from script location
JENA_HOME="$( cd "$( dirname "$SCRIPT" )/.." && pwd )"
export JENA_HOME
fi
# If JENA_HOME is a symbolic link need to resolve
if [ -L "${JENA_HOME}" ]; then
JENA_HOME=$(resolveLink "$JENA_HOME")
# If link is relative
case "$JENA_HOME" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
JENA_HOME=$(dirname "$JENA_HOME")
;;
esac
export JENA_HOME
fi
# ---- Setup
# JVM_ARGS : don't set here but it can be set in the environment.
# Expand JENA_HOME but literal *
JENA_CP="$JENA_HOME"'/lib/*'
SOCKS=
LOGGING="${LOGGING:--Dlog4j.configuration=file:$JENA_HOME/jena-log4j.properties}"
# Platform specific fixup
# On CYGWIN convert path and end with a ';'
case "$(uname)" in
CYGWIN*) JENA_CP="$(cygpath -wp "$JENA_CP");";;
esac
# Respect TMPDIR or TMP (windows?) if present
# important for tdbloader spill
if [ -n "$TMPDIR" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMPDIR\""
elif [ -n "$TMP" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMP\""
fi
java $JVM_ARGS $LOGGING -cp "$JENA_CP" arq.arq "$@"
#!/bin/sh
## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
resolveLink() {
local NAME=$1
if [ -L "$NAME" ]; then
case "$OSTYPE" in
darwin*|bsd*)
# BSD style readlink behaves differently to GNU readlink
# Have to manually follow links
while [ -L "$NAME" ]; do
NAME=$( cd $NAME && pwd -P ) ;
done
;;
*)
# Assuming standard GNU readlink with -f for
# canonicalize and follow
NAME=$(readlink -f "$NAME")
;;
esac
fi
echo "$NAME"
}
# If JENA_HOME is empty
if [ -z "$JENA_HOME" ]; then
SCRIPT="$0"
# Catch common issue: script has been symlinked
if [ -L "$SCRIPT" ]; then
SCRIPT=$(resolveLink "$0")
# If link is relative
case "$SCRIPT" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
SCRIPT=$( dirname "$0" )/$SCRIPT
;;
esac
fi
# Work out root from script location
JENA_HOME="$( cd "$( dirname "$SCRIPT" )/.." && pwd )"
export JENA_HOME
fi
# If JENA_HOME is a symbolic link need to resolve
if [ -L "${JENA_HOME}" ]; then
JENA_HOME=$(resolveLink "$JENA_HOME")
# If link is relative
case "$JENA_HOME" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
JENA_HOME=$(dirname "$JENA_HOME")
;;
esac
export JENA_HOME
fi
# ---- Setup
# JVM_ARGS : don't set here but it can be set in the environment.
# Expand JENA_HOME but literal *
JENA_CP="$JENA_HOME"'/lib/*'
SOCKS=
LOGGING="${LOGGING:--Dlog4j.configuration=file:$JENA_HOME/jena-log4j.properties}"
# Platform specific fixup
# On CYGWIN convert path and end with a ';'
case "$(uname)" in
CYGWIN*) JENA_CP="$(cygpath -wp "$JENA_CP");";;
esac
# Respect TMPDIR or TMP (windows?) if present
# important for tdbloader spill
if [ -n "$TMPDIR" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMPDIR\""
elif [ -n "$TMP" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMP\""
fi
java $JVM_ARGS $LOGGING -cp "$JENA_CP" riotcmd.infer "$@"
#!/bin/sh
## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
resolveLink() {
local NAME=$1
if [ -L "$NAME" ]; then
case "$OSTYPE" in
darwin*|bsd*)
# BSD style readlink behaves differently to GNU readlink
# Have to manually follow links
while [ -L "$NAME" ]; do
NAME=$( cd $NAME && pwd -P ) ;
done
;;
*)
# Assuming standard GNU readlink with -f for
# canonicalize and follow
NAME=$(readlink -f "$NAME")
;;
esac
fi
echo "$NAME"
}
# If JENA_HOME is empty
if [ -z "$JENA_HOME" ]; then
SCRIPT="$0"
# Catch common issue: script has been symlinked
if [ -L "$SCRIPT" ]; then
SCRIPT=$(resolveLink "$0")
# If link is relative
case "$SCRIPT" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
SCRIPT=$( dirname "$0" )/$SCRIPT
;;
esac
fi
# Work out root from script location
JENA_HOME="$( cd "$( dirname "$SCRIPT" )/.." && pwd )"
export JENA_HOME
fi
# If JENA_HOME is a symbolic link need to resolve
if [ -L "${JENA_HOME}" ]; then
JENA_HOME=$(resolveLink "$JENA_HOME")
# If link is relative
case "$JENA_HOME" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
JENA_HOME=$(dirname "$JENA_HOME")
;;
esac
export JENA_HOME
fi
# ---- Setup
# JVM_ARGS : don't set here but it can be set in the environment.
# Expand JENA_HOME but literal *
JENA_CP="$JENA_HOME"'/lib/*'
SOCKS=
LOGGING="${LOGGING:--Dlog4j.configuration=file:$JENA_HOME/jena-log4j.properties}"
# Platform specific fixup
# On CYGWIN convert path and end with a ';'
case "$(uname)" in
CYGWIN*) JENA_CP="$(cygpath -wp "$JENA_CP");";;
esac
# Respect TMPDIR or TMP (windows?) if present
# important for tdbloader spill
if [ -n "$TMPDIR" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMPDIR\""
elif [ -n "$TMP" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMP\""
fi
java $JVM_ARGS $LOGGING -cp "$JENA_CP" arq.iri "$@"
#!/bin/sh
## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
resolveLink() {
local NAME=$1
if [ -L "$NAME" ]; then
case "$OSTYPE" in
darwin*|bsd*)
# BSD style readlink behaves differently to GNU readlink
# Have to manually follow links
while [ -L "$NAME" ]; do
NAME=$( cd $NAME && pwd -P ) ;
done
;;
*)
# Assuming standard GNU readlink with -f for
# canonicalize and follow
NAME=$(readlink -f "$NAME")
;;
esac
fi
echo "$NAME"
}
# If JENA_HOME is empty
if [ -z "$JENA_HOME" ]; then
SCRIPT="$0"
# Catch common issue: script has been symlinked
if [ -L "$SCRIPT" ]; then
SCRIPT=$(resolveLink "$0")
# If link is relative
case "$SCRIPT" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
SCRIPT=$( dirname "$0" )/$SCRIPT
;;
esac
fi
# Work out root from script location
JENA_HOME="$( cd "$( dirname "$SCRIPT" )/.." && pwd )"
export JENA_HOME
fi
# If JENA_HOME is a symbolic link need to resolve
if [ -L "${JENA_HOME}" ]; then
JENA_HOME=$(resolveLink "$JENA_HOME")
# If link is relative
case "$JENA_HOME" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
JENA_HOME=$(dirname "$JENA_HOME")
;;
esac
export JENA_HOME
fi
# ---- Setup
# JVM_ARGS : don't set here but it can be set in the environment.
# Expand JENA_HOME but literal *
JENA_CP="$JENA_HOME"'/lib/*'
SOCKS=
LOGGING="${LOGGING:--Dlog4j.configuration=file:$JENA_HOME/jena-log4j.properties}"
# Platform specific fixup
# On CYGWIN convert path and end with a ';'
case "$(uname)" in
CYGWIN*) JENA_CP="$(cygpath -wp "$JENA_CP");";;
esac
# Respect TMPDIR or TMP (windows?) if present
# important for tdbloader spill
if [ -n "$TMPDIR" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMPDIR\""
elif [ -n "$TMP" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMP\""
fi
## ---- Determine the command.
case "$#" in
0)
V="$(java -cp "$JENA_CP" jena.version)"
echo "Jena version : $V"
echo "Jena home : $JENA_HOME"
exit
;;
*) CMD="$1" ; shift ;;
esac
java $JVM_ARGS $LOGGING -cp "$JENA_CP" "$CMD" "$@"
#!/bin/sh
## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
resolveLink() {
local NAME=$1
if [ -L "$NAME" ]; then
case "$OSTYPE" in
darwin*|bsd*)
# BSD style readlink behaves differently to GNU readlink
# Have to manually follow links
while [ -L "$NAME" ]; do
NAME=$( cd $NAME && pwd -P ) ;
done
;;
*)
# Assuming standard GNU readlink with -f for
# canonicalize and follow
NAME=$(readlink -f "$NAME")
;;
esac
fi
echo "$NAME"
}
# If JENA_HOME is empty
if [ -z "$JENA_HOME" ]; then
SCRIPT="$0"
# Catch common issue: script has been symlinked
if [ -L "$SCRIPT" ]; then
SCRIPT=$(resolveLink "$0")
# If link is relative
case "$SCRIPT" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
SCRIPT=$( dirname "$0" )/$SCRIPT
;;
esac
fi
# Work out root from script location
JENA_HOME="$( cd "$( dirname "$SCRIPT" )/.." && pwd )"
export JENA_HOME
fi
# If JENA_HOME is a symbolic link need to resolve
if [ -L "${JENA_HOME}" ]; then
JENA_HOME=$(resolveLink "$JENA_HOME")
# If link is relative
case "$JENA_HOME" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
JENA_HOME=$(dirname "$JENA_HOME")
;;
esac
export JENA_HOME
fi
# ---- Setup
# JVM_ARGS : don't set here but it can be set in the environment.
# Expand JENA_HOME but literal *
JENA_CP="$JENA_HOME"'/lib/*'
SOCKS=
LOGGING="${LOGGING:--Dlog4j.configuration=file:$JENA_HOME/jena-log4j.properties}"
# Platform specific fixup
# On CYGWIN convert path and end with a ';'
case "$(uname)" in
CYGWIN*) JENA_CP="$(cygpath -wp "$JENA_CP");";;
esac
# Respect TMPDIR or TMP (windows?) if present
# important for tdbloader spill
if [ -n "$TMPDIR" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMPDIR\""
elif [ -n "$TMP" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMP\""
fi
java $JVM_ARGS $LOGGING -cp "$JENA_CP" arq.juuid "$@"
#!/bin/sh
## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
resolveLink() {
local NAME=$1
if [ -L "$NAME" ]; then
case "$OSTYPE" in
darwin*|bsd*)
# BSD style readlink behaves differently to GNU readlink
# Have to manually follow links
while [ -L "$NAME" ]; do
NAME=$( cd $NAME && pwd -P ) ;
done
;;
*)
# Assuming standard GNU readlink with -f for
# canonicalize and follow
NAME=$(readlink -f "$NAME")
;;
esac
fi
echo "$NAME"
}
# If JENA_HOME is empty
if [ -z "$JENA_HOME" ]; then
SCRIPT="$0"
# Catch common issue: script has been symlinked
if [ -L "$SCRIPT" ]; then
SCRIPT=$(resolveLink "$0")
# If link is relative
case "$SCRIPT" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
SCRIPT=$( dirname "$0" )/$SCRIPT
;;
esac
fi
# Work out root from script location
JENA_HOME="$( cd "$( dirname "$SCRIPT" )/.." && pwd )"
export JENA_HOME
fi
# If JENA_HOME is a symbolic link need to resolve
if [ -L "${JENA_HOME}" ]; then
JENA_HOME=$(resolveLink "$JENA_HOME")
# If link is relative
case "$JENA_HOME" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
JENA_HOME=$(dirname "$JENA_HOME")
;;
esac
export JENA_HOME
fi
# ---- Setup
# JVM_ARGS : don't set here but it can be set in the environment.
# Expand JENA_HOME but literal *
JENA_CP="$JENA_HOME"'/lib/*'
SOCKS=
LOGGING="${LOGGING:--Dlog4j.configuration=file:$JENA_HOME/jena-log4j.properties}"
# Platform specific fixup
# On CYGWIN convert path and end with a ';'
case "$(uname)" in
CYGWIN*) JENA_CP="$(cygpath -wp "$JENA_CP");";;
esac
# Respect TMPDIR or TMP (windows?) if present
# important for tdbloader spill
if [ -n "$TMPDIR" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMPDIR\""
elif [ -n "$TMP" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMP\""
fi
java $JVM_ARGS $LOGGING -cp "$JENA_CP" riotcmd.nquads "$@"
#!/bin/sh
## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
resolveLink() {
local NAME=$1
if [ -L "$NAME" ]; then
case "$OSTYPE" in
darwin*|bsd*)
# BSD style readlink behaves differently to GNU readlink
# Have to manually follow links
while [ -L "$NAME" ]; do
NAME=$( cd $NAME && pwd -P ) ;
done
;;
*)
# Assuming standard GNU readlink with -f for
# canonicalize and follow
NAME=$(readlink -f "$NAME")
;;
esac
fi
echo "$NAME"
}
# If JENA_HOME is empty
if [ -z "$JENA_HOME" ]; then
SCRIPT="$0"
# Catch common issue: script has been symlinked
if [ -L "$SCRIPT" ]; then
SCRIPT=$(resolveLink "$0")
# If link is relative
case "$SCRIPT" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
SCRIPT=$( dirname "$0" )/$SCRIPT
;;
esac
fi
# Work out root from script location
JENA_HOME="$( cd "$( dirname "$SCRIPT" )/.." && pwd )"
export JENA_HOME
fi
# If JENA_HOME is a symbolic link need to resolve
if [ -L "${JENA_HOME}" ]; then
JENA_HOME=$(resolveLink "$JENA_HOME")
# If link is relative
case "$JENA_HOME" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
JENA_HOME=$(dirname "$JENA_HOME")
;;
esac
export JENA_HOME
fi
# ---- Setup
# JVM_ARGS : don't set here but it can be set in the environment.
# Expand JENA_HOME but literal *
JENA_CP="$JENA_HOME"'/lib/*'
SOCKS=
LOGGING="${LOGGING:--Dlog4j.configuration=file:$JENA_HOME/jena-log4j.properties}"
# Platform specific fixup
# On CYGWIN convert path and end with a ';'
case "$(uname)" in
CYGWIN*) JENA_CP="$(cygpath -wp "$JENA_CP");";;
esac
# Respect TMPDIR or TMP (windows?) if present
# important for tdbloader spill
if [ -n "$TMPDIR" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMPDIR\""
elif [ -n "$TMP" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMP\""
fi
java $JVM_ARGS $LOGGING -cp "$JENA_CP" riotcmd.ntriples "$@"
#!/bin/sh
## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
resolveLink() {
local NAME=$1
if [ -L "$NAME" ]; then
case "$OSTYPE" in
darwin*|bsd*)
# BSD style readlink behaves differently to GNU readlink
# Have to manually follow links
while [ -L "$NAME" ]; do
NAME=$( cd $NAME && pwd -P ) ;
done
;;
*)
# Assuming standard GNU readlink with -f for
# canonicalize and follow
NAME=$(readlink -f "$NAME")
;;
esac
fi
echo "$NAME"
}
# If JENA_HOME is empty
if [ -z "$JENA_HOME" ]; then
SCRIPT="$0"
# Catch common issue: script has been symlinked
if [ -L "$SCRIPT" ]; then
SCRIPT=$(resolveLink "$0")
# If link is relative
case "$SCRIPT" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
SCRIPT=$( dirname "$0" )/$SCRIPT
;;
esac
fi
# Work out root from script location
JENA_HOME="$( cd "$( dirname "$SCRIPT" )/.." && pwd )"
export JENA_HOME
fi
# If JENA_HOME is a symbolic link need to resolve
if [ -L "${JENA_HOME}" ]; then
JENA_HOME=$(resolveLink "$JENA_HOME")
# If link is relative
case "$JENA_HOME" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
JENA_HOME=$(dirname "$JENA_HOME")
;;
esac
export JENA_HOME
fi
# ---- Setup
# JVM_ARGS : don't set here but it can be set in the environment.
# Expand JENA_HOME but literal *
JENA_CP="$JENA_HOME"'/lib/*'
SOCKS=
LOGGING="${LOGGING:--Dlog4j.configuration=file:$JENA_HOME/jena-log4j.properties}"
# Platform specific fixup
# On CYGWIN convert path and end with a ';'
case "$(uname)" in
CYGWIN*) JENA_CP="$(cygpath -wp "$JENA_CP");";;
esac
# Respect TMPDIR or TMP (windows?) if present
# important for tdbloader spill
if [ -n "$TMPDIR" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMPDIR\""
elif [ -n "$TMP" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMP\""
fi
java $JVM_ARGS $LOGGING -cp "$JENA_CP" arq.qparse "$@"
#!/bin/sh
## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
resolveLink() {
local NAME=$1
if [ -L "$NAME" ]; then
case "$OSTYPE" in
darwin*|bsd*)
# BSD style readlink behaves differently to GNU readlink
# Have to manually follow links
while [ -L "$NAME" ]; do
NAME=$( cd $NAME && pwd -P ) ;
done
;;
*)
# Assuming standard GNU readlink with -f for
# canonicalize and follow
NAME=$(readlink -f "$NAME")
;;
esac
fi
echo "$NAME"
}
# If JENA_HOME is empty
if [ -z "$JENA_HOME" ]; then
SCRIPT="$0"
# Catch common issue: script has been symlinked
if [ -L "$SCRIPT" ]; then
SCRIPT=$(resolveLink "$0")
# If link is relative
case "$SCRIPT" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
SCRIPT=$( dirname "$0" )/$SCRIPT
;;
esac
fi
# Work out root from script location
JENA_HOME="$( cd "$( dirname "$SCRIPT" )/.." && pwd )"
export JENA_HOME
fi
# If JENA_HOME is a symbolic link need to resolve
if [ -L "${JENA_HOME}" ]; then
JENA_HOME=$(resolveLink "$JENA_HOME")
# If link is relative
case "$JENA_HOME" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
JENA_HOME=$(dirname "$JENA_HOME")
;;
esac
export JENA_HOME
fi
# ---- Setup
# JVM_ARGS : don't set here but it can be set in the environment.
# Expand JENA_HOME but literal *
JENA_CP="$JENA_HOME"'/lib/*'
SOCKS=
LOGGING="${LOGGING:--Dlog4j.configuration=file:$JENA_HOME/jena-log4j.properties}"
# Platform specific fixup
# On CYGWIN convert path and end with a ';'
case "$(uname)" in
CYGWIN*) JENA_CP="$(cygpath -wp "$JENA_CP");";;
esac
# Respect TMPDIR or TMP (windows?) if present
# important for tdbloader spill
if [ -n "$TMPDIR" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMPDIR\""
elif [ -n "$TMP" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMP\""
fi
java $JVM_ARGS $LOGGING -cp "$JENA_CP" jena.rdfcat "$@"
#!/bin/sh
## Licensed under the terms of http://www.apache.org/licenses/LICENSE-2.0
resolveLink() {
local NAME=$1
if [ -L "$NAME" ]; then
case "$OSTYPE" in
darwin*|bsd*)
# BSD style readlink behaves differently to GNU readlink
# Have to manually follow links
while [ -L "$NAME" ]; do
NAME=$( cd $NAME && pwd -P ) ;
done
;;
*)
# Assuming standard GNU readlink with -f for
# canonicalize and follow
NAME=$(readlink -f "$NAME")
;;
esac
fi
echo "$NAME"
}
# If JENA_HOME is empty
if [ -z "$JENA_HOME" ]; then
SCRIPT="$0"
# Catch common issue: script has been symlinked
if [ -L "$SCRIPT" ]; then
SCRIPT=$(resolveLink "$0")
# If link is relative
case "$SCRIPT" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
SCRIPT=$( dirname "$0" )/$SCRIPT
;;
esac
fi
# Work out root from script location
JENA_HOME="$( cd "$( dirname "$SCRIPT" )/.." && pwd )"
export JENA_HOME
fi
# If JENA_HOME is a symbolic link need to resolve
if [ -L "${JENA_HOME}" ]; then
JENA_HOME=$(resolveLink "$JENA_HOME")
# If link is relative
case "$JENA_HOME" in
/*)
# Already absolute
;;
*)
# Relative, make absolute
JENA_HOME=$(dirname "$JENA_HOME")
;;
esac
export JENA_HOME
fi
# ---- Setup
# JVM_ARGS : don't set here but it can be set in the environment.
# Expand JENA_HOME but literal *
JENA_CP="$JENA_HOME"'/lib/*'
SOCKS=
LOGGING="${LOGGING:--Dlog4j.configuration=file:$JENA_HOME/jena-log4j.properties}"
# Platform specific fixup
# On CYGWIN convert path and end with a ';'
case "$(uname)" in
CYGWIN*) JENA_CP="$(cygpath -wp "$JENA_CP");";;
esac
# Respect TMPDIR or TMP (windows?) if present
# important for tdbloader spill
if [ -n "$TMPDIR" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMPDIR\""
elif [ -n "$TMP" ]
then
JVM_ARGS="$JVM_ARGS -Djava.io.tmpdir=\"$TMP\""
fi
java $JVM_ARGS $LOGGING -cp "$JENA_CP" jena.rdfcompare "$@"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment