【发布时间】:2013-06-12 23:03:56
【问题描述】:
我发现如果我有一个 Viewable (jersey) 将模型传递给 JSP,那么访问它的方法是在映射键前面加上 it
例如
index.jsp
<html>
<body>
<h2>Hello World ${it.foo}!</h2>
</body>
</html>
JAX-RS 资源方法:
@GET
@Path("index")
public Viewable index(@Context HttpServletRequest request) {
System.out.println("/INDEX called");
HashMap<String, String> model = new HashMap<String, String>();
model.put("foo","bar");
return new Viewable("/index.jsp", model);
}
我是基于这个资源:http://blog.usul.org/using-jsp-in-a-jersey-jax-rs-restful-application/
但我想知道,it 是什么,它来自哪里,是泽西岛特有的吗?如果是这样,它在哪里记录(很难搜索“它”,因为谷歌倾向于将其从搜索中删除,没有双关语)
在 Java EE 文档中找不到任何提及它的内容。
【问题讨论】: