| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| <!-- NewPage --> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc (version 1.7.0_25) on Mon Mar 31 09:56:25 CEST 2014 --> |
| <meta http-equiv="Content-Type" content="text/html" charset="UTF-8"> |
| <title>MethodInterceptor (Apache Felix iPOJO ~ JavaDoc 1.11.2 API)</title> |
| <meta name="date" content="2014-03-31"> |
| <link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style"> |
| </head> |
| <body> |
| <script type="text/javascript"><!-- |
| if (location.href.indexOf('is-external=true') == -1) { |
| parent.document.title="MethodInterceptor (Apache Felix iPOJO ~ JavaDoc 1.11.2 API)"; |
| } |
| //--> |
| </script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="topNav"><a name="navbar_top"> |
| <!-- --> |
| </a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/MethodInterceptor.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../index-all.html">Index</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../org/apache/felix/ipojo/IPOJOServiceFactory.html" title="interface in org.apache.felix.ipojo"><span class="strong">Prev Class</span></a></li> |
| <li><a href="../../../../org/apache/felix/ipojo/MissingHandlerException.html" title="class in org.apache.felix.ipojo"><span class="strong">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/apache/felix/ipojo/MethodInterceptor.html" target="_top">Frames</a></li> |
| <li><a href="MethodInterceptor.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_top"> |
| <li><a href="../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_top"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method_summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method_detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip-navbar_top"> |
| <!-- --> |
| </a></div> |
| <!-- ========= END OF TOP NAVBAR ========= --> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <div class="header"> |
| <div class="subTitle">org.apache.felix.ipojo</div> |
| <h2 title="Interface MethodInterceptor" class="title">Interface MethodInterceptor</h2> |
| </div> |
| <div class="contentContainer"> |
| <div class="description"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <dl> |
| <dt>All Known Implementing Classes:</dt> |
| <dd><a href="../../../../org/apache/felix/ipojo/handlers/architecture/ArchitectureHandler.html" title="class in org.apache.felix.ipojo.handlers.architecture">ArchitectureHandler</a>, <a href="../../../../org/apache/felix/ipojo/handlers/context/BundleContextHandler.html" title="class in org.apache.felix.ipojo.handlers.context">BundleContextHandler</a>, <a href="../../../../org/apache/felix/ipojo/handlers/configuration/ConfigurationHandler.html" title="class in org.apache.felix.ipojo.handlers.configuration">ConfigurationHandler</a>, <a href="../../../../org/apache/felix/ipojo/handlers/lifecycle/controller/ControllerHandler.html" title="class in org.apache.felix.ipojo.handlers.lifecycle.controller">ControllerHandler</a>, <a href="../../../../org/apache/felix/ipojo/handlers/dependency/Dependency.html" title="class in org.apache.felix.ipojo.handlers.dependency">Dependency</a>, <a href="../../../../org/apache/felix/ipojo/handlers/dependency/DependencyHandler.html" title="class in org.apache.felix.ipojo.handlers.dependency">DependencyHandler</a>, <a href="../../../../org/apache/felix/ipojo/handlers/lifecycle/callback/LifecycleCallbackHandler.html" title="class in org.apache.felix.ipojo.handlers.lifecycle.callback">LifecycleCallbackHandler</a>, <a href="../../../../org/apache/felix/ipojo/PrimitiveHandler.html" title="class in org.apache.felix.ipojo">PrimitiveHandler</a>, <a href="../../../../org/apache/felix/ipojo/handlers/providedservice/ProvidedServiceHandler.html" title="class in org.apache.felix.ipojo.handlers.providedservice">ProvidedServiceHandler</a></dd> |
| </dl> |
| <hr> |
| <br> |
| <pre>public interface <a href="../../../../src-html/org/apache/felix/ipojo/MethodInterceptor.html#line.39">MethodInterceptor</a></pre> |
| <div class="block">Method interceptor. |
| A class implementing this interface is able to be notified of method invocations ( |
| i.e. entries, exits, and errors). |
| The listener needs to be register on the instance manager with the |
| <a href="../../../../org/apache/felix/ipojo/InstanceManager.html#register(org.apache.felix.ipojo.parser.MethodMetadata, org.apache.felix.ipojo.MethodInterceptor)"><code>InstanceManager.register(org.apache.felix.ipojo.parser.MethodMetadata, MethodInterceptor)</code></a> |
| method. |
| Events are sent before the method entry (onEntry), after the method returns (onExit), |
| when an error is thrown by the method (onError), and before the after either a returns or an error (onFinally). |
| |
| Instead of a <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Method.html?is-external=true" title="class or interface in java.lang.reflect"><code>Method</code></a> object, the callbacks received a <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Member.html?is-external=true" title="class or interface in java.lang.reflect"><code>Member</code></a> object which can be either a <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Method.html?is-external=true" title="class or interface in java.lang.reflect"><code>Method</code></a> |
| or a <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Constructor.html?is-external=true" title="class or interface in java.lang.reflect"><code>Constructor</code></a>.</div> |
| <dl><dt><span class="strong">Author:</span></dt> |
| <dd><a href="mailto:dev@felix.apache.org">Felix Project Team</a></dd></dl> |
| </li> |
| </ul> |
| </div> |
| <div class="summary"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method_summary"> |
| <!-- --> |
| </a> |
| <h3>Method Summary</h3> |
| <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> |
| <caption><span>Methods</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colLast" scope="col">Method and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/felix/ipojo/MethodInterceptor.html#onEntry(java.lang.Object, java.lang.reflect.Member, java.lang.Object[])">onEntry</a></strong>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> pojo, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Member.html?is-external=true" title="class or interface in java.lang.reflect">Member</a> method, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>[] args)</code> |
| <div class="block">This method is called when a thread enters in a method.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/felix/ipojo/MethodInterceptor.html#onError(java.lang.Object, java.lang.reflect.Member, java.lang.Throwable)">onError</a></strong>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> pojo, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Member.html?is-external=true" title="class or interface in java.lang.reflect">Member</a> method, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</a> throwable)</code> |
| <div class="block">This method is called when the execution throws an exception in the given |
| method.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/felix/ipojo/MethodInterceptor.html#onExit(java.lang.Object, java.lang.reflect.Member, java.lang.Object)">onExit</a></strong>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> pojo, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Member.html?is-external=true" title="class or interface in java.lang.reflect">Member</a> method, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> returnedObj)</code> |
| <div class="block">This method is called when the execution exits a method : |
| before a <code>return</code>.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/felix/ipojo/MethodInterceptor.html#onFinally(java.lang.Object, java.lang.reflect.Member)">onFinally</a></strong>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> pojo, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Member.html?is-external=true" title="class or interface in java.lang.reflect">Member</a> method)</code> |
| <div class="block">This method is called when the execution of a method is going to terminate : |
| just before to throw an exception or before to return.</div> |
| </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| <div class="details"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ============ METHOD DETAIL ========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method_detail"> |
| <!-- --> |
| </a> |
| <h3>Method Detail</h3> |
| <a name="onEntry(java.lang.Object, java.lang.reflect.Member, java.lang.Object[])"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>onEntry</h4> |
| <pre>void <a href="../../../../src-html/org/apache/felix/ipojo/MethodInterceptor.html#line.48">onEntry</a>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> pojo, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Member.html?is-external=true" title="class or interface in java.lang.reflect">Member</a> method, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>[] args)</pre> |
| <div class="block">This method is called when a thread enters in a method. |
| The given argument array is created from the method argument.</div> |
| <dl><dt><span class="strong">Parameters:</span></dt><dd><code>pojo</code> - the pojo on which the method is called.</dd><dd><code>method</code> - the invoked method.</dd><dd><code>args</code> - the arguments array.</dd></dl> |
| </li> |
| </ul> |
| <a name="onExit(java.lang.Object, java.lang.reflect.Member, java.lang.Object)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>onExit</h4> |
| <pre>void <a href="../../../../src-html/org/apache/felix/ipojo/MethodInterceptor.html#line.60">onExit</a>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> pojo, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Member.html?is-external=true" title="class or interface in java.lang.reflect">Member</a> method, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> returnedObj)</pre> |
| <div class="block">This method is called when the execution exits a method : |
| before a <code>return</code>. |
| If the given returned object is <code>null</code>, either the method is |
| <code>void</code>, or it returns <code>null</code>. |
| This method must not modify the returned object.</div> |
| <dl><dt><span class="strong">Parameters:</span></dt><dd><code>pojo</code> - the pojo on which the method exits.</dd><dd><code>method</code> - the exiting method.</dd><dd><code>returnedObj</code> - the the returned object (boxed for primitive type)</dd></dl> |
| </li> |
| </ul> |
| <a name="onError(java.lang.Object, java.lang.reflect.Member, java.lang.Throwable)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>onError</h4> |
| <pre>void <a href="../../../../src-html/org/apache/felix/ipojo/MethodInterceptor.html#line.69">onError</a>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> pojo, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Member.html?is-external=true" title="class or interface in java.lang.reflect">Member</a> method, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</a> throwable)</pre> |
| <div class="block">This method is called when the execution throws an exception in the given |
| method.</div> |
| <dl><dt><span class="strong">Parameters:</span></dt><dd><code>pojo</code> - the pojo on which the method was accessed.</dd><dd><code>method</code> - the invoked method.</dd><dd><code>throwable</code> - the thrown exception</dd></dl> |
| </li> |
| </ul> |
| <a name="onFinally(java.lang.Object, java.lang.reflect.Member)"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>onFinally</h4> |
| <pre>void <a href="../../../../src-html/org/apache/felix/ipojo/MethodInterceptor.html#line.78">onFinally</a>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> pojo, |
| <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Member.html?is-external=true" title="class or interface in java.lang.reflect">Member</a> method)</pre> |
| <div class="block">This method is called when the execution of a method is going to terminate : |
| just before to throw an exception or before to return. |
| (onError or onExit was already called).</div> |
| <dl><dt><span class="strong">Parameters:</span></dt><dd><code>pojo</code> - the pojo on which the method was accessed.</dd><dd><code>method</code> - the invoked method.</dd></dl> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| </div> |
| <!-- ========= END OF CLASS DATA ========= --> |
| <!-- ======= START OF BOTTOM NAVBAR ====== --> |
| <div class="bottomNav"><a name="navbar_bottom"> |
| <!-- --> |
| </a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/MethodInterceptor.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../index-all.html">Index</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../org/apache/felix/ipojo/IPOJOServiceFactory.html" title="interface in org.apache.felix.ipojo"><span class="strong">Prev Class</span></a></li> |
| <li><a href="../../../../org/apache/felix/ipojo/MissingHandlerException.html" title="class in org.apache.felix.ipojo"><span class="strong">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/apache/felix/ipojo/MethodInterceptor.html" target="_top">Frames</a></li> |
| <li><a href="MethodInterceptor.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_bottom"> |
| <li><a href="../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_bottom"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method_summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method_detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip-navbar_bottom"> |
| <!-- --> |
| </a></div> |
| <!-- ======== END OF BOTTOM NAVBAR ======= --> |
| <p class="legalCopy"><small>Copyright © 2014. All rights reserved.</small></p> |
| </body> |
| </html> |