Package org.apache.tapestry.web

Examples of org.apache.tapestry.web.WebContextResource


        return createAsset(localized, location);
    }

    public IAsset createAbsoluteAsset(String path, Locale locale, Location location)
    {
        Resource base = new WebContextResource(_webContext, path);
        Resource localized = _localizer.findLocalization(base, locale);

        if (localized == null)
            throw new ApplicationRuntimeException(AssetMessages.missingContextResource(path), location, null);
View Full Code Here


        return createAsset(localized, location);
    }

    public IAsset createAbsoluteAsset(String path, Locale locale, Location location)
    {
        Resource base = new WebContextResource(_webContext, path);
        Resource localized = _localizer.findLocalization(base, locale);

        if (localized == null)
            throw new ApplicationRuntimeException(AssetMessages.missingContextResource(path),
                    location, null);
View Full Code Here

        checkOrder(comp, false);
        WebContext context = newMock(WebContext.class);
        IRequestCycle cycle = newMock(IRequestCycle.class);

        IComponentSpecification spec = new ComponentSpecification();
        WebContextResource base = new WebContextResource(context, "/WEB-INF/MyComponent.jwc");
        spec.setSpecificationLocation(base);
       
        ComponentResourceResolverImpl resolver = new ComponentResourceResolverImpl();

        expect(comp.getSpecification()).andReturn(spec).anyTimes();
View Full Code Here

        checkOrder(comp, false);
        WebContext context = newMock(WebContext.class);
        IRequestCycle cycle = newMock(IRequestCycle.class);

        IComponentSpecification spec = new ComponentSpecification();
        WebContextResource base = new WebContextResource(context, "/WEB-INF/MyComponent.jwc");
        spec.setSpecificationLocation(base);

        ComponentResourceResolverImpl resolver = new ComponentResourceResolverImpl();

        expect(comp.getSpecification()).andReturn(spec).anyTimes();
View Full Code Here

     */

    protected void addModuleIfExists(RegistryBuilder builder, ClassResolver resolver,
            WebContext context, String path)
    {
        Resource r = new WebContextResource(context, path);

        if (r.getResourceURL() == null)
            return;

        builder.addModuleDescriptorProvider(new XmlModuleDescriptorProvider(resolver, r));
    }
View Full Code Here

    public Resource getContextRoot()
    {
        WebContext context = (WebContext) getProperty("context");

        return new WebContextResource(context, "/");
    }
View Full Code Here

        return createAsset(localized, location);
    }

    public IAsset createAbsoluteAsset(String path, Locale locale, Location location)
    {
        Resource base = new WebContextResource(_webContext, path);
        Resource localized = base.getLocalization(locale);

        if (localized == null)
            throw new ApplicationRuntimeException(AssetMessages.missingContextResource(path),
                    location, null);
View Full Code Here

        return createAsset(localized, location);
    }

    public IAsset createAbsoluteAsset(String path, Locale locale, Location location)
    {
        Resource base = new WebContextResource(_webContext, path);
        Resource localized = _localizer.findLocalization(base, locale);

        if (localized == null)
            throw new ApplicationRuntimeException(AssetMessages.missingContextResource(path),
                    location, null);
View Full Code Here

TOP

Related Classes of org.apache.tapestry.web.WebContextResource

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.