??xml version="1.0" encoding="utf-8" standalone="yes"?>亚洲成a人片在线不卡一二三区,亚洲&http://www.tkk7.com/iamtin/category/7425.htmlYou are coming a long way, baby~Thinking, feeling, memory...zh-cnTue, 27 Feb 2007 11:55:38 GMTTue, 27 Feb 2007 11:55:38 GMT60使用WebWork和RomeL暴露RSShttp://www.tkk7.com/iamtin/archive/2006/06/05/50596.htmlTinTinMon, 05 Jun 2006 14:25:00 GMThttp://www.tkk7.com/iamtin/archive/2006/06/05/50596.htmlhttp://www.tkk7.com/iamtin/comments/50596.htmlhttp://www.tkk7.com/iamtin/archive/2006/06/05/50596.html#Feedback8http://www.tkk7.com/iamtin/comments/commentRss/50596.htmlhttp://www.tkk7.com/iamtin/services/trackbacks/50596.htmlWebWork的result实现非常实用Q它很好的解决了View渲染的灵zL问题。这才是MVC模式的优势所在,而像JSF那样帮定JSP的MVC吃不到q个甜头了。说WebWork2是Model 2 MVC的巅峰就在这些灵zȝ地方?br />闲扯q个不是主要目的。现在Rome是Java下最常用的RSS包,最q消息似乎要转入Apache的Abdera合ƈ变成更强大的聚合引擎。用Rome生成和解析RSS都很方便。今天讨Z下用ROMEl网站生成RSSQƈ通过WebWork2的Result机制渲染?br />最初是从WebWork的Cookbook上看到的RomeResult的文章,一看就会,我这里其实不q是举个详细点的例子Q注意我使用的是WebWork 2.2.2和Rome 0.8Q?br />http://wiki.opensymphony.com/display/WW/RomeResult
参考了和东的这BlogQ利用rome写rss feed生成E序Q?br />http://hedong.3322.org/newblog/archives/000051.html

首先创徏RomeResultc:

/**
 * 
 
*/
package  com.goldnet.framework.webwork.result;

import  java.io.Writer;

import  org.apache.log4j.Logger;

import  com.opensymphony.webwork.ServletActionContext;
import  com.opensymphony.xwork.ActionInvocation;
import  com.opensymphony.xwork.Result;
import  com.sun.syndication.feed.synd.SyndFeed;
import  com.sun.syndication.io.SyndFeedOutput;

/**
 * A simple Result to output a Rome SyndFeed object into a newsfeed.
 * 
@author  Philip Luppens
 * 
 
*/
public   class  RomeResult  implements  Result {
 
private   static   final   long  serialVersionUID  =   - 6089389751322858939L ;

 
private  String feedName;

 
private  String feedType;

 
private   final   static  Logger logger  =  Logger.getLogger(RomeResult. class );

 
/*
  * (non-Javadoc)
  * 
  * @see com.opensymphony.xwork.Result#execute(com.opensymphony.xwork.ActionInvocation)
  
*/
 
public   void  execute(ActionInvocation ai)  throws  Exception {
  
if  (feedName  ==   null ) {
   
//  ack, we need this to find the feed on the stack
   logger
     .error(
" Required parameter 'feedName' not found.  "
       
+   " Make sure you have the param tag set and  "
       
+   " the static-parameters interceptor enabled in your interceptor stack. " );
   
//  no point in continuing ..
    return ;
  }

  
//  don't forget to set the content to the correct mimetype
  ServletActionContext.getResponse().setContentType( " text/xml " );
  
//  get the feed from the stack that can be found by the feedName
  SyndFeed feed  =  (SyndFeed) ai.getStack().findValue(feedName);

  
if  (logger.isDebugEnabled()) {
   logger.debug(
" Found object on stack with name ' "   +  feedName  +   " ':  "
     
+  feed);
  }
  
if  (feed  !=   null ) {

   
if  (feedType  !=   null ) {
    
//  Accepted types are: rss_0.90 - rss_2.0 and atom_0.3
    
//  There is a bug though in the rss 2.0 generator when it checks
    
//  for the type attribute in the description element. It's has a
    
//  big 'FIXME' next to it (v. 0.7beta).
    feed.setFeedType(feedType);
   }
   SyndFeedOutput output 
=   new  SyndFeedOutput();
   
// we'll need the writer since Rome doesn't support writing to an outputStream yet
   Writer out  =   null ;
   
try  {
    out 
=  ServletActionContext.getResponse().getWriter();
    output.output(feed, out);
   } 
catch  (Exception e) {
    
//  Woops, couldn't write the feed ?
    logger.error( " Could not write the feed " , e);
   } 
finally  {
    
// close the output writer (will flush automatically)
     if  (out  !=   null ) {
     out.close();
    }
   }

  } 
else  {
   
//  woops .. no object found on the stack with that name ?
   logger.error( " Did not find object on stack with name ' "   +  feedName
     
+   " ' " );
  }
 }

 
public   void  setFeedName(String feedName) {
  
this .feedName  =  feedName;
 }

 
public   void  setFeedType(String feedType) {
  
this .feedType  =  feedType;
 }

}

E序很简单。实CResult接口Q寻找一个与feedName参数匚w的SyndFeed实例Q然后{换ؓ指定的feedTypecdQ然后通过rome的SyndFeedOutput输出到Response厅R?br />然后我们l我们的WebWork配置romeResult?br />在xwork.xml中配|:

< package  name ="default"  extends ="webwork-default" >
  
< result-types >
   
< result-type  name ="feed"  class ="com.goldnet.framework.webwork.result.RomeResult" />
  
</ result-types >
  
< interceptors >
  
<!--  然后是你的那些inteceptor配置{?/span> -->

q样我们qxwork配置了一个叫做feed的resultQ它是我们的romeResult?br />然后我们实现一个类Q来试一下这个romeResult?br />

/**
 *
 
*/
package  com.goldnet.webwork.action.news;

import  com.opensymphony.xwork.ActionSupport;

import  com.sun.syndication.feed.synd.SyndCategory;
import  com.sun.syndication.feed.synd.SyndCategoryImpl;
import  com.sun.syndication.feed.synd.SyndContent;
import  com.sun.syndication.feed.synd.SyndContentImpl;
import  com.sun.syndication.feed.synd.SyndEntry;
import  com.sun.syndication.feed.synd.SyndEntryImpl;
import  com.sun.syndication.feed.synd.SyndFeed;
import  com.sun.syndication.feed.synd.SyndFeedImpl;

import  org.apache.commons.logging.Log;
import  org.apache.commons.logging.LogFactory;

import  java.util.ArrayList;
import  java.util.Date;
import  java.util.List;


/**
 * 
@author  Tin
 *
 
*/
public   class  TestFeedCreateAction  extends  ActionSupport {
    
private   static   final   long  serialVersionUID  =   - 2207516408313865979L ;
    
private   transient   final  Log log  =  LogFactory.getLog(TestFeedCreateAction. class );
    
private   int  maxEntryNumber  =   25 ;
    
private  String siteUrl  =   " http://127.0.0.1 " ;
    
private  SyndFeed feed  =   null ;

    
public  TestFeedCreateAction() {
        
super ();
    }

    @Override
    
public  String execute() {
        List
< News >  newsList  =  getNewsList();

        
if  (log.isDebugEnabled()) {
            log.debug(
" Geting feed! and got news  "   +  newsList.size()  +
                
"  pieces. " );
        }

        feed 
=   new  SyndFeedImpl();

        feed.setTitle(converttoISO(
" 试中的新闻pȝ " ));
        feed.setDescription(converttoISO(
" 试中的新闻pȝQ测试Rome Result " ));
        feed.setAuthor(converttoISO(
" 试Tin " ));
        feed.setLink(
" http://www.justatest.cn " );

        List
< SyndEntry >  entries  =   new  ArrayList < SyndEntry > ();
        feed.setEntries(entries);

        
for  (News news : newsList) {
            SyndEntry entry 
=   new  SyndEntryImpl();
            entry.setAuthor(converttoISO(news.getAuthor()));

            SyndCategory cat 
=   new  SyndCategoryImpl();
            cat.setName(converttoISO(news.getCategory()));

            List
< SyndCategory >  cats  =   new  ArrayList < SyndCategory > ();
            cats.add(cat);
            entry.setCategories(cats);

            SyndContent content 
=   new  SyndContentImpl();
            content.setValue(converttoISO(news.getContent()));

            List
< SyndContent >  contents  =   new  ArrayList < SyndContent > ();
            contents.add(content);
            entry.setContents(contents);
            entry.setDescription(content);
            entry.setLink(siteUrl 
+   " /common/news/displayNews.action?id= "   +
                news.getId());
            entry.setTitle(converttoISO(news.getTitle()));
            entry.setPublishedDate(news.getPublishDate());
            entries.add(entry);
        }

        
return  SUCCESS;
    }

    
private   static  String converttoISO(String s) {
        
try  {
            
byte [] abyte0  =  s.getBytes( " UTF-8 " );

            
return   new  String(abyte0,  " ISO-8859-1 " );
        } 
catch  (Exception exception) {
            
return  s;
        }
    }

    
private  List < News >  getNewsList() {
        List
< News >  newsList  =   new  ArrayList < News > ();

        
for  ( int  i  =   0 ; i  <  maxEntryNumber; i ++ ) {
            News news 
=   new  News();
            news.setTitle(
" 试标题 "   +  i);
            news.setContent(
                
" <p>试内容试内容<span style=\ " color:red\ " >试内容</span></p> " );
            news.setPublishDate(
new  Date());
            news.setId(
new  Long(i));
            news.setAuthor(
" Tin " );
            newsList.add(news);
        }

        
return  newsList;
    }

    
/**
     * 
@return  Returns the maxEntryNumber.
     
*/
    
public   long  getMaxEntryNumber() {
        
return  maxEntryNumber;
    }

    
/**
     * 
@param  maxEntryNumber The maxEntryNumber to set.
     
*/
    
public   void  setMaxEntryNumber( int  maxEntryNumber) {
        
this .maxEntryNumber  =  maxEntryNumber;
    }

    
/**
     * 
@param  siteUrl The siteUrl to set.
     
*/
    
public   void  setSiteUrl(String siteUrl) {
        
this .siteUrl  =  siteUrl;
    }

    
/**
     * 
@return  Returns the feed.
     
*/
    
public  SyndFeed getFeed() {
        
return  feed;
    }

    
private   class  News {
        
private  Long id;
        
private  String title;
        
private  String content;
        
private  Date publishDate;
        
private  String author;
        
private  String category;

        
/**
  * Getter/Setter都省略了Q用了内部c,是图个方便
  * 本意是模仿我们常怋用的PojoQ大家的实现都不一P我突单,里面其实可以有复杂类型的
  
*/
    }
}

真是不好意思,Getter/Setter占了大部分地Ҏ省略M。逻辑很简单,是把我们的POJO影射到Feed的模型上面,q程很简单。我留下了几个参数可以在外面讄Q?br />maxEntryNumber昄的feed的条敎ͼ链接生成时用的SiteUrlQ当然也可以通过request获取?br />下面我们配置我们的ActionQ注意^时我们可能用DAO生成newsListQ而不是我q个写死的getNewsList()ҎQ此时可能需要配合Springq行IOC的设|,我们q里省略掉?br />下面是我们这个Action的xwork配置Q?/p>

< package  name ="news"  extends ="default"  namespace ="/news" >
  
< action  name ="feed"  class ="com.goldnet.webwork.action.news.TestFeedCreateAction" >
   
<!--  每次生成15条rss feed  -->
   
< param  name ="maxEntryNumber" > 15 </ param >
   
<!--  链接的前~Q我们用Weblogic?001Q也怽的是8080  -->
   
< param  name ="siteUrl" > http://127.0.0.1:7001 </ param >
   
<!--  result是feed  -->
   
< result  name ="success"  type ="feed" >
    
<!--  feed名字是feedQ对应我们这个Action中的那个SyndFeed的实例的名字feedQ别忘记写getter  -->
    
< param  name ="feedName" > feed </ param >
    
<!--  制定生成的feed的类型,我这里选择rss_2.0  -->
    
<!--  rome 0.8支持atom_0.3、atom_1.0、rss_1.0、rss_2.0、rss_0.90、rss_0.91、rss_0.91、rss_0.91U、rss_0.92、rss_0.93、rss_0.94  -->
    
< param  name ="feedType" > rss_2.0 </ param >
   
</ result >
  
</ action >
</ package >

OKQ配|完毕后讉K/news/feed.action可以访问到q个feed了。倒入你的feedDeamonQ看看,是不是非常简单?
不过需要考虑两个地方Q一个是~码问题Q看了和东说的中文问题,本没当回事,l果生成qQ我们项目全部用UTF-8Q,然后q是转了一下。没有研IROME源代码,感觉xml不应该有UTF-8q会q的问题呀Q也许还需要看看是否是讄不到位。还有就是对于feed如果增加了权限认证则讉K比较ȝQ用feedDeamonq样的客L无法访问到了,因ؓ它不会显C登陆失败后昄的登陆页面,也许放feedp开放一点吧Q当然还是有变通放案的Q?br />和动例子里面的rome 0.7和现在的rome 0.8相比QApi已经发生了不变化,唉,开源要代码E_q真难?br />p些,到q里Q粗陋了:D



Tin 2006-06-05 22:25 发表评论
]]>
WebWork 2.2.2中文上传q问题[临时解决Ҏ] http://www.tkk7.com/iamtin/archive/2006/03/30/38365.htmlTinTinThu, 30 Mar 2006 13:40:00 GMThttp://www.tkk7.com/iamtin/archive/2006/03/30/38365.htmlhttp://www.tkk7.com/iamtin/comments/38365.htmlhttp://www.tkk7.com/iamtin/archive/2006/03/30/38365.html#Feedback10http://www.tkk7.com/iamtin/comments/commentRss/38365.htmlhttp://www.tkk7.com/iamtin/services/trackbacks/38365.html使用jakarta commons-upload?
升?.2.2后发C传中文会q?
l过跟踪发现在com.opensymphony.webwork.dispatcher.DispatcherUtils的prepare(HttpServletRequest request, HttpServletResponse response)Ҏ?
2.2.1->2.2.2时这个方法发生了非常的的变化?
2.2.1Ӟ 
public void prepare(HttpServletRequest request, HttpServletResponse response) { 
        
if (encoding != null) { 
            
try { 
                request.setCharacterEncoding(encoding); 
            } 
catch (Exception e) { 
                LOG.error(
"Error setting character encoding to '" + encoding + "' - ignoring.", e); 
            } 
        } 

        
if (locale != null) { 
            response.setLocale(locale); 
        } 

        
if (paramsWorkaroundEnabled) { 
            request.getParameter(
"foo"); // simply read any parameter (existing or not) to "prime" the request 
        } 
    }

