Java Forum / General / December 2005
BrowserLauncher - JWS example
Andrew Thompson - 08 Dec 2005 16:08 GMT I have made a JWS'd implemenation of BrowserLauncher (BL). <http://www.physci.org/browserlauncher/>.
There are a couple of reasons I made this JWS'd version..
- It is a convenient way to use BL for the PhySci applications. - As an easily viewable example for those who are considering the use of BL in their own application/s. - As an easy way to test BL itself*.
Trawling for information/comments on.. a) * Does this implementation work for you? b) Suggestion for additions/corrections to the web page? c) Is there any point to it? Given how the JWS API offers, <http://java.sun.com/j2se/1.4.2/docs/guide/jws/jnlp/javax/jnlp/BasicService.html# showDocument(java.net.URL)> (the jnlp.jar is distributed with 1.5+ JRE's) ( ..has anyone successfully used that? )
 Signature Andrew Thompson physci, javasaver, 1point1c, lensescapes - athompson.info/andrew
Steve W. Jackson - 08 Dec 2005 18:47 GMT > I have made a JWS'd implemenation of BrowserLauncher (BL). > <http://www.physci.org/browserlauncher/>. [quoted text clipped - 14 lines] > (the jnlp.jar is distributed with 1.5+ JRE's) > ( ..has anyone successfully used that? ) This failed miserably for me. The reason is that the BrowserLauncher code in use is woefully out of date. It makes widespread use of the com.apple.mrj package hierarchy, which is no longer in Apple's Java implementation after 1.3.1. Apple's available Java documentation is at <http://developer.apple.com/referencelibrary/API_Fundamentals/Java-api-da te.html>.
Apple also has a Tech Note on identifying Java for Mac OS X. It addresses the outmoded use of mrj.version. Essentially, though, every version of Mac OS X ever shipped has at least Java 1.3.1, while older systems with "MRJ" stopped their support at about 1.1.8.
= Steve =
 Signature Steve W. Jackson Montgomery, Alabama
Andrew Thompson - 09 Dec 2005 10:09 GMT >>I have made a JWS'd implemenation of BrowserLauncher (BL). >><http://www.physci.org/browserlauncher/>. ..
> This failed miserably for me. Thanks Steve! Good to know I can rely on you (as ever) for.. a) Mac testing/tips (at least 95% of all testing/tips on the Mac that I have ever heard, came from you) b) Not beating about the bush.
>...The reason is that the BrowserLauncher > code in use is woefully out of date. ...
> Apple also has a Tech Note on identifying Java for Mac OS X. Tah. I'll chase that up and report back, if I can produce a good V. 2 for testing.
This thread is essentially 'on hold' till then..
 Signature Andrew Thompson physci, javasaver, 1point1c, lensescapes - athompson.info/andrew
Mickey Segal - 09 Dec 2005 13:42 GMT >I have made a JWS'd implemenation of BrowserLauncher (BL). > <http://www.physci.org/browserlauncher/>. You refer to http://browserlauncher.sourceforge.net/ but there seems to be a newer version http://browserlaunch2.sourceforge.net/.
Andrew Thompson - 09 Dec 2005 15:10 GMT >>I have made a JWS'd implemenation of BrowserLauncher (BL). >><http://www.physci.org/browserlauncher/>. > > You refer to http://browserlauncher.sourceforge.net/ but there seems to be a > newer version http://browserlaunch2.sourceforge.net/. Thanks. Here is my JWS'd version of the test app. that comes with BL2. <http://www.physci.org/browserlauncher/browserlauncher2.jnlp> (The JNLP descriptor claims I 'built' the jar, but all I did was sign the jar from the BL2 homepage).
Does that work OK on the Mac., Steve? (It works just fine here, but then, so did the first..)
 Signature Andrew Thompson physci, javasaver, 1point1c, lensescapes - athompson.info/andrew
Steve W. Jackson - 09 Dec 2005 15:59 GMT > >>I have made a JWS'd implemenation of BrowserLauncher (BL). > >><http://www.physci.org/browserlauncher/>. [quoted text clipped - 10 lines] > Does that work OK on the Mac., Steve? > (It works just fine here, but then, so did the first..) Worked for me. Here's what was in the window when it appeared:
Please let us know the results of testing on your OS/Java configuration. The information displayed below as well as any stack traces will be helpful. Use the copy button to copy and paste the data into an email.
Java Version: 1.4.2_09 Java Vendor: Apple Computer, Inc. OS Name: Mac OS X OS Version: 10.4.3 2005-12-09 09:55:58,375 [javawsApplicationMain] INFO Mac OS
2005-12-09 09:55:58,377 [javawsApplicationMain] INFO version=232.0
2005-12-09 09:56:19,755 [AWT-EventQueue-0] INFO browse button clicked
2005-12-09 09:56:19,761 [AWT-EventQueue-0] DEBUG Default
2005-12-09 09:56:58,093 [AWT-EventQueue-0] INFO copy button clicked
As you can see, I used the Copy button to put the window contents into the clipboard for pasting here. While I've installed Apple's Java 1.5, release, I haven't taken any action to have my browser(s) use it. When I entered a URL, it caused Firefox to open that URL in a new tab (per my preference settings).
= Steve =
 Signature Steve W. Jackson Montgomery, Alabama
Andrew Thompson - 10 Dec 2005 00:32 GMT >>>>I have made a JWS'd implemenation of BrowserLauncher (BL). ...
>>>...there seems to be a >>>newer version http://browserlaunch2.sourceforge.net/. >> >>Thanks. Here is my JWS'd version of the test app. that comes with BL2. >><http://www.physci.org/browserlauncher/browserlauncher2.jnlp> ..
>>Does that work OK on the Mac., Steve? ...
> Worked for me. Thanks.
OK. We are back on track.
Any Linux test systems out there for some results?
 Signature Andrew Thompson physci, javasaver, 1point1c, lensescapes - athompson.info/andrew
Steve W. Jackson - 12 Dec 2005 17:37 GMT > >>>>I have made a JWS'd implemenation of BrowserLauncher (BL). > ... [quoted text clipped - 13 lines] > > Any Linux test systems out there for some results? I connected to my Linux Mandrake 9 system at the office and tried this out. I have Sun's Java 1.4.2_02 installed there and use KDE via my VPN connection. I launched Mozilla (which I only picked because it's on the KDE menus under "Launch Application") and went to the jnlp link above. I had to tell it what to do with a jnlp file, since that wasn't set. When I did so, it opened for me as it had previously done here on my Mac. When I gave it a URL, it launched it in Konqueror, which is currently set as the default browser in my KDE environment there. This is the system where we test our application's Linux version, and it worked as it should.
= Steve =
 Signature Steve W. Jackson Montgomery, Alabama
Andrew Thompson - 18 Dec 2005 00:24 GMT (BrowserLauncher Test)
>>Any Linux test systems out there for some results? > > I connected to my Linux Mandrake 9 system at the office and tried this > out. .. it > worked as it should. Thanks again Steve.
I would like some test results for more (flavors of) Linux systems, and some pre XP Windows boxes, but at least we have observed it to work on at least one PC each runing Mac/*nix/XP.
That address again, is.. <http://www.physci.org/browserlauncher/browserlauncher2.jnlp>
Further test results welcome.
 Signature Andrew Thompson physci, javasaver, 1point1c, lensescapes - athompson.info/andrew
IchBin - 18 Dec 2005 01:45 GMT > Further test results welcome.
Did not want to wast time looking up your email address, so..
My default browser is Opera 8.5.1 Other browsers I use are..
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20051003 Firefox/1.6a1, aka Deer Park Alpha 2 Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20051216 SeaMonkey/1.5a The nightly updated version IE 6.0 SP 2
It had problem finding either of the Mozilla's. IE and Opera, as the default, displayed ok.
Java Version: 1.5.0_06 Java Vendor: Sun Microsystems Inc. OS Name: Windows XP OS Version: 5.1 2005-12-17 20:20:38,422 [javawsApplicationMain] INFO Windows OS 2005-12-17 20:20:38,452 [javawsApplicationMain] INFO WindowsNT launcher 2005-12-17 20:21:06,623 [AWT-EventQueue-0] INFO browse button clicked 2005-12-17 20:21:06,623 [AWT-EventQueue-0] DEBUG Default 2005-12-17 20:21:06,643 [Thread-7] INFO default or null browser target 2005-12-17 20:21:06,653 [Thread-7] INFO HTTP://localhost/JHackerAppManager 2005-12-17 20:21:06,653 [Thread-7] INFO http 2005-12-17 20:21:06,653 [Thread-7] DEBUG [cmd.exe, /c, start, "", "HTTP://localhost/JHackerAppManager"] 2005-12-17 20:21:53,651 [AWT-EventQueue-0] INFO browse button clicked 2005-12-17 20:21:53,651 [AWT-EventQueue-0] DEBUG firefox 2005-12-17 20:21:53,671 [Thread-8] INFO HTTP://localhost/JHackerAppManager 2005-12-17 20:21:53,681 [Thread-8] INFO http 2005-12-17 20:21:53,691 [Thread-8] DEBUG [cmd.exe, /c, start, firefox, "HTTP://localhost/JHackerAppManager"] 2005-12-17 20:21:58,107 [Thread-8] DEBUG falling through to non-targetted openUrl 2005-12-17 20:21:58,117 [Thread-8] INFO HTTP://localhost/JHackerAppManager 2005-12-17 20:21:58,117 [Thread-8] INFO http 2005-12-17 20:21:58,147 [Thread-8] DEBUG [cmd.exe, /c, start, "", "HTTP://localhost/JHackerAppManager"] 2005-12-17 20:22:26,167 [AWT-EventQueue-0] INFO browse button clicked 2005-12-17 20:22:26,167 [AWT-EventQueue-0] DEBUG iexplore 2005-12-17 20:22:26,177 [Thread-9] INFO HTTP://localhost/JHackerAppManager 2005-12-17 20:22:26,187 [Thread-9] INFO http 2005-12-17 20:22:26,187 [Thread-9] DEBUG [cmd.exe, /c, start, iexplore, "HTTP://localhost/JHackerAppManager"] 2005-12-17 20:22:55,990 [AWT-EventQueue-0] INFO browse button clicked 2005-12-17 20:22:56,000 [AWT-EventQueue-0] DEBUG mozilla 2005-12-17 20:22:56,010 [Thread-10] INFO HTTP://localhost/JHackerAppManager 2005-12-17 20:22:56,010 [Thread-10] INFO http 2005-12-17 20:22:56,010 [Thread-10] DEBUG [cmd.exe, /c, start, mozilla, "HTTP://localhost/JHackerAppManager"] 2005-12-17 20:22:57,573 [Thread-10] DEBUG falling through to non-targetted openUrl 2005-12-17 20:22:57,573 [Thread-10] INFO HTTP://localhost/JHackerAppManager 2005-12-17 20:22:57,583 [Thread-10] INFO http 2005-12-17 20:22:57,583 [Thread-10] DEBUG [cmd.exe, /c, start, "", "HTTP://localhost/JHackerAppManager"] 2005-12-17 20:23:05,834 [AWT-EventQueue-0] INFO copy button clicked
Thanks in Advance... IchBin, Pocono Lake, Pa, USA http://weconsultants.servebeer.com/JHackerAppManager __________________________________________________________________________
'If there is one, Knowledge is the "Fountain of Youth"' -William E. Taylor, Regular Guy (1952-)
Andrew Thompson - 18 Dec 2005 02:25 GMT > > Further test results welcome. > > Did not want to wast time looking up your email address, so.. The 'email' message is from the authors of BrowserLauncher itself, in this test I am using the default test app. that they provide with the latest version. I would prefer the information back to the forum.
> My default browser is Opera 8.5.1 Other browsers I use are.. ..
> It had problem finding either of the Mozilla's. IE and Opera, as the > default, displayed ok. Thank you. Since it found 'a browser', I'll take that as another success.
 Signature Andrew Thompson physci, javasaver, 1point1c, lensescapes - athompson.info/andrew
Free MagazinesGet these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...
|
|
|