Lotus BeanMachine Reference Guide

The Ins and Outs of Publishing


Where to Publish
OK, you've been working hard building a really cool applet. You've tested it on your own machine and now it is time to get it out on a web server so all your friends can see it. You might be LAN connected to a server. Or, maybe the server is your own computer. Or perhaps you're using a web server maintained by an internet connection service provider. You might even want to publish to a Marimba Castanet Transmitter on a server. In any case, how do you get your applet and all the necessary files on the server so your applet can be viewed and accessed by other people?
Simple, using BeanMachine's Publish Wizard, you can publish almost anywhere. The Local tab lets you publish to specific folder on your local file system. It could be your local C drive or perhaps a LAN drive that you are connected to.



There will be times, however, when you need to publish to a remote system like an web server or you may want to publish to a Castanet Transmitter. To publish to a remote site, fill in the appropriate information on the remote page. If you choose to publish to a Castanet Transmitter fill in the appropriate information on the Castanet page. Lastly, click Finish to kick off the actual publishing step.
Keep in mind, you need to provide all the appropriate information on each page of the Publish Wizard. BeanMachine will alert you if you have not filled in all the required fields for the publish option you choose. If you change your mind about publishing in a specific manner, simply click "No, thank you" on the publish tab of the option you are changing.
Note: when you publish locally and choose "Publish NetObjects Fusion Component", you will also see a nfx.gif
and applet nameComp.nfx
file in your publish folder. These files are used by NetObjects FusionTM.

Optimizing for Performance
As your applets become more complex, they become larger and, because class files are downloaded one at a time in uncompressed form, overall download time over the web increases. BeanMachine helps you shorten overall download time by utilizing JAR files. When you publish your applet, BeanMachine identifies and locates the necessary .class and media files used in your applet and packs them into one compressed JAR (.jar) file. BeanMachine then creates a subdirectory below the location you specified and places the JAR and an HTML file within it. You can view the contents of the JAR file at anytime by unzipping it. This directory structure must be preserved on the web server for everything to work as expected. For a more detailed discussion of JavaBeans and JAR files, see Customizing the Palette.
Here is a sample of the HTML applet tag that BeanMachine generates for you:
<applet code="ThreeLostSouls.class" width=400 height=400
archive="ThreeLostSouls.jar">
</applet>
The archive is needed to tell your browser to look for a JAR file. No special parameter is needed for media files.
