Java Server Pages: A Code-Intensive Premium Reference- P19
Số trang: 10
Loại file: pdf
Dung lượng: 182.42 KB
Lượt xem: 11
Lượt tải: 0
Xem trước 2 trang đầu tiên của tài liệu này:
Thông tin tài liệu:
Java Server Pages: A Code-Intensive Premium Reference- P19:Before you begin reading Pure JSP Java Server Pages, you might want to take a look at its basicstructure. This should help you outline your reading plan if you choose not to read the text from cover tocover. This introduction gives you an overview of what each chapter covers.
Nội dung trích xuất từ tài liệu:
Java Server Pages: A Code-Intensive Premium Reference- P19This method is typically called from JspFactory.getPageContext() in order to initialize state.This method is required to create an initial JspWriter. Associate the out name in page scope with thisnewly created object. initialize() returns no value.Parameters javax.servlet.Servlet javax.servlet.ServletRequest javax.servlet.ServletResponse java.lang.String boolean int booleanExceptions Thrown java.io.IOException java.lang.IllegalStateException java.lang.IllegalArgumentExceptionpopBody() Methodpublic abstract JspWriter popBody()The popBody() method returns the previous JspWriter out saved by the matching pushBody(), andupdates the value of the out attribute in the page scope attribute namespace of the PageContext.popBody() has no parameters and throws no exceptions. JspWriterpushBody() Methodpublic abstract BodyJspWriter pushBody()The pushBody() method returns a new BodyJspWriter object, saves the current out JspWriter,and updates the value of the out attribute in the page scope attribute namespace of the PageContext.pushBody() has no parameters and throws no exceptions.Returns BodyJspWriterExceptions Thrown Nonerelease() Methodpublic abstract void release()The release() method resets the internal state of a PageContext, releasing all internal references,and preparing the PageContext for potential reuse by a later invocation of initialize(). This methodis typically called from JspFactory.releasePageContext(). release() has no parameters, returnsno value, and throws no exceptions.removeAttribute(java.lang.String name) Methodpublic abstract void removeAttribute(java.lang.String name)The removeAttribute(java.lang.String name) method removes the object reference associatedwith the specified name. It returns no value and throws no exceptions.Parameters java.lang.StringremoveAttribute(java.lang.String name, int scope) Methodpublic abstract void removeAttribute(java.lang.String name, int scope)The removeAttribute() method removes the object reference associated with the specified name andscope. It returns no value and throws no exceptions. - 181 -Parameters java.lang.String intsetAttribute() Methodpublic abstract void setAttribute(java.lang.String name, java.lang.Object attribute) throws NullPointerExceptionThe setAttribute() method registers the name and object specified with page scope semantics. Itreturns no value.Parameters java.lang.String java.lang.ObjectExceptions Thrown NullPointerExceptionsetAttribute(java.lang.String name, java.lang.Object o, int scope)Methodpublic abstract void setAttribute(java.lang.String name, java.lang.Object o, int scope) throws NullPointerException, java.lang.IllegalArgumentExceptionThe setAttribute() method registers the name and object specified with appropriate scope semantics.It returns no value.Parameters java.lang.String java.lang.Object intExceptions Thrown NullPointerException java.lang.IllegalArgumentExceptionExceptionsThe javax.servlet.jsp package has two exceptions, JspError and JspException. Each has twomethods.JspError Exceptionpublic class JspError extends JspExceptionWhen the JspError exception is caught, output generation should stop and forward the exception toerrorpage.JspError(java.lang.String msg) Methodpublic JspError(java.lang.String msg)The JspError(java.lang.String msg) method is a constructor with a message. It returns no valueand throws no exceptions.Parameters java.lang.String - 182 -JspError() Methodpublic JspError()This method is a default empty constructor. It has no parameters, returns no value, and throws noexceptions.JspException Exceptionpublic class JspException extends java.lang.ExceptionThe JspException exception is a generic exception used by the JSP engine.JspException(java.lang.String msg) Methodpublic JspException (java.lang.String msg)This method is a constructor with a message. It returns no value and throws no exceptions.Parameters java.lang.StringJspException() Methodpublic JspException ()This method is a default empty constructor. It has no parameters, returns no value, and throws noexceptions.Parameters NoneReturns NoneExceptions Thrown NoneChapter 19: The javax.servlet.jsp.tagext PackageOverviewThe JavaServer Pages 1.1 specification provides a portable mechanism for the description of tag libraries.Figure 19.1 contains the javax.servlet.jsp.tagext object model.Figure 19.1: The javax.servlet.jsp.tagext object model. - 183 -ClassesThe eight classes for the definition of JavaServer Pages tag libraries are described in the followingsections. They are BodyJspWriter, Tag, TagAttributeInfo, TagData, TagExtraInfo, TagInfo,TagLibraryInfo, and VariableInfo.BodyJspWriter Classpublic abstract class BodyJspWriter extends JspWriterBodyJspWriter is a JspWriter subclass that can be used to process body evaluations so they can bere-extracted at a later time. It has five methods.BodyJspWriter() Methodprotected BodyJspWriter(int buffersize, boolean autoflush)This method is used to construct a BodyJspWriter. It should only to be used by a subclass.BodyJspWriter() returns no values and throws no exceptions.Parameters int booleanclearBody() Methodpublic void clearBody()The clearBody() method is another implementation of the JspWriter method clear(). The onlydifference is that clearBody() is guaranteed not to throw an exception. clearBody() has noparameters and returns n ...
Nội dung trích xuất từ tài liệu:
Java Server Pages: A Code-Intensive Premium Reference- P19This method is typically called from JspFactory.getPageContext() in order to initialize state.This method is required to create an initial JspWriter. Associate the out name in page scope with thisnewly created object. initialize() returns no value.Parameters javax.servlet.Servlet javax.servlet.ServletRequest javax.servlet.ServletResponse java.lang.String boolean int booleanExceptions Thrown java.io.IOException java.lang.IllegalStateException java.lang.IllegalArgumentExceptionpopBody() Methodpublic abstract JspWriter popBody()The popBody() method returns the previous JspWriter out saved by the matching pushBody(), andupdates the value of the out attribute in the page scope attribute namespace of the PageContext.popBody() has no parameters and throws no exceptions. JspWriterpushBody() Methodpublic abstract BodyJspWriter pushBody()The pushBody() method returns a new BodyJspWriter object, saves the current out JspWriter,and updates the value of the out attribute in the page scope attribute namespace of the PageContext.pushBody() has no parameters and throws no exceptions.Returns BodyJspWriterExceptions Thrown Nonerelease() Methodpublic abstract void release()The release() method resets the internal state of a PageContext, releasing all internal references,and preparing the PageContext for potential reuse by a later invocation of initialize(). This methodis typically called from JspFactory.releasePageContext(). release() has no parameters, returnsno value, and throws no exceptions.removeAttribute(java.lang.String name) Methodpublic abstract void removeAttribute(java.lang.String name)The removeAttribute(java.lang.String name) method removes the object reference associatedwith the specified name. It returns no value and throws no exceptions.Parameters java.lang.StringremoveAttribute(java.lang.String name, int scope) Methodpublic abstract void removeAttribute(java.lang.String name, int scope)The removeAttribute() method removes the object reference associated with the specified name andscope. It returns no value and throws no exceptions. - 181 -Parameters java.lang.String intsetAttribute() Methodpublic abstract void setAttribute(java.lang.String name, java.lang.Object attribute) throws NullPointerExceptionThe setAttribute() method registers the name and object specified with page scope semantics. Itreturns no value.Parameters java.lang.String java.lang.ObjectExceptions Thrown NullPointerExceptionsetAttribute(java.lang.String name, java.lang.Object o, int scope)Methodpublic abstract void setAttribute(java.lang.String name, java.lang.Object o, int scope) throws NullPointerException, java.lang.IllegalArgumentExceptionThe setAttribute() method registers the name and object specified with appropriate scope semantics.It returns no value.Parameters java.lang.String java.lang.Object intExceptions Thrown NullPointerException java.lang.IllegalArgumentExceptionExceptionsThe javax.servlet.jsp package has two exceptions, JspError and JspException. Each has twomethods.JspError Exceptionpublic class JspError extends JspExceptionWhen the JspError exception is caught, output generation should stop and forward the exception toerrorpage.JspError(java.lang.String msg) Methodpublic JspError(java.lang.String msg)The JspError(java.lang.String msg) method is a constructor with a message. It returns no valueand throws no exceptions.Parameters java.lang.String - 182 -JspError() Methodpublic JspError()This method is a default empty constructor. It has no parameters, returns no value, and throws noexceptions.JspException Exceptionpublic class JspException extends java.lang.ExceptionThe JspException exception is a generic exception used by the JSP engine.JspException(java.lang.String msg) Methodpublic JspException (java.lang.String msg)This method is a constructor with a message. It returns no value and throws no exceptions.Parameters java.lang.StringJspException() Methodpublic JspException ()This method is a default empty constructor. It has no parameters, returns no value, and throws noexceptions.Parameters NoneReturns NoneExceptions Thrown NoneChapter 19: The javax.servlet.jsp.tagext PackageOverviewThe JavaServer Pages 1.1 specification provides a portable mechanism for the description of tag libraries.Figure 19.1 contains the javax.servlet.jsp.tagext object model.Figure 19.1: The javax.servlet.jsp.tagext object model. - 183 -ClassesThe eight classes for the definition of JavaServer Pages tag libraries are described in the followingsections. They are BodyJspWriter, Tag, TagAttributeInfo, TagData, TagExtraInfo, TagInfo,TagLibraryInfo, and VariableInfo.BodyJspWriter Classpublic abstract class BodyJspWriter extends JspWriterBodyJspWriter is a JspWriter subclass that can be used to process body evaluations so they can bere-extracted at a later time. It has five methods.BodyJspWriter() Methodprotected BodyJspWriter(int buffersize, boolean autoflush)This method is used to construct a BodyJspWriter. It should only to be used by a subclass.BodyJspWriter() returns no values and throws no exceptions.Parameters int booleanclearBody() Methodpublic void clearBody()The clearBody() method is another implementation of the JspWriter method clear(). The onlydifference is that clearBody() is guaranteed not to throw an exception. clearBody() has noparameters and returns n ...
Tìm kiếm theo từ khóa liên quan:
nhập môn lập trình kỹ thuật lập trình lập trình flash lập trình web ngôn ngữ html lập trình hướng đối tượngGợi ý tài liệu liên quan:
-
Đề cương chi tiết học phần Cấu trúc dữ liệu và giải thuật (Data structures and algorithms)
10 trang 317 0 0 -
Giáo trình Lập trình hướng đối tượng: Phần 2
154 trang 275 0 0 -
Kỹ thuật lập trình trên Visual Basic 2005
148 trang 265 0 0 -
NGÂN HÀNG CÂU HỎI TRẮC NGHIỆM THIẾT KẾ WEB
8 trang 207 0 0 -
101 trang 200 1 0
-
Giới thiệu môn học Ngôn ngữ lập trình C++
5 trang 194 0 0 -
Bài giảng Nhập môn về lập trình - Chương 1: Giới thiệu về máy tính và lập trình
30 trang 166 0 0 -
Luận văn: Nghiên cứu kỹ thuật giấu tin trong ảnh Gif
33 trang 153 0 0 -
Luận văn tốt nghiệp Công nghệ thông tin: Xây dựng website bán hàng nông sản
67 trang 141 0 0 -
Giáo trình nhập môn lập trình - Phần 22
48 trang 138 0 0