Package org.apache.beehive.netui.core.urltemplates

Examples of org.apache.beehive.netui.core.urltemplates.URLTemplatesFactory


           
            // set the TemplatedURLFormatter attribute on the context.
            TemplatedURLFormatter.initServletContext( servletContext, formatter );
        }

        URLTemplatesFactory templatesFactory = URLTemplatesFactory.getURLTemplatesFactory( servletContext );
        if ( templatesFactory == null )
        {
            // URLTemplatesFactory has not been initialized,
            // get a URLTemplatesFactory object from the containerAdapter.
            templatesFactory = PageFlowUtils.createURLTemplatesFactory( servletContext );

            // get the known/req tokens from the default formatter for the factory to use to verify templates
            templatesFactory.setKnownTokens( formatter.getKnownTokens() );
            templatesFactory.setRequiredTokens( formatter.getRequiredTokens() );
            templatesFactory.load( servletContext );

            // set the URLTemplatesFactory attribute on the context.
            URLTemplatesFactory.initServletContext( servletContext, templatesFactory );
        }
    }
View Full Code Here


     */
    public static URLTemplatesFactory createURLTemplatesFactory( ServletContext servletContext )
    {
        // get the URLTemplatesFactory from the containerAdapter.
        ServletContainerAdapter containerAdapter = AdapterManager.getServletContainerAdapter( servletContext );
        URLTemplatesFactory factory = (URLTemplatesFactory) containerAdapter.getFactory( URLTemplatesFactory.class, null, null );

        // if there's no URLTemplatesFactory, use our default impl.
        if ( factory == null )
        {
            factory = new DefaultURLTemplatesFactory();
View Full Code Here

     */
    public static URLTemplatesFactory createURLTemplatesFactory( ServletContext servletContext )
    {
        // get the URLTemplatesFactory from the containerAdapter.
        ServletContainerAdapter containerAdapter = AdapterManager.getServletContainerAdapter( servletContext );
        URLTemplatesFactory factory = (URLTemplatesFactory) containerAdapter.getFactory( URLTemplatesFactory.class, null, null );

        // if there's no URLTemplatesFactory, use our default impl.
        if ( factory == null )
        {
            factory = new DefaultURLTemplatesFactory();
View Full Code Here

            // set the TemplatedURLFormatter attribute on the context.
            TemplatedURLFormatter.initServletContext( servletContext, formatter );
        }

        URLTemplatesFactory templatesFactory = URLTemplatesFactory.getURLTemplatesFactory( servletContext );
        if ( templatesFactory == null )
        {
            // URLTemplatesFactory has not been initialized,
            // get a URLTemplatesFactory object from the containerAdapter.
            templatesFactory = PageFlowUtils.createURLTemplatesFactory( servletContext );

            // get the known/req tokens from the default formatter for the factory to use to verify templates
            templatesFactory.setKnownTokens( formatter.getKnownTokens() );
            templatesFactory.setRequiredTokens( formatter.getRequiredTokens() );
            templatesFactory.load( servletContext );

            // set the URLTemplatesFactory attribute on the context.
            URLTemplatesFactory.initServletContext( servletContext, templatesFactory );
        }
    }
View Full Code Here

    {
        // Look for the template config and get the right template.
        // If it is found, apply the value to the template.
        String result = null;
        URLTemplate template = null;
        URLTemplatesFactory factory = URLTemplatesFactory.getURLTemplatesFactory( servletContext );

        if ( factory != null )
        {
            String templateName = factory.getTemplateNameByRef( DEFAULT_TEMPLATE_REF, key );

            if ( templateName != null )
            {
                template = factory.getURLTemplate( templateName );
            }
        }

        if ( template != null )
        {
View Full Code Here

            // set the TemplatedURLFormatter attribute on the context.
            TemplatedURLFormatter.initServletContext( servletContext, formatter );
        }

        URLTemplatesFactory templatesFactory = URLTemplatesFactory.getURLTemplatesFactory( servletContext );
        if ( templatesFactory == null )
        {
            // URLTemplatesFactory has not been initialized,
            // get a URLTemplatesFactory object from the containerAdapter.
            templatesFactory = PageFlowUtils.createURLTemplatesFactory( servletContext );

            // get the known/req tokens from the default formatter for the factory to use to verify templates
            templatesFactory.setKnownTokens( formatter.getKnownTokens() );
            templatesFactory.setRequiredTokens( formatter.getRequiredTokens() );
            templatesFactory.load( servletContext );

            // set the URLTemplatesFactory attribute on the context.
            URLTemplatesFactory.initServletContext( servletContext, templatesFactory );
        }
    }
View Full Code Here

    {
        // Look for the template config and get the right template.
        // If it is found, apply the value to the template.
        String result = null;
        URLTemplate template = null;
        URLTemplatesFactory factory = URLTemplatesFactory.getURLTemplatesFactory( request );

        if ( factory != null )
        {
            String templateName = factory.getTemplateNameByRef( DEFAULT_TEMPLATE_REF, key );

            if ( templateName != null )
            {
                template = factory.getURLTemplate( templateName );
            }
        }

        if ( template != null )
        {
View Full Code Here

     */
    public static URLTemplatesFactory createURLTemplatesFactory( ServletContext servletContext )
    {
        // get the URLTemplatesFactory from the containerAdapter.
        ServletContainerAdapter containerAdapter = AdapterManager.getServletContainerAdapter( servletContext );
        URLTemplatesFactory factory = (URLTemplatesFactory) containerAdapter.getFactory( URLTemplatesFactory.class, null, null );

        // if there's no URLTemplatesFactory, use our default impl.
        if ( factory == null )
        {
            factory = new DefaultURLTemplatesFactory();
View Full Code Here

TOP

Related Classes of org.apache.beehive.netui.core.urltemplates.URLTemplatesFactory

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.