@ECHO OFF 
rem
rem 
rem   Copyright 2009 Bundesamt für Informatik und Telekommunikation
rem
rem   Licensed under the Apache License, Version 2.0 (the "License");
rem   you may not use this file except in compliance with the License.
rem   You may obtain a copy of the License at
rem
rem       http://www.apache.org/licenses/LICENSE-2.0
rem
rem   Unless required by applicable law or agreed to in writing, software
rem   distributed under the License is distributed on an "AS IS" BASIS,
rem   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
rem   See the License for the specific language governing permissions and
rem   limitations under the License.
rem
rem 

echo JAVA_HOME: %JAVA_HOME%

set APP_DIR=%~dp0

if exist "%JAVA_HOME%" goto :java_home_set

goto :java_home_not_set



:java_home_set
set RUN_CMD=%JAVA_HOME%\jre\bin\java
goto :run


:java_home_not_set
set RUN_CMD=java
goto :run


:run

set PARAM=-cp edec-signature-validator.jar ch.admin.bit.edec.evv.ui.EVVValidator %*

echo run %RUN_CMD% %PARAM%
%RUN_CMD% %PARAM%