2.2.2Ӟ
public void prepare(HttpServletRequest request, HttpServletResponse response) { 
        String encoding 
= null
        
if (Configuration.isSet(WebWorkConstants.WEBWORK_I18N_ENCODING)) { 
            encoding 
= Configuration.getString(WebWorkConstants.WEBWORK_I18N_ENCODING); 
        } 

        Locale locale 
= null
        
if (Configuration.isSet(WebWorkConstants.WEBWORK_LOCALE)) { 
            locale 
= LocalizedTextUtil.localeFromString(Configuration.getString(WebWorkConstants.WEBWORK_LOCALE), request.getLocale()); 
        } 

        
if (encoding != null && !MultiPartRequest.isMultiPart(request)) { 
            
try { 
                request.setCharacterEncoding(encoding); 
            } 
catch (Exception e) { 
                LOG.error(
"Error setting character encoding to '" + encoding + "' - ignoring.", e); 
            } 
        } 

        
if (locale != null) { 
            response.setLocale(locale); 
        } 

        
if (paramsWorkaroundEnabled) { 
            request.getParameter(
"foo"); // simply read any parameter (existing or not) to "prime" the request 
        } 
    }


我看了jira没有发现encoding != null && !MultiPartRequest.isMultiPart(request)q个判断的意义。但是它会造成对multiPartRequest的encoding判断p|Q中文就会ؕ码?
所以时的解决Ҏ是将判断ҎQ?
if (encoding != null)

听说WW的Jira已经不接受新issue了,不知是否真的Q?Crying or Very sad


