Examples of TldTaglib


Examples of org.apache.openejb.jee.TldTaglib

        urls = TldScanner.scan(parentClassLoader);
        tldLocations.addAll(urls);

        // load the tld files
        for (final URL location : tldLocations) {
            final TldTaglib taglib = ReadDescriptors.readTldTaglib(location);
            webModule.getTaglibs().add(taglib);
            if ("file".equals(location.getProtocol())) {
                webModule.getWatchedResources().add(URLs.toFilePath(location));
            }
        }
View Full Code Here

Examples of org.apache.openejb.jee.TldTaglib

        // TOMEE-164 Optimization on reading built-in tld files
        if (url.getPath().contains("jstl-1.2.jar")) {
            return SKIP_TAGLIB;
        }
        if (url.getPath().contains("myfaces-impl")) { // we should return SKIP_TAGLIB too
            final TldTaglib taglib = new TldTaglib();
            final Listener listener = new Listener();
            listener.setListenerClass("org.apache.myfaces.webapp.StartupServletContextListener");
            taglib.getListener().add(listener);
            return taglib;
        }

        try {
            return TldTaglibXml.unmarshal(url);
View Full Code Here

Examples of org.apache.openejb.jee.TldTaglib

        urls = TldScanner.scan(parentClassLoader);
        tldLocations.addAll(urls);

        // load the tld files
        for (final URL location : tldLocations) {
            final TldTaglib taglib = ReadDescriptors.readTldTaglib(location);
            if (taglib != null && taglib != ReadDescriptors.SKIP_TAGLIB) {
                webModule.getTaglibs().add(taglib);
                if ("file".equals(location.getProtocol())) {
                    webModule.getWatchedResources().add(URLs.toFilePath(location));
                }
View Full Code Here

Examples of org.apache.openejb.jee.TldTaglib

        urls = TldScanner.scan(parentClassLoader);
        tldLocations.addAll(urls);

        // load the tld files
        for (final URL location : tldLocations) {
            final TldTaglib taglib = ReadDescriptors.readTldTaglib(location);
            webModule.getTaglibs().add(taglib);
            if ("file".equals(location.getProtocol())) {
                webModule.getWatchedResources().add(URLs.toFilePath(location));
            }
        }
View Full Code Here

Examples of org.apache.openejb.jee.TldTaglib

        urls = TldScanner.scan(parentClassLoader);
        tldLocations.addAll(urls);

        // load the tld files
        for (final URL location : tldLocations) {
            final TldTaglib taglib = ReadDescriptors.readTldTaglib(location);
            webModule.getTaglibs().add(taglib);
            if ("file".equals(location.getProtocol())) {
                webModule.getWatchedResources().add(URLs.toFilePath(location));
            }
        }
View Full Code Here

Examples of org.apache.openejb.jee.TldTaglib

        return webApp;
    }

    public static TldTaglib readTldTaglib(URL url) throws OpenEJBException {
        // TOMEE-164 Optimization on reading built-in tld files
        if (url.getPath().contains("jstl-1.2.jar")) return new TldTaglib();
        if (url.getPath().contains("myfaces-impl")) {
            final TldTaglib taglib = new TldTaglib();
            final Listener listener = new Listener();
            listener.setListenerClass("org.apache.myfaces.webapp.StartupServletContextListener");
            taglib.getListener().add(listener);
            return taglib;
        }

        TldTaglib tldTaglib;
        try {
            tldTaglib = (TldTaglib) JaxbJavaee.unmarshalTaglib(TldTaglib.class, IO.read(url));
        } catch (SAXException e) {
            throw new OpenEJBException("Cannot parse the JSP tag library definition file: " + url.toExternalForm(), e);
        } catch (JAXBException e) {
View Full Code Here

Examples of org.apache.openejb.jee.TldTaglib

        return webApp;
    }

    public static TldTaglib readTldTaglib(URL url) throws OpenEJBException {
        // TOMEE-164 Optimization on reading built-in tld files
        if (url.getPath().contains("jstl-1.2.jar")) return new TldTaglib();
        if (url.getPath().contains("myfaces-impl")) {
            final TldTaglib taglib = new TldTaglib();
            final Listener listener = new Listener();
            listener.setListenerClass("org.apache.myfaces.webapp.StartupServletContextListener");
            taglib.getListener().add(listener);
            return taglib;
        }

        TldTaglib tldTaglib;
        try {
            tldTaglib = (TldTaglib) JaxbJavaee.unmarshalTaglib(TldTaglib.class, IO.read(url));
        } catch (SAXException e) {
            throw new OpenEJBException("Cannot parse the JSP tag library definition file: " + url.toExternalForm(), e);
        } catch (JAXBException e) {
View Full Code Here

Examples of org.apache.openejb.jee.TldTaglib$JAXB

* @version $Rev$ $Date$
*/
public class TldTaglibXml {

    public static TldTaglib unmarshal(final InputStream inputStream) throws Exception {
        return Sxc.unmarshalJavaee(new TldTaglib$JAXB(), inputStream);
    }
View Full Code Here

Examples of org.apache.openejb.jee.TldTaglib$JAXB

    public static TldTaglib unmarshal(final URL url) throws Exception {
        final InputStream inputStream = IO.read(url);
        try {
            final XMLStreamReader filter = new TaglibNamespaceFilter(Sxc.prepareReader(inputStream));
            return Sxc.unmarhsal(new TldTaglib$JAXB(), new XoXMLStreamReaderImpl(filter));
        } finally {
            IO.close(inputStream);
        }
    }
View Full Code Here

Examples of org.apache.openejb.jee.TldTaglib$JAXB

            IO.close(inputStream);
        }
    }

    public static void marshal(final TldTaglib taglib, final OutputStream outputStream) throws Exception {
        Sxc.marshal(new TldTaglib$JAXB(), taglib, new StreamResult(outputStream));
    }
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.