精选分类

文章列表

3.4k 3 分钟

# 监听器 Listener # 会话事件 HttpSessionEvent sessionCreated sessionDestroyed getSession() : 获取当前涉及的 Session 对象。 # 会话监听器 HttpSessionListener 用于监听 HttpSession 的创建和销毁事件。 当 Web 容器创建一个新的 HttpSession 时,触发 sessionCreated 。 当 HttpSession 失效(超时或调用 invalidate)时,触发 sessionDestroyed 。 # 示例代码 下面这段代码通过实现...
3k 3 分钟

# 会话管理 HTTP 协议本身是基于请求 / 响应模式的,无状态的协议; 作为 Web 服务器来说,必须能够: 采用一种机制来唯一的表示一个用户(目标一) 同时记录该用户的状态(目标二),即对用户进行会话管理。 # Cookie Cookie 是服务器通知客户端保存键值对的一种技术。客户端有了 Cookie 后,每次请求都发送给服务器。 每个 Cookie 的大小不能超过 4kb 。 # Cookie 常用方法 new Cookie(name: String, value: String) 创建一个 Cookie 对象。 setMaxAge(expiry: int) 设置 Cookie...
8.8k 8 分钟

# 请求 ServletRequest # 处理参数 Parameter 请求来到服务器时,Web 容器会创建 HttpServletRequest 实例来包装请求中的相关信息,HttpservletRequest 定义了取得请求信息的方法。例如,可以使用以下方法来取得请求参数: getParameter(name: String) -> String 指定请求参数名称来取得相应的值 (String),因此可能需要解析为基本类型 (如 Integer) getParameterValues(name: String) ->...
3.2k 3 分钟

# Servlet 类与接口 Servlet 类图 用户请求时序图 # Servlet 接口 定义了 Servlet 的生命周期方法: init(config: ServletConfig) : 初始化 调用:第一个用户的第一次访问 目的是为了在处理客户端请求前完成一些初始化的工作,如建立数据库连接、读取资源文件信息等; service(req: ServletRequest, resp: ServletResponse) : 服务 调用:每一个用户的每一次访问 ++ 用于处理客户端的请求并返回响应对象 destroy() : 销毁 调用:最后一个用户的最后一次访问 当 Web...
495 1 分钟

# Web 基础架构 # 桌面端网络编程的两种模式 C/S (Client/Server): 客户端 / 服务器模式。 优点:交互性强、响应速度快、减轻服务器压力。 缺点:需要安装特定的客户端软件,维护和升级成本高。 B/S (Browser/Server): 浏览器 / 服务器模式。 优点:零安装(有浏览器即可),维护方便,跨平台性好。 缺点:响应速度受网络限制,功能受浏览器限制。 # 基础概念 WWW: World Wide Web(万维网)。 CGI: Common Gateway...
23k 21 分钟

# Chapter 12 Enhancing Decision Making Which of the following statements best describes the business value of improved decision making at all levels of a firm? Improved decision making creates better products. Improved decision making results in a large monetary value for the firm as numerous...
30k 27 分钟

# Chapter 11 Managing Knowledge and Artificial Intelligence Which of the following is the first value-adding step of information system activities in the knowledge management value chain? Feedback Acquire Disseminate Store Apply Which of the following involves where, when, and how to apply...
27k 25 分钟

# Chapter 9 Achieving Operational Excellence and Customer Intimacy: Enterprise Applications From your reading of the chapter's opening case, which of the answers below is not a reason why Lenzing chose JDA's Sales & Operations Planning software? Minimize the environmental impact of...
28k 25 分钟

# Chapter 2 Global E-business and Collaboration Producing a bill of materials is a business process in which of the following functional areas? Finance and accounting Human resources Manufacturing and production Research and development Sales and marketing Which of the following is an example of...
26k 24 分钟

# Chapter 1 Information Systems in Global Business Today Which of the following is not one of the six strategic business objectives that businesses are seeking to achieve when they invest in information systems? Operational excellence Improved decision making Improved community...