1 10 11 package org.mule.interceptors; 12 13 import org.mule.umo.Invocation; 14 import org.mule.umo.UMOException; 15 import org.mule.umo.UMOInterceptor; 16 import org.mule.umo.UMOMessage; 17 18 25 public abstract class EnvelopeInterceptor implements UMOInterceptor 26 { 27 32 public abstract void before(Invocation invocation) throws UMOException; 33 34 39 public abstract void after(Invocation invocation) throws UMOException; 40 41 public final UMOMessage intercept(Invocation invocation) throws UMOException 42 { 43 before(invocation); 44 UMOMessage message = invocation.execute(); 45 invocation.setMessage(message); 46 after(invocation); 47 return message; 48 } 49 } 50 | Popular Tags |