/*
 * Generated by the Jasper component of Apache Tomcat
 * Version: jetty/9.4.54.v20240208
 * Generated at: 2026-03-12 22:21:47 UTC
 * Note: The last modified time of this file was set to
 *       the last modified time of the source file after
 *       generation to assist with modification tracking.
 */
package org.apache.jsp;

import javax.servlet.*;
import javax.servlet.http.*;
import javax.servlet.jsp.*;

public final class learn_jsp extends org.apache.jasper.runtime.HttpJspBase
    implements org.apache.jasper.runtime.JspSourceDependent,
                 org.apache.jasper.runtime.JspSourceImports {

  private static final javax.servlet.jsp.JspFactory _jspxFactory =
          javax.servlet.jsp.JspFactory.getDefaultFactory();

  private static java.util.Map<java.lang.String,java.lang.Long> _jspx_dependants;

  static {
    _jspx_dependants = new java.util.HashMap<java.lang.String,java.lang.Long>(2);
    _jspx_dependants.put("file:/home/llm/.m2/repository/org/apache/struts/struts2-core/6.4.0/struts2-core-6.4.0.jar", Long.valueOf(1772603570859L));
    _jspx_dependants.put("jar:file:/home/llm/.m2/repository/org/apache/struts/struts2-core/6.4.0/struts2-core-6.4.0.jar!/META-INF/struts-tags.tld", Long.valueOf(1712452520000L));
  }

  private static final java.util.Set<java.lang.String> _jspx_imports_packages;

  private static final java.util.Set<java.lang.String> _jspx_imports_classes;

  static {
    _jspx_imports_packages = new java.util.HashSet<>();
    _jspx_imports_packages.add("javax.servlet");
    _jspx_imports_packages.add("javax.servlet.http");
    _jspx_imports_packages.add("javax.servlet.jsp");
    _jspx_imports_classes = null;
  }

  private volatile javax.el.ExpressionFactory _el_expressionfactory;
  private volatile org.apache.tomcat.InstanceManager _jsp_instancemanager;

  public java.util.Map<java.lang.String,java.lang.Long> getDependants() {
    return _jspx_dependants;
  }

  public java.util.Set<java.lang.String> getPackageImports() {
    return _jspx_imports_packages;
  }

  public java.util.Set<java.lang.String> getClassImports() {
    return _jspx_imports_classes;
  }

  public javax.el.ExpressionFactory _jsp_getExpressionFactory() {
    if (_el_expressionfactory == null) {
      synchronized (this) {
        if (_el_expressionfactory == null) {
          _el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();
        }
      }
    }
    return _el_expressionfactory;
  }

  public org.apache.tomcat.InstanceManager _jsp_getInstanceManager() {
    if (_jsp_instancemanager == null) {
      synchronized (this) {
        if (_jsp_instancemanager == null) {
          _jsp_instancemanager = org.apache.jasper.runtime.InstanceManagerFactory.getInstanceManager(getServletConfig());
        }
      }
    }
    return _jsp_instancemanager;
  }

  public void _jspInit() {
  }

  public void _jspDestroy() {
  }

  public void _jspService(final javax.servlet.http.HttpServletRequest request, final javax.servlet.http.HttpServletResponse response)
      throws java.io.IOException, javax.servlet.ServletException {

    final java.lang.String _jspx_method = request.getMethod();
    if (!"GET".equals(_jspx_method) && !"POST".equals(_jspx_method) && !"HEAD".equals(_jspx_method) && !javax.servlet.DispatcherType.ERROR.equals(request.getDispatcherType())) {
      response.sendError(HttpServletResponse.SC_METHOD_NOT_ALLOWED, "JSPs only permit GET, POST or HEAD. Jasper also permits OPTIONS");
      return;
    }

    final javax.servlet.jsp.PageContext pageContext;
    javax.servlet.http.HttpSession session = null;
    final javax.servlet.ServletContext application;
    final javax.servlet.ServletConfig config;
    javax.servlet.jsp.JspWriter out = null;
    final java.lang.Object page = this;
    javax.servlet.jsp.JspWriter _jspx_out = null;
    javax.servlet.jsp.PageContext _jspx_page_context = null;


    try {
      response.setContentType("text/html;charset=UTF-8");
      pageContext = _jspxFactory.getPageContext(this, request, response,
      			null, true, 8192, true);
      _jspx_page_context = pageContext;
      application = pageContext.getServletContext();
      config = pageContext.getServletConfig();
      session = pageContext.getSession();
      out = pageContext.getOut();
      _jspx_out = out;

      out.write("\n");
      out.write("\n");
      out.write("<!DOCTYPE html>\n");
      out.write("<html>\n");
      out.write("<head>\n");
      out.write("    <meta charset=\"UTF-8\">\n");
      out.write("    <title>Struts2 学习中心</title>\n");
      out.write("    <style>\n");
      out.write("        body { font-family: Arial, sans-serif; max-width: 1000px; margin: 40px auto; padding: 20px; background:#f7f8fa; }\n");
      out.write("        h1 { color: #e74c3c; }\n");
      out.write("        h2 { color: #3498db; border-bottom: 2px solid #3498db; padding-bottom: 10px; }\n");
      out.write("        .card { background: #fff; padding: 20px; border-radius: 12px; margin: 20px 0; box-shadow:0 4px 14px rgba(0,0,0,.06); }\n");
      out.write("        .card h3 { margin-top: 0; }\n");
      out.write("        ul { line-height: 1.9; }\n");
      out.write("        a { color: #3498db; text-decoration: none; }\n");
      out.write("        a:hover { text-decoration: underline; }\n");
      out.write("        .btn { display: inline-block; background: #3498db; color: white; padding: 10px 20px; border-radius: 6px; margin: 5px; }\n");
      out.write("        .btn:hover { text-decoration: none; background: #2980b9; }\n");
      out.write("        .btn-green { background: #27ae60; }\n");
      out.write("        .btn-purple { background: #9b59b6; }\n");
      out.write("        code { background: #eee; padding: 2px 6px; border-radius: 3px; }\n");
      out.write("        .lab { background:#fff7e6; border-left:4px solid #fa8c16; padding:15px; border-radius:8px; margin:20px 0; }\n");
      out.write("        .quick-tools { display:flex; gap:10px; flex-wrap:wrap; margin-top:10px; }\n");
      out.write("        .grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(280px,1fr)); gap:16px; }\n");
      out.write("    </style>\n");
      out.write("</head>\n");
      out.write("<body>\n");
      out.write("    <h1>🎓 Struts2 学习中心</h1>\n");
      out.write("\n");
      out.write("    <div class=\"lab\">\n");
      out.write("        <strong>🧪 学习任务卡</strong>\n");
      out.write("        <ul>\n");
      out.write("            <li>先点“拦截器演示”，观察执行统计和链路顺序</li>\n");
      out.write("            <li>再点“计算器”，故意输入非法值体验 Struts2 校验</li>\n");
      out.write("            <li>最后点“用户管理”，理解 Action + JSP + 表单提交流程</li>\n");
      out.write("        </ul>\n");
      out.write("        <div class=\"quick-tools\">\n");
      out.write("            <a class=\"btn btn-purple\" href=\"interceptor\">直接去拦截器实验</a>\n");
      out.write("            <a class=\"btn\" href=\"calc\">直接去计算器实验</a>\n");
      out.write("            <a class=\"btn btn-green\" href=\"user\">直接去用户管理实验</a>\n");
      out.write("        </div>\n");
      out.write("    </div>\n");
      out.write("\n");
      out.write("    <div class=\"grid\">\n");
      out.write("        <div class=\"card\">\n");
      out.write("            <h3>👋 最小闭环</h3>\n");
      out.write("            <p>从 <code>/hello</code> 开始，看 Action 如何返回 JSP 页面。</p>\n");
      out.write("            <a class=\"btn\" href=\"hello\">打开 Hello</a>\n");
      out.write("        </div>\n");
      out.write("        <div class=\"card\">\n");
      out.write("            <h3>🔢 表单与校验</h3>\n");
      out.write("            <p>用计算器理解参数绑定、校验失败回显、成功结果显示。</p>\n");
      out.write("            <a class=\"btn\" href=\"calc\">打开计算器</a>\n");
      out.write("        </div>\n");
      out.write("        <div class=\"card\">\n");
      out.write("            <h3>🛡️ 拦截器机制</h3>\n");
      out.write("            <p>学习 Struts2 最核心的增强机制：日志、计时、限流、监控。</p>\n");
      out.write("            <a class=\"btn btn-purple\" href=\"interceptor\">打开拦截器实验</a>\n");
      out.write("        </div>\n");
      out.write("        <div class=\"card\">\n");
      out.write("            <h3>👥 CRUD 业务流</h3>\n");
      out.write("            <p>通过用户管理体验列表页、表单页、重定向和状态更新。</p>\n");
      out.write("            <a class=\"btn btn-green\" href=\"user\">打开用户管理</a>\n");
      out.write("        </div>\n");
      out.write("        <div class=\"card\">\n");
      out.write("            <h3>🧪 OGNL / 参数绑定实验</h3>\n");
      out.write("            <p>通过真正可交互的表单观察 Struts2 的字段绑定、嵌套对象绑定和集合绑定。</p>\n");
      out.write("            <a class=\"btn btn-purple\" href=\"ognl\">打开 OGNL 实验室</a>\n");
      out.write("        </div>\n");
      out.write("        <div class=\"card\">\n");
      out.write("            <h3>⚠️ 验证与错误流实验</h3>\n");
      out.write("            <p>学习为什么校验失败不会直接 500，而是回到 input 页面并显示字段级错误。</p>\n");
      out.write("            <a class=\"btn\" href=\"validation\">打开验证实验室</a>\n");
      out.write("        </div>\n");
      out.write("        <div class=\"card\">\n");
      out.write("            <h3>🚀 AJAX 异步交互</h3>\n");
      out.write("            <p>学习Struts2如何处理AJAX请求，返回JSON数据，实现无刷新交互和实时数据更新。</p>\n");
      out.write("            <a class=\"btn purple\" href=\"ajax\">打开AJAX演示</a>\n");
      out.write("        </div>\n");
      out.write("        <div class=\"card\">\n");
      out.write("            <h3>📁 文件上传</h3>\n");
      out.write("            <p>演示单文件和多文件上传，学习文件类型验证、大小限制和文件处理流程。</p>\n");
      out.write("            <a class=\"btn green\" href=\"upload\">打开文件上传</a>\n");
      out.write("        </div>\n");
      out.write("    </div>\n");
      out.write("\n");
      out.write("    <h2>📚 学习路径</h2>\n");
      out.write("    <div class=\"card\">\n");
      out.write("        <h3>1. MVC 架构</h3>\n");
      out.write("        <ul>\n");
      out.write("            <li><strong>Model:</strong> Action 类 + JavaBean</li>\n");
      out.write("            <li><strong>View:</strong> JSP + Struts 标签库</li>\n");
      out.write("            <li><strong>Controller:</strong> StrutsPrepareAndExecuteFilter</li>\n");
      out.write("        </ul>\n");
      out.write("    </div>\n");
      out.write("\n");
      out.write("    <div class=\"card\">\n");
      out.write("        <h3>2. 拦截器机制</h3>\n");
      out.write("        <ul>\n");
      out.write("            <li><code>Interceptor</code> 接口: init() → intercept() → destroy()</li>\n");
      out.write("            <li><code>interceptor-stack</code>: 组合多个拦截器</li>\n");
      out.write("            <li>执行顺序: 责任链模式（先入后出）</li>\n");
      out.write("        </ul>\n");
      out.write("    </div>\n");
      out.write("\n");
      out.write("    <div class=\"card\">\n");
      out.write("        <h3>3. OGNL 与标签库</h3>\n");
      out.write("        <ul>\n");
      out.write("            <li><code>&lt;s:property value=\"name\"/&gt;</code> - 输出属性</li>\n");
      out.write("            <li><code>&lt;s:iterator value=\"list\"&gt;</code> - 遍历集合</li>\n");
      out.write("            <li><code>&lt;s:form&gt;</code> + <code>&lt;s:textfield&gt;</code> - 表单绑定</li>\n");
      out.write("        </ul>\n");
      out.write("    </div>\n");
      out.write("\n");
      out.write("    <div class=\"card\">\n");
      out.write("        <h3>4. 你当前项目里有哪些实验</h3>\n");
      out.write("        <ul>\n");
      out.write("            <li><strong>Hello：</strong>最小 Action/JSP 映射</li>\n");
      out.write("            <li><strong>Calculator：</strong>参数绑定 + 校验 + 错误回显</li>\n");
      out.write("            <li><strong>Interceptor：</strong>理解自定义拦截器与请求链</li>\n");
      out.write("            <li><strong>User CRUD：</strong>模拟真实业务增删改查</li>\n");
      out.write("        </ul>\n");
      out.write("    </div>\n");
      out.write("\n");
      out.write("    <p><a href=\"/\">← 返回首页</a></p>\n");
      out.write("</body>\n");
      out.write("</html>\n");
    } catch (java.lang.Throwable t) {
      if (!(t instanceof javax.servlet.jsp.SkipPageException)){
        out = _jspx_out;
        if (out != null && out.getBufferSize() != 0)
          try {
            if (response.isCommitted()) {
              out.flush();
            } else {
              out.clearBuffer();
            }
          } catch (java.io.IOException e) {}
        if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
        else throw new ServletException(t);
      }
    } finally {
      _jspxFactory.releasePageContext(_jspx_page_context);
    }
  }
}
