FunctionMapper (Java EE 5)

Java EE API


javax.el Class FunctionMapper

java.lang.Object
  extended by javax.el.FunctionMapper

public abstract class FunctionMapper
extends Object


在 EL 函数名称和方法之间映射的接口。

FunctionMapper${prefix:name()} 样式函数映射到可以执行该函数的静态方法。

英文文档:

The interface to a map between EL function names and methods.

A FunctionMapper maps ${prefix:name()} style functions to a static method that can execute that function.

Since:
JSP 2.1

Constructor Summary
 
Method Summary
abstract  Method
 
Methods inherited from class java.lang.Object
 

Constructor Detail

public FunctionMapper()
英文文档:

FunctionMapper

public FunctionMapper()
Method Detail

abstract public Method resolveFunction(String prefix, String localName)
将指定的前缀和本地名称解析为 java.lang.Method

如果找不到与给定前缀和本地名称匹配的函数,则返回 null

prefix 函数前缀;如果没有前缀,则为 ""。例如,${fn:method()} 中的 "fn"${method()} 中的 ""
localName 函数的短名称。例如,${fn:method()} 中的 "method"
return 要调用的静态方法;如果找不到匹配的方法,则返回 null
英文文档:

resolveFunction

public abstract Method resolveFunction(String prefix,
                                       String localName)
Resolves the specified prefix and local name into a java.lang.Method.

Returns null if no function could be found that matches the given prefix and local name.

Parameters:
prefix - the prefix of the function, or "" if no prefix. For example, "fn" in ${fn:method()}, or "" in ${method()}.
localName - the short name of the function. For example, "method" in ${fn:method()}.
Returns:
the static method to invoke, or null if no match was found.


Submit a bug or feature

Copyright 2007 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.

一看就知道只有菜鸟才干这么无知的事啦。

PS : 未经我党受权你也可自由散发此文档。 如有任何错误请自行修正;若因此而造成任何损失请直接找人民主席,请勿与本人联系。谢谢!