条纹1.5 - 任何方式向系统所有ActionBeans的列表? [英] Stripes 1.5 - any way to ask the system for a list of all ActionBeans?
问题描述
我建立一个应用程序,我有我的默认网页作为的index.jsp',包括℃的名单;条纹:链接...>
标签,链接到我的各种actionBeans(他们defaulthandlers)。
I'm building an application where I have my default webpage as 'index.jsp' which consists of a list of <stripes:link...>
tags, to link out to my various actionBeans (to their defaulthandlers).
由于我的应用程序的发展,并收集更多的actionBeans我要回去,并在一个新的链接到他们补充说:有没有办法自动执行此 - 考虑到条纹框架(我相信)遍历所有actionBeans加载时达 - ?有没有办法询问这些信息的框架
As my application evolves and gathers more actionBeans I'm going back and adding in a new link to them : is there a way to automate this - considering that the stripes framework (I believe) iterates through all the actionBeans when it loads up - is there a way to ask the framework for this information ?
推荐答案
的<一个href=\"http://stripes.sourceforge.net/docs/current/javadoc/net/sourceforge/stripes/controller/ActionResolver.html\"相对=nofollow> ActionResolver
接口有几种方法可以使用,包括<一个href=\"http://stripes.sourceforge.net/docs/current/javadoc/net/sourceforge/stripes/controller/ActionResolver.html#getActionBeanClasses%28%29\"相对=nofollow> getActionBeanClasses()
<一个href=\"http://stripes.sourceforge.net/docs/current/javadoc/net/sourceforge/stripes/controller/StripesFilter.html#getConfiguration%28%29\"相对=nofollow> StripesFilter.getConfiguration()
允许您访问配置对象(因而 ActionResolver
)的静态方法。
下面是如何做到这一点:
Here's how to do it:
StripesFilter.getConfiguration().getActionResolver().getActionBeanClasses()
这篇关于条纹1.5 - 任何方式向系统所有ActionBeans的列表?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!