bundles/org.apache.jasper.glassfish/src/org/apache/jasper/runtime/ProtectedFunctionMapper.java
public void mapFunction(String fnQName, final Class<?> c,
			    final String methodName, final Class<?>[] args ) 
    {
	java.lang.reflect.Method method;
        if (SecurityUtil.isPackageProtectionEnabled()){
            try{
                method = AccessController.doPrivileged(
                new PrivilegedExceptionAction<Method>(){
                    public Method run() throws Exception{
                        return c.getDeclaredMethod(methodName, args);
                    }                
                });      
            } catch (PrivilegedActionException ex){
                throw new RuntimeException(
                    "Invalid function mapping - no such method: "
		    + ex.getException().getMessage());               
            }
        } else {
             try {
                method = c.getDeclaredMethod(methodName, args);
            } catch( NoSuchMethodException e ) {
                throw new RuntimeException(
                    "Invalid function mapping - no such method: "
		    + e.getMessage());
            }
        }

	this.fnmap.put(fnQName, method );
    }
public void mapFunction(String fnQName, final Class<?> c,
			    final String methodName, final Class<?>[] args ) 
    {
	java.lang.reflect.Method method;
        if (SecurityUtil.isPackageProtectionEnabled()){
            try{
                method = AccessController.doPrivileged(
                new PrivilegedExceptionAction<Method>(){
                    public Method run() throws Exception{
                        return c.getDeclaredMethod(methodName, args);
                    }                
                });      
            } catch (PrivilegedActionException ex){
                throw new RuntimeException(
                    "Invalid function mapping - no such method: "
		    + ex.getException().getMessage());               
            }
        } else {
             try {
                method = c.getDeclaredMethod(methodName, args);
            } catch( NoSuchMethodException e ) {
                throw new RuntimeException(
                    "Invalid function mapping - no such method: "
		    + e.getMessage());
            }
        }

	this.fnmap.put(fnQName, method );
    }
Stores a mapping from the given EL function prefix and name to
the given Java method.

@param fnQName The EL function qualified name (including prefix)
@param c The class containing the Java method
@param methodName The name of the Java method
@param args The arguments of the Java method
@throws RuntimeException if no method with the given signature
could be found.