1 /**************************************************************************************2 * Copyright (c) Jonas Bon?r, Alexandre Vasseur. All rights reserved. *3 * http://aspectwerkz.codehaus.org *4 * ---------------------------------------------------------------------------------- *5 * The software in this package is published under the terms of the LGPL license *6 * a copy of which has been included with this distribution in the license.txt file. *7 **************************************************************************************/8 package test.aopc;9 10 import org.codehaus.aspectwerkz.joinpoint.JoinPoint;11 import org.codehaus.aspectwerkz.AspectContext;12 import org.codehaus.aspectwerkz.AspectContext;13 14 /**15 * @author <a HREF="mailto:alex@gnilux.com">Alexandre Vasseur </a>16 */17 public class BaseAspect {18 private AspectContext m_cci;19 20 public BaseAspect(AspectContext cci) {21 m_cci = cci;22 }23 24 public Object logAround(JoinPoint jp) throws Throwable {25 String vfqn = m_cci.getUuid() + "/" + m_cci.getName();26 ((Callable) jp.getTarget()).log(vfqn + ".beforeAround ");27 Object result = jp.proceed();28 ((Callable) jp.getTarget()).log(vfqn + ".afterAround ");29 return result;30 }31 }