Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [aspectj-users] NoSuchMethodError

It appears that the user project default.ajsym file was also not correctly
getting updated with the aspect coming in from the library aspect jar.

To recreate:

Library project:
Deleted all of the /bin files and dirs

User project:
Deleted all of the /bin files and dirs

Recompiled library project
Recompiled user project

Changed aspect code did NOT show in the user project where the user code was
advised by the library aspect.

When I also deleted the default.ajsym files and then followed the steps
above, the changed aspect code correctly advised the user code.

Looks like a bug with the Eclipse AJDE.  I'll file it later today.

> -----Original Message-----
> From: aspectj-users-admin@xxxxxxxxxxx
> [mailto:aspectj-users-admin@xxxxxxxxxxx]On Behalf Of R. Dale Asberry
> Sent: Sunday, January 04, 2004 10:13 AM
> To: aspectj-users@xxxxxxxxxxx
> Subject: RE: [aspectj-users] NoSuchMethodError
>
>
> Found a fix to the problem.  I was accessing that code from
> another Eclipse
> project that needed the aspect applied to it also.  I then had the luxor
> project made into a jar and then used that jar as an input aspect
> jar to the
> second project.  I also had to remove everything from the bin directory to
> clean up the code references.  It seems that it was a simple
> misconfiguration problem.
>
> > -----Original Message-----
> > From: aspectj-users-admin@xxxxxxxxxxx
> > [mailto:aspectj-users-admin@xxxxxxxxxxx]On Behalf Of R. Dale Asberry
> > Sent: Sunday, January 04, 2004 8:32 AM
> > To: AspectJ Users
> > Subject: [aspectj-users] NoSuchMethodError
> >
> >
> > I have a file luxor.XulManager with the following method definition:
> >
> > public NComponent lookupComponent( String key )
> > {
> >   NComponentFactory def = (NComponentFactory)_defMap.lookupComponentDef(
> > key );
> >   return def.getNComponent();
> > }
> >
> > The file compiles fine.
> >
> > I have an aspect in the same project with the following advice:
> >
> > NComponent around(NComponentFactory pCompFactory):
> > createNComponent(pCompFactory)
> > {
> > 	XulManager lXulMgr = XulManager.getXulManager();
> > 	XulTag lTag = (XulTag)pCompFactory;
> > 	NComponent lComp = null;
> > 	if(!"anonymous".equals(lTag.getId()))
> > 	{
> > 		System.out.println(lTag.getId() + pCompFactory);
> > 		lComp = lXulMgr.lookupComponent(lTag.getId());
> > 		if(lComp == null)
> > 		{
> > 			lComp = proceed(pCompFactory);
> > 		}
> > 	}
> > 	else
> > 	{
> > 		lComp = proceed(pCompFactory);
> > 	}
> > 	pCompFactory.cPeer = lComp;
> > 	return lComp;
> > }
> >
> > (In essence, the two code snippets are caching the NComponent)
> >
> > When the JVM executes the line:
> > lComp = lXulMgr.lookupComponent(lTag.getId());
> >
> > I am getting -
> >
> > java.lang.NoSuchMethodError:
> >
> luxor.XulManager.lookupComponent(Ljava/lang/String;)Lluxor/spi/NComponent;
> >
> > on the advised NComponentFactory.
> >
> >
> > I'm baffled - any ideas?
> >
> > _______________________________________________
> > aspectj-users mailing list
> > aspectj-users@xxxxxxxxxxx
> > http://dev.eclipse.org/mailman/listinfo/aspectj-users
> >
>
> _______________________________________________
> aspectj-users mailing list
> aspectj-users@xxxxxxxxxxx
> http://dev.eclipse.org/mailman/listinfo/aspectj-users
>



Back to the top