Tin 2006-03-30 21:40 发表评论
]]>
Java Web 框架的“甜点?/title><link>http://www.tkk7.com/iamtin/archive/2006/03/30/WebFrameworkSweetSpots.html</link><dc:creator>Tin</dc:creator><author>Tin</author><pubDate>Thu, 30 Mar 2006 08:28:00 GMT</pubDate><guid>http://www.tkk7.com/iamtin/archive/2006/03/30/WebFrameworkSweetSpots.html</guid><wfw:comment>http://www.tkk7.com/iamtin/comments/38276.html</wfw:comment><comments>http://www.tkk7.com/iamtin/archive/2006/03/30/WebFrameworkSweetSpots.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.tkk7.com/iamtin/comments/commentRss/38276.html</wfw:commentRss><trackback:ping>http://www.tkk7.com/iamtin/services/trackbacks/38276.html</trackback:ping><description><![CDATA[ <p> <font size="6"> <strong>Jave Web Framework Sweet Spots</strong> </font> <br /> <font size="5"> <strong>Java Web 框架的“甜点?/strong> </font> </p> <p>q是一很有趣的文档,所以摘要一下,其实cM阅读W记Q好像是3/25发布的:</p> <p>不知怎么译Sweet SpotsQ难道翻译ؓ甜处、甜头、蜜炏V蜜I_</p> <p>q时Z对以下h的采访:<br />JSF  Jacob Hookom<br />RIFE  Geert Bevin<br />Seam  Gavin King<br />Spring MVC Rob Harrop<br />Spring Web Flow Rob Harrop and Keith Donald<br />Stripes  Tim Fennell<br />Struts Action 1 Don Brown<br />Tapestry Howard Lewis Ship<br />Trails  Chris Nelson<br />WebWork  Patrick Lightbody<br />Wicket  Eelco Hillenius</p> <p>原文在此Q?a >http://www.virtuas.com/articles/webframework-sweetspots.html</a></p> <p> <font size="6"> <strong> <font size="5">JSF(Jacob Hookom)</font> <br /> </strong> </font>1、你认ؓ你的framework的“甜点”在哪里Q他最适合哪种cd的项目?<br />当你希望览器程序像桌面E序一样工作的时候,你可以遵循标准ƈ获得大量W三Ҏ持。它致力于降低复杂度。它允许你不与view和特定的action、参C递、状态传递、渲染打交道可以进行高质量的开发,不管是否使用工具?br />2、它不适合于什么样的场景?在这些场景你推荐什么fremeworkQ它是哪个?<br />它不适合大规模的、只读(其实指读ZQ的|站。在q种情况推荐StrutsQ因为知识库丰富Q应该指文档和用LQ?br />3、在下面提到的framework中,你试验过他们么?如果试验q,你比较喜Ƣ哪个?你不喜欢哪个Q?br />SeamQ?br />优点Q非常简单直?br />~点Q对于大目q于单;没有模块化开发的好例?br />StrutsQ?br />优点Q巨大的文档和用LQ跟着它没?br />~点Q状?行ؓ的分过于教条化<br />WebWorkQ?br />优点Q比Struts易于使用<br />~点Q复杂的UI难于l护QUI代码q于复杂QJSF作者对action Framework都攻击这一点)<br />TapestryQ?br />优点Q概忉|颖;可以应付复杂的UI<br />~点Q对于一个组件化QJSF主要竞争ҎQ,它依然依附于page/action的概?br />4、你的framework的未来会怎样Q对于用户开发会有什么方便用的变化Q你会原生支持Ajax么?你们计划支持它了么?<br />他认为JSFq个标准下这些应该有W三Ҏ供。JSF(2.0)会提供“Partial Faces Request”,它是Ajax实现。JSF也会增强annotationl徏~程?br />5、有对你们的framework的传a需要澄清么Q如果有Q是哪个Q?br />很多JSF书都拿Struts作ؓҎ。他认ؓq不能体现JSF的特炏V他认ؓStruts和WebWork能做到的JSF也能做到?br />6、你对Ruby on Rails的看法如何?<br />它与WebWork一样好用,它的CoCQConvention over ConfigrationQ和脚手枉常好用。他认ؓCoC可以被应用在MframeworkQ他认ؓq是RoR最大的优点。他q认为RoR会走上其它framework的\Q复杂性等Q,因ؓZ需要自q扩展?/p> <p> <font size="5"> <strong>RIFE(Geert Bevin)</strong> <br /> </font> <strong>1、你认ؓ你的framework的“甜点”在哪里Q他最适合哪种cd的项目?</strong> <br />你可以付?0%的工作量Q得到其它framework?0%的……,它是一个full-stack frameworkQ如RoRQ。它吸收了成熟的分层框架的架构,q将共同的优Ҏ集在一赗提供了web continuationQPOJO驱动的CRUD生成Q可扩展的基于组建的架构Q无session的状态控ӞxREST作ؓAPIQ双向无逻辑模版引擎Q集成了内容控制框架QCMSQ)。每个层ơ的l徏提供了可复用性(AOPQsiteQsub-siteQpageQwidgetQportlet{)。适合于团队快速开发公共Web目Q适合喜欢开发可复用lg的h?br /><strong>2、它不适合于什么样的场景?在这些场景你推荐什么fremeworkQ它是哪个?</strong><br />团队中的每个人都有其它framework的知识,难于培训他们。开发状态相关的服务器端WeblgQ而不是用RIA或Ajaxd现。第三方支持很重要的情况下(可怜RIFE用户还不大Q。他推荐q种情况下用JSF。或者在XMLZ要发布Ş式的情况下,推荐Cocoon?br /><strong>3、在下面提到的framework中,你试验过他们么?如果试验q,你比较喜Ƣ哪个?你不喜欢哪个Q?/strong><br />他试验过WebWorkQJSFQWicket。他喜欢WebWork的简单,但是不喜Ƣ它的模版方式(tag的templateQ应该)Q它也不提供lg装。他认ؓJSF的工h持非常吸引h。Wicket的纯Java实现很不错,可惜XML配置很不爽?br /><strong>4、你的framework的未来会怎样Q对于用户开发会有什么方便用的变化Q你会原生支持Ajax么?你们计划支持它了么?</strong><br />关于AjaxQRIFE刚刚集成了DWRQ而且选定以后也用这个。集成DojoQScriptaculousQPrototype都很Ҏ集成q来?br /><strong>5、有对你们的framework的传a需要澄清么Q如果有Q是哪个Q?/strong><br />q些错误理念Q?、RIFE的XML配置J琐 2、RIFE是continuations server 3、RIFE重新造轮子没有提供新鲜东?4、RIFE的模版语法很y脚q于单和业余 5、RIFE是基于request的framework 6、RIFE的功能太多,学习曲线陡峭<br /><strong>6、你对Ruby on Rails的看法如何?</strong><br />RoR对JavaC֌的冲击非常棒Q元~成也得C信Q。RoR没什么特D之处,也没有从Ruby语言L很多?br />我讨厌:它的模版。PartialsQRoR中的lgQ。URL的分散处理。Active Record提供了从数据库schema而来的DSLQ但是却不是从domain model而来。没有l10n和i18n支持。手动状态{换。不能在JVMq行Q……)。实际上脚手架生成了实际代码。Ruby~少工具和IDE?/p> <p> <strong> <font size="6"> <font size="5">Seam(Gavin King)</font> <br /> </font>1、你认ؓ你的framework的“甜点”在哪里Q他最适合哪种cd的项目?</strong> <br />拥有丰富用户交互体验的应用。方便实现多H口的操作,回退的支持,单窗口多工作区,无状态浏览。对商务程QBPMQ的集成是独一无二的。Seam方便使用数据驱动的ORM。遵循JSF和EJB3Q多d支持Q多H口/多工作区Q,BPM的领先解x案?br /><strong>2、它不适合于什么样的场景?在这些场景你推荐什么fremeworkQ它是哪个?</strong><br />不适合只是数据从数据库显C到|页的应用,q时应该使用PHP或RoR。不适合需要设计特别的HTMLlg的情况,此时应该选用Tapestry或Wicket。还在用JDK1.4的h们。还有那些喜ƢStruts的hQ嘿嘿,够狠Q?br /><strong>3、在下面提到的framework中,你试验过他们么?如果试验q,你比较喜Ƣ哪个?你不喜欢哪个Q?/strong><br />JSFQ喜Ƣ他的事?交互模型。喜Ƣ他的EL和模型绑定。不喜欢那么多XMLQؓ什么没有annotationQ。创qcontrols太难了?br />TapestryQ非常好。form验证是它的杀手锏Q模版方式很有创意。不q非ZPOJO的组件模型则让我对它失去兴趣?br />RIFEQ这个东西很怪,但是有创业也有趣。我惌一步学习。如果学习先要自Ҏ?D<br />StrutsQ这个东西的模型viewl定太复杂了。东西已l过时了?br />WebWorkQ比Struts好一点,不过也过时了。XWork曄是个很好的实玎ͼ不过现在也过时了?br /><strong>4、你的framework的未来会怎样Q对于用户开发会有什么方便用的变化Q你会原生支持Ajax么?你们计划支持它了么?</strong><br />Portal支持。远E框架Seam Remoting FrameworkQAjaxQ。模版消息的工具支持。以后还要集成ESBQ计划引擎和异步支持?br /><strong>5、有对你们的framework的传a需要澄清么Q如果有Q是哪个Q?/strong><br />q些都不是真的:JSF不能处理GET requests。JSF post后无法redirect。JSF不能与REST共存?br /><strong>6、你对Ruby on Rails的看法如何?</strong><br />它是PHP的很好替代品。如果它有一个正l一点的持久化层它就可以和Java竞争了?/p> <p> <font size="6"> <strong> <font size="5">Spring MVC(Rob Harrop)和Spring Web Flow(Rob Harrop and Keith Donald)</font> </strong> </font> <br /> <strong>1、你认ؓ你的framework的“甜点”在哪里Q他最适合哪种cd的项目?</strong> <br />Spring MVCQ?br />E_可扩展,支持了i18n、文件上传、异常处理,q些E_的支持给开发者坚实的工作基础。是最佛_践,告诉你怎么做是最好的。与Spring集成Q领先的IoCq生支持。支持,SpringC֌z跃和庞大。Struts开发者可以^滑过渡。适合多种目Q可选的多种resultcd?br />Spring Web FlowQ?br />内置d处理引擎Q支持线性处理过E中的持l状态。抽象,减少开发的x炏V适合多种目cdQ插件支持Spring MVC、Struts、JSF{?br /><strong>2、它不适合于什么样的场景?在这些场景你推荐什么fremeworkQ它是哪个?</strong><br />Spring MVCQ不适合需要组件化开发的场景。它是一个request驱动的MVC。那些场景推荐JSF或Tapestry?br />Spring Web FlowQ处理线性页面流Q不适合一般的“自由浏览”。当然Spring Web Flow可以与request驱动或者组仉动共存?br /><strong>3、在下面提到的framework中,你试验过他们么?如果试验q,你比较喜Ƣ哪个?你不喜欢哪个Q?/strong><br />Spring框架支持Struts和JSF集成?br /><strong>4、你的framework的未来会怎样Q对于用户开发会有什么方便用的变化Q你会原生支持Ajax么?你们计划支持它了么?</strong><br />Spring MVCQ简化JSP标签。更多的MVC配置schema。CoC风格的默认控制器、URL影射、viewQ学习Rails和Stripes的优炏V增强数据绑定和验证Q支持范型绑定)。Portlet支持。Spring也要接受AjaxQ用DWR库?br />Spring Web FlowQ一大堆Q关心的可以自己看…?br /><strong>5、有对你们的framework的传a需要澄清么Q如果有Q是哪个Q?/strong><br />Spring MVC难于配置。在Spring 2.0Q将会改善,可以使用自己定义的基于schema的配|?br /><strong>6、你对Ruby on Rails的看法如何?</strong><br />Spring MVCQRoR非常有趣。不q现在就拿出来用q有点幼E。这里D了个例子Q关于变量的复数形式的处理,RoR会用这LCoC风格来处理变量listQ而Spring MVC也实验了U种风格Q但是受到的l果却很差。h们认语的复数很古怪,没有一定的规则Q所以会带来混ؕQ如Qperson -> peopleQ。所以Spring MVC设计了变?List的命名,personList更加明确Q虽然这样不P但更好用。就是说Spring MVC要取其精华去其糟_?/p> <p> <font size="6"> <strong> <font size="5">Stripes(Tim Fennell)</font> </strong> </font> <br /> <strong>1、你认ؓ你的framework的“甜点”在哪里Q他最适合哪种cd的项目?</strong> <br />与Spring MVC、WebWork{相同。它提供高质量action驱动的框架的同时Q尽量简化配|,增进开发效率。Stripes适合复杂的数据交互的场合。这U情况下l定验证的强就完全体现出来了,能够很好的处理form和map转换{?br /><strong>2、它不适合于什么样的场景?在这些场景你推荐什么fremeworkQ它是哪个?</strong><br />所有的action驱动的framework都适合用户在非Ajax驱动的情况下在一个页面进行松兌Qloosely relatedQ和无状态交互的情况。适合每次都刷新的面。管理多H口间持l状态的应用会比较麻烦,此时应该选择JSF。不q我认ؓ90%以上的WebE序都是前者,JSF只适合剩下的那9%QAJAX对于理无状态UI更加适合。客L不需要AJAXQ则可以看看WicketQ它更加单?br /><strong>3、在下面提到的framework中,你试验过他们么?如果试验q,你比较喜Ƣ哪个?你不喜欢哪个Q?/strong><br />用过Struts、WebWork、Spring MVC。其中Struts做过商业目Q不q这个东西带来的ȝq比带来的效率提升要多。它认ؓq些MVC都有三个~点Q暴露了q多的复杂性给可发者。没有提供够的开发便利性,没有提供_多的错误和提CZ息,也没有date格式化等的便利Q其实有Q。稳当太差?br /><strong>4、你的framework的未来会怎样Q对于用户开发会有什么方便用的变化Q你会原生支持Ajax么?你们计划支持它了么?</strong><br />1.3要加入InteceptorQ实现AOP功能。验证系l要加强。支持Ajax。我q在L一个好的Ajax/javascript库?br /><strong>5、有对你们的framework的传a需要澄清么Q如果有Q是哪个Q?/strong><br />q些观点Q?、Stripes使用了annotation代替XMLQ只是换汤不换药Q由于元数据更接q代码,所以修攚w认的配置非常方便Q不像XML那样复杂Q这是实质的变化?、Annotation意味着你只能有一套配|:我认?0%的action都有自己的一套配|!Stripes会根据承关pd找AnnotationsQ子cȝannotation会覆盖父cȝQ因为像validation都是可以l承的,如果特别需要还可以覆盖。这样很合理。在1.3中允许validationsZUI事gq行。它向后兼容Q不需要可以不用?br /><strong>6、你对Ruby on Rails的看法如何?</strong><br />我认为JavaC֌有很多可以从RoR学习的地斏VStripes学习了RoR的前端部分,开发者可以减配|量。但是RoR的RHTML让我惛_了以前的JSP中؜qscriptlet。而后面的ActiveRecord是一个很好的理念Q实现的也很好。ActiveRecord比Hibernate{复杂的ORM工具要容易理解,因ؓq样的特点RoR才引起了q么大的波澜?/p> <p> <font size="5"> <strong>Struts Action 1(Don Brown)</strong> <br /> </font> <strong>1、你认ؓ你的framework的“甜点”在哪里Q他最适合哪种cd的项目?</strong> <br />文档和用户基Q书c和背后的支持。容易雇ChQ也Ҏ扑ַ作)。虽然其他项目的理念比这个要先进Q但是这些不什么。实际上QWeb层是很容易也很直接的?br /><strong>2、它不适合于什么样的场景?在这些场景你推荐什么fremeworkQ它是哪个?</strong><br />如果你需要portlets或者复杂的面Q显C很多东西)Q那么Struts要么无法工作要么太枯燥。这U情况你需要一个基于组件的frameworkQ如JSF、Tapestry/Wicket?br />3<strong>、在下面提到的framework中,你试验过他们么?如果试验q,你比较喜Ƣ哪个?你不喜欢哪个Q?/strong><br />q些我基本都试验q,他们每个都工作的很不错?br /><strong>4、你的framework的未来会怎样Q对于用户开发会有什么方便用的变化Q你会原生支持Ajax么?你们计划支持它了么?</strong><br />Struts Action 2ZWebWork2Q很快会开始。现在已l支持Ajax了,我们在寻找更加容易的开发方式,JSF支持QStruts ShaleQ,continuation支持Q还有支持更多的脚本语言QBSF扩展脚本撰写ActionQ?br /><strong>5、有对你们的framework的传a需要澄清么Q如果有Q是哪个Q?/strong><br />Struts太过时了Q而且也不P难于使用。但是你可以自己修改或者扩展它。我认ؓ团队对于你的限制q大于framework对你的限制?br /><strong>6、你对Ruby on Rails的看法如何?</strong><br />不需要D&D工具Q旨在帮助开发h员提高开发效率的好例子。我们在Action 2中将学习它的先进理念?/p> <p> <font size="6"> <strong> <font size="5">Tapestry(Howard Lewis Ship)</font> </strong> </font> <br /> <strong>1、你认ؓ你的framework的“甜点”在哪里Q他最适合哪种cd的项目?</strong> <br />我想Tapestry对于中等规模或者大规模的应用会带来很多好处Q甚至你可以在单面的应用程序中获得好处Q。这里有允许你创建新的组件的良好工具。Tapestry不关心数据从哪里来,很多“项目类型”都Z切面QaspectQ(如CRUD vs. RSS feed vs. etc.Q。我认ؓTapestry非常Ҏ与IoC集成QHiveMind或与SpringQ,方便q行试?br /><strong>2、它不适合于什么样的场景?在这些场景你推荐什么fremeworkQ它是哪个?</strong><br />我在其它Java framework中没有找到到ZTapestry的优炏V但是对于RoRQ我自己没有使用q用,很难说RoR中的目应该是什么样子。我没有仔细ҎqRIFEQ它看v来受了RoR影响Q尤其是cMActiveRecord的数据访问层。但是如果你的应用需要特定的URL格式Q那么在Tapestry中奋战胜不大?br /><strong>3、在下面提到的framework中,你试验过他们么?如果试验q,你比较喜Ƣ哪个?你不喜欢哪个Q?/strong><br />在这两年来我没怎么试qTapestry以外的东ѝ我没怎么学习RoRQ因为时间太有限了?br /><strong>4、你的framework的未来会怎样Q对于用户开发会有什么方便用的变化Q你会原生支持Ajax么?你们计划支持它了么?</strong><br />Tapestry 4.0有很好的Ajax支持Q通过Tacos库。而Tapestry 4.1q要q一步强化这斚w的支持?br />Tapestry 5.0提供了明昄改进Q没有abstractc(Tapestry的怪癖:Q。没有强q的l承关系。对属性进行annotation而不是方法。没有XMLQ只有模版和annotaions。只能类装蝲Q自动寻扄的变化。最化APIQ超annotaion。面向方面(Aspect-orientedQ模块构造,使用mix-ins?br /><strong>5、有对你们的framework的传a需要澄清么Q如果有Q是哪个Q?/strong><br />Tapestry 3.0q不Ҏ试Q?.0改善了一些。Tapestry只是个hUQ实际上我们有很多活跃的贡献者。Tapestry的学习曲UK场陡峭。它只有漂亮的模版实玎ͼ实际上Tapestry的特点在于状态管理(允许对象存储状态,而不是多U程的单例来理requests之间的游d持久状态)<br /><strong>6、你对Ruby on Rails的看法如何?</strong><br />很有影响力。但是模版的实现非常丑陋。我听到了很多意见,关于RoR的优~点。基于我的基本理解,q些观念对Tapestry 4产生了媄响(它对Tapestry 5影响更深Q?br />RoR意味着限制了你的选择Q如果你选择RoR那么p旬它的实践QCoC..Q,看v来你的钱会花的恨倹{这些类似Microsoft的哲学。而Java更崇给你更宽松的选择Q不限定你用的工具Q但是暧昧的说这需要你对你的工L解更深。不仅对TapestryQ还对于JEE、Springq写entire stack的框Ӟ需要从RoR学习Q不仅提供工Pq需要提供整套的解决Ҏ?/p> <p> <font size="6"> <strong> <font size="5">Trails(Chris Nelson)</font> </strong> </font> <br /> <strong>1、你认ؓ你的framework的“甜点”在哪里Q他最适合哪种cd的项目?</strong> <br />Trails的应用程序只需要Web界面和持久化的domain model可以了。Trailsl你的domain model快速的提供一个界面,除了POJO自己不需要附加的代码。Trails允许你修改界面的外观和行为,包括验证、i18n、安全。这些都不需要java代码生成Q不喜欢代码生成的h应该感觉很舒适?br /><strong>2、它不适合于什么样的场景?在这些场景你推荐什么fremeworkQ它是哪个?</strong><br />Trails讲究够用好。它允许你快速交付,问问你的客户Q“这样够好么Q”。这会改变你的工作流E,当然q不是可以覆盖所有需求的解决Ҏ。当UI需求很高,Trails没有优势。我认ؓTrails适合于؜合的应用Q对于管理员他们只需要够用就好,那么可以用Trails。其它的部分我们可以订制开发,我们在用Tapestry、Hibernate、Spring来实现这些部分,Trails正是Z它们。对于非交互的应用,Trails也不适合Q如报表应用Q可以考虑Eclipse BIRT?br />3<strong>、在下面提到的framework中,你试验过他们么?如果试验q,你比较喜Ƣ哪个?你不喜欢哪个Q?/strong><br />我用Struts很多。它曄是伟大的framework。主要的~陷是它不能自动帮定数据到domain model。我也研I过JSFQ它比Struts强,但是自定义组建非帔R。Tapestry非常便于自定义组建,其对于建立高阶lgQ有其它lgl成的)非常方便QTrails正在使用它?br /><strong>4、你的framework的未来会怎样Q对于用户开发会有什么方便用的变化Q你会原生支持Ajax么?你们计划支持它了么?</strong><br />对于Trails来说我们站在巨h的肩膀上。Tapestry在ajax功能作了很多努力Q所以Trails也不难与其共舞。但是我们需要创建更多的例子来演C些。我们也致力于让TrailsҎ介入到已l进行的目中。以后Trailsq要加入Z实例的安全(instance-based securityQ(目前正在使用Z角色的role-basedQ,q有method invocation?br /><strong>5、有对你们的framework的传a需要澄清么Q如果有Q是哪个Q?/strong><br />Trails是对RoR的移植。Trails的名字来自Rails。它是基于Rails的理念,但不是对它的UL?br /><strong>6、你对Ruby on Rails的看法如何?</strong><br />我认为我们有很多需要从RoR学习的地方,那将帮助我们享受开发WebE序的惬意?/p> <p> <font size="6"> <strong> <font size="5">WebWork(Patrick Lightbody)</font> </strong> </font> <br /> <strong>1、你认ؓ你的framework的“甜点”在哪里Q他最适合哪种cd的项目?</strong> <br />一般来_WebWork一般适合的团队Q它们愿意保持一双脏手,学习开元工具如何用。WebWork不面向“轮椅程序员”,那些人只喜欢拖拽式的开发。WebWorkl花旉学习它的人回报。例如,直到输入和输出的人(阅读了参考文档,那样很好Q能够容易的创徏ActionMapper和Configuration实现来提供“惯例”代曉K|(CoCQ的方便。我最q的例子中,URL是这样?project/123/suite/456/test/create”媄到“com.autoriginate.actions.project.suite.test.CreateAction”,然后自动的传递参敎ͼprojectId=123、suiteId=456。而Result是“[action].jsp”或者“[action]-[result].jsp”,也可以通过annotation来配|?br />也就是说QWebWork是你的应用程序framework中的最佛_工具。在q种情况以外也很好,但是目前不算最佳的“甜点”?br />除去q些一般的QWebWork对于正在创徏需要插件和扩展的品的人是必备的。例如JIRA、Confluence、Jive Forums。因为WebWork支持q泛的模版语aQVelociy和FreeMarkerQ,完整的tag支持Q模块写好后非常Ҏ插入。一个jar包就可以包括所有的action和viewQ得益于ftl的classpath支持Q。最l的效果很好Q在Confluence中你可以通过理界面上传一个jarQ这个plug-in׃自动部v。这是因为AtlassianQConfluence、Jira的小l)非常了解q个frameworkQƈ且作了很多的贡献?br /><strong>2、它不适合于什么样的场景?在这些场景你推荐什么fremeworkQ它是哪个?</strong><br />与其它action framework相同QWebWork在控制状态和wizards上比较弱。如果你写了很多长的wizardsQJSF可能是比较好的解x案。我q想_文档q需要改善(参考文档还不错Q但是教E、cookbooks和FAQq比较差Q,如果没有一个WebWork高手作ؓ目领队Q新手可能会敬而远之?br />对于非常单的E序Q我推荐使用单的JSP或者Spring MVCQ如果用h受Spring的话。但是ȝ来说Q我认ؓ在action framework中WebWork是最好的?br /><strong>3、在下面提到的framework中,你试验过他们么?如果试验q,你比较喜Ƣ哪个?你不喜欢哪个Q?br /></strong>我试验过RIFE、Spring MVC、Struts、Spring Web FlowQ还有一点点Tapestry。我发现RIFE的概念很优秀Q但是它的实C怎么栗不难想象Geertq是使用“m_”作为字D늚前缀。它看v来不像Java。模版难住了我,所以就没有l箋看?br />Spring MVCq可以,但是它是一个非常简单的framework实现。WebWork的数据绑定(WebWork世界中称为类型{换)要强多了Q而且是自动的Q而Spring需要自己写property editorsQ。在Spring中的view替换支持泰有限了Q而WebWork中的UI tags在Spring中压Ҏ有提供。Spring中你可以使用JSP 2.0L的写自己的tagQ但是不支持其它的语a?br />Spring Web FlowQXML让我抓狂。太q火了,不管Keith的主张,它“不支持M的Web framework”。这个web framwork回避掉了WebWork、Spring MVC、Struts或者其它framework中的99%。我倒不是说q是个坏LQ但是我应该诚实的说它是一个完整的框架?br />Tapestry很优雅,但是HTML属性(jwcidQ惹人厌。我接受q种理念Q且实践中这会带来一些好处(Shale也有怼的地方)。但是实际上Q我发现“HTML/CSS开发者”和“app开发者”一般是同一个hQTapestry架讑֦此。实际上Q由于Ajax的推动,我想来多的“程序逻辑”会被嵌入到UIQ这L话,Tapestry的模型就不那么适宜了?br /><strong>4、你的framework的未来会怎样Q对于用户开发会有什么方便用的变化Q你会原生支持Ajax么?你们计划支持它了么?</strong><br />在Struts Action 2.0我们希望Q更好的文档。支持标准(如果可以Q我们希望用JSTL代替OGNLQ但是首先要保证不会有功能损失)。增强AJAX支持Q提供更多的widgetsQ如自动完成。解除配|地狱;提供更多的选择Q如我们开始所说的CoC?br /><strong>5、有对你们的framework的传a需要澄清么Q如果有Q是哪个Q?/strong><br />他需要很多的配置Q我已经演示q,通过CoC风格Q它可以做的比Rails更好QRails的管理部允许内嵌controllersQ?br /><strong>6、你对Ruby on Rails的看法如何?</strong><br />非常重要的一ҎQ我要说RoR不能与大多数的frameworkҎQ除了RIFE和Seam。对比RoR和WebWorkq当于ҎHibernate和JDBC。一个是full stackQ另一个只是stack中的一部分?br />另一个重要的问题QDHH是个怪胎Q但是聪明的怪胎。它的高效率无可争辩Q它被称为Rails?br />好的Q我们不说这个,随便说说别的Q?br />我用Rails创徏了一个小的app。我把它扔掉q很快用Java重写了。我认ؓRails可以让你的app中的80%快速完成;而剩下的20%比前?0%需要花的时间还多。当然程序开发就是这栗脚手架非常P其是ActiveRecord在运行时改变cR但是后来你需要写UI、自定义的验证规则,自定义安全媄等{。一个基于CRUD的app能够?0分钟内运行ƈ不意味着你能以这个速度完成它?br />Rails的web framework部分相比于WebWork很可怕。实际上Ҏ无法比较。它的实现更接近于Spring MVC的简单功能?br />完整的stack非常。他们在q方面做得很好,q里Javaq有差距需要追赶。WebWork是web stackQ但是持久化解决Ҏq不定。所以最大的问题在于即WebWork和SiteMesh提供了如配置动态读取和动态类reloadingQSpring、iBatis和Hibernateq不提供。它们至需要提供配|重d后才可以发展出类似Rails那样的功能。类似的QHibernate和iBatis对WebWork{的h提供的支持不够。对于一个类Q我可以不需要再xwork.xml中进行配|,但是持久化引擎ƈ不允许我们这样做。当q些功能能够同时具备Q没准一个complete stack的框架就会推出?br />要求??0倍是愚蠢的。可靠的工程师都知道开发品的时候最大的警力都花费在构思代码上Q而不是书写代码。定义需求,获取反馈Q市场定位,定义数据库结构,映射用户接口。不用什么语aQ你需要思考很长时间。没有语a或者框架能够提升思考的速度?br />最后,Rails提供了:用脚本语a良好实现的stack。Python、Perl其是PHP中的其它框架q没有成熟。我认ؓ“PHP猴子”们q有很多事情要做Q他们通常不是很有才干的工E师。(可能我翻译错误了Q希望纠正)。在脚本语言中提供良好的框架Qh们能够实现设计精良的appq的到回报(因ؓ脚本语言的特点)。不只是“管理代曉K|CoC”甚x集成stackQJava需要的是立d出变化的能力。很多Java开源领袖认为“修改web.xml”的重新载入是一U方法。这U智力游戏应该结束了。我们不仅仅需要配|文件和cȝ重新载入Q我们需要社区给Sun_的压力,使其能够在下一代的JVM中提供热插拔QHotSwapQ的能力。或者,更加复杂的程序模型,如OSGiQ需要进一布被C֌所接受。当然我q不希望走那条\Uѝ?/p> <p> <font size="5"> <strong>Wicket(Eelco Hillenius)</strong> <br /> </font>1<strong>、你认ؓ你的framework的“甜点”在哪里Q他最适合哪种cd的项目?</strong><br />我认为有5点:Wicket是以代码Z心的Q可以在view层进行OO~程。组件是完全自管理的Q容易创建和重用。概늚分离是清晰的也是的。干净的模版。开发׾~性大-像OO一栗?br /><strong>2、它不适合于什么样的场景?在这些场景你推荐什么fremeworkQ它是哪个?<br /></strong>Wicket不适合UI很简单且只读的场合。这旉面脚本更加适合Q比如JSPQ或者JSF。如果你需要无限的可׾~性,你可能需要状态无关的实现。从1.2版开始,Wicket也有无状态页面的概念Q这样可伸羃性与其它framework差不多了?br /><strong>3、在下面提到的framework中,你试验过他们么?如果试验q,你比较喜Ƣ哪个?你不喜欢哪个Q?/strong><br />JSFQ?br />优点Q基于组件。工业背景。工h持。一些扩展让他更Ҏ使用。它允许你从传统JSP升到JSF?br />~点Q它~少其它API的优雅。以JSPZ心。配|很多而且代码很难看。有很多U实现。它让我回忆起EJB1/2Q以厂商Z心等{?br />RIFEQ没用过Q说了一大堆?br />SeamQ不是一个真正的Web framework。类似JSF扩展。如果用EJB/JSF/JBossl合Q这个选择很好。但是不遵@JSR 227/235?br />TapestryQ很好,4.0版本好了很多。我把它推荐l我所工作的公司。Wicket更加以编Eؓ中心。而Tapestry更加pragmatic?br />TrailsQ从来没用过?br />Spring Web FlowQframework本n很好Q但是我不喜Ƣ它的stacking。如果用工作,我希望选择一个如jBMP的方案。我也不喜欢以流Z心的解决ҎQ认样很q程化?br />WebWork、Spring MVC、StrutsQModel 2的frameworkp透了。我用过几年Q也对Maverick贡献q代码,但是我彻底失d了。Model 2 framework太过E化了,q些E序员不知道怎么用OO~程。我宁可雇䄦一个Swing~程的h也不会去选择一个用Model 2 framework~程的hQ因为Swing~程的h写的E序一般更漂亮。……如果让我从q些Model 2 framework中挑一个出来,我选择StripesQ它抛弃了model 2中的一些不好的斚w?br /><strong>4、你的framework的未来会怎样Q对于用户开发会有什么方便用的变化Q你会原生支持Ajax么?你们计划支持它了么?</strong><br />我们会支持Java5。我们会增强Spring支持Q复杂的权限认证支持Q和Z角色的参考实玎ͼq会提供原生AJAX支持QURL加蝲Qnice URLsQ,无状态页{?br />我们的市场占有率不高Q但是用L在提高。我正在写“Wicket In Action”(Manning出版Q正在筹划中Q今q夏天会出版?br /><strong>5、有对你们的framework的传a需要澄清么Q如果有Q是哪个Q?/strong><br />关于伸羃性的问题是第一位的。程序的可׾~型一般是由数据库性能差或者缓存策略查询优化ƈ发等问题。服务器端可伸羃性ƈ不一定不可扩展,可以通过集群来l。…?br /><strong>6、你对Ruby on Rails的看法如何?</strong><br />我喜Ƣ我看到的RubyQ如果我有时间我q会仔细把玩它。如果不是Wicket的问题,我希望更多的实践RoR。…?/p> <img src ="http://www.tkk7.com/iamtin/aggbug/38276.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.tkk7.com/iamtin/" target="_blank">Tin</a> 2006-03-30 16:28 <a href="http://www.tkk7.com/iamtin/archive/2006/03/30/WebFrameworkSweetSpots.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>Webwork 2.2.2新增的ww:date的用?/title><link>http://www.tkk7.com/iamtin/archive/2006/03/28/37865.html</link><dc:creator>Tin</dc:creator><author>Tin</author><pubDate>Tue, 28 Mar 2006 12:00:00 GMT</pubDate><guid>http://www.tkk7.com/iamtin/archive/2006/03/28/37865.html</guid><wfw:comment>http://www.tkk7.com/iamtin/comments/37865.html</wfw:comment><comments>http://www.tkk7.com/iamtin/archive/2006/03/28/37865.html#Feedback</comments><slash:comments>2</slash:comments><wfw:commentRss>http://www.tkk7.com/iamtin/comments/commentRss/37865.html</wfw:commentRss><trackback:ping>http://www.tkk7.com/iamtin/services/trackbacks/37865.html</trackback:ping><description><![CDATA[ <p>今天览WW的WikiQ结果无意发现ww:date标签的用法,挠头一想以前没有见q呀Q仔l一看原来是2006/3/21才加上的?br />会头看看目发现用的ww 2.2.1中没有这个标{,心想是不是发布新版本了?<br />果不出所料!发现OPENSYMPHONY已经发布2.2.2了?br />不过2.2.2是在Opensymphony下的最后一个版本了Q以后的版本׃以Struts Action 2.0的Ş式发布了Q而后者今q?月才发布Q中间的日子估计只能靠nightly build了?br />说说变化Q发现增加了RichTextEditorQ经考察是我们熟悉的FCK Editor。发现还增加了nifty cornersQ这是一个不用images的圆角容器(css+jsQ,估计用在了某个theme里面。还有J2SE5的支持也更加完善Q现在已l可以支持泛型Collection的反(无需-conversion文g了)Q还支持annotation风格的validation声名Q如此像Stripes那样的Web框架没什么可吹嘘的了Q。其它的变化请参考他们的ReleaseNotes?br /><a >http://www.opensymphony.com/webwork/wikidocs/Release%20Notes.html</a></p> <p>说说新添加的ww:date标签。很多朋友可能都认ؓww:property输出date比较不如意,以前很多解决Ҏ感觉都不够灵zRWW肯定察觉了,新增加的ww:date把玩了一下发现非常好用,所以推荐给大家?br />语法非常单:<br />nameQ你取值的ognl表达?br />niceQ是否用易读(readable notationsQ的模式Q其实就是类似conflunce里面昄旉的方式,cM“in 2 hours, 14 minutes?br />formatQ就是我们常用的旉formatQ例如“yyyy-MM-dd hh:mm?br />idQ就是HTML中的元素id</p> <p>使用h如下Q官方的例子Q?br /><ww:date name="person.birthday" format="dd/MM/yyyy" /><br />按照“dd/MM/yyyy”格式显C?br /><ww:date name="person.birthday" format="%{getText('some.i18n.key')}" /><br />format定义到i18n文g中的方式Q这个很常用:D<br /><ww:date name="person.birthday" nice="true" /><br />使用易读Qreadable notationsQ的模式<br /><ww:date name="person.birthday" /><br />使用默认的格式输?/p> <p>其中昄的规则如下:<br />1、如果制定了nice="true"则优先以易读Qreadable notationsQ的模式昄<br />2、如果nice="false"则按照指定的format昄<br />3、如果上面两个属性都没有指定Q则从默认的资源文g中寻找webwork.date.formatq个i18n的keyQ按照它昄<br />4、如果还没有扑ֈ则按照DateFormat.MEDIUM格式昄<br />5、特别之处:如果从ValueStack没有扑ֈ|则默认显C空白(而不是nullQ?/p> <p>p么简单,感觉读(readable notationsQ模式尤其有,非常好用Q你q可以给它指定i18n的显C方式?br />下面׃n一下我写的zh_cn版本Q你只需要将一下内Ҏ贝到classpath下面的default.properties文g中就可以了(也可以按照i18的资源文件命名规则)Q?/p> <div style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"> <img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" /> <span style="COLOR: #000000">webwork.date.format.past</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">} 以前<br /><img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" />webwork.date.format.future</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">在 {</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">} <br /><img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" />webwork.date.format.seconds</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">几秒钟前 <br /><img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" />webwork.date.format.minutes</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#一分钟|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">} 分钟} <br /><img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" />webwork.date.format.hours</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#一时|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">} 时}{</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">#|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#零一分钟|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><零 {</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">} 分钟} <br /><img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" />webwork.date.format.days</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#一天|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">} 天}{</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">#|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#零一时|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><零 {</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">} 时} <br /><img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" />webwork.date.format.years</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#一q|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">} q}{</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">#|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#零一天|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><零 {</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">} 天} </span> </div> <p>输出的样子如Q“一天零 8 时 以前”,? 天零 23 时 以前”…?/p> <p>你也可以自己译Q默认的key如下Q?br />i18n文g默认为default.properties</p> <div style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"> <img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" /> <span style="COLOR: #000000">webwork.date.format.past</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">} ago <br /><img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" />webwork.date.format.future</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">in {</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">} <br /><img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" />webwork.date.format.seconds</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">an instant <br /><img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" />webwork.date.format.minutes</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#one minute|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">} minutes} <br /><img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" />webwork.date.format.hours</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#one hour|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">} hours}{</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">#|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000"> one minute|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000"> {</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">} minutes} <br /><img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" />webwork.date.format.days</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#one day|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">} days}{</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">#|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000"> one hour|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000"> {</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">} hours} <br /><img src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align="top" />webwork.date.format.years</span> <span style="COLOR: #000000">=</span> <span style="COLOR: #000000">{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#one year|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><{</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">} years}{</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">choice</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000">0</span> <span style="COLOR: #000000">#|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">#</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000"> one day|</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000"><</span> <span style="COLOR: #000000">,</span> <span style="COLOR: #000000"> {</span> <span style="COLOR: #000000">1</span> <span style="COLOR: #000000">} days} </span> </div> <p>?.2.2的Webwork发布兴奋之余也ؓ它的未来有些担心Q到Struts Action Framework发布q有ZQ其中的真空期很隄待呀QWW一向有些小毛病Q靠nightly build改善q是很麻烦的?br />2.2.2的更多功能的探烦希望大家能够互相交流?/p> <p>q有点补充:现在用ww:property输出Datecd的数据默认会昄到毫U……请注意?/p> <img src ="http://www.tkk7.com/iamtin/aggbug/37865.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.tkk7.com/iamtin/" target="_blank">Tin</a> 2006-03-28 20:00 <a href="http://www.tkk7.com/iamtin/archive/2006/03/28/37865.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>[犯弱]偉奇怪的“浏览器兼容问题?/title><link>http://www.tkk7.com/iamtin/archive/2006/03/14/35301.html</link><dc:creator>Tin</dc:creator><author>Tin</author><pubDate>Tue, 14 Mar 2006 13:12:00 GMT</pubDate><guid>http://www.tkk7.com/iamtin/archive/2006/03/14/35301.html</guid><wfw:comment>http://www.tkk7.com/iamtin/comments/35301.html</wfw:comment><comments>http://www.tkk7.com/iamtin/archive/2006/03/14/35301.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.tkk7.com/iamtin/comments/commentRss/35301.html</wfw:commentRss><trackback:ping>http://www.tkk7.com/iamtin/services/trackbacks/35301.html</trackback:ping><description><![CDATA[遇到了一个奇怪的“浏览器兼容问题”…?BR>是这LQ登陆页面工作不正常Q在firefox下L没有登陆Q根本就没有触发webwork的filter dispatcher?BR>打开我的三剑客:IE、Firefox、Opera试Q发现只有Firefox不行QMozzila内核的都不行Q?BR>然后׃3个多时扑֎因,遍|络Qweblogic、webwork、fireforx所有关键词都搜索了Q没有收莗?BR>然后开始snifferQ看报文?BR>l过多次分析Q发现firefoxҎ没有post那个formQ?BR>然后又是l箋的分析还是无果,一{莫展…?BR>然后旁边同事大喊Q你q?lt;input type="submit".../>外面怎么嵌套了一?lt;a>呀Q?BR>我当场晕菜,原来以前静态演C里放了个<a>……结果后来犯L<input>写在了里面,而firefox对a的解释和IE不同Q结果a的内容优先于inputQ结果没有post而只是触发了a的fref  ?$#&U$#*&$…?BR>没话说了Q绝对的弱智行ؓ。结l事,以绝后患?BR>注意<a>和其它元素嵌套时览器的解释差异Q这是个错Q谁知还会有什么大错?<IMG height=19 src="http://www.tkk7.com/Emoticons/74_74.gif" width=19 border=0><img src ="http://www.tkk7.com/iamtin/aggbug/35301.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.tkk7.com/iamtin/" target="_blank">Tin</a> 2006-03-14 21:12 <a href="http://www.tkk7.com/iamtin/archive/2006/03/14/35301.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>在Webwork中用ww:action实现面控制器风格Action复用http://www.tkk7.com/iamtin/archive/2006/03/10/34666.htmlTinTinFri, 10 Mar 2006 06:45:00 GMThttp://www.tkk7.com/iamtin/archive/2006/03/10/34666.htmlhttp://www.tkk7.com/iamtin/comments/34666.htmlhttp://www.tkk7.com/iamtin/archive/2006/03/10/34666.html#Feedback4http://www.tkk7.com/iamtin/comments/commentRss/34666.htmlhttp://www.tkk7.com/iamtin/services/trackbacks/34666.htmlWebwork是标准的h风格Web MVCQ类似的有Struts、Spring MVC。这q种风格的MVC中都使用了前端控制器模式Q企业架构模式)Q也是说一个URL会被解析然后z֏到对应的Action解析Q而View调用的是Action处理后的Form对象或者Command对象QRod的Without EJBQ?BR>上面引用了一些经典的a论,而它们和“页面控制器风格Action复用”有什么关pdQ?BR>嘿嘿Q页面控制器在这里指CView的Page里面依然可以调用控制器(在Webwork中就是ActionQ。如果是以前肯定有h会说Q如果用JSP我随时可以在Page里面写scriptletQ什么东襉K能调用…?BR>可是Q现在不一样了。我们希望让View单纯一点,不要有杂乱无章的逻辑参与其中?BR>可是Q如果要是如上面所说那么Action在它的一个请求生命周期就要做所有的事……这样一是Action逻辑变得复杂Q二是会变得难以复用?BR>所以,说到q里引Zq个主题Q?BR>1、在面调用控制?BR>2、复用控制器逻辑
在Webwork中我们可以?lt;ww:action/>标签实现q个目的?BR>—————————————————————————————————————?BR>不要着急,我们先介l一下ww:action的两U主要用法,而说用法之前先说语法Q?BR>语法Q?BR><ww:action/>?个属性:
1、idQ给Actionq回的ValueStack命名Q如果不写则默认用的Action的名字。(详细使用参照后面Q?BR>2、nameQ调用的Action的name?BR>3、namespaceQ调用的Action的namespace?BR>4、executeResultQtrue或falseQ是否渲染Action的View。这个决定了ww:action的用法。(后面会做说明Q?BR>5、ignoreContextParamsQBoolean|request参数是否在Action被调用时所包括?/P>

好了Q语法很单,我们说ww:action的两U主要用法?BR>1、代?lt;jsp:include>Q?BR>include有两U方式@ include和jsp:includeQ它们一个是~译前一个是q行时include。webwork是不能?lt;jsp:include>的?BR>但其实ww有ww:include标签Q但是根据Webwork in Action中的推荐Qww:include标签适合调用一般servletQ而对于action则推荐用强大的ww:action。所以我们这里就略过ww:include?BR>说强大是什么意思呢Qww:action充当q个角色Ӟ可以选择是否valueStack的东西复制过来?BR>当ww:action代替jsp:include的时候我们需要executeResult="true"Q这个时候调用的actionq回的view会被include到调用的位置?lt;ww:action><param name="xxx" value="yyy"/></ww:action>则可以给action传递参数。其它的用法׃jsp:include或者ww:include用法差别不大了?/P>

2、页面控制器风格Action复用Q?BR>我们l常遇到q样的场景,比如用户注册的时候需要选择单位列表。那么我们reg.actionq行之前需要先把单位列表unitsList取出来。而它们本w与User注册逻辑上没什么关pR?BR>所以有的h把这个取出unitsList单独写在prepare()Ҏ里面Q然后用prepare Inteceptor……或者把dunitsList的逻辑写在executeҎ里面?BR>但是q显焉以复用!
其实如果有单位unitq样的domainQ我们可能就有对应的CRUD的Action。其中可能就有UnitsListActionq样的Action?BR>我们完全可以在用h册的时候就复用q个ActionQ而不是把同样的逻辑写到用户注册的Action里面。这是面控制器风D解决的问题?BR>说那么多大帽子其实没有意义,我们看看怎么实现Q?BR>UnitsListAction片断Q我们要复用它)Q?/P>

UnitService unitService = null;//注入Q商业逻辑
List<Unit> unitsList = null;//讄对应getter、setter

Public String execute() {
 unitsList 
= unitDao.listAll();
 
return SUCCESS;
}

UserRegAction假设在注册前只是doDefault()直接q回SUCCESSQ只有在Post数据时在调用execute()Q我们就不写I的代码了。或者不通过MAction调用注册面Q直接调用注册的jsp文g直接讉K也可以?/P>

CUserRegAction昄的ViewQ我q里是Jsp片断Q?/P>

<ww:action id="listUnits" executeResult="false" namespace="/" name="unitsListAction" />
<ww:select name="unitId" list="#attr.listUnits.unitsList" listKey="id" listValue="name" required="true"/>

注意QexecuteResult="false"Q也是说我们不渲染unitsListActionq回的viewQ只用它的倹{?BR>而访问它的值的时候要使用#attr.listUnits.unitsListq样的引用,因ؓq时unitsListActionq回的VlueStack不是面的ognl的rootStackQ我们需要访?attrq个StackQ这部分可以参考一下Webwork的wiki?BR>上面我给unitsListAction规定了一个idQ这栯用比较灵z,你可以多ơ调用同一个Actionq且值放?attr下的不同地方?BR>我们引用unitsListActionq回的unitsListq个list的时候需要用#attr加上我们lunitsListAction讑֮的idQ如果不指定idQ则默认unitsListActionQ再加上你要讉K的变量名讉K?BR>其实很简单,而这U方式就是开始说的页面控制器风格的action复用。虽然和真正的叶面控制器的Tapestry和JSF相差甚远Q但是也有炚w个意思了?BR>扩展ҎQ如果我们在Action实现了一个counterQ也可以通过q种方式调用Q连q回的值都可以忽略Q呵呵,q种逻辑复用q是挺有用的?/P>

抛砖引玉Q我q个话啰嗦,见谅Q就到这里?/P>

Tin 2006-03-10 14:45 发表评论
]]>
如何lWebwork的redirect的result传递多个参?/title><link>http://www.tkk7.com/iamtin/archive/2006/02/24/32290.html</link><dc:creator>Tin</dc:creator><author>Tin</author><pubDate>Fri, 24 Feb 2006 05:56:00 GMT</pubDate><guid>http://www.tkk7.com/iamtin/archive/2006/02/24/32290.html</guid><wfw:comment>http://www.tkk7.com/iamtin/comments/32290.html</wfw:comment><comments>http://www.tkk7.com/iamtin/archive/2006/02/24/32290.html#Feedback</comments><slash:comments>6</slash:comments><wfw:commentRss>http://www.tkk7.com/iamtin/comments/commentRss/32290.html</wfw:commentRss><trackback:ping>http://www.tkk7.com/iamtin/services/trackbacks/32290.html</trackback:ping><description><![CDATA[<P>今天遇到一个问题,在Webwork 2.2里面l一个Action的result传多个参敎ͼ<BR>原先配置如下</P> <DIV style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">action </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="blahblahAction"</SPAN><SPAN style="COLOR: #ff0000"> class</SPAN><SPAN style="COLOR: #0000ff">="blahAction"</SPAN><SPAN style="COLOR: #ff0000"> method</SPAN><SPAN style="COLOR: #0000ff">="blah"</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"><BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>   </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">result </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="success"</SPAN><SPAN style="COLOR: #ff0000"> type</SPAN><SPAN style="COLOR: #0000ff">="redirect"</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000">/some.action?field1=${field1}</SPAN><SPAN style="COLOR: #ff0000">&field2</SPAN><SPAN style="COLOR: #000000">=${field2}</SPAN><SPAN style="COLOR: #0000ff"></</SPAN><SPAN style="COLOR: #800000">result</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"><BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top></SPAN><SPAN style="COLOR: #0000ff"></</SPAN><SPAN style="COLOR: #800000">action</SPAN><SPAN style="COLOR: #0000ff">></SPAN></DIV> <P>q行时候出现如下提C:<BR>The reference to entity "field2" must end with the ';' delimiter.<BR>我本以ؓ是OGNL的问题,四处搜寻Q不得其解……看了DTD也没有发现问题?BR>后来修改q程中突然发现原来是SAX解析器出错,我这才想到可能是XML的问题?BR>l过再三查询得到解决ҎQ?BR>使用"&amp;"代替"&"Q原理和HTML中的转义相同Q我居然忘记了XML的语法规范,惭愧?BR>配置如下Q?/P> <DIV style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">action </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="blahblahAction"</SPAN><SPAN style="COLOR: #ff0000"> class</SPAN><SPAN style="COLOR: #0000ff">="blahAction"</SPAN><SPAN style="COLOR: #ff0000"> method</SPAN><SPAN style="COLOR: #0000ff">="blah"</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"><BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>   </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">result </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="success"</SPAN><SPAN style="COLOR: #ff0000"> type</SPAN><SPAN style="COLOR: #0000ff">="redirect"</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000">/some.action?field1=${field1}</SPAN><SPAN style="COLOR: #ff0000">&amp;</SPAN><SPAN style="COLOR: #000000">field2=${field2}</SPAN><SPAN style="COLOR: #0000ff"></</SPAN><SPAN style="COLOR: #800000">result</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"><BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top></SPAN><SPAN style="COLOR: #0000ff"></</SPAN><SPAN style="COLOR: #800000">action</SPAN><SPAN style="COLOR: #0000ff">></SPAN></DIV> <P>工作正常了!希望对大家有用?BR>q几天超忙,没怎么写BlogQ还是要勤呀?/P><img src ="http://www.tkk7.com/iamtin/aggbug/32290.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.tkk7.com/iamtin/" target="_blank">Tin</a> 2006-02-24 13:56 <a href="http://www.tkk7.com/iamtin/archive/2006/02/24/32290.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>webwork 2.2 中如何给Collection赋?/title><link>http://www.tkk7.com/iamtin/archive/2006/02/16/31099.html</link><dc:creator>Tin</dc:creator><author>Tin</author><pubDate>Thu, 16 Feb 2006 13:19:00 GMT</pubDate><guid>http://www.tkk7.com/iamtin/archive/2006/02/16/31099.html</guid><wfw:comment>http://www.tkk7.com/iamtin/comments/31099.html</wfw:comment><comments>http://www.tkk7.com/iamtin/archive/2006/02/16/31099.html#Feedback</comments><slash:comments>9</slash:comments><wfw:commentRss>http://www.tkk7.com/iamtin/comments/commentRss/31099.html</wfw:commentRss><trackback:ping>http://www.tkk7.com/iamtin/services/trackbacks/31099.html</trackback:ping><description><![CDATA[<P>原本javaeye有这么一帖子“在WebWork2 Action中如何自动设|Array、List、Map”,是moxie大哥写的?<BR><A >http://forum.javaeye.com/viewtopic.php?t=8770</A> </P> <P>但是已经?004q?1月的文章了,在webwork 2.2 b4中,XWorkList和XWorkMap已经是deprecated状态了Q当时我׃头雾_也没扑ֈ什么好的线索?<BR>去java.net下蝲了XWork的最C码,看到了其中的注释Q说q个工作已经可以自动完成了?<BR>又几l周折,才算搞明白先在如何让List、Map{工作v来,l予2.2 b4和b5工作正常Q?</P> <P>下面单介l一下: <BR>1、如果要值映到pojo的collectionQ则需要用conversion功能?<BR>如我又一个ActionQ叫testActionQ?</P> <DIV style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><IMG id=Codehighlighter1_46_804_Open_Image onclick="this.style.display='none'; Codehighlighter1_46_804_Open_Text.style.display='none'; Codehighlighter1_46_804_Closed_Image.style.display='inline'; Codehighlighter1_46_804_Closed_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ExpandedBlockStart.gif" align=top><IMG id=Codehighlighter1_46_804_Closed_Image style="DISPLAY: none" onclick="this.style.display='none'; Codehighlighter1_46_804_Closed_Text.style.display='none'; Codehighlighter1_46_804_Open_Image.style.display='inline'; Codehighlighter1_46_804_Open_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ContractedBlock.gif" align=top><SPAN style="COLOR: #0000ff">public</SPAN><SPAN style="COLOR: #000000"> </SPAN><SPAN style="COLOR: #0000ff">class</SPAN><SPAN style="COLOR: #000000"> testAction </SPAN><SPAN style="COLOR: #0000ff">extends</SPAN><SPAN style="COLOR: #000000"> ActionSupport </SPAN><SPAN id=Codehighlighter1_46_804_Closed_Text style="BORDER-RIGHT: #808080 1px solid; BORDER-TOP: #808080 1px solid; DISPLAY: none; BORDER-LEFT: #808080 1px solid; BORDER-BOTTOM: #808080 1px solid; BACKGROUND-COLOR: #ffffff"><IMG src="http://www.tkk7.com/images/dot.gif"></SPAN><SPAN id=Codehighlighter1_46_804_Open_Text><SPAN style="COLOR: #000000">{ <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff">private</SPAN><SPAN style="COLOR: #000000"> Collection smoeAttrs </SPAN><SPAN style="COLOR: #000000">=</SPAN><SPAN style="COLOR: #000000"> </SPAN><SPAN style="COLOR: #0000ff">null</SPAN><SPAN style="COLOR: #000000">;</SPAN><SPAN style="COLOR: #008000">//</SPAN><SPAN style="COLOR: #008000">Q用webwork自动负|应有对应getter和setterQ?nbsp;</SPAN><SPAN style="COLOR: #008000"><BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top></SPAN><SPAN style="COLOR: #000000">        </SPAN><SPAN style="COLOR: #0000ff">private</SPAN><SPAN style="COLOR: #000000"> IDeptJgzTjkEcoAttDAO ecoAttDAO </SPAN><SPAN style="COLOR: #000000">=</SPAN><SPAN style="COLOR: #000000"> </SPAN><SPAN style="COLOR: #0000ff">null</SPAN><SPAN style="COLOR: #000000">;</SPAN><SPAN style="COLOR: #008000">//</SPAN><SPAN style="COLOR: #008000">Q改DAO使用Spring注入Q应有相应setterQ?nbsp;</SPAN><SPAN style="COLOR: #008000"><BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top></SPAN><SPAN style="COLOR: #000000"><BR><IMG id=Codehighlighter1_269_801_Open_Image onclick="this.style.display='none'; Codehighlighter1_269_801_Open_Text.style.display='none'; Codehighlighter1_269_801_Closed_Image.style.display='inline'; Codehighlighter1_269_801_Closed_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ExpandedSubBlockStart.gif" align=top><IMG id=Codehighlighter1_269_801_Closed_Image style="DISPLAY: none" onclick="this.style.display='none'; Codehighlighter1_269_801_Closed_Text.style.display='none'; Codehighlighter1_269_801_Open_Image.style.display='inline'; Codehighlighter1_269_801_Open_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ContractedSubBlock.gif" align=top>            </SPAN><SPAN style="COLOR: #0000ff">public</SPAN><SPAN style="COLOR: #000000"> String execute() </SPAN><SPAN style="COLOR: #0000ff">throws</SPAN><SPAN style="COLOR: #000000"> Exception </SPAN><SPAN id=Codehighlighter1_269_801_Closed_Text style="BORDER-RIGHT: #808080 1px solid; BORDER-TOP: #808080 1px solid; DISPLAY: none; BORDER-LEFT: #808080 1px solid; BORDER-BOTTOM: #808080 1px solid; BACKGROUND-COLOR: #ffffff"><IMG src="http://www.tkk7.com/images/dot.gif"></SPAN><SPAN id=Codehighlighter1_269_801_Open_Text><SPAN style="COLOR: #000000">{ <BR><IMG id=Codehighlighter1_314_401_Open_Image onclick="this.style.display='none'; Codehighlighter1_314_401_Open_Text.style.display='none'; Codehighlighter1_314_401_Closed_Image.style.display='inline'; Codehighlighter1_314_401_Closed_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ExpandedSubBlockStart.gif" align=top><IMG id=Codehighlighter1_314_401_Closed_Image style="DISPLAY: none" onclick="this.style.display='none'; Codehighlighter1_314_401_Closed_Text.style.display='none'; Codehighlighter1_314_401_Open_Image.style.display='inline'; Codehighlighter1_314_401_Open_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ContractedSubBlock.gif" align=top>                </SPAN><SPAN style="COLOR: #0000ff">if</SPAN><SPAN style="COLOR: #000000"> (log.isDebugEnabled()) </SPAN><SPAN id=Codehighlighter1_314_401_Closed_Text style="BORDER-RIGHT: #808080 1px solid; BORDER-TOP: #808080 1px solid; DISPLAY: none; BORDER-LEFT: #808080 1px solid; BORDER-BOTTOM: #808080 1px solid; BACKGROUND-COLOR: #ffffff"><IMG src="http://www.tkk7.com/images/dot.gif"></SPAN><SPAN id=Codehighlighter1_314_401_Open_Text><SPAN style="COLOR: #000000">{ <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>                        log.debug(</SPAN><SPAN style="COLOR: #000000">"</SPAN><SPAN style="COLOR: #000000">performing execute() method!</SPAN><SPAN style="COLOR: #000000">"</SPAN><SPAN style="COLOR: #000000">); <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/ExpandedSubBlockEnd.gif" align=top>                }</SPAN></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>                <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>                </SPAN><SPAN style="COLOR: #008000">//</SPAN><SPAN style="COLOR: #008000">持久化collection里面的pojo </SPAN><SPAN style="COLOR: #008000"><BR><IMG id=Codehighlighter1_545_722_Open_Image onclick="this.style.display='none'; Codehighlighter1_545_722_Open_Text.style.display='none'; Codehighlighter1_545_722_Closed_Image.style.display='inline'; Codehighlighter1_545_722_Closed_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ExpandedSubBlockStart.gif" align=top><IMG id=Codehighlighter1_545_722_Closed_Image style="DISPLAY: none" onclick="this.style.display='none'; Codehighlighter1_545_722_Closed_Text.style.display='none'; Codehighlighter1_545_722_Open_Image.style.display='inline'; Codehighlighter1_545_722_Open_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ContractedSubBlock.gif" align=top></SPAN><SPAN style="COLOR: #000000">                </SPAN><SPAN style="COLOR: #0000ff">for</SPAN><SPAN style="COLOR: #000000"> (Iterator iterator </SPAN><SPAN style="COLOR: #000000">=</SPAN><SPAN style="COLOR: #000000"> smoeAttrs.iterator(); iterator.hasNext();) </SPAN><SPAN id=Codehighlighter1_545_722_Closed_Text style="BORDER-RIGHT: #808080 1px solid; BORDER-TOP: #808080 1px solid; DISPLAY: none; BORDER-LEFT: #808080 1px solid; BORDER-BOTTOM: #808080 1px solid; BACKGROUND-COLOR: #ffffff"><IMG src="http://www.tkk7.com/images/dot.gif"></SPAN><SPAN id=Codehighlighter1_545_722_Open_Text><SPAN style="COLOR: #000000">{ <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>                            SomeAttr someAttr </SPAN><SPAN style="COLOR: #000000">=</SPAN><SPAN style="COLOR: #000000"> (SomeAttr) iterator.next(); <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>                            ecoAttDAO.saveOrUpdate(someAttr, someAttr.getId()); <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/ExpandedSubBlockEnd.gif" align=top>                }</SPAN></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>                <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>                       </SPAN><SPAN style="COLOR: #0000ff">return</SPAN><SPAN style="COLOR: #000000"> Action.SUCCESS; <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/ExpandedSubBlockEnd.gif" align=top>            }</SPAN></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/ExpandedBlockEnd.gif" align=top>}</SPAN></SPAN><SPAN style="COLOR: #000000"><BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top></SPAN></DIV> <P>对应一个pojoQ?</P> <DIV style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top><SPAN style="COLOR: #0000ff">package</SPAN><SPAN style="COLOR: #000000"> org.tin.test; <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top><BR><IMG id=Codehighlighter1_70_361_Open_Image onclick="this.style.display='none'; Codehighlighter1_70_361_Open_Text.style.display='none'; Codehighlighter1_70_361_Closed_Image.style.display='inline'; Codehighlighter1_70_361_Closed_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ExpandedBlockStart.gif" align=top><IMG id=Codehighlighter1_70_361_Closed_Image style="DISPLAY: none" onclick="this.style.display='none'; Codehighlighter1_70_361_Closed_Text.style.display='none'; Codehighlighter1_70_361_Open_Image.style.display='inline'; Codehighlighter1_70_361_Open_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ContractedBlock.gif" align=top></SPAN><SPAN style="COLOR: #0000ff">public</SPAN><SPAN style="COLOR: #000000"> </SPAN><SPAN style="COLOR: #0000ff">class</SPAN><SPAN style="COLOR: #000000"> SomeAttr </SPAN><SPAN style="COLOR: #0000ff">implements</SPAN><SPAN style="COLOR: #000000"> Serializable </SPAN><SPAN id=Codehighlighter1_70_361_Closed_Text style="BORDER-RIGHT: #808080 1px solid; BORDER-TOP: #808080 1px solid; DISPLAY: none; BORDER-LEFT: #808080 1px solid; BORDER-BOTTOM: #808080 1px solid; BACKGROUND-COLOR: #ffffff"><IMG src="http://www.tkk7.com/images/dot.gif"></SPAN><SPAN id=Codehighlighter1_70_361_Open_Text><SPAN style="COLOR: #000000">{ <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top><BR><IMG id=Codehighlighter1_82_120_Open_Image onclick="this.style.display='none'; Codehighlighter1_82_120_Open_Text.style.display='none'; Codehighlighter1_82_120_Closed_Image.style.display='inline'; Codehighlighter1_82_120_Closed_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ExpandedSubBlockStart.gif" align=top><IMG id=Codehighlighter1_82_120_Closed_Image style="DISPLAY: none" onclick="this.style.display='none'; Codehighlighter1_82_120_Closed_Text.style.display='none'; Codehighlighter1_82_120_Open_Image.style.display='inline'; Codehighlighter1_82_120_Open_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ContractedSubBlock.gif" align=top>        </SPAN><SPAN id=Codehighlighter1_82_120_Closed_Text style="BORDER-RIGHT: #808080 1px solid; BORDER-TOP: #808080 1px solid; DISPLAY: none; BORDER-LEFT: #808080 1px solid; BORDER-BOTTOM: #808080 1px solid; BACKGROUND-COLOR: #ffffff">/** */</SPAN><SPAN id=Codehighlighter1_82_120_Open_Text><SPAN style="COLOR: #008000">/**</SPAN><SPAN style="COLOR: #008000"> The composite primary key value. </SPAN><SPAN style="COLOR: #008000">*/</SPAN></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff">private</SPAN><SPAN style="COLOR: #000000"> java.lang.Long id; <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top><BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff">private</SPAN><SPAN style="COLOR: #000000"> java.lang.Float fild1; <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff">private</SPAN><SPAN style="COLOR: #000000"> java.lang.String fild2; <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff">private</SPAN><SPAN style="COLOR: #000000"> java.util.Date fild3; <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top><BR><IMG id=Codehighlighter1_289_358_Open_Image onclick="this.style.display='none'; Codehighlighter1_289_358_Open_Text.style.display='none'; Codehighlighter1_289_358_Closed_Image.style.display='inline'; Codehighlighter1_289_358_Closed_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ExpandedSubBlockStart.gif" align=top><IMG id=Codehighlighter1_289_358_Closed_Image style="DISPLAY: none" onclick="this.style.display='none'; Codehighlighter1_289_358_Closed_Text.style.display='none'; Codehighlighter1_289_358_Open_Image.style.display='inline'; Codehighlighter1_289_358_Open_Text.style.display='inline';" src="http://www.tkk7.com/images/OutliningIndicators/ContractedSubBlock.gif" align=top>        </SPAN><SPAN id=Codehighlighter1_289_358_Closed_Text style="BORDER-RIGHT: #808080 1px solid; BORDER-TOP: #808080 1px solid; DISPLAY: none; BORDER-LEFT: #808080 1px solid; BORDER-BOTTOM: #808080 1px solid; BACKGROUND-COLOR: #ffffff">/**/</SPAN><SPAN id=Codehighlighter1_289_358_Open_Text><SPAN style="COLOR: #008000">/*</SPAN><SPAN style="COLOR: #008000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>                <IMG src="http://www.tkk7.com/images/dot.gif">. <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/InBlock.gif" align=top>                对应的getter和setter <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/ExpandedSubBlockEnd.gif" align=top>        </SPAN><SPAN style="COLOR: #008000">*/</SPAN></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/ExpandedBlockEnd.gif" align=top>}</SPAN></SPAN><SPAN style="COLOR: #000000"><BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top></SPAN></DIV> <P>可以看到Q上面的Action声明的时候没有Q何涉及到XWorkList的地方(moxie介绍的那U风|Q也是说现在webworkq不知道Collection里面攄pojo的类型。这是Webwork目前的高明之处,q样的代码非常干净。但是如果要自动讑֮Collection的|讉K到这些PojoQ则一定要知道Pojo的类型,Webwork如何做呢Q?<BR>通过-conversion配置?<BR>需要在对应该才那个testAction.java的相同目录写一个testAction-conversion.properties文gQ格式就是Action名字+?conversion.properties”)?<BR>文g里面注明Q?<BR>Element_someAttrs = org.tin.test.SomeAttr Q以前版本曾l用qCollection、Map分开Q但是现在不什么类型,都用ElementQ?<BR>格式是“Element_?Action中Collection的名???你的pojo的完整类?</P> <P>如此配置后,自动讄值的时候就可以知道你的pojo的类型了Q很q净?</P> <P>下面一段׃我接触Webwork不久Q所以是个很初的经验,如果需要则自取Q?<BR>回忆moxie帖子中的重要的部分,在post到相应action的页面的form中,input要遵循这L命名Q?<BR>对应刚才所说的那个pojoQ?</P> <DIV style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">form</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">input  </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[0].fild1"</SPAN><SPAN style="COLOR: #ff0000"> value</SPAN><SPAN style="COLOR: #0000ff">="45555.6"</SPAN><SPAN style="COLOR: #ff0000"> id</SPAN><SPAN style="COLOR: #0000ff">="xxx11"</SPAN><SPAN style="COLOR: #ff0000"> </SPAN><SPAN style="COLOR: #0000ff">/></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">input  </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[0].fild2"</SPAN><SPAN style="COLOR: #ff0000"> value</SPAN><SPAN style="COLOR: #0000ff">="test"</SPAN><SPAN style="COLOR: #ff0000"> id</SPAN><SPAN style="COLOR: #0000ff">="xxx12"</SPAN><SPAN style="COLOR: #ff0000"> </SPAN><SPAN style="COLOR: #0000ff">/></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">input  </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[0].fild3"</SPAN><SPAN style="COLOR: #ff0000"> value</SPAN><SPAN style="COLOR: #0000ff">="2006-01-05"</SPAN><SPAN style="COLOR: #ff0000"> id</SPAN><SPAN style="COLOR: #0000ff">="xxx13"</SPAN><SPAN style="COLOR: #ff0000"> </SPAN><SPAN style="COLOR: #0000ff">/></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">input  </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[1].fild1"</SPAN><SPAN style="COLOR: #ff0000"> value</SPAN><SPAN style="COLOR: #0000ff">="45555.6"</SPAN><SPAN style="COLOR: #ff0000"> id</SPAN><SPAN style="COLOR: #0000ff">="xxx21"</SPAN><SPAN style="COLOR: #ff0000"> </SPAN><SPAN style="COLOR: #0000ff">/></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">input  </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[1].fild2"</SPAN><SPAN style="COLOR: #ff0000"> value</SPAN><SPAN style="COLOR: #0000ff">="test"</SPAN><SPAN style="COLOR: #ff0000"> id</SPAN><SPAN style="COLOR: #0000ff">="xxx22"</SPAN><SPAN style="COLOR: #ff0000"> </SPAN><SPAN style="COLOR: #0000ff">/></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">input  </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[1].fild3"</SPAN><SPAN style="COLOR: #ff0000"> value</SPAN><SPAN style="COLOR: #0000ff">="2006-01-05"</SPAN><SPAN style="COLOR: #ff0000"> id</SPAN><SPAN style="COLOR: #0000ff">="xxx23"</SPAN><SPAN style="COLOR: #ff0000"> </SPAN><SPAN style="COLOR: #0000ff">/></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">input  </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[2].fild1"</SPAN><SPAN style="COLOR: #ff0000"> value</SPAN><SPAN style="COLOR: #0000ff">="45555.6"</SPAN><SPAN style="COLOR: #ff0000"> id</SPAN><SPAN style="COLOR: #0000ff">="xxx31"</SPAN><SPAN style="COLOR: #ff0000"> </SPAN><SPAN style="COLOR: #0000ff">/></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">input  </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[2].fild2"</SPAN><SPAN style="COLOR: #ff0000"> value</SPAN><SPAN style="COLOR: #0000ff">="test"</SPAN><SPAN style="COLOR: #ff0000"> id</SPAN><SPAN style="COLOR: #0000ff">="xxx32"</SPAN><SPAN style="COLOR: #ff0000"> </SPAN><SPAN style="COLOR: #0000ff">/></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">input  </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[2].fild3"</SPAN><SPAN style="COLOR: #ff0000"> value</SPAN><SPAN style="COLOR: #0000ff">="2006-01-05"</SPAN><SPAN style="COLOR: #ff0000"> id</SPAN><SPAN style="COLOR: #0000ff">="xxx33"</SPAN><SPAN style="COLOR: #ff0000"> </SPAN><SPAN style="COLOR: #0000ff">/></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top></SPAN><SPAN style="COLOR: #0000ff"></</SPAN><SPAN style="COLOR: #800000">form</SPAN><SPAN style="COLOR: #0000ff">></SPAN></DIV> <P>如何输出Q很单,在列表页中: </P> <DIV style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">ww:iterator </SPAN><SPAN style="COLOR: #ff0000">value</SPAN><SPAN style="COLOR: #0000ff">="someAttrs"</SPAN><SPAN style="COLOR: #ff0000"> status</SPAN><SPAN style="COLOR: #0000ff">="someAttrsIter"</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top></SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">tr</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">td</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>                </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">ww:hidden </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[%{#someAttrsIter.index}].id"</SPAN><SPAN style="COLOR: #ff0000"> value</SPAN><SPAN style="COLOR: #0000ff">="%{id}"</SPAN><SPAN style="COLOR: #0000ff">/></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>                </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">ww:textfield </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[%{#someAttrsIter.index}].fild1"</SPAN><SPAN style="COLOR: #ff0000"> value</SPAN><SPAN style="COLOR: #0000ff">="%{fild1}"</SPAN><SPAN style="COLOR: #0000ff">/></</SPAN><SPAN style="COLOR: #800000">td</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">td</SPAN><SPAN style="COLOR: #0000ff">><</SPAN><SPAN style="COLOR: #800000">ww:textfield </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[%{#someAttrsIter.index}].fild2 value="</SPAN><SPAN style="COLOR: #ff0000">%{fild2}"</SPAN><SPAN style="COLOR: #0000ff">/></</SPAN><SPAN style="COLOR: #800000">td</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">td</SPAN><SPAN style="COLOR: #0000ff">><</SPAN><SPAN style="COLOR: #800000">ww:textfield </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="someAttrs[%{#someAttrsIter.index}].fild3"</SPAN><SPAN style="COLOR: #ff0000"> value</SPAN><SPAN style="COLOR: #0000ff">="%{fild3}"</SPAN><SPAN style="COLOR: #0000ff">/></</SPAN><SPAN style="COLOR: #800000">td</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top></SPAN><SPAN style="COLOR: #0000ff"></</SPAN><SPAN style="COLOR: #800000">tr</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top></SPAN><SPAN style="COLOR: #0000ff"></</SPAN><SPAN style="COLOR: #800000">ww:iterator</SPAN><SPAN style="COLOR: #0000ff">></SPAN></DIV> <P><BR>卛_以,因ؓiteratrorq个tag支持iteratroStatusq个东西Q用它可以获取index、isOdd{信息,很方ѝ?</P> <P>配合 </P> <DIV style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">action </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="saveAction"</SPAN><SPAN style="COLOR: #ff0000"> class</SPAN><SPAN style="COLOR: #0000ff">="testAction"</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top>        </SPAN><SPAN style="COLOR: #0000ff"><</SPAN><SPAN style="COLOR: #800000">result </SPAN><SPAN style="COLOR: #ff0000">name</SPAN><SPAN style="COLOR: #0000ff">="success"</SPAN><SPAN style="COLOR: #ff0000"> type</SPAN><SPAN style="COLOR: #0000ff">="redirect"</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000">/loadByInf.action?id=${someAttrOwner.id}</SPAN><SPAN style="COLOR: #0000ff"></</SPAN><SPAN style="COLOR: #800000">result</SPAN><SPAN style="COLOR: #0000ff">></SPAN><SPAN style="COLOR: #000000"> <BR><IMG src="http://www.tkk7.com/images/OutliningIndicators/None.gif" align=top></SPAN><SPAN style="COLOR: #0000ff"></</SPAN><SPAN style="COLOR: #800000">action</SPAN><SPAN style="COLOR: #0000ff">></SPAN></DIV> <P>则很Ҏ的实现对Collection的CRUD。正好用CONGL的集中基本访问方式:#?{}?{} </P> <P>以上内容Q错漏难免。因Z天终于可以偷Ԍ赶紧lC。欢q大家讨论更便的Ҏ?/P> <P> </P><img src ="http://www.tkk7.com/iamtin/aggbug/31099.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.tkk7.com/iamtin/" target="_blank">Tin</a> 2006-02-16 21:19 <a href="http://www.tkk7.com/iamtin/archive/2006/02/16/31099.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>Webwork22b5中datapicker的本地化使用Ҏhttp://www.tkk7.com/iamtin/archive/2006/02/16/31098.htmlTinTinThu, 16 Feb 2006 13:15:00 GMThttp://www.tkk7.com/iamtin/archive/2006/02/16/31098.htmlhttp://www.tkk7.com/iamtin/comments/31098.htmlhttp://www.tkk7.com/iamtin/archive/2006/02/16/31098.html#Feedback0http://www.tkk7.com/iamtin/comments/commentRss/31098.htmlhttp://www.tkk7.com/iamtin/services/trackbacks/31098.html 文章旉: 2006-1-05 19:00:49    标题: Webwork22b5中datapicker的本地化使用Ҏ 引用回复 ~辑/删除文章 这个帖子加入我的Blog
仅作录,量明:
1、我使用Weblogic 8.1 SP5+Webwork 2.2 beta 5?.2b5的Webwork已经完全转向使用jscalendar作ؓdatapicker的jsQ而不是以前的tigracalendarQ因为tigracalendar不支持国际化。Web目使用FilterDispatcherQ本应改可以?webwork/*的请求拦截下来,但是它工做不正常。所以我把webwork.jar里面的\com\opensymphony\webwork\static目录拯到Web根目录,q将static目录重名名ؓwebwork?
此时Q你的Web根目录下面应有一个名为webwork的目录,里面有jscalendar、dojo、niftycornersq几个文件加Q如果不需要其它的Q可以只保留jscalendar一个目录?
2、在需要显Cdatapicker的地方用如下标?lt;ww:datepicker name="ecoInf.turninDate" id="ecoInf.turninDate" template="datepicker.ftl" language="cn_utf8" format="%Y-%m-%d %H:%M:%S" showstime="true" />?
其中template完全可以不写。而name标明你的数据的来源。id是方便javascript讉K所保留的,可以和name相同Q如果有重复nameQ如l过iteratorQ则需要区别其idQ保持id在html dom中唯一Q?
showstime标明是否可以选择旉Q可以是"true"Q?false"Q?24"Q?12"?
language军_jscalendar使用的语aQ参照下面说明?
3、language指定的语a其实对应jscalendar/lang下面的语a文gQ格式就是calendar-语言?jsQ默认的中文使用的是zh。但是其实j2ee目l常面对中文q问题Q最佌x案就是统一使用UTF-8。但是calendar-zh.js正好不是UTF-8的,所以如果直接用zh语言则datapicker没法正常工作?
我的解决Ҏ是将webwork附带的jscalendar 1.0的lang里面的cn_utf8.js改名为calendar-cn_utf8.jsQ然后将language="cn_utf8"工作正怺?
4、关于时间的昄格式。其实cn_utf8.js里面已经制定了时间的标准昄格式?Y-%m-%dQ符合我们的习惯。但是有时我们需要显C具体时_参照他们|站的说明,使用format="%Y-%m-%d %H:%M:%S"Q这个也W合我们的习惯?

发个牢骚Q?
本来奇简单。但是很奇?webwork/*居然不能在Weblogic下自动映,我一会而去试验下TomcatQ还有就是js解析utf-8出错造成整个js没法工作Q浪费了半天旉Q唉?

相关链接Q?
2.2 beta 5的datapicker的docQ?
http://wiki.opensymphony.com/display/WW/datepicker
jscalendar的官方网站:
http://www.dynarch.com/projects/calendar/
jscalendar的用方法简单demoQ?
http://www.dynarch.com/demos/jscalendar/
jscalendar下蝲Q?
http://prdownloads.sourceforge.net/jscalendar/jscalendar-1.0.zip?download
datapicker本地化的相关讨论Q?
http://forums.opensymphony.com/thread.jspa?messageID=21466
http://forums.opensymphony.com/thread.jspa?messageID=21526


昨天说要试验一下在tomcat下面?webwork/*的映是否工作正常?
l过试验在tomcat下面工作正常Q所有com.opensymphony.webwork.static下面的东襉K可以自动映射?webwork/*下面?

也就是说又是Weblogic的倒霉问题……烦啊?

也就是说不用Webloigic 8.1的朋友们可以蟩q第一步了?

有的朋友可能没有2.2 beta5Q可以去q里下蝲nightly buildQ谢谢jscud上次提供q两个链接:
http://ivyrep.opensymphony.com/opensymphony/webwork/
q有对应的xworkQ?
http://ivyrep.opensymphony.com/opensymphony/xwork/

q是一老帖子了Q已l不是最斎ͼ
http://forum.javaeye.com/viewtopic.php?t=17936&highlight=


Tin 2006-02-16 21:15 发表评论
]]>
Webwork 2.2的Action是否使用Spring的prototypeB获取的性能Ҏhttp://www.tkk7.com/iamtin/archive/2006/02/14/30699.htmlTinTinTue, 14 Feb 2006 13:48:00 GMThttp://www.tkk7.com/iamtin/archive/2006/02/14/30699.htmlhttp://www.tkk7.com/iamtin/comments/30699.htmlhttp://www.tkk7.com/iamtin/archive/2006/02/14/30699.html#Feedback0http://www.tkk7.com/iamtin/comments/commentRss/30699.htmlhttp://www.tkk7.com/iamtin/services/trackbacks/30699.html阅读全文

Tin 2006-02-14 21:48 发表评论
]]>
վ֩ģ壺 99߹ۿ| ҳվѹۿ| Ļɫͼ| ɫһ| ޻ɫߵӰ| ޵һվ| ˳ھþۺվ| sssۺþþþ| Ȼר| У԰޴ɫС˵ϼ| è˳վ߹ۿ| ҳվ߹ۿ| ߹ۿѻɫַ| δʮ18ֹվ| 91ƷѾþù鶹| 鶹ƷƵ| ëƬѹۿַ| ִӲˬƵ| ݺۺɫ| ޾ƷŮþþ| ĻۺϾƷһ| Ʒ޾Ʒۿ| þþƷAVδʮ | ޹ۺ߾Ʒ| AVҹ丣㽶149| AVר4SE| þþƷAV鶹վ| ˳ͼƬվ| ɫػaëƬѹۿ| ȫƵѹۿ߿| 57PAO˹Ƶ | aƵ߹ۿ| ŷ߾Ʒѹۿһ| ѹۿƵ| һ߲| þþùƷһ| av| avƬ쿴| ҹ1000| AV˾þԭ| ޹Ʒþþþվ|