Vincent Thinking

          All about Vincent's work and life

            BlogJava :: 首頁 :: 新隨筆 :: 聯系 :: 聚合  :: 管理 ::
            34 隨筆 :: 0 文章 :: 183 評論 :: 0 Trackbacks
          public ? class ?ActionMapperFactory? {
          ????
          ????
          protected ? static ? final ?Log?LOG? = ?LogFactory.getLog(ActionMapperFactory. class );

          ????
          private ? static ? final ?HashMap?classMap? = ? new ?HashMap();

          ????
          public ? static ?ActionMapper?getMapper()? {
          ????????
          synchronized ?(classMap)? {
          ????????????String?clazz?
          = ?(String)?Configuration.get(WebWorkConstants.WEBWORK_MAPPER_CLASS);
          ????????????
          try ? {
          ????????????????ActionMapper?mapper?
          = ?(ActionMapper)?classMap.get(clazz);
          ????????????????
          if ?(mapper? == ? null )? {
          ????????????????????mapper?
          = ?(ActionMapper)?ObjectFactory.getObjectFactory().buildBean(clazz,? null );
          ????????????????????classMap.put(clazz,?mapper);
          ????????????????}


          ????????????????
          return ?mapper;
          ????????????}
          ? catch ?(Exception?e)? {
          ????????????????String?msg?
          = ? " Could?not?create?ActionMapper:?WebWork?will?*not*?work! " ;
          ????????????????LOG.fatal(msg,?e);
          ????????????????
          throw ? new ?RuntimeException(msg,?e);
          ????????????}

          ????????}

          ????}

          }


          明白的告訴我一下,謝謝. 覺的有點問題...
          posted on 2006-05-31 22:55 Vincent Thinking 閱讀(1754) 評論(0)  編輯  收藏 所屬分類: JAVA
          主站蜘蛛池模板: 阿荣旗| 浦北县| 牙克石市| 客服| 兴安盟| 卢龙县| 廉江市| 扎兰屯市| 隆安县| 合江县| 丰宁| 阜新市| 紫金县| 云南省| 泾源县| 河东区| 五大连池市| 永平县| 浑源县| 成安县| 宝坻区| 玉门市| 长顺县| 临朐县| 嘉荫县| 体育| 子洲县| 武陟县| 宁国市| 通道| 清原| 阳新县| 莒南县| 肃宁县| 青神县| 青龙| 金华市| 大邑县| 清河县| 项城市| 大英县|