Changes for page Java Client and Direct To Java Client Example Project using WebStart
Last modified by David Avendasora on 2008/07/01 16:52
From version 24.1
edited by David Avendasora
on 2008/06/25 10:06
on 2008/06/25 10:06
Change comment:
There is no comment for this version
To version 34.1
edited by David Avendasora
on 2008/06/25 10:18
on 2008/06/25 10:18
Change comment:
There is no comment for this version
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -1,3 +1,5 @@ 1 +This tutorial will help you get a new Java Client or Direct To Java Client Application setup in Eclipse/WOLips and get it building properly. 2 + 1 1 1. Create a new WebObjects Application 2 2 [[image:Picture 9.png]] 3 3 1. Name it "WebStartJNLPTest" in Eclipse with a package of "your.app" {{note title="Note!"}}If you change the Project name or packages, then you'll need to make additional changes in the subsequent steps.{{/note}} ... ... @@ -101,70 +101,9 @@ 101 101 102 102 {{/code}} 103 103 104 - 1. Create a javaclientbuild.xmlfile in rootofthe projectandpastethe follwingascontents:106 +This file is only required by the application when it is being launched from within Eclipse. 105 105 106 -{{code title="javaclientbuild.xml"}} 107 - 108 -<project name="javaclient" default="javaclient" basedir="."> 109 - <target name="setProps"> 110 - <property file="${user.home}${file.separator}build.properties"/> 111 - <property file="build.properties"/> 112 - <property file="${user.home}${file.separator}Library${file.separator}wobuild.properties"/> 113 - <condition property="wo.properties.check.failed"> 114 - <not> 115 - <and> 116 - <isset property="wo.wosystemroot"/> 117 - <isset property="wo.wolocalroot"/> 118 - </and> 119 - </not> 120 - </condition> 121 - <fail message="Could not find ${user.home}${file.separator}Library${file.separator}wobuild.properties." if="wo.properties.check.failed"/> 122 - </target> 123 - <target name="javaclient" depends="setProps"> 124 - <mkdir dir="build/${project.name}.woa/Contents/WebServerResources/Java"/> 125 - 126 - <!-- project client-side classes --> 127 - <copy todir="build/${project.name}.woa/Contents/WebServerResources/Java/"> 128 - <fileset dir="${classes.dir}"> 129 - <include name="**/client/**/*.class,**/common/**/*.class,**/BMGenericRecord.class"/> 130 - <exclude name="**/server/**/*.class"/> 131 - </fileset> 132 - </copy> 133 - 134 - <jar basedir="${classes.dir}" 135 - includes="**/client/**/*.class,**/common/**/*.class,**/BMGenericRecord.class" 136 - excludes="**/server/**/*.class" 137 - jarfile="build/${project.name}.woa/Contents/WebServerResources/Java/${project.name}.jar"> 138 - </jar> 139 - 140 - <!-- Launch Scripts and WOBootstrap.jar--> 141 - <mkdir dir="build/${project.name}.woa/Contents/MacOS"/> 142 - <mkdir dir="build/${project.name}.woa/Contents/UNIX"/> 143 - <mkdir dir="build/${project.name}.woa/Contents/Windows"/> 144 - 145 - <copy file="/Library/Application Support/Apple/Developer Tools/WebObjects Support/UnixLaunch.sh" 146 - tofile="build/${project.name}.woa/Contents/${project.name}"/> 147 - <chmod file="build/${project.name}.woa/Contents/${project.name}" perm="ugo+rx"/> 148 - <copy file="/Library/Application Support/Apple/Developer Tools/WebObjects Support/WinLaunch.CMD" 149 - tofile="build/${project.name}.woa/Contents/${project.name}.CMD"/> 150 - <copy file="/Library/Application Support/Apple/Developer Tools/WebObjects Support/WOBootstrap.jar" 151 - tofile="build/${project.name}.woa/Contents/WOBootstrap.jar"/> 152 - 153 - <copy file="/Library/Application Support/Apple/Developer Tools/WebObjects Support/UnixLaunchClient.sh" 154 - tofile="build/${project.name}.woa/Contents/MacOS/${project.name}_Client"/> 155 - <chmod file="build/${project.name}.woa/Contents/MacOS/${project.name}_Client" perm="ugo+rx"/> 156 - <copy file="ClasspathClient.txt" tofile="build/${project.name}.woa/Contents/MacOS/ClasspathClient.txt"/> 157 - 158 - <copy file="/Library/Application Support/Apple/Developer Tools/WebObjects Support/WinLaunch.CMD" 159 - tofile="build/${project.name}.woa/Contents/Windows/${project.name}.CMD"/> 160 - 161 - </target> 162 -</project> 163 - 164 -{{/code}} 165 - 166 -This file is needed to make up for the lack of Java Client application building by the WOLips Incremental Builder. Please follow the [[instructions>>Java Client-WebStart Incremental Build]] for how to create the Java Client Incremental Builder. 167 - 108 +1. Create a Java Client Incremental Builder by following the [[instructions>>Java Client-WebStart Incremental Build]]. This file is needed to make up for the lack of Java Client application building by the WOLips Incremental Builder. It also copies the client launch scripts into the project so that the application will auto-launch when you run it from within Eclipse. 168 168 1. If you did not setup the Java Client Incremental Builder, then right-click on the javaclientbuild.xml file and select "Run As -> Ant Build" 169 169 [[image:Picture 12.png]] 170 170 1. Right-click on the project and select "Run As -> WebObjects Application" ... ... @@ -171,6 +171,7 @@ 171 171 [[image:Picture 13.png]] 172 172 1. Select your.app.Application as the Application class 173 173 [[image:Picture 14.png]] 115 +1. If you want to actually deploy this application, then you will also need to [[modify the build.xml file>>Java Client-Building]]. 174 174 This is it. WebStart should automatically download your client application and launch it. If you are creating a D2JC application and did not put an EOModel file in the Resources directory of your project, then you'll see something like this: 175 175 [[image:Picture 15.png]] 176 176 If you don't want a D2JC application, then you are on your own for creating the user interface for it. Your client-side application can be a command-line or GUI application. If you want a Swing GUI, then I **highly** recommend Florijan Stamenkovic's [[JBND Framework>>http://web.mac.com/flor385/JBND/]]