Is JSF using JSP?

夙愿已清 提交于 2020-08-22 09:37:08

问题


I am learning JSF and I have some questions regarding it. I know JSF is a UI framework for making pages and I am using it at the moment and successfully been able to make zome. However I don't understand if JSF is built on JSP, so to write your own components you need to know JSP. Or is this a completly another technology? I have not a strong foundation in Servlet/JSP programming and I wonder if I need to read anout that first? What are the best places to learn apart from the Core JavaServerFaces book? If i should learn servlet and jsp as well which books should i start reading?


回答1:


As of JSF 2.0, which is part of Java EE 6, released at december 2009 (over 2 years ago already), JSP is been deprecated as view technology and replaced by Facelets, a XML based view technology. See also the Java EE 6 tutorial (emphasis mine):

The term Facelets refers to the view declaration language for JavaServer Faces technology. JavaServer Pages (JSP) technology, previously used as the presentation technology for JavaServer Faces, does not support all the new features available in JavaServer Faces in the Java EE 6 platform. JSP technology is considered to be a deprecated presentation technology for JavaServer Faces. Facelets is a part of the JavaServer Faces specification and also the preferred presentation technology for building JavaServer Faces technology-based applications.

As to preparing the basic knowledge before learning JSF, make sure that you know and understand at least HTTP, HTML, CSS, JavaScript, Servlets and XML. HTTP, because you need to understand its stateless nature. HTML, CSS and JavaScript, because that's what JSF code ultimately produces, especially HTML forms is important, JSF is geared towards form based applications. Servlets, because that's where the JSF framework is built on top of. XML, because that's where Facelets is based on.

See also:

  • Our JSF tag wiki page


来源:https://stackoverflow.com/questions/10259045/is-jsf-using-jsp

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!