锁定老帖子 主题:分享下我的代码生成工具(上传了文档)
精华帖 (0) :: 良好帖 (4) :: 新手帖 (0) :: 隐藏帖 (0)
|
|
---|---|
作者 | 正文 |
发表时间:2010-02-04
Spring Roo目前用这个。。。。反正自己看。。。够用了。。。
|
|
返回顶楼 | |
发表时间:2010-02-04
应该贴上运行环境,最好还是把源码发上来,这样可以共同研究,说不定会成为下一个流利工具
|
|
返回顶楼 | |
发表时间:2010-02-04
整体还是不错,不过对于这种开发辅助工具,不如直接写eclipse的插件了。
|
|
返回顶楼 | |
发表时间:2010-02-04
不管怎样,赞个
|
|
返回顶楼 | |
发表时间:2010-02-04
要是能做成eclispe plugin就好了
|
|
返回顶楼 | |
发表时间:2010-02-04
只支持Windows? 在linux下不支持
14:10:22,724 [ERROR] - [Thread-1] [The Microsoft Windows Look and Feel - com.sun.java.swing.plaf.windows.WindowsLookAndFeel] not supported on this platform javax.swing.UnsupportedLookAndFeelException: [The Microsoft Windows Look and Feel - com.sun.java.swing.plaf.windows.WindowsLookAndFeel] not supported on this platform at javax.swing.UIManager.setLookAndFeel(UIManager.java:501) at javax.swing.UIManager.setLookAndFeel(UIManager.java:558) at com.agile.webdev.util.LookAndFeelManager.setDefaultTheme(LookAndFeelManager.java:13) at com.agile.webdev.SplashWindow.run(SplashWindow.java:95) at java.lang.Thread.run(Thread.java:619) javax.swing.UnsupportedLookAndFeelException: [The Microsoft Windows Look and Feel - com.sun.java.swing.plaf.windows.WindowsLookAndFeel] not supported on this platform at javax.swing.UIManager.setLookAndFeel(UIManager.java:501) at javax.swing.UIManager.setLookAndFeel(UIManager.java:558) at com.agile.webdev.util.LookAndFeelManager.setDefaultTheme(LookAndFeelManager.java:13) at com.agile.webdev.SplashWindow.run(SplashWindow.java:95) at java.lang.Thread.run(Thread.java:619) |
|
返回顶楼 | |
发表时间:2010-02-04
代码生成工具的害处经常会大于好处。前段时间还看见有公司招聘要求有一条:熟悉appfuse,于是我很晕菜。。。
|
|
返回顶楼 | |
发表时间:2010-02-04
neo 写道 只支持Windows? 在linux下不支持
14:10:22,724 [ERROR] - [Thread-1] [The Microsoft Windows Look and Feel - com.sun.java.swing.plaf.windows.WindowsLookAndFeel] not supported on this platform javax.swing.UnsupportedLookAndFeelException: [The Microsoft Windows Look and Feel - com.sun.java.swing.plaf.windows.WindowsLookAndFeel] not supported on this platform at javax.swing.UIManager.setLookAndFeel(UIManager.java:501) at javax.swing.UIManager.setLookAndFeel(UIManager.java:558) at com.agile.webdev.util.LookAndFeelManager.setDefaultTheme(LookAndFeelManager.java:13) at com.agile.webdev.SplashWindow.run(SplashWindow.java:95) at java.lang.Thread.run(Thread.java:619) javax.swing.UnsupportedLookAndFeelException: [The Microsoft Windows Look and Feel - com.sun.java.swing.plaf.windows.WindowsLookAndFeel] not supported on this platform at javax.swing.UIManager.setLookAndFeel(UIManager.java:501) at javax.swing.UIManager.setLookAndFeel(UIManager.java:558) at com.agile.webdev.util.LookAndFeelManager.setDefaultTheme(LookAndFeelManager.java:13) at com.agile.webdev.SplashWindow.run(SplashWindow.java:95) at java.lang.Thread.run(Thread.java:619) 运行环境 的确是 window |
|
返回顶楼 | |
发表时间:2010-02-04
好东西呀,不过生成项目报错了 ,最好有个文档。
Exception occurred during event dispatching: java.lang.StringIndexOutOfBoundsException: String index out of range: -1 at java.lang.String.substring(String.java:1937) at com.agile.webdev.util.FileGenerator.genClassPath(FileGenerator.java:1 122) at com.agile.webdev.view.OpenProjectDialog.getProjectInfo(OpenProjectDia log.java:392) at com.agile.webdev.view.OpenProjectDialog$3.actionPerformed(OpenProject Dialog.java:345) at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:19 95) at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.jav a:2318) at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel .java:387) at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242 ) at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonL istener.java:236) at java.awt.Component.processMouseEvent(Component.java:6263) at javax.swing.JComponent.processMouseEvent(JComponent.java:3267) at java.awt.Component.processEvent(Component.java:6028) at java.awt.Container.processEvent(Container.java:2041) at java.awt.Component.dispatchEventImpl(Component.java:4630) at java.awt.Container.dispatchEventImpl(Container.java:2099) at java.awt.Component.dispatchEvent(Component.java:4460) at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4574 ) at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4238) at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4168) at java.awt.Container.dispatchEventImpl(Container.java:2085) at java.awt.Window.dispatchEventImpl(Window.java:2475) at java.awt.Component.dispatchEvent(Component.java:4460) at java.awt.EventQueue.dispatchEvent(EventQueue.java:599) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThre ad.java:269) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread. java:184) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread. java:178) at java.awt.Dialog$1.run(Dialog.java:1045) at java.awt.Dialog$3.run(Dialog.java:1097) at java.security.AccessController.doPrivileged(Native Method) at java.awt.Dialog.show(Dialog.java:1095) at java.awt.Component.show(Component.java:1563) at java.awt.Component.setVisible(Component.java:1515) at java.awt.Window.setVisible(Window.java:841) at java.awt.Dialog.setVisible(Dialog.java:985) at com.agile.webdev.view.OpenProjectDialog.<init>(OpenProjectDialog.java :112) at com.agile.webdev.view.bar.WDMenuBar.genFileActionPerformed(WDMenuBar. java:221) at com.agile.webdev.view.bar.WDMenuBar$8.actionPerformed(WDMenuBar.java: 192) at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:19 95) at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.jav a:2318) at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel .java:387) at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242 ) at javax.swing.AbstractButton.doClick(AbstractButton.java:357) at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:1 225) at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMen uItemUI.java:1266) at java.awt.Component.processMouseEvent(Component.java:6263) at javax.swing.JComponent.processMouseEvent(JComponent.java:3267) at java.awt.Component.processEvent(Component.java:6028) at java.awt.Container.processEvent(Container.java:2041) at java.awt.Component.dispatchEventImpl(Component.java:4630) at java.awt.Container.dispatchEventImpl(Container.java:2099) at java.awt.Component.dispatchEvent(Component.java:4460) at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4574 ) at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4238) at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4168) at java.awt.Container.dispatchEventImpl(Container.java:2085) at java.awt.Window.dispatchEventImpl(Window.java:2475) at java.awt.Component.dispatchEvent(Component.java:4460) at java.awt.EventQueue.dispatchEvent(EventQueue.java:599) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThre ad.java:269) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread. java:184) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThre ad.java:174) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161) at java.awt.EventDispatchThread.run(EventDispatchThread.java:122) |
|
返回顶楼 | |
发表时间:2010-02-04
以前做过一个报表代码生成工具,用ant,生成java代码之类的东西,用的velocity模板,这样可以由用户自定义生成模板,还算自由点。 简单试了试,你这个是完全写死的,别人没啥用了吧,毕竟每家公司都有自己的技术框架和习惯组合。 实际上mvc三层结构中,只有m那一层适合自动生成(得益于jdbc的metainfo,以及数据库为中心的开发流程),但相关的orm/sqlmap都有完备的工具来辅助,似乎用不着专门写一个。 局限性太大,但是构造这个工具本身的技术是很有价值的,相信总是有大量公司需要做自己的RAD工具,做这种工具很烦——尤其是需要界面的时候。所以如果楼主能把你的东东改造成一个基础平台提供二次开发接口,那就很有市场,说不定可以卖钱哦。当然,这类需求早就出现了,最伟大的实现就是eclipse platform。 所以建议迁移到eclipse ps: 我对swingx和grouplayout的使用比较感兴趣。 一直没正经学习swing,最近有点写gui的机会,正好学学楼主的了。 |
|
返回顶楼 | |