Java EE 6: JSF vs Servlet + JSP. Should I bother learning JSF?

前端 未结 5 1481
感动是毒
感动是毒 2020-12-24 02:05

I am trying to get familiar with Java EE 6 by reading http://java.sun.com/javaee/6/docs/tutorial/doc/gexaf.html. I am a bit confused about the use of JSF.
Usually, the w

5条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-12-24 02:11

    JSF provide an abstraction layer with several responsibilities, but most important it handles all the messy details of HTML forms and transferring data back and forth between web pages and Java POJO beans (getX, setX methods), which is notoriously difficult to do right.

    It also provides navigation and in the latest incarnation in Java EE 6 rudimentary AJAX support is available allowing for simple updates of the web page as the user inputs data.

    You might find it easier to think of it as a way to avoid writing JavaScript yourself.

提交回复
热议问题