Package org.onemind.swingweb.resource

Examples of org.onemind.swingweb.resource.Resource


     * @param resp
     * @param object
     */
    private void sendResource(HttpServletRequest req, HttpServletResponse resp, String id)
    {
        Resource res = _manager.getContext().getResource(id);
        if (res != null)
        {
            try
            {
                resp.setContentType(res.getType());
                resp.setStatus(200, "Ok");
                OutputStream out = new BufferedOutputStream(resp.getOutputStream());
                FileUtils.copyStream(res.getInputStream(), out, 1024);
                out.flush();
            } catch (Exception e)
            {
                _logger.throwing(getClass().getName(), "sendResource", e);
            }
View Full Code Here

TOP

Related Classes of org.onemind.swingweb.resource.Resource

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.