[icedtea-web] RFC: parse jnlps containing component-desc as well as application-desc elements
omajid at redhat.com
Thu Oct 28 14:04:12 PDT 2010
On 10/27/2010 03:14 PM, Omair Majid wrote:
> Some JNLPs such as space weasel  contain a "component-desc" element
> along with an "application-desc" element. Netx current fails trying to
> run such an application. The parser error says that having multiple
> *-desc elements is not supported. In the case of "component-desc" this
> does not make much sense. "application-desc", "applet-desc" and
> "installer-desc" describe what should be done with this jnlp file;
> "component-desc" carries no such meaning, so it should be ok to have a
> "component-desc" along with "application-desc" in the same JNLP file.
> The attached patch fixes this.
A very slightly updated patch attached. Instead of using recursion (and
always returning null - my mistake) in getComponent, return a new
ComponentDesc. As far as I know nothing in netx actually uses
ComponentDesc - applications that loaded components/extensions worked
before this patch, work with the patch I posted yesterday and work with
this latest patch.
> 2010-10-27 Omair Majid <omajid at redhat.com>
> * netx/net/sourceforge/jnlp/JNLPFile.java: Add component.
> (getLaunchInfo): Modify javadoc to indicate that it does not return
> the ComponentDesc.
> (getComponent): Return component instead of launchType.
> (isComponent): Check if component is not null.
> (parse): Find and set component.
> * netx/net/sourceforge/jnlp/Parser.java
> (getLauncher): Remove all checks for component-desc. Allow having
> none of application-desc, applet-desc and installer-desc.
> (getComponent): Check for more than one component-desc element.
> Read and parse the component-desc.
> Any thoughts or comments?
>  http://spaceweasel.googlecode.com/svn/wiki/weasel.jnlp
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 3644 bytes
Desc: not available
Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20101028/0d0f7839/icedtea-web-component-desc-02.patch
More information about the distro-pkg-dev