Table of Contents
Install Enhydra5.1 (in this tutorial, it will be assumed that ENHYDRA_HOME directory is "C:\enhydra5.1")
Install Kelp5.1 for JBuilder8
Rename original Poker application directory "C:\enhydra5.1\examples\poker" to avoid overwriting (in this tutorial, application directory has been renamed to "C:\enhydra5.1\examples\poker1").
Open JBuilder8 and create new Kelp project via Kelp Wizard (File > New > Enhydra >Enhydra Application). Appeared wizard has three steps, and following parameters in step 1 of 3 should be set:
Project name: poker
Project for defaults: Default project
Root path: C:/enhydra5.1/examples
Other parameters should be left as default. Note that directory structure of generated project is same as previosly renamed directory structure.
After Kelp wizard, automaticly appears Enhydra , and following parameters in step 1 of 2 should be set:
Project directory name: poker
Package: poker
Client type: HTML
Project root: C:/enhydra5.1/examples
Application server root: C:/enhydra5.1
Edit JBuilder project properties to add/create necessery library (tag paths > Required Libraries > Add > New). Set the new library for idb database jar file, or use existing, if it exists:
Name: idb
Location: JBuilder
Library Path: C:/enhydra5.1/lib/tools/idb/idb.jar
Delete all files from directories: "C:\enhydra5.1\examples\poker\resources" and "C:\enhydra5.1\examples\poker\src\poker\presentation" and delete single file Poker.java
Now, copy particular files and subdirectories from renamed (original) Poker application to new created project:
files from: "C:/enhydra5.1/examples/poker1/src" directory (except resources subdirectory) to: "C:/enhydra5.1/examples/poker/src"
files from: "C:/enhydra5.1/examples/poker1/src/poker/resources" to "C:/enhydra5.1/examples/poker/resources directory".
files: dods.properties and poker.doml from C:/enhydra5.1/examples/poker1 to: "C:/enhydra5.1/examples/poker"
files from: "C:/enhydra5.1/examples/poker1/input/conf" to: "C:/enhydra5.1/examples/poker/input/conf"
files and subdirectories from "C:/enhydra5.1/examples/poker1/src/poker/data/idb" to: "C:/enhydra5.1/examples/poker/input/idb directory"
file: poker.prp from "C:/enhydra5.1/examples/poker1/src/poker/data" to "C:/enhydra5.1/examples/poker/input"
Save the JBuilder project and edit poker.jpx file from the directory "C:\enhydra5.1\examples\poker" as described in following lines:
original tag:
<node name="presentation" type="Folder"> <file path="src/poker/presentation/RedirectPresentation.java"/> <file pa th="src/poker/presentation/WelcomePresentation.java"/> </node>
should be changed to:
<node name="presentation" type="Folder"> <file path="src/poker/presentation/login/BlackPagePresentation.java"/> <file path="src/poker/presentation/login/CreatePlayerPresentation.java"/> <file path="src/poker/presentation/login/CreationProcessorPresentation.java"/> <file path="src/poker/presentation/login/LoginPresentation.java"/> <file path="src/poker/presentation/login/LoginProcessorPresentation.java"/> <file path="src/poker/presentation/login/StartPresentation.java"/> <file path="src/poker/presentation/login/WelcomePresentation.java"/> <file path="src/poker/presentation/main/BankruptPresentation.java"/> <file path="src/poker/presentation/main/BetProcessorPresentation.java"/> <file path="src/poker/presentation/main/FirstDealPresentation.java"/> <file path="src/poker/presentation/main/HelpPresentation.java"/> <file path="src/poker/presentation/main/HousePresentation.java"/> <file path="src/poker/presentation/main/PayoutPresentation.java"/> <file path="src/poker/presentation/main/PlaceBetPresentation.java"/> <file path="src/poker/presentation/main/PopupPayoutPresentation.java"/> <file path="src/poker/presentation/main/QuitPresentation.java"/> <file path="src/poker/presentation/main/RedirectPresentation.java"/> <file path="src/poker/presentation/main/ScoresPresentation.java"/> <file path="src/poker/presentation/main/StatsPresentation.java"/> </node>
original tag:
<node name="resources" type="Folder"> <file path="resources/options.xmlc"/> <file path="resources/Welcome.html"/> </node>
should be changed to:
<node name="resources" type="Folder"> <file path="resources/login/BlackPage.html"/> <file path="resources/login/CreatePlayer.html"/> <file path="resources/login/Login.html"/> <file path="resources/login/options.xmlc"/> <file path="resources/login/Start.html"/> <file path="resources/login/Welcome.html"/> <file path="resources/main/Bankrupt.html"/> <file path="resources/main/FirstDeal.html"/> <file path="resources/main/Help.html"/> <file path="resources/main/House.html"/> <file path="resources/main/options.xmlc"/> <file path="resources/main/Payout.html"/> <file path="resources/main/PlaceBet.html"/> <file path="resources/main/PopupPayout.html"/> <file path="resources/main/Quit.html"/> <file path="resources/main/Scores.html"/> <file path="resources/main/Stats.html"/> </node>
original tag:
<node name="resources/media" type="Folder"> <file path="resources/media/Enhydra.gif"/> </node>
should be changed to:
<node name="resources/media" type="Folder"> <file path="resources/media/rank_n.gif"/> <file path="resources/media/21.gif"/> <file path="resources/media/5.gif"/> <file path="resources/media/52.gif"/> <file path="resources/media/newPla_n.gif"/> <file path="resources/media/stat_b.gif"/> <file path="resources/media/deck5.jpg"/> <file path="resources/media/17.gif"/> <file path="resources/media/morecash.gif"/> <file path="resources/media/odd_n.gif"/> <file path="resources/media/48.gif"/> <file path="resources/media/25.gif"/> <file path="resources/media/close2.gif"/> <file path="resources/media/9.gif"/> <file path="resources/media/bkgver4.jpg"/> <file path="resources/media/newhnd_b.gif"/> <file path="resources/media/33.gif"/> <file path="resources/media/draw_n.gif"/> <file path="resources/media/10.gif"/> <file path="resources/media/41.gif"/> <file path="resources/media/2.gif"/> <file path="resources/media/29.gif"/> <file path="resources/media/quit_n.gif"/> <file path="resources/media/deck2.jpg"/> <file path="resources/media/37.gif"/> <file path="resources/media/14.gif"/> <file path="resources/media/whatpass.gif"/> <file path="resources/media/sneakPak_b.gif"/> <file path="resources/media/45.gif"/> <file path="resources/media/22.gif"/> <file path="resources/media/6.gif"/> <file path="resources/media/30.gif"/> <file path="resources/media/spacery.gif"/> <file path="resources/media/hold_b.gif"/> <file path="resources/media/18.gif"/> <file path="resources/media/49.gif"/> <file path="resources/media/stat_n.gif"/> <file path="resources/media/26.gif"/> <file path="resources/media/bkgver5.jpg"/> <file path="resources/media/34.gif"/> <file path="resources/media/11.gif"/> <file path="resources/media/adapti_b.gif"/> <file path="resources/media/bankrupt.jpg"/> <file path="resources/media/42.gif"/> <file path="resources/media/totabl_b.gif"/> <file path="resources/media/newhnd_n.gif"/> <file path="resources/media/3.gif"/> <file path="resources/media/50.gif"/> <file path="resources/media/house_b.gif"/> <file path="resources/media/deck3.jpg"/> <file path="resources/media/38.gif"/> <file path="resources/media/15.gif"/> <file path="resources/media/46.gif"/> <file path="resources/media/23.gif"/> <file path="resources/media/drawca_b.gif"/> <file path="resources/media/7.gif"/> <file path="resources/media/logint_b.gif"/> <file path="resources/media/blank.gif"/> <file path="resources/media/31.gif"/> <file path="resources/media/sneakPak_n.gif"/> <file path="resources/media/help_b.gif"/> <file path="resources/media/playcard.gif"/> <file path="resources/media/19.gif"/> <file path="resources/media/hold_n.gif"/> <file path="resources/media/27.gif"/> <file path="resources/media/rank_b.gif"/> <file path="resources/media/35.gif"/> <file path="resources/media/12.gif"/> <file path="resources/media/Enhydra.gif"/> <file path="resources/media/43.gif"/> <file path="resources/media/20.gif"/> <file path="resources/media/newPla_b.gif"/> <file path="resources/media/4.gif"/> <file path="resources/media/51.gif"/> <file path="resources/media/adapti_n.gif"/> <file path="resources/media/odd_b.gif"/> <file path="resources/media/totabl_n.gif"/> <file path="resources/media/house_n.gif"/> <file path="resources/media/deck4.jpg"/> <file path="resources/media/39.gif"/> <file path="resources/media/16.gif"/> <file path="resources/media/Enhydraw.jpg"/> <file path="resources/media/draw_b.gif"/> <file path="resources/media/47.gif"/> <file path="resources/media/24.gif"/> <file path="resources/media/close1.gif"/> <file path="resources/media/8.gif"/> <file path="resources/media/32.gif"/> <file path="resources/media/whatuser.gif"/> <file path="resources/media/drawca_n.gif"/> <file path="resources/media/40.gif"/> <file path="resources/media/logint_n.gif"/> <file path="resources/media/quit_b.gif"/> <file path="resources/media/1.gif"/> <file path="resources/media/28.gif"/> <file path="resources/media/help_n.gif"/> <file path="resources/media/deck1.jpg"/> <file path="resources/media/36.gif"/> <file path="resources/media/13.gif"/> <file path="resources/media/44.gif"/> </node>
Close JBuilder project withouth saving and reopen it.
From the menu Tools > Enhydra Tools > DODS start DODS Generator Wizard, and choose:
Config Directory: C: /Enhydra5.1/dods\build\conf
Output Directory: C:/enhydra5.1/examples/poker/dods_generated_src
Doml file: C:/enhydra5.1/examples/poker/poker.doml
Template set: standard
DB Vendor: Instant DB
Edit JBuilder project properties to set necessery JVM parameters in JBuilder shortcut properties (tag Run > Edit). Set VM parameters to:
-Denhydra.home=C:/enhydra5.1
Run poker