Examples of HttpBridge


Examples of com.volantis.synergetics.osgi.j2ee.bridge.http.HttpBridge

        HttpServletRequest request = (HttpServletRequest) genericRequest;
        HttpServletResponse response = (HttpServletResponse) genericResponse;

        // Attempt to retrieve the service from OSGi that will dispath requests
        // to servlets registered with the HttpService.
        HttpBridge bridge = (HttpBridge)
                manager.getExportedBridgeService(HttpBridge.class);
        if (bridge == null) {
            response.sendError(HttpServletResponse.SC_NOT_FOUND,
                    "Requested resource '" + request.getRequestURI() +
                    "'could not be found");
            return;
        }

        try {
            // Dispatch the request to the bridge.
            bridge.dispatch(request, response);
        } catch(ServletException e) {
            e.printStackTrace();
            throw e;
        } catch(IOException e) {
            e.printStackTrace();
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.