XClass.getInterface() does not return extended interfaces

[email protected] Fri, 07 Dec 2007 11:02:30 +0100
Newsgroups gmane.comp.java.xdoclet.devel
Message-ID <[email protected]>
Hi,

I've taken the latest code from CVS to get support for Java5 syntax support=
 (xjavadoc-1.5.jar).
What I have observed is a bug in the generated NodeParser that causes the m=
ethod =

XClass.getInterfaces() to return only implemented interfaces but not extend=
ed ones.
After the follwing change in xjavadoc\javacc\Java1.5x.jjt this seems to be =
fixed.

void ExtendsList(boolean isInterface):
{
   SourceClass sourceClass =3D currentClass();
   String name =3D null;
}
{
   "extends" name=3DClassOrInterfaceType() =

   {
     if (isInterface) sourceClass.addInterface(name); =

   }

   ( "," name=3DClassOrInterfaceType()  =

   {
     if (isInterface) =

       sourceClass.addInterface(name);
     else =

       throw new ParseException("A class cannot extend more than one other =
class");  =

   })*

   {
    //System.err.println("setSuperclass name=3D" + (name !=3D null ? name :=
 "java.lang.Object"));
    sourceClass.setSuperclass(name !=3D null ? name : "java.lang.Object");
   }
}


So, I'm not familar with javacc, maybe someone can re-check that modificati=
on.

Kind regards,

Andr=E9




"Jetzt Handykosten senken mit klarmobil - 14 Ct./Min.! Hier klicken"
http://produkte.shopping.freenet.de/handy_voip_isdn/klarmobil/indexhtml?pid=
=3D730025




-------------------------------------------------------------------------
SF.Net email is sponsored by:
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php