Package org.directwebremoting

Examples of org.directwebremoting.Container


        };

        // add the scaDomainScriptHandler to the urlProcessor
        // bit of a hack, there's probably cleaner way to get it registered
        urlProcessor.afterContainerSetup(new Container() {
            public Object getBean(String name) {
                return scaDomainScriptHandler;
            }
            public Collection getBeanNames() {
                return Arrays.asList(new String[] {PathConstants.URL_PREFIX + SCADOMAIN_SCRIPT_PATH});
View Full Code Here


        };

        // add the scaDomainScriptHandler to the urlProcessor
        // bit of a hack, there's probably cleaner way to get it registered
        urlProcessor.afterContainerSetup(new Container() {
            public Object getBean(String name) {
                return scaDomainScriptHandler;
            }
            public Collection<?> getBeanNames() {
                return Arrays.asList(new String[] {PathConstants.URL_PREFIX + SCRIPT_PATH});
View Full Code Here

        };

        // add the scaDomainScriptHandler to the urlProcessor
        // bit of a hack, there's probably cleaner way to get it registered
        urlProcessor.afterContainerSetup(new Container() {
            public Object getBean(String name) {
                return scaDomainScriptHandler;
            }
            public Collection getBeanNames() {
                return Arrays.asList(new String[] {PathConstants.URL_PREFIX + SCADOMAIN_SCRIPT_PATH});
View Full Code Here

        };

        // add the scaDomainScriptHandler to the urlProcessor
        // bit of a hack, there's probably cleaner way to get it registered
        urlProcessor.afterContainerSetup(new Container() {
            public Object getBean(String name) {
                return scaDomainScriptHandler;
            }
            public Collection getBeanNames() {
                return Arrays.asList(new String[] {PathConstants.URL_PREFIX + SCADOMAIN_SCRIPT_PATH});
View Full Code Here

        out.print("<p>ContextPath: " + contextPath + "</p>");
        out.print("<p>Current Page: " + webContext.getCurrentPage() + "</p>");

        //ScriptSession scriptSession = webContext.getScriptSession();

        Container container = webContext.getContainer();
        SortedMap<String, Object> beans = new TreeMap<String, Object>();
        SortedMap<String, String> settings = new TreeMap<String, String>();
        SortedMap<String, String> urls = new TreeMap<String, String>();
        for (String name : container.getBeanNames())
        {
            Object bean = container.getBean(name);
            if (name.startsWith("url:"))
            {
                urls.put(name.substring(4), bean.getClass().getName());
            }
            else if (bean instanceof String)
View Full Code Here

     */
    public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException
    {
        ServletContext servletContext = filterConfig.getServletContext();

        Container container = (Container) servletContext.getAttribute(Container.class.getName());
        if (container == null)
        {
            log.error("DwrWebContextFilter can not find ServletContext attribute for the DWR Container. Is DwrServlet configured in this web-application?");
        }

View Full Code Here

            else
            {
                throw new ConversionException(object.getClass());
            }

            Container container = WebContextFactory.get().getContainer();
            boolean preferDataUrlSchema = ContainerUtil.getBooleanSetting(container, "preferDataUrlSchema", false);

            DownloadManager downloadManager;
            if (preferDataUrlSchema && isDataUrlAvailable())
            {
                downloadManager = new DataUrlDownloadManager();
            }
            else
            {
                downloadManager = container.getBean(DownloadManager.class);
            }

            String url = downloadManager.addFileTransfer(transfer);
            return new NonNestedOutboundVariable(url);
        }
View Full Code Here

    @Override
    public int doEndTag() throws JspException
    {
        try
        {
            Container container = ServerContextFactory.get().getContainer();
            ConverterManager converterManager = container.getBean(ConverterManager.class);

            HttpServletRequest request = (HttpServletRequest) pageContext.getRequest();
            HttpServletResponse response = (HttpServletResponse) pageContext.getResponse();
            WebContextFactory.WebContextBuilder contextBuilder = container.getBean(WebContextFactory.WebContextBuilder.class);
            contextBuilder.engageThread(container, request, response);

            try
            {
                if (json)
View Full Code Here

    {
        try
        {
            ServletConfig servletConfig = new FakeServletConfig("test", new FakeServletContext());
            logStartup("DWR:OutOfContainer", servletConfig);
            Container container = createAndSetupDefaultContainer(servletConfig);
            configureContainerFully(container, servletConfig);

            return container;
        }
        catch (ContainerConfigurationException ex)
View Full Code Here

     * @return A setup implementation of DefaultContainer
     * @throws ContainerConfigurationException If the specified class could not be found or instantiated
     */
    public static Container createAndSetupDefaultContainer(ServletConfig servletConfig) throws ContainerConfigurationException
    {
        Container container;

        try
        {
            String typeName = servletConfig.getInitParameter(LocalUtil.originalDwrClassName(Container.class.getName()));
            if (typeName == null)
View Full Code Here

TOP

Related Classes of org.directwebremoting.Container

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.