java - Spring mvc 中有哪些 portlet 类?

标签 java spring web-applications spring-mvc portlet

在 Spring MVC 中似乎有两种平行的类层次结构,一种有 portlet,一种没有。

那是什么?为什么会这样,我应该用什么。

最佳答案

那是因为

In addition to supporting conventional (servlet-based) Web development, Spring also supports JSR-168 Portlet development. As much as possible, the Portlet MVC framework is a mirror image of the Web MVC framework, and also uses the same underlying view abstractions and integration technology.

Spring documentation (Chapter 16. Portlet MVC Framework)提供有关差异的更多信息。

要回答您的最后一个问题:您应该使用 Portlet MVC framework如果您正在开发 portlet(要部署在门户中的 Web 应用程序)。如果您正在开发传统的 Web 应用程序,您应该使用 Web MVC framework .

关于java - Spring mvc 中有哪些 portlet 类?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/722383/

相关文章:

Java避免重复导入(不是继承导入)

java - 为什么我需要 jdbc 和 sqlite java?

spring - 使用curl测试时,Grails Spring Security Rest未经授权(401)

spring - Spring 4.x 是否支持 Mybatis?

java - 使用@MappedSuperclass 而不是@Entity 可以不使用JPA 在数据库中创建表吗?

apache - 从用户启动 Tomcat

java - 实现依赖注入(inject)的最简单方法是什么?

java - 无法调用某些变量

javascript - 与 native 文件系统共享网页中的变量

java - 从预填充 post 参数的 java 程序打开浏览器