Package javango.http

Examples of javango.http.HttpException


  public void render(HttpServletRequest req, HttpServletResponse resp) throws HttpException {
    try {
      renderToWriter(new OutputStreamWriter(resp.getOutputStream()));
    } catch (IOException e) {
      log.error(e,e);
      throw new HttpException(e);
    }
  }
View Full Code Here


      context.put("latest_poll_list", latest_poll_list);
     
      return renderToResponse("src/main/webapp/templates/index.html", context);
     
    } catch (DaoException e) {
      throw new HttpException(e);
    }
  }
View Full Code Here

      context.put("poll", p);
      context.put("form", form);
                   
      return renderToResponse("src/main/webapp/templates/detail.html", context);
    } catch (DaoException e) {
      throw new HttpException(e);
    }
  }
View Full Code Here

      Map<String, Object> context = new HashMap<String, Object>();
      context.put("poll", p);
     
      return renderToResponse("src/main/webapp/templates/results.html", context);
    } catch (DaoException e) {
      throw new HttpException(e);
    }   
  }
View Full Code Here

        selected_choice.setVotes(votes + 1);
        // due to the way hibernate works this will automatically save when the middleware commits
        return new HttpResponseRedirect("/polls/" + poll_id + "/results/");
      }
    } catch (DaoException e) {
      throw new HttpException(e);
    }
  }
View Full Code Here

TOP

Related Classes of javango.http.HttpException

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.