PortletURLTag168.java 文件源码

java
阅读 21 收藏 0 点赞 0 评论 0

项目:portals-pluto 作者:
/**
 * Provides a list of all static PortletMode available in the specifications by using introspection
 * 
 * @return Hashtable
 */
private static Hashtable<String, Object> getDefinedPortletModes() {
   Hashtable<String, Object> portletModes = new Hashtable<String, Object>();
   Field[] f = PortletMode.class.getDeclaredFields();

   for (int i = 0; i < f.length; i++) {
      if (f[i].getType().isAssignableFrom(javax.portlet.PortletMode.class)) {
         try {
            portletModes.put(f[i].get(f[i]).toString().toUpperCase(), f[i].get(f[i]));
         } catch (IllegalAccessException e) {
         }
      }
   }

   return portletModes;
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号