I am revisiting a project and need to limit it to Java 1.4 (unfortunately). I was interested in introducing a MVC framework to improve ease of maintenance in the future.
我正在重新审视一个项目,需要将其限制为Java 1.4(不幸的是)。我有兴趣引入MVC框架以改善未来的易维护性。
Besides Struts 1, what options do I have? The lightweight the framework, the better.
除了Struts 1,我还有什么选择?框架越轻越好。
Not to dismiss Struts off hand, I've just heard a lot of bad things about it. If anyone wants to defend it here, please do so.
不要轻易放弃Struts,我刚刚听到很多关于它的坏事。如果有人想在这里捍卫它,请这样做。
Additionally the framework has to be able to run on Jrun, which may limit my choices. I can not, for example, get Spring MVC to work.
此外,框架必须能够在Jrun上运行,这可能会限制我的选择。例如,我不能让Spring MVC工作。
3 个解决方案
#1
I found this question while looking for something else, so I apologize that this answer may not find you in time.
我在寻找其他东西时发现了这个问题,所以我很抱歉这个答案可能找不到你的时间。
There is a great option for your needs! The MVC framework is Induction, it is written using JDK 1.4. Induction controllers are multi-action, like Spring MVC 2.5, but Induction does not use annotations or XML, the controller get auto-wired by default.
有一个很好的选择,您的需求! MVC框架是Induction,它是使用JDK 1.4编写的。感应控制器是多动作的,如Spring MVC 2.5,但Induction不使用注释或XML,控制器默认自动连接。
Induction is an extremely light-weight and fast MVC framework (7.7K lines) but has many features absent in the major MVC frameworks, such as:
归纳是一个非常轻量级和快速的MVC框架(7.7K行),但在主要的MVC框架中没有许多功能,例如:
- dynamic reloading during development when you change the controllers, views, models
- file uploads so simple (not much different that a string input)
- no configuration required for controllers
- capability to analyze dependencies between your Models, Views and Controllers using your IDE
- regular expression based URL mappings
- best support for managing redirects of any MVC framework
更改控制器,视图和模型时,在开发期间动态重新加载
文件上传如此简单(与字符串输入差别不大)
控制器无需配置
使用IDE分析模型,视图和控制器之间的依赖关系的功能
基于正则表达式的URL映射
管理任何MVC框架重定向的最佳支持
Check out the getting started tutorial here: http://www.inductionframework.org/getting-started-tutorial.html
查看入门教程:http://www.inductionframework.org/getting-started-tutorial.html
Good luck!
#2
Spring MVC is extremely lightweight. You can use as much of Spring, or as little of Spring, as you want.
Spring MVC非常轻巧。您可以根据需要使用尽可能多的Spring或Spring。
#3
Although JSF is hard to understand at the beginning I like it more than Struts 1, in Java 1.4 I used MyFaces to build an application and it worked well for me.
尽管JSF在开始时很难理解,但我比Struts 1更喜欢它,在Java 1.4中我使用MyFaces来构建应用程序,它对我来说很有用。
Also I voted up Spring MVC proposal ;)
我也投了Spring MVC提案;)
#1
I found this question while looking for something else, so I apologize that this answer may not find you in time.
我在寻找其他东西时发现了这个问题,所以我很抱歉这个答案可能找不到你的时间。
There is a great option for your needs! The MVC framework is Induction, it is written using JDK 1.4. Induction controllers are multi-action, like Spring MVC 2.5, but Induction does not use annotations or XML, the controller get auto-wired by default.
有一个很好的选择,您的需求! MVC框架是Induction,它是使用JDK 1.4编写的。感应控制器是多动作的,如Spring MVC 2.5,但Induction不使用注释或XML,控制器默认自动连接。
Induction is an extremely light-weight and fast MVC framework (7.7K lines) but has many features absent in the major MVC frameworks, such as:
归纳是一个非常轻量级和快速的MVC框架(7.7K行),但在主要的MVC框架中没有许多功能,例如:
- dynamic reloading during development when you change the controllers, views, models
- file uploads so simple (not much different that a string input)
- no configuration required for controllers
- capability to analyze dependencies between your Models, Views and Controllers using your IDE
- regular expression based URL mappings
- best support for managing redirects of any MVC framework
更改控制器,视图和模型时,在开发期间动态重新加载
文件上传如此简单(与字符串输入差别不大)
控制器无需配置
使用IDE分析模型,视图和控制器之间的依赖关系的功能
基于正则表达式的URL映射
管理任何MVC框架重定向的最佳支持
Check out the getting started tutorial here: http://www.inductionframework.org/getting-started-tutorial.html
查看入门教程:http://www.inductionframework.org/getting-started-tutorial.html
Good luck!
#2
Spring MVC is extremely lightweight. You can use as much of Spring, or as little of Spring, as you want.
Spring MVC非常轻巧。您可以根据需要使用尽可能多的Spring或Spring。
#3
Although JSF is hard to understand at the beginning I like it more than Struts 1, in Java 1.4 I used MyFaces to build an application and it worked well for me.
尽管JSF在开始时很难理解,但我比Struts 1更喜欢它,在Java 1.4中我使用MyFaces来构建应用程序,它对我来说很有用。
Also I voted up Spring MVC proposal ;)
我也投了Spring MVC提案;)