Package javax.el

Examples of javax.el.FunctionMapper


   */
  public ExpressionBuilder(String expression, ELContext ctx)
      throws ELException {
    this.expression = expression;

    FunctionMapper ctxFn = ctx.getFunctionMapper();
    VariableMapper ctxVar = ctx.getVariableMapper();

    if (ctxFn != null) {
      this.fnMapper = new FunctionMapperFactory(ctxFn);
    }
View Full Code Here


   */
  public ExpressionBuilder(String expression, ELContext ctx)
      throws ELException {
    this.expression = expression;

    FunctionMapper ctxFn = ctx.getFunctionMapper();
    VariableMapper ctxVar = ctx.getVariableMapper();

    if (ctxFn != null) {
      this.fnMapper = new FunctionMapperFactory(ctxFn);
    }
View Full Code Here

    private VariableMapper variableMapper;

    public ELContextImpl() {
        this(ELResolverImpl.getDefaultResolver());
        if (Globals.IS_SECURITY_ENABLED) {
            functionMapper = new FunctionMapper() {
                public Method resolveFunction(String prefix, String localName) {
                    return null;
                }
            };
        } else {
View Full Code Here

        this.next = next;
    }

    public void apply(FaceletContext ctx, UIComponent parent)
            throws IOException {
        FunctionMapper orig = ctx.getFunctionMapper();
        pushMapper(ctx.getFacesContext(), this);
        ctx.setFunctionMapper(new CompositeFunctionMapper(this, orig));
        try {
            next.apply(ctx, parent);
        } finally {
View Full Code Here

   */
  public ExpressionBuilder(String expression, ELContext ctx)
      throws ELException {
    this.expression = expression;

    FunctionMapper ctxFn = ctx.getFunctionMapper();
    VariableMapper ctxVar = ctx.getVariableMapper();

    if (ctxFn != null) {
      this.fnMapper = new FunctionMapperFactory(ctxFn);
    }
View Full Code Here

    }

    public Class getType(EvaluationContext ctx)
            throws ELException {
       
        FunctionMapper fnMapper = ctx.getFunctionMapper();
       
        // quickly validate again for this request
        if (fnMapper == null) {
            throw new ELException(MessageFactory.get("error.fnMapper.null"));
        }
        Method m = fnMapper.resolveFunction(this.prefix, this.localName);
        if (m == null) {
            throw new ELException(MessageFactory.get("error.fnMapper.method",
                    this.getOutputName()));
        }
        return m.getReturnType();
View Full Code Here

    }

    public Object getValue(EvaluationContext ctx)
            throws ELException {
       
        FunctionMapper fnMapper = ctx.getFunctionMapper();
       
        // quickly validate again for this request
        if (fnMapper == null) {
            throw new ELException(MessageFactory.get("error.fnMapper.null"));
        }
        Method m = fnMapper.resolveFunction(this.prefix, this.localName);
        if (m == null) {
            throw new ELException(MessageFactory.get("error.fnMapper.method",
                    this.getOutputName()));
        }
View Full Code Here

   */
  public ExpressionBuilder(String expression, ELContext ctx)
      throws ELException {
    this.expression = expression;

    FunctionMapper ctxFn = ctx.getFunctionMapper();
    VariableMapper ctxVar = ctx.getVariableMapper();

    if (ctxFn != null) {
      this.fnMapper = new FunctionMapperFactory(ctxFn);
    }
View Full Code Here

        this.next = next;
    }

    public void apply(FaceletContext ctx, UIComponent parent)
            throws IOException {
        FunctionMapper orig = ctx.getFunctionMapper();
        pushMapper(ctx.getFacesContext(), this);
        ctx.setFunctionMapper(new CompositeFunctionMapper(this, orig));
        try {
            next.apply(ctx, parent);
        } finally {
View Full Code Here

  protected Method getStaticMethod(String name)
    throws ELParseException
  {
    Method method = null;

    FunctionMapper funMapper = _elContext.getFunctionMapper();

    if (funMapper != null) {
      String prefix = "";
      String localName = name;

      int p = name.indexOf(':');
      if (p > 0) {
  prefix = name.substring(0, p);
  localName = name.substring(p + 1);
      }
     
      method = funMapper.resolveFunction(prefix, localName);
    }
   
    return method;
  }
View Full Code Here

TOP

Related Classes of javax.el.FunctionMapper

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.