zoukankan      html  css  js  c++  java
  • JAVA-JSP内置对象之pageContext对象

    相关资料:
    《21天学通Java Web开发》

    pageContext对象
    1.pageContext对象不但可以用来设置page范围的属性,同样也可以用来设置其他范围属性,
    不过需要指定范围参数。通过pageContext对象还可以获得其他内置对象。

    方法                                                                              返回值                    方法说明
    getException()                                                              Exception              获取当前的exception内置对象
    getOut()                                                                       JspWriter               获取当前的out内置对象
    getPage()                                                                     Object                    获取当前的page内置对象
    getRequest()                                                                ServletRequset      获取当前的request内置对象
    getResponse()                                                             ServletResponse    获取当前的response内置对象
    getServletConfig()                                                        ServletConfig         获取当前的config内置对象
    getServeltContext()                                                     ServletContext       获取当前的application内置对象
    getSession()                                                                HttpSession            获取当前的session内置对象
    getAttribute(String name,int scope)                            Object                    获取指定范围的name属性值
    getAttributeNamesInScope(int scope)                         Enumeration          获取指定范围所有属性名称
    getAttributesScope(String name)                                int                           获取属性名称为name的属性范围
    removeAttribute(String name)                                    void                        移除属性名称为name的 属性
    removeAttribute(String name,int scope)                     void                        移除指定范围的属性名称为name的 属性
    setAttribute(String name,Object value,int scope)       void                        设置指定范围的name属性
    findAttribute(String name)                                          Object                    寻找所有范围的属性名称为name的属性

  • 相关阅读:
    20180209-json&pickle&shelve模块
    20180209-shutil模块
    20180209-sys模块
    20180209-os模块
    20180115-Xcode创建多个工程协同开发
    20180108-递归函数
    20180105-Python中dict的使用方法
    Python-编码这趟浑水
    20171218-编程语言的介绍
    20180119-01-RACSignal的基础
  • 原文地址:https://www.cnblogs.com/FKdelphi/p/7670642.html
Copyright © 2011-2022 走看看