Webclient
This document describes the Java API for WebShell, also known as the java webclient.
You can download the latest webclient by clicking here.
- NEW 20070923: Webclient Roadmap
- Screencasts have been recorded and made available for public viewing.
- The beginnings of a webclient FAQ are available.
- Overview
- Screencasts
- Blogs and Articles
- History
- Requirements
- Getting and Building the Code
- Webclient Developers Guide
- Webclient Implementation Guide
- Using the webclient
- Requirements Specification
- Requirements Analysis
- Design
- How to Contribute
- The latest status is tracked on this thread on n.p.m.java
- References
Overview
Mission Statement:
The webclient project aims to provide the premier browser-neutral Java API that enables generic web browsing capability. This capability includes, but is not limited to: web content rendering, navigation, a history mechanism, and progress notification. The actual capabilities implemented depend on the underlying browser implementation. |
Screencasts
Some screencasts have been recorded with Elluminate. They require a Java WebStart enabled browser. It is recommended you press the pause button in the Elluminate window once the screencast starts playing and allow at least half of the content to load before pressing play. This can solve the choppy playback problem, and prevent the speaker's voice being played back too fast.
Getting started: From downloading the bits to running your first MCP test. Elluminate Session (33 minutes)
Advanced: using Maven 2 to launch Glassfish and run an MCP test on an AJax application
Part 1: What to put in the POM. Dependencies. Executing the test using Maven 2. Elluminate Session (18 minutes)
Part 2: Understanding the test. Debugging the test. Elluminate Session (26 minutes)
Blogs and Articles
Pre mozilla.org history
- This project was started by Kirk Baker <kbaker@eb.com>
and Ian Wilkinson <iw@ennoble.com>
and was originally called RaptorCanvas.
In the first quarter of 1999, the AOL/Netscape/Sun deal closed and a group
at Sun started the blackwood project, to
better integrate Java and Mozilla. One of the subprojects in blackwood
was to provide a Java API to the mozilla webshell, which Kirk and Ian had
already done. Thus, Sun
has joined forces with Kirk and Ian to produce webclient.
Requirements
-
The requirements that need to be met to build and use webclient vary depending on what webclient milestone you want to use. Please visit the release notes page at http://www.mozilla.org/projects/blackwood/webclient/release-notes/ for more information.
Getting and Building the Code
Getting the Code
You can either build the latest webclient, or build a milestone release. For milestone releases, please see http://www.mozilla.org/projects/blackwood/webclient/release-notes/ for more information.
Building the Code
-
To build webclient, follow the instructions in the release notes, at http://www.mozilla.org/projects/blackwood/webclient/release-notes/m3-detail.html#read_this.
Webclient Developers Guide
- The Developers Guide is intended for programmers who will use the
Webclient API to integrate the Mozilla browser into their Java applications.
Webclient Implementation Guide
- The Implementation Guide is intended for members of the the open source
community who wish to contribute to the enhancement of the
Webclient API under the Mozilla.org Open Source Public License.
Using the webclient
- There is an example browser in the java-webclient distribution that
illustrates how to use the basic webclient features. This class is included
by reference here [1] for your convenience.
You may also want to visit the web presentation, given at Codestock, about webclient. http://www.mozilla.org/projects/blackwood/webclient/codestock/index.htm
Basically, you create yourself a BrowserControlCanvas, which is a subclass of java.awt.Canvas, and add it into your display hierarchy.
// Create the browser BrowserControlCanvas browser = BrowserControlCanvasFactory.newBrowserControlCanvas(); add(browser, BorderLayout.CENTER);
- Then you can control the embedded mozilla via the BrowserControl
interface.
public void actionPerformed (ActionEvent evt) { String command = evt.getActionCommand(); try { if (command.equals("Back")) { if (browserControl.canBack()) { browserControl.back(); int index = browserControl.getHistoryIndex(); String newURL = browserControl.getURL(index); System.out.println(newURL); urlField.setText(newURL); } } else if (command.equals("Forward")) { if (browserControl.canForward()) { browserControl.forward(); int index = browserControl.getHistoryIndex(); String newURL = browserControl.getURL(index); System.out.println(newURL); urlField.setText(newURL); } } else if (command.equals("Stop")) { browserControl.stop(); } else { browserControl.loadURL(urlField.getText()); } } catch (Exception e) { System.out.println(e.toString()); } } // actionPerformed()API documentation is available here, [2].
Requirements Specification
- The webclient requirements specification is available at http://www.mozilla.org/projects/blackwood/webclient/RequirementsSpec.html
We welcome feedback on the requirements specification. Post all feedback
to the newsgroup netscape.public.mozilla.java. Use the subject:
webclient spec.
Requirements Analysis
- For webclient, Requirements Analysis, will be the process of takeing
the Requirements Spec, and seeing what can realistically be built with
today's browser API technology. The webclient requirements analysis document
is available at http://www.mozilla.org/projects/blackwood/webclient/RequirementsAnalysis.html
Design
This section contains pointers to design documents. Currently, design documents exist for the mozilla based webclient implementation. They are accessible at http://www.mozilla.org/projects/blackwood/webclient/design/spec-compliant-design.html
How to Contribute
There are several ways in which one can contribute to webclient. You can work on the mozilla implementation, in which case you'll need to know the ins and outs of being a mozilla contributor. You might want to read this document about contributing to mozilla, http://www.doczilla.com/development/extmoz.html.
I'm focusing on the mozilla implementation, so if you want to help, please peruse the issues page, or the pending grep page.
You could also work on wrapping webclient around another browser implementation, this is valuable work. Currently, we have efforts either in place or starting up for wrapping IE, and fizzilla.
If any of these contribution options sound attractive, please contact me at the address below.
Current Status
- 31 August 2007
Release candidate 3 makes it so the standard java proxy properties are passed down to the mozilla prefs, making it possible to use webclient inside a firewall to access the open Internet.
- 28 August 2007
Release candidate 2 just fixes the non-ide build file to work, so you can still try webclient even if you don't have netbeans.
- 29 Juni 2007
I had the fortune to present MCP at the first ever Jazoon Conference in Zürich, Switzerland. I am happy to report that I now have Mac OS X support working. Thanks to timeless, cbarrett, bsmedberg, sdwilsh, and the whole gang at #developers on irc.mozilla.org for making this mac support possible. Please see the release notes at http://www.mozilla.org/projects/blackwood/webclient/release-notes/#2_0_alpha_9
- 4 May 2007
This release adds a timeout facility which is useful for catching regressions in Ajax applications. Please see the release notes at http://www.mozilla.org/projects/blackwood/webclient/release-notes/#2_0_alpha_8
- 27 April 2007
This release adds a new automated test that shows the usage of MCP to test an application that uses two different Ajax technologies together. Project Dynamic Faces and Project jMaki. Please see the release notes at http://www.mozilla.org/projects/blackwood/webclient/release-notes/#2_0_alpha_7
- 14 March 2007
This release adds a facility to use webclient as a means to enable automated testing of Ajax applications. Please see the release notes at http://www.mozilla.org/projects/blackwood/webclient/release-notes/#2_0_alpha_6
- 23 February 2007
After languishing in near obscurity for over two years, I finally have a win32 binary of webclient ready that I have qualified with the xulrunner nightly binary from 20061206. Please see the release notes at http://www.mozilla.org/projects/blackwood/webclient/release-notes/#2_0_alpha_5
- 19 January 2005
New release with bug fixes and new features. Please see the release notes at http://www.mozilla.org/projects/blackwood/webclient/release-notes/.
- 19 October 2004
Thanks again to Annie Lau for discovering that the use of the zip installer instead of the .exe installer fixes all the problems. I have rolled back the installation to 2.0 alpha. Please see the release notes at http://www.mozilla.org/projects/blackwood/webclient/release-notes/.
- 18 October 2004
Thanks to Annie Lau in Australia for pointing out that the binary dist wouldn't run. This lead me to investigate the problem. My results are posted on netscape.public.mozilla.java. I have produced a new binary and removed the old one. Please see the release notes at http://www.mozilla.org/projects/blackwood/webclient/release-notes/.
- 9 October 2004
I finally have a binary distribution for win32. This one works with mozilla 1.7 and includes the "header sniffer" feature I've been wanting to implement for years. Please see the release notes at http://www.mozilla.org/projects/blackwood/webclient/release-notes/.
- 3 August 2004
I've put together a source code only release and I'm calling it webclient 2.0 alpha 1. Please see the release notes at http://www.mozilla.org/projects/blackwood/webclient/release-notes/
This website needs a major overhaul, but getting 2.0 completed is of higher priority.
- 20030929
Here's the development plan. I'm doing all of this on GNU/Linux RedHat 7.2 first. Later, I'll get around to Windows.
Complete test-first work on Bookmarks
Write unit test and core code that proves BrowserControlCanvas, can be added to a parent window, shown, hidden, resized, etc.
Write unit test and core code that proves BrowserControlCanvas can be added to a parent window, and a sequence of web pages can be navigated.
Remove the rest of the nasty "stub" code in mozilla/java/webclient/src_moz/gtk. I've found this is no longer necessary with JDK 1.3.
tag the workspace.
Update documentation and build instructions so I can start taking contributions from the community.
As I have very limited time to contribute to this, I'll try to get to the last step as soon as possible. It's just not worth it to try to explain the way things are now so people can contribute. I have to clean it up considerably before I can ask anyone to help.
- 20030928
I've made my first major checkin for webclient 2.0. Big things are in store. I'm refactoring the entire project and cleaning lots of things up. I'm using test first development practices to produce junit tests for each webclient interface as I go. Currently I have the Preferences, ProfileManager, and Bookmarks interfaces working. Please see my checkin message on bonsai.
- 2 January 2003
I finally have binaries available for Webclient 1.3 for Win32 and RedHat GNU/Linux 7.2. See release-notes. I've tagged the mozilla/java directory with WEBCLIENT_20030102. Webclient 1.3 works with Mozilla 1.0.1 or Netscape 7.
- 30 August 2002
I've built an XPI bundle for Webclient 1.2 for GNU/Linux. You can get it at the release notes page. I'm now going to undertake a major rewrite of the mozilla support in webclient based on the best practices documented in the embedding documentation. This might take a while, but it needs to be done.
I've tagged the Blackwood module with the cvs tag
WEBCLIENT_20020830
. This module goes along withMOZILLA_0_9_9_BRANCH
.- 1 June 2002
I have applied Michal Ceresna and John Marmion's patch to the webclient trunk to enable it to build with the MOZILLA_0_9_9_BRANCH on linux. Can someone please verify that it builds "out of the box" on linux? Instructions are at http://www.mozilla.org/projects/blackwood/webclient/release-notes/1_1-detail.html#UNIX_INSTALL
- 18 May 2002
I have created an XPI bundle for Webclient 1.2 on Win32. There is no source bundle yet due to bug 143115. Please visit the release notes for more information.
- 7 May 2002
I now have webclient mostly working on win32. The following features have been tested and work well.
File->New Window
File->Close
View->View Page Source as String
Search->Find
Search->Find Next
Edit->Select All
Edit->Copy
History->Back
History->Forward
History-> <Navigation Number>
Bookmarks->Manage Bookmarks
The bookmarks window pops up and you can double click on bookmarks to cause webclient to go to that page.
Stream->Load Stream From File...
Stream->Load Random HTML InputStream
Mouse over events work
The DOMViewer works
Navigation buttons work.
This leaves Bookmarks->Add Current Page, Bookmarks->Add Current Page in New Folder, Profile->Create Profile, and Profile->Delete Profile. The first two should be easy, the second two, I'll probably just take out, since their implementation was based in BlackConnect, which is currently quite dead.
When I'm happy with the state of Webclient on win32, I'll get it working on linux.
- 7 April 2002
I've abandoned plans to get webclient working with Netscape 6.2.1 in favor of going with mozilla 0.99. Here are the short term plans:
Remove dependency on blackconnect
Get everything working with 0.99 on win32, then linux.
Conduct analysis on the way webclient uses embedding with respect to the lastet notion of the "right way" to use embedding.
Work on bugs.
Do a 1.1 release for use with mozilla 0.99.
- 12 January 2002
From: edburns@acm.org (Ed Burns) Newsgroups: netscape.public.mozilla.java,netscape.public.mozilla.embedding Subject: Webclient plans: Netscape 6.2.1 compliant release Message-ID: <133edd06.0201121048.5f6ea51a@posting.google.com> Hi Folks, People continue to express interest in webclient, so I'm going to try to maintain it in my spare time. Sorry for the long delay in updating, I have taken a new job and am just now getting time to work on Webclient again. Here are my immediate plans: - Get webclient and its dependents working on Win32 and Linux with Netscape 6.2.1 (or the closest mozilla milestone) - Investigate open bugs in blackconnect (the XPCOM to Java thing). If they look to hard to fix, consider de-coupling webclient from blackconnect. - Investigate general open bugs. I'll only be able to spend about three hours a week on this so progress will be slow, but there will be progress. Of course, I welcome any help from the community. Thanks, Ed- 21 March 2001
- It's time to call it official. The webclient 1.0 release notes are here.
- 6 March 2001
- This isn't the official release, but I want people to start testing the XPI bundles on win32 and linux. Please visit the pre-release release-notes for the Webclient 1.0 release. These release notes are strictly advisory, and there are errors. The only part I updated was the binary install part, and there may be omissions. Please let me know if you find errors.
- 9 January 2001
- Long overdue status update. The only excuse I can offer is being pulled away to work on getting Netscape 6 out the door with functional Java. Here is a brief summary of work that has been done since the last milestone. For the exhaustive summary of all substantial code changes since 5 June 2000 see the notes page section for this entry.
- Added Preferences API
- Enabled the adding of bookmarks and bookmark folders
- Pop up warn dialog if prefs say to warn about cookies and the browser gets a cookie.
- Added basic authentication support
- History improvements
- Kept up to date with mozilla tree changes
- Added Linux support
- Custom APP UI improvements
We will release webclient 1.0 in source and binary formats for use with Netscape 6.0 on Windows, Solaris and Linux on 5 March 2001. Sorry for the delay, we're having problems with the XPI packaging. We are currently working on showstopper bugs for this release. Please see the issues page for the bugs we're working on.
- 26 June 2000
- Webclient Milestone 3 available. Known to work on Win32 and Solaris with JDK1.2.2 and mozilla M13.
- April-May 2000
- Constrained resources forced limited work on webclient to be done. During this time, webclient was made do run inside StarOffice however.
- 08 March 2000
- Source code for the spec compliant implementation checked in. Works on Win32 and Solaris with mozilla Milestone 13.
- 06 March 2000
- Webclient milestone 2 released. Source available here, win32 binary available here, and solaris binaries available here
- 25 February 2000
- Mozilla based webclient spec implementation documents checked in here.
- 24 February 2000
- webclient working on Win32 and Solaris. Milestone 2 nearing release.
- 7 January 2000
- Trying to get webclient working on Win32 and Solaris at the same time.
Added a notes page, accessible here. I'll try to update this page as soon as I have news about webclient.
- 29 October 1999
- Completed Requirements Analysis.
- 15 October 1999
- Working on Requirements Analysis.
- 23 September 1999
- Working on, and gathering feedback on Requirements Specification.
References
Ed Burns - Webclient Technical Lead. Ashu Kulkarni
Last
modified: Wed 08 March 12:29:11 Pacific Standard Time 2000