Examples of FunctionLibrary


Examples of net.sf.saxon.functions.FunctionLibrary

        // We need to remove the default XPathFunctionLibrary to replace it
        // with our own
        List libList = ((FunctionLibraryList)getFunctionLibrary()).libraryList;
        XPathFunctionLibrary xpathLib = null;
        for (Object lib : libList) {
            FunctionLibrary flib = (FunctionLibrary) lib;
            if (flib instanceof XPathFunctionLibrary) xpathLib = (XPathFunctionLibrary) flib;
        }
        if (xpathLib != null) libList.remove(xpathLib);
        OdeXPathFunctionLibrary oxpfl = new OdeXPathFunctionLibrary(funcResolver);
        oxpfl.setXPathFunctionResolver(funcResolver);
View Full Code Here

Examples of net.sf.saxon.functions.FunctionLibrary

        // We need to remove the default XPathFunctionLibrary to replace it
        // with our own
        List libList = ((FunctionLibraryList)getFunctionLibrary()).libraryList;
        XPathFunctionLibrary xpathLib = null;
        for (Object lib : libList) {
            FunctionLibrary flib = (FunctionLibrary) lib;
            if (flib instanceof XPathFunctionLibrary) xpathLib = (XPathFunctionLibrary) flib;
        }
        if (xpathLib != null) libList.remove(xpathLib);
        OdeXPathFunctionLibrary oxpfl = new OdeXPathFunctionLibrary(funcResolver);
        oxpfl.setXPathFunctionResolver(funcResolver);
View Full Code Here

Examples of net.sf.saxon.functions.FunctionLibrary

        // We need to remove the default XPathFunctionLibrary to replace it
        // with our own
        List libList = ((FunctionLibraryList)getFunctionLibrary()).libraryList;
        XPathFunctionLibrary xpathLib = null;
        for (Object lib : libList) {
            FunctionLibrary flib = (FunctionLibrary) lib;
            if (flib instanceof XPathFunctionLibrary) xpathLib = (XPathFunctionLibrary) flib;
        }
        if (xpathLib != null) libList.remove(xpathLib);
        OdeXPathFunctionLibrary oxpfl = new OdeXPathFunctionLibrary(funcResolver);
        oxpfl.setXPathFunctionResolver(funcResolver);
View Full Code Here

Examples of nodebox.function.FunctionLibrary

    }

    private void addLibrary(String prefix, File libraryFile) {
        String relativePath = FileUtils.getRelativePath(libraryFile, document.getDocumentFile().getParentFile());
        FunctionLibrary library = FunctionLibrary.load(document.getDocumentFile(), prefix + ":" + relativePath);
        functionRepository = functionRepository.withLibraryAdded(library);
        reloadListModel();
        repositoryChanged = true;

    }
View Full Code Here

Examples of org.apache.commons.jxpath.FunctionLibrary

        // JXPathMetaModule starts copying here
        // please keep both in sync.

        lenient = config.getChild("lenient").getValueAsBoolean(lenient);
        FunctionLibrary library = new FunctionLibrary();
        getFunctions(library, config);
        getPackages(library, config);
        // the following is necessary to be able to use methods on objects without
        // explicitely registering extension functions (see PackageFunctions javadoc)
        library.addFunctions(new PackageFunctions("", null));
        return new JXPathHelperConfiguration(library, lenient);
    }
View Full Code Here

Examples of org.apache.commons.jxpath.FunctionLibrary

     * @param conf a <code>Configuration</code> value holding local
     * packages and functions.
     */
    private static void setupExtensions(JXPathHelperConfiguration setup, JXPathContext context, Configuration conf) {

        FunctionLibrary localLib = null;

        if (conf != null) {
            localLib = new FunctionLibrary();
            localLib.addFunctions(setup.getLibrary());
            getPackages(localLib, conf);
            getFunctions(localLib, conf);
        } else {
            localLib = setup.getLibrary();
        }
View Full Code Here

Examples of org.apache.commons.jxpath.FunctionLibrary

        // JXPathMetaModule starts copying here
        // please keep both in sync.

        lenient = config.getChild("lenient").getValueAsBoolean(lenient);
        FunctionLibrary library = new FunctionLibrary();
        getFunctions(library, config);
        getPackages(library, config);
        return new JXPathHelperConfiguration(library, lenient);
    }
View Full Code Here

Examples of org.apache.commons.jxpath.FunctionLibrary

     * @param conf a <code>Configuration</code> value holding local
     * packages and functions.
     */
    private static void setupExtensions(JXPathHelperConfiguration setup, JXPathContext context, Configuration conf) {

        FunctionLibrary localLib = null;

        if (conf != null) {
            localLib = new FunctionLibrary();
            localLib.addFunctions(setup.getLibrary());
            getPackages(localLib, conf);
            getFunctions(localLib, conf);
        } else {
            localLib = setup.getLibrary();
        }
View Full Code Here

Examples of org.apache.commons.jxpath.FunctionLibrary

        if (context == null) {
            context = JXPathContext.newContext(new TestBean());
            Variables vars = context.getVariables();
            vars.declareVariable("test", new TestFunctions(4, "test"));

            FunctionLibrary lib = new FunctionLibrary();
            lib.addFunctions(new ClassFunctions(TestFunctions.class, "test"));
            lib.addFunctions(new ClassFunctions(TestFunctions2.class, "test"));
            lib.addFunctions(new PackageFunctions("", "call"));
            lib.addFunctions(
                new PackageFunctions(
                    "org.apache.commons.jxpath.ri.compiler.",
                    "jxpathtest"));
            context.setFunctions(lib);
        }
View Full Code Here

Examples of org.apache.commons.jxpath.FunctionLibrary

     * Create root jxpath configuration
     */
    public JXPathHelperConfiguration(Configuration config)
    throws ConfigurationException {
        this.lenient = config.getChild("lenient").getValueAsBoolean(true);
        this.library = new FunctionLibrary();
        setup(config);

        // the following is necessary to be able to use methods on objects without
        // explicitely registering extension functions (see PackageFunctions javadoc)
        this.library.addFunctions(new PackageFunctions("", null));
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.