Examples of FunctionMapper


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

Examples of javax.el.FunctionMapper

    }

    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

Examples of javax.el.FunctionMapper

    /**
     * Test method for {@link org.apache.tiles.el.ELContextImpl#setFunctionMapper(javax.el.FunctionMapper)}.
     */
    @Test
    public void testSetFunctionMapper() {
        FunctionMapper functionMapper = createMock(FunctionMapper.class);

        replay(resolver, functionMapper);
        context.setFunctionMapper(functionMapper);
        assertEquals(functionMapper, context.getFunctionMapper());
        verify(resolver, functionMapper);
View Full Code Here

Examples of javax.el.FunctionMapper

     * Tests {@link ELContextImpl#getFunctionMapper()}.
     */
    @Test
    public void testNullFunctionMapper() {
        replay(resolver);
        FunctionMapper functionMapper = context.getFunctionMapper();
        assertNull(functionMapper.resolveFunction("whatever", "it_IT"));
        verify(resolver);
    }
View Full Code Here

Examples of javax.el.FunctionMapper

    }

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

Examples of javax.el.FunctionMapper

    @Override
    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

Examples of javax.el.FunctionMapper

    @Override
    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

Examples of javax.servlet.jsp.el.FunctionMapper

            for (Iterator it = bookmarks.iterator(); it.hasNext();) {
                Bookmark bookmark = (Bookmark) it.next();
                if (bookmark.pattern.matcher(uri).matches()) {
                  String expression = bookmark.value;
          DefaultVariables variables = new DefaultVariables(uri, null, title);
          FunctionMapper functionMapper = StaticFunctionMapper.getDefault();
                    String name = (String) eval.evaluate(expression, String.class, variables, functionMapper);
                    name = name.trim();
                    if (name.length() > 0) {
            pluckerDocument.addBookmark(name, uri);
                    }
View Full Code Here

Examples of jnr.ffi.mapper.FunctionMapper

    }
   
    private static Map<LibraryOption, Object> options() {
        Map<LibraryOption, Object> options = new HashMap<LibraryOption, Object>();
       
        FunctionMapper functionMapper = functionMapper();
        if (functionMapper != null) {
            options.put(LibraryOption.FunctionMapper, functionMapper);
        }

        options.put(LibraryOption.TypeMapper, POSIXTypeMapper.INSTANCE);
View Full Code Here

Examples of org.zkoss.xel.FunctionMapper

        _eval.parseExpression(expression, expectedType));
    if (_v102)
      return new ELXelExpression102(
        _eval.parseExpression(expression, expectedType));

    FunctionMapper mapper = xelc != null ? xelc.getFunctionMapper(): null;
    return new ELXelExpression100(
      _eval.parseExpression(expression, expectedType, mapper),
      expression, mapper, expectedType);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.