@echo off
rem *** Batch file, called from wrun.bat, 
rem *** that starts the Browser running under JERI

set JDK_HOME=%1
set JINI_HOME=%2
set EXAMPLE_HOME=%3
set HOSTNAME=%4
set CODEBASE_PORT=%5
set DEBUG_ON=%6

if on==%DEBUG_ON% set DEBUG=access,failure

set START_SERVICE=%JDK_HOME%\bin\java ^
-Djava.security.manager= ^
-Djava.security.policy=%EXAMPLE_HOME%\example\browser\jeri\policy\browser.policy ^
-Djava.rmi.server.codebase=http://%HOSTNAME%:%CODEBASE_PORT%/browser-dl.jar ^
-Djava.util.logging.manager=com.sun.jini.logging.LogManager ^
-Djava.util.logging.config.file=%EXAMPLE_HOME%\example\common\logging\jini.logging ^
-Dconfig=%EXAMPLE_HOME%\example\browser\jeri\config\browser.config ^
-DserverHost=%HOSTNAME% ^
-DjiniDir=%JINI_HOME% ^
-DinstallDir=%EXAMPLE_HOME% ^
-Djava.security.debug=%DEBUG% ^
-jar %JINI_HOME%\lib\browser.jar ^
%EXAMPLE_HOME%\example\browser\jeri\config\browser.config

echo.
echo %START_SERVICE%
echo.

start %START_SERVICE%
