Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[aspectj-users] NoAspectBoundException

I'm getting a NoAspectBoundException thrown from the static getInstance()
method in a singleton class(belonging to the data.dir package), using the
following tracing aspect (in the same package):
public aspect TraceEnterLeave
{
	pointcut method():  within(data.dir.*) && execution(* *(..));
						
	pointcut constructor():  within(data.dir.*) && execution(new(..));
	

	before(): method() || constructor()
	{
		Logger logger = (Logger)
Logger.getLogger(thisJoinPointStaticPart.getSignature().getDeclaringType().g
etName());
	
logger.enter(thisJoinPointStaticPart.getSignature().getName() ,
thisJoinPoint.getArgs());
	}
		
	after() returning(Object r): method()
	{
		Logger logger = (Logger)
Logger.getLogger(thisJoinPointStaticPart.getSignature().getDeclaringType().g
etName());
	
logger.leave(thisJoinPointStaticPart.getSignature().getName(), r);
	}	
	

	after() throwing(Exception e): method()
	{
		Logger logger = (Logger)
Logger.getLogger(thisJoinPointStaticPart.getSignature().getDeclaringType().g
etName());
	
logger.leave(thisJoinPointStaticPart.getSignature().getName(), e);
	}
	
}
I've checked the exception definition but am not familiar with the concept
of a bounded aspect. Can someone please explain or point to the source of
the problem ?
Thanks.



Back to the top