On 22 Apr 2003, <[EMAIL PROTECTED]> wrote:

>   +        if (o instanceof FileSet) {
>   +           return (AbstractFileSet)(new ZipFileSet((FileSet)o));

the cast is not needed here.

>   +        }
>   +        else if (!(o instanceof ZipFileSet)) {

will always be true as instanceof ZipFileSet implies instanceof
FileSet.

Maybe you really wanted something like

        if (o instanceof FileSet) {
            return (AbstractFileSet) o;
        } else if (o instanceof FileSet) {
           return (new ZipFileSet((FileSet) o));
        } else {
            String msg = getRefid().getRefId() + " doesn\'t denote a zipfileset 
or a fileset";
            throw new BuildException(msg);
        }

Stefan

Reply via email to