[rfc][icedtea-web] manifests attributes Validation Moved To Separate Class

Omair Majid omajid at redhat.com
Fri Mar 21 14:51:43 UTC 2014


* Jiri Vanek <jvanek at redhat.com> [2014-03-20 11:01]:
> +++ b/netx/net/sourceforge/jnlp/runtime/ManifestsAttributesValidator.java	Thu Mar 20 16:04:20 2014 +0100

> +public class ManifestsAttributesValidator {

Can you please add a unit test for this class? It's nice to 'document'
the behaviour using a test.

> +     public static URL guessCodeBase(JNLPFile file) {
> +        if (file.getCodeBase() != null) {
> +            return file.getCodeBase();
> +        } else {
> +            //Fixme: codebase should be the codebase of the Main Jar not
> +            //the location. Although, it still works in the current state.
> +            return file.getResources().getMainJAR().getLocation();
> +        }

I am not sure if UrlUtils is the right place to move this method. It has
very little to do with manipulating URLs (which is what the rest of the
methods in this class do).

Thanks,
Omair

-- 
PGP Key: 66484681 (http://pgp.mit.edu/)
Fingerprint = F072 555B 0A17 3957 4E95  0056 F286 F14F 6648 4681


More information about the distro-pkg-dev mailing list