KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > sapia > soto > aop > TestReturnAdvice


1 package org.sapia.soto.aop;
2
3 import java.lang.reflect.Method JavaDoc;
4
5
6 /**
7  * @author Yanick Duchesne
8  * <dl>
9  * <dt><b>Copyright:</b><dd>Copyright &#169; 2002-2003 <a HREF="http://www.sapia-oss.org">Sapia Open Source Software</a>. All Rights Reserved.</dd></dt>
10  * <dt><b>License:</b><dd>Read the license.txt file of the jar or visit the
11  * <a HREF="http://www.sapia-oss.org/license.html">license page</a> at the Sapia OSS web site</dd></dt>
12  * </dl>
13
14  */

15 public class TestReturnAdvice implements ReturnAdvice {
16   int count = 0;
17
18   /**
19    * Constructor for TestReturnAdvice.
20    */

21   public TestReturnAdvice() {
22     super();
23   }
24
25   /**
26    * @see org.sapia.soto.aop.ReturnAdvice#onReturn(Invocation)
27    */

28   public Object JavaDoc onReturn(Invocation call) throws Throwable JavaDoc {
29     count++;
30
31     return call.getReturnValue();
32   }
33 }
34
Popular Tags