org.mule.model.resolvers
Class MethodHeaderPropertyEntryPointResolver

java.lang.Object
  extended by org.mule.model.resolvers.AbstractEntryPointResolver
      extended by org.mule.model.resolvers.MethodHeaderPropertyEntryPointResolver
All Implemented Interfaces:
EntryPointResolver

public class MethodHeaderPropertyEntryPointResolver
extends AbstractEntryPointResolver

This resolver will look for a MuleProperties.MULE_METHOD_PROPERTY property on the incoming event to determine which method to invoke Users can customise the name of the property used to look up the method name on the event


Field Summary
 
Fields inherited from class org.mule.model.resolvers.AbstractEntryPointResolver
logger, methodCache
 
Constructor Summary
MethodHeaderPropertyEntryPointResolver()
           
 
Method Summary
 java.lang.String getMethodProperty()
           
 InvocationResult invoke(java.lang.Object component, MuleEventContext context)
           
 void setMethodProperty(java.lang.String methodProperty)
           
 java.lang.String toString()
           
protected  void validateMethod(java.lang.Object component, java.lang.reflect.Method method)
          This method can be used to validate that the method exists and is allowed to be executed.
 
Methods inherited from class org.mule.model.resolvers.AbstractEntryPointResolver
addMethodByArguments, addMethodByName, getCacheKeyForPayload, getMethodByArguments, getMethodByName, getPayloadFromMessage, invokeMethod, isAcceptVoidMethods, isSynchronizeCall, setAcceptVoidMethods, setSynchronizeCall
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MethodHeaderPropertyEntryPointResolver

public MethodHeaderPropertyEntryPointResolver()
Method Detail

getMethodProperty

public java.lang.String getMethodProperty()

setMethodProperty

public void setMethodProperty(java.lang.String methodProperty)

invoke

public InvocationResult invoke(java.lang.Object component,
                               MuleEventContext context)
                        throws java.lang.Exception
Throws:
java.lang.Exception

validateMethod

protected void validateMethod(java.lang.Object component,
                              java.lang.reflect.Method method)
                       throws java.lang.NoSuchMethodException
This method can be used to validate that the method exists and is allowed to be executed.

Parameters:
component - the service component being invoked
method - the method to invoke on the component
Throws:
java.lang.NoSuchMethodException - if the method does not exist on the component

toString

public java.lang.String toString()
Overrides:
toString in class AbstractEntryPointResolver


Copyright © 2003-2010 MuleSoft, Inc.. All Rights Reserved.