ï»??xml version="1.0" encoding="utf-8" standalone="yes"?>免费在线观看一区二区三区,亚洲a区在线视频,亚洲精品欧美日韩http://www.aygfsteel.com/rory/Happy study,Happy work,Happy lifezh-cnTue, 06 May 2025 07:31:32 GMTTue, 06 May 2025 07:31:32 GMT60xstream对xmlnode的属æ€?attribute)è§£æžçš„问题[æ›´æ–°]ã€?/title><link>http://www.aygfsteel.com/rory/archive/2007/01/17/howto-dealwith-xstream-xmlnode-attribute.html</link><dc:creator>莫多</dc:creator><author>莫多</author><pubDate>Wed, 17 Jan 2007 10:24:00 GMT</pubDate><guid>http://www.aygfsteel.com/rory/archive/2007/01/17/howto-dealwith-xstream-xmlnode-attribute.html</guid><wfw:comment>http://www.aygfsteel.com/rory/comments/94475.html</wfw:comment><comments>http://www.aygfsteel.com/rory/archive/2007/01/17/howto-dealwith-xstream-xmlnode-attribute.html#Feedback</comments><slash:comments>2</slash:comments><wfw:commentRss>http://www.aygfsteel.com/rory/comments/commentRss/94475.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/rory/services/trackbacks/94475.html</trackback:ping><description><![CDATA[xstream是个好东è¥Ñ€‚对于酾|®æ–‡ä»¶çš„è¯Õd–很方ä¾Ñ€‚在mybog中我ž®Þq”¨åˆîCº†ã€‚丘q‡ä»Šå¤©æ‰“½Ž—用yupooçš„apiæ¥åšç›¸å†Œã€‚å‘现xstream对于xmlnodeçš„attributeè§£æžæ”¯æŒä¸æ˜¯é‚£ä¹ˆçš„好ã€?br />对于˜q™ç§èŠ‚ç‚¹æ ¼å¼çš„éžå¸¸çš„½Ž€å?br /><div style="border: 1px solid rgb(204, 204, 204); padding: 4px 5px 4px 4px; font-size: 13px; width: 98%; background-color: rgb(238, 238, 238);"><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">result</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />    </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">page</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);">1</span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">page</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />    </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">pages</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);">1</span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">pages</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />    </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">perpage</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);">100</span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">perpage</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />    </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">total</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);">19</span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">total</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />    </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">photos</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />        </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">photo</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />            </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">id</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);">ff8080810fc8ac78010fd3f158d40a52</span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">id</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />            </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">owner</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);">ff8080810f1a387b010f1a83d6530dfc</span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">owner</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />            </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">title</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);">Gmail-2</span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">title</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />            </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">host</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);">4</span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">host</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />            </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">dir</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);">20061230</span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">dir</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />            </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">filename</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);">231905_1463411198</span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">filename</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />        </span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">photo</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />    </span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">photos</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br /></span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">result</span><span style="color: rgb(0, 0, 255);">></span></div><br />½Ž€å•çš„alias一下就å¯ä»¥è¯Õdˆ°å€égº†<br /><div style="border: 1px solid rgb(204, 204, 204); padding: 4px 5px 4px 4px; font-size: 13px; width: 98%; background-color: rgb(238, 238, 238);"><span style="color: rgb(0, 0, 0);">File file </span><span style="color: rgb(0, 0, 0);">=</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> File(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">src/test/java/com/jdkcn/test/result.xml</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">);<br />BufferedReader reader </span><span style="color: rgb(0, 0, 0);">=</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> BufferedReader(</span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> InputStreamReader(</span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> FileInputStream(file), </span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">UTF-8</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">));<br />XStream stream </span><span style="color: rgb(0, 0, 0);">=</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> XStream();<br />stream.alias(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">result</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, YupooResult.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />stream.alias(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">photo</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">,YupooPhoto.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />YupooResult result </span><span style="color: rgb(0, 0, 0);">=</span><span style="color: rgb(0, 0, 0);"> (YupooResult)stream.fromXML(reader);</span></div>坿˜¯Yupooçš„api˜q”回的xmlrpc的结果是˜q™æ ·çš?br /><div style="border: 1px solid rgb(204, 204, 204); padding: 4px 5px 4px 4px; font-size: 13px; width: 98%; background-color: rgb(238, 238, 238);"><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">result </span><span style="color: rgb(255, 0, 0);">page</span><span style="color: rgb(0, 0, 255);">="1"</span><span style="color: rgb(255, 0, 0);"> pages</span><span style="color: rgb(0, 0, 255);">="1"</span><span style="color: rgb(255, 0, 0);"> perpage</span><span style="color: rgb(0, 0, 255);">="100"</span><span style="color: rgb(255, 0, 0);"> total</span><span style="color: rgb(0, 0, 255);">="19"</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />    </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">photos</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br />        </span><span style="color: rgb(0, 0, 255);"><</span><span style="color: rgb(128, 0, 0);">photo </span><span style="color: rgb(255, 0, 0);">id</span><span style="color: rgb(0, 0, 255);">="ff8080810fc8ac78010fd3f158d40a52"</span><span style="color: rgb(255, 0, 0);"><br />            owner</span><span style="color: rgb(0, 0, 255);">="ff8080810f1a387b010f1a83d6530dfc"</span><span style="color: rgb(255, 0, 0);"> title</span><span style="color: rgb(0, 0, 255);">="Gmail-2"</span><span style="color: rgb(255, 0, 0);"> host</span><span style="color: rgb(0, 0, 255);">="4"</span><span style="color: rgb(255, 0, 0);"><br />            dir</span><span style="color: rgb(0, 0, 255);">="20061230"</span><span style="color: rgb(255, 0, 0);"> filename</span><span style="color: rgb(0, 0, 255);">="231905_1463411198"</span><span style="color: rgb(255, 0, 0);"> </span><span style="color: rgb(0, 0, 255);">/></span><span style="color: rgb(0, 0, 0);"><br />    </span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">photos</span><span style="color: rgb(0, 0, 255);">></span><span style="color: rgb(0, 0, 0);"><br /></span><span style="color: rgb(0, 0, 255);"></</span><span style="color: rgb(128, 0, 0);">result</span><span style="color: rgb(0, 0, 255);">></span></div>˜q™æ ·ž®±loadä¸åˆ°å€égº†ã€‚没法去mailisté‡Œé¢æ‰„¡­”案,果然有ähé—®ã€?br /><pre><font color="#ff9900">Hello, I am not sure about the subject but here is what I needed help for: XML: <field name="value">I am a Field.</field> I have already tried several structures and nothing seem to work. Is this possible for XStream? :) How is the Java class form to support this? Thanks!</font><br /><br /><br /><br /><br />有äh回答是看Converter的文档。果然找到答案了ã€?br />自己写一个converterž®±å¯ä»¥äº†ã€?br />䏋颿˜¯æˆ‘çš„converter<br /><div style="border: 1px solid rgb(204, 204, 204); padding: 4px 5px 4px 4px; font-size: 13px; width: 98%; background-color: rgb(238, 238, 238);"><span style="color: rgb(0, 0, 255);">package</span><span style="color: rgb(0, 0, 0);"> com.jdkcn.xstream;<br /><br /></span><span style="color: rgb(0, 0, 255);">import</span><span style="color: rgb(0, 0, 0);"> java.util.ArrayList;<br /></span><span style="color: rgb(0, 0, 255);">import</span><span style="color: rgb(0, 0, 0);"> java.util.List;<br /><br /></span><span style="color: rgb(0, 0, 255);">import</span><span style="color: rgb(0, 0, 0);"> com.jdkcn.yupoo.YupooPhoto;<br /></span><span style="color: rgb(0, 0, 255);">import</span><span style="color: rgb(0, 0, 0);"> com.jdkcn.yupoo.YupooResult;<br /></span><span style="color: rgb(0, 0, 255);">import</span><span style="color: rgb(0, 0, 0);"> com.thoughtworks.xstream.converters.Converter;<br /></span><span style="color: rgb(0, 0, 255);">import</span><span style="color: rgb(0, 0, 0);"> com.thoughtworks.xstream.converters.MarshallingContext;<br /></span><span style="color: rgb(0, 0, 255);">import</span><span style="color: rgb(0, 0, 0);"> com.thoughtworks.xstream.converters.UnmarshallingContext;<br /></span><span style="color: rgb(0, 0, 255);">import</span><span style="color: rgb(0, 0, 0);"> com.thoughtworks.xstream.io.HierarchicalStreamReader;<br /></span><span style="color: rgb(0, 0, 255);">import</span><span style="color: rgb(0, 0, 0);"> com.thoughtworks.xstream.io.HierarchicalStreamWriter;<br /><br /></span><span style="color: rgb(0, 128, 0);">/**</span><span style="color: rgb(0, 128, 0);"><br /> * </span><span style="color: rgb(128, 128, 128);">@author</span><span style="color: rgb(0, 128, 0);"> <a href="mailto:rory.cn@gmail.com">somebody</a><br /> * </span><span style="color: rgb(128, 128, 128);">@since</span><span style="color: rgb(0, 128, 0);"> Jan 16, 2007 6:12:35 PM<br /> * </span><span style="color: rgb(128, 128, 128);">@version</span><span style="color: rgb(0, 128, 0);"> $Id YupooResultConverter.java$<br /> </span><span style="color: rgb(0, 128, 0);">*/</span><span style="color: rgb(0, 0, 0);"><br /></span><span style="color: rgb(0, 0, 255);">public</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);"> YupooResultConverter </span><span style="color: rgb(0, 0, 255);">implements</span><span style="color: rgb(0, 0, 0);"> Converter {<br />    </span><span style="color: rgb(0, 128, 0);">/*</span><span style="color: rgb(0, 128, 0);"> (non-Javadoc)<br />     * @see com.thoughtworks.xstream.converters.Converter#marshal(java.lang.Object, com.thoughtworks.xstream.io.HierarchicalStreamWriter, com.thoughtworks.xstream.converters.MarshallingContext)<br />     </span><span style="color: rgb(0, 128, 0);">*/</span><span style="color: rgb(0, 0, 0);"><br />    </span><span style="color: rgb(0, 0, 255);">public</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 255);">void</span><span style="color: rgb(0, 0, 0);"> marshal(Object obj, HierarchicalStreamWriter writer, MarshallingContext context) {<br />        </span><span style="color: rgb(0, 128, 0);">//</span><span style="color: rgb(0, 128, 0);"> FIXME unfinish.</span><span style="color: rgb(0, 128, 0);"><br /></span><span style="color: rgb(0, 0, 0);">    }<br /><br />    </span><span style="color: rgb(0, 128, 0);">/*</span><span style="color: rgb(0, 128, 0);"> (non-Javadoc)<br />     * @see com.thoughtworks.xstream.converters.Converter#unmarshal(com.thoughtworks.xstream.io.HierarchicalStreamReader, com.thoughtworks.xstream.converters.UnmarshallingContext)<br />     </span><span style="color: rgb(0, 128, 0);">*/</span><span style="color: rgb(0, 0, 0);"><br />    </span><span style="color: rgb(0, 0, 255);">public</span><span style="color: rgb(0, 0, 0);"> Object unmarshal(HierarchicalStreamReader reader, UnmarshallingContext context) {<br />        YupooResult result </span><span style="color: rgb(0, 0, 0);">=</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> YupooResult();<br />        result.setPage(</span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> Integer(reader.getAttribute(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">page</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">)));<br />        result.setPages(</span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> Integer(reader.getAttribute(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">pages</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">)));<br />        result.setPerpage(</span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> Integer(reader.getAttribute(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">perpage</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">)));<br />        result.setTotal(</span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> Integer(reader.getAttribute(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">total</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">)));<br />        reader.moveDown();<br />        List</span><span style="color: rgb(0, 0, 0);"><</span><span style="color: rgb(0, 0, 0);">YupooPhoto</span><span style="color: rgb(0, 0, 0);">></span><span style="color: rgb(0, 0, 0);"> photos </span><span style="color: rgb(0, 0, 0);">=</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> ArrayList</span><span style="color: rgb(0, 0, 0);"><</span><span style="color: rgb(0, 0, 0);">YupooPhoto</span><span style="color: rgb(0, 0, 0);">></span><span style="color: rgb(0, 0, 0);">();<br />        </span><span style="color: rgb(0, 0, 255);">while</span><span style="color: rgb(0, 0, 0);">(reader.hasMoreChildren()) {<br />            reader.moveDown();<br />            YupooPhoto photo </span><span style="color: rgb(0, 0, 0);">=</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> YupooPhoto();<br />            photo.setDir(reader.getAttribute(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">dir</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">));<br />            photo.setFilename(reader.getAttribute(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">filename</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">));<br />            photo.setHost(reader.getAttribute(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">host</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">));<br />            photo.setId(reader.getAttribute(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">id</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">));<br />            photo.setOwner(reader.getAttribute(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">owner</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">));<br />            photo.setTitle(reader.getAttribute(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">title</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">));<br />            photos.add(photo);<br />            reader.moveUp();<br />        }<br />        result.setPhotos(photos);<br />        </span><span style="color: rgb(0, 0, 255);">return</span><span style="color: rgb(0, 0, 0);"> result;<br />    }<br />    </span><span style="color: rgb(0, 128, 0);">/*</span><span style="color: rgb(0, 128, 0);"> (non-Javadoc)<br />     * @see com.thoughtworks.xstream.converters.ConverterMatcher#canConvert(java.lang.Class)<br />     </span><span style="color: rgb(0, 128, 0);">*/</span><span style="color: rgb(0, 0, 0);"><br />    </span><span style="color: rgb(0, 0, 255);">public</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 255);">boolean</span><span style="color: rgb(0, 0, 0);"> canConvert(Class clazz) {<br />        </span><span style="color: rgb(0, 0, 255);">return</span><span style="color: rgb(0, 0, 0);"> clazz.equals(YupooResult.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />    }<br />}<br /></span></div><br />ç„¶åŽè°ƒç”¨çš„地方修改一下就ok了ã€?br /><div style="border: 1px solid rgb(204, 204, 204); padding: 4px 5px 4px 4px; font-size: 13px; width: 98%; background-color: rgb(238, 238, 238);"><span style="color: rgb(0, 0, 0);">XStream stream </span><span style="color: rgb(0, 0, 0);">=</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> XStream();<br />stream.registerConverter(</span><span style="color: rgb(0, 0, 255);">new</span><span style="color: rgb(0, 0, 0);"> YupooResultConverter());<br />stream.alias(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">result</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, YupooResult.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);</span></div><br /><br /><br />å‚è€?<br /><a >http://xstream.codehaus.org/converter-tutorial.html</a></pre><br />2007òq?æœ?8日更新ã€?br />˜q™é‡Œæ„Ÿè°¢¾|‘å‹ <a id="AjaxHolder_Comments_CommentList_ctl00_NameLink" target="_blank">Ivan ChenåQˆè¥¿æ»¨ï¼‰</a> 的æ½Cºã€‚åŽŸæ¥æ–°ç‰ˆçš„xstreamå¯ä»¥½Ž€å•的解决了。在1.2.1çš„docé‡Œé¢æ‰‘Öˆ°äº†è¿™ä¸ªä¸¤ä¸ªæ–¹æ³•ã€?br /><h3>useAttributeFor</h3><pre>public void <b>useAttributeFor</b>(java.lang.String fieldName, java.lang.Class type)</pre><dl><dd>Use an XML attribute for a field or a specific type. <p></p></dd><dd><dl><dt><b>Parameters:</b></dt><dd><code>fieldName</code> - the name of the field </dd><dd><code>type</code> - the Class of the type to be rendered as XML attribute </dd><dt><b>Throws:</b></dt><dd><code><a title="class in com.thoughtworks.xstream" >XStream.InitializationException</a></code> - if no <a title="class in com.thoughtworks.xstream.mapper" ><code>AttributeMapper</code></a> is available </dd><dt><b>Since:</b></dt><dd>1.2</dd></dl></dd></dl><hr /><a name="useAttributeFor(java.lang.Class)"><!-- --></a><h3>useAttributeFor</h3><pre>public void <b>useAttributeFor</b>(java.lang.Class type)</pre><dl><dd>Use an XML attribute for an arbotrary type. <p></p></dd><dd><dl><dt><b>Parameters:</b></dt><dd><code>type</code> - the Class of the type to be rendered as XML attribute </dd><dt><b>Throws:</b></dt><dd><code><a title="class in com.thoughtworks.xstream" >XStream.InitializationException</a></code> - if no <a title="class in com.thoughtworks.xstream.mapper" ><code>AttributeMapper</code></a> is available </dd><dt><b>Since:</b></dt><dd>1.2</dd></dl></dd></dl><br />˜q™ä¸¤ä¸ªæ–¹æ³•都是从1.2开始支æŒçš„ã€?br />也ä¸ç”¨è‡ªå·±å†™converter了。这样就å¯ä»¥äº?br /><div style="border: 1px solid rgb(204, 204, 204); padding: 4px 5px 4px 4px; font-size: 13px; width: 98%; background-color: rgb(238, 238, 238);"><span style="color: rgb(0, 0, 0);">        stream.alias(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">result</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, YupooResult.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />        stream.useAttributeFor(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">page</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, Integer.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />        stream.useAttributeFor(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">pages</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, Integer.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />        stream.useAttributeFor(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">perpage</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, Integer.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />        stream.useAttributeFor(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">total</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, Integer.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />        stream.alias(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">photo</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, YupooPhoto.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />        stream.useAttributeFor(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">id</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, String.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />        stream.useAttributeFor(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">owner</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, String.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />        stream.useAttributeFor(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">title</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, String.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />        stream.useAttributeFor(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">host</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, String.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />        stream.useAttributeFor(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">dir</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, String.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);<br />        stream.useAttributeFor(</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">filename</span><span style="color: rgb(0, 0, 0);">"</span><span style="color: rgb(0, 0, 0);">, String.</span><span style="color: rgb(0, 0, 255);">class</span><span style="color: rgb(0, 0, 0);">);</span></div><a target="_blank"><br /><img alt="创造共用åè®?¾|²å,éžå•†ä¸?ä¿æŒä¸€è‡? src="http://leaf.jdk.cn/rights.gif" border="0" height="31" width="88" /></a>   除ç»ç‰¹åˆ«æ³¨æ˜Žå¤?本文章版æƒå½’<strong><a class="" ><font color="#6b6b52">莫多泡æˆö</font></a></strong>所æœ? <br /><font color="#ff0000">¾|²å,éžå•†ä¸šç”¨é€?ä¿æŒä¸€è‡?</font>   <a title="莫多泡æˆö" target="_blank">somebody(莫多)</a><img src ="http://www.aygfsteel.com/rory/aggbug/94475.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/rory/" target="_blank">莫多</a> 2007-01-17 18:24 <a href="http://www.aygfsteel.com/rory/archive/2007/01/17/howto-dealwith-xstream-xmlnode-attribute.html#Feedback" target="_blank" style="text-decoration:none;">å‘表评论</a></div>]]></description></item><item><title>åˆæ˜¯ä¹Þq é—®é¢˜-Filter é…置也很é‡è¦http://www.aygfsteel.com/rory/archive/2006/12/27/character_encoding_problem_filtermapping_position.html莫多莫多Wed, 27 Dec 2006 02:37:00 GMThttp://www.aygfsteel.com/rory/archive/2006/12/27/character_encoding_problem_filtermapping_position.htmlhttp://www.aygfsteel.com/rory/comments/90236.htmlhttp://www.aygfsteel.com/rory/archive/2006/12/27/character_encoding_problem_filtermapping_position.html#Feedback3http://www.aygfsteel.com/rory/comments/commentRss/90236.htmlhttp://www.aygfsteel.com/rory/services/trackbacks/90236.html  上周更新了一下myblog,æ·ÕdŠ äº†ä¸€ä¸ªFilteråQŒåš¾lŸè®¡è®‰K—®ç”¨ã€‚坿˜¯åŽæ¥å‘现出çŽîCØ•ç é—®é¢˜äº†ã€‚找了很久都没有扑ֈ°é—®é¢˜ã€‚debug的时候看åˆ?CharacterEncodingFilter¼‹®å®žæ˜¯æ‰§è¡Œäº†ã€‚丘q‡å°±æ˜¯æ²¡æœ‰æ•ˆæžœã€‚æ‰§è¡Œä¹‹å‰æ˜¯ISO-8859-1¾~–ç çš„,执行之厘q˜æ˜¯åQ?CharacterEncodingFilterž®±æ²¡æœ‰è“våˆîC½œç”¨ã€‚åŽæ¥ç»ˆäºŽæ‰¾åˆ°é—®é¢˜çš„åŽŸå› äº†ã€‚åŽŸæ¥æ˜¯Filteré…置先厙åºåºçš„原因ã€?br />       刚开始的é…置是这æ ïL(f¨¥ng)š„:

     < filter-mapping >
        
< filter-name > requestCounterFilter </ filter-name >
        
< url-pattern > *.jhtml </ url-pattern >
    
</ filter-mapping >
  
    
< filter-mapping >
        
< filter-name > encodingFilter </ filter-name >
        
< url-pattern > /dwr/* </ url-pattern >
    
</ filter-mapping >
    
    
< filter-mapping >
        
< filter-name > encodingFilter </ filter-name >
        
< url-pattern > *.jhtml </ url-pattern >
    
</ filter-mapping >
    
    
< filter-mapping >
        
< filter-name > encodingFilter </ filter-name >
        
< url-pattern > *.jsp </ url-pattern >
    
</ filter-mapping >

  先绘q‡é‚£ä¸ªç»Ÿè®¡çš„filterç„¶åŽå†ç»˜q‡ç¼–ç çš„filter。这æ ïL(f¨¥ng)š„è¯ç¼–ç çš„filterž®×ƒ¸èµ·ä½œç”¨äº†ã€‚åªè¦å§¾~–ç çš„filter攑ֈ°æœ€å‰é¢ž®±æ²¡æœ‰é—®é¢˜äº†ã€‚改æˆè¿™æ ·å°±å¥½ã€?br />

     < filter-mapping >
        
< filter-name > encodingFilter </ filter-name >
        
< url-pattern > /dwr/* </ url-pattern >
    
</ filter-mapping >
    
    
< filter-mapping >
        
< filter-name > encodingFilter </ filter-name >
        
< url-pattern > *.jhtml </ url-pattern >
    
</ filter-mapping >
    
    
< filter-mapping >
        
< filter-name > encodingFilter </ filter-name >
        
< url-pattern > *.jsp </ url-pattern >
    
</ filter-mapping >
    
    
< filter-mapping >
        
< filter-name > requestCounterFilter </ filter-name >
        
< url-pattern > *.jhtml </ url-pattern >
    
</ filter-mapping >


以åŽå¤§å®¶ä¸€å®šè¦æ³¨æ„啊。顺åºé—®é¢˜ä¹Ÿæ˜¯å¾ˆé‡è¦çš„ã€?br />创造共用åè®?¾|²å,éžå•†ä¸?ä¿æŒä¸€è‡? src=   除ç»ç‰¹åˆ«æ³¨æ˜Žå¤?本文章版æƒå½’莫多泡æˆö所æœ?
¾|²å,éžå•†ä¸šç”¨é€?ä¿æŒä¸€è‡?   somebody(莫多)



莫多 2006-12-27 10:37 å‘表评论
]]>
tuckey urlrewrite 3.x的问é¢?/title><link>http://www.aygfsteel.com/rory/archive/2006/12/12/tuckey-urlrewrite_3-querystring-problem.html</link><dc:creator>莫多</dc:creator><author>莫多</author><pubDate>Tue, 12 Dec 2006 02:33:00 GMT</pubDate><guid>http://www.aygfsteel.com/rory/archive/2006/12/12/tuckey-urlrewrite_3-querystring-problem.html</guid><wfw:comment>http://www.aygfsteel.com/rory/comments/87151.html</wfw:comment><comments>http://www.aygfsteel.com/rory/archive/2006/12/12/tuckey-urlrewrite_3-querystring-problem.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.aygfsteel.com/rory/comments/commentRss/87151.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/rory/services/trackbacks/87151.html</trackback:ping><description><![CDATA[昨天晚上é…ç½®myblogçš„rewrite。å‘çŽîC¸€ä¸ªå¥‡æ€ªçš„问题。由于现在ä‹É用的˜q™ä¸ªpjblogåQŒäØ“(f¨´)了让æœçƒ¦å¼•擎收录的连接有效。我æƒÏxŠŠåŽŸæ¥çš„asp˜qžæŽ¥rewrite到我的新½E‹åºä¸Šé¢ã€‚所以有˜q™æ ·ä¸€æ¡è§„则ã€?br /><br /><div style="BORDER-RIGHT: rgb(204,204,204) 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: rgb(204,204,204) 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: rgb(204,204,204) 1px solid; WIDTH: 98%; PADDING-TOP: 4px; BORDER-BOTTOM: rgb(204,204,204) 1px solid; BACKGROUND-COLOR: rgb(238,238,238)"><span style="COLOR: rgb(0,0,0)">    </span><span style="COLOR: rgb(0,0,255)"><</span><span style="COLOR: rgb(128,0,0)">rule</span><span style="COLOR: rgb(0,0,255)">></span><span style="COLOR: rgb(0,0,0)"><br />        </span><span style="COLOR: rgb(0,0,255)"><</span><span style="COLOR: rgb(128,0,0)">from</span><span style="COLOR: rgb(0,0,255)">></span><span style="COLOR: rgb(0,0,0)">^/article.asp\?id=(.*)$</span><span style="COLOR: rgb(0,0,255)"></</span><span style="COLOR: rgb(128,0,0)">from</span><span style="COLOR: rgb(0,0,255)">></span><span style="COLOR: rgb(0,0,0)"><br />        </span><span style="COLOR: rgb(0,0,255)"><</span><span style="COLOR: rgb(128,0,0)">to </span><span style="COLOR: rgb(255,0,0)">type</span><span style="COLOR: rgb(0,0,255)">="redirect"</span><span style="COLOR: rgb(0,0,255)">></span><span style="COLOR: rgb(0,0,0)">/entry/$1.jhtml</span><span style="COLOR: rgb(0,0,255)"></</span><span style="COLOR: rgb(128,0,0)">to</span><span style="COLOR: rgb(0,0,255)">></span><span style="COLOR: rgb(0,0,0)"><br />    </span><span style="COLOR: rgb(0,0,255)"></</span><span style="COLOR: rgb(128,0,0)">rule</span><span style="COLOR: rgb(0,0,255)">></span></div>     但是我这æ ïL(f¨¥ng)š„˜qžæŽ¥æ€ÀL˜¯åŒšw…ä¸åˆ°åQŒåªè¦åŽ»æŽ‰é‚£ä¸ªï¼Ÿž®±å¯ä»¥äº†ã€‚这个正则表辑ּ是没有问题的ã€?article.asp?id=64是å¯ä»¥åŒ¹é…的到的ã€?br />    åŽæ¥çœ?.0çš„manual (http://tuckey.org/urlrewrite/manual/3.0/)æ‰å‘çŽ°åŽŸæ¥æ˜¯˜q™ä¸ªçš„问题ã€?br /><h3><urlrewrite> element</h3><p>The top level element.</p><table cellspacing="0"><tbody><tr><th>Attribute</th><th>Possible Value</th><th>Explanation</th></tr><tr><td rowspan="2">default-match-type <br /><small>(optional)</small></td><td><b>regex</b> (default)</td><td>All rules and thier conditions will be processed using the Java Regular Expression engine (unless <code>match-type</code> is specified on a rule).</td></tr><tr><td>wildcard</td><td>All rules and thier conditions will be processed using the <a >Wildcard Expression engine</a> (unless <code>match-type</code> is specified on a rule).</td></tr><tr><td rowspan="3">decode-using <br /><small>(optional)</small></td><td><b>utf8</b> (default)</td><td>When URL is decoded UTF-8 will be used.</td></tr><tr><td>null</td><td>Do not decode.</td></tr><tr><td>[encoding]</td><td>Any string representing a supported character encoding eg, ISO-8859-1. See <a >Java Charset Object</a> for more info. </td></tr><tr><td style="FONT-WEIGHT: bold; COLOR: rgb(0,0,255)" rowspan="2">use-query-string <br /><small>(optional)</small></td><td><b>false</b> (default)</td><td>The query string will <em>not</em> be appended to the url that the "from" element matches against.</td></tr><tr><td>true</td><td>The query string will be appended to the url that the "from" element matches against.</td></tr><tr><td rowspan="2">use-context <br /><small>(optional)</small></td><td><b>false</b> (default)</td><td>The context path will <em>not</em> be added to the url that the "from" element matches against.</td></tr><tr><td>true</td><td>The context path will be added to the url that the "from" element matches against.</td></tr></tbody></table><br />ž®±æ˜¯é‚£ä¸ªuse-query-string 的问题,默认的是ä¸ä‹É用query-stringž®±æ˜¯æŠ?åŽé¢çš„都忽略了。所以就ä¸èƒ½åŒšw…åˆîCº†ã€‚åªè¦åœ¨<urlrewrite>里é¢åŠ ä¸€ä¸ªå±žæ€§å°±å¯ä»¥äº†ã€?br /><div style="BORDER-RIGHT: rgb(204,204,204) 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: rgb(204,204,204) 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: rgb(204,204,204) 1px solid; WIDTH: 98%; PADDING-TOP: 4px; BORDER-BOTTOM: rgb(204,204,204) 1px solid; BACKGROUND-COLOR: rgb(238,238,238)"><span style="COLOR: rgb(0,0,255)"><</span><span style="COLOR: rgb(128,0,0)">urlrewrite </span><span style="COLOR: rgb(255,0,0)">use-query-string</span><span style="COLOR: rgb(0,0,255)">="true"</span><span style="COLOR: rgb(0,0,255)">></span><span style="COLOR: rgb(0,0,0)"><br />    <img alt="" src="http://www.aygfsteel.com/images/dot.gif" /><br /></span><span style="COLOR: rgb(0,0,255)"></</span><span style="COLOR: rgb(128,0,0)">urlrewrite</span><span style="COLOR: rgb(0,0,255)">></span></div><p><a target="_blank"><img height="31" alt="创造共用åè®?¾|²å,éžå•†ä¸?ä¿æŒä¸€è‡? src="http://leaf.jdk.cn/rights.gif" width="88" border="0" /></a>   除ç»ç‰¹åˆ«æ³¨æ˜Žå¤?本文章版æƒå½’<strong><a class="" ><font color="#6b6b52">莫多泡æˆö</font></a></strong>所æœ? <br /><font color="#ff0000">¾|²å,éžå•†ä¸šç”¨é€?ä¿æŒä¸€è‡?</font>   <a title="莫多泡æˆö" target="_blank">somebody(莫多)</a></p><img src ="http://www.aygfsteel.com/rory/aggbug/87151.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/rory/" target="_blank">莫多</a> 2006-12-12 10:33 <a href="http://www.aygfsteel.com/rory/archive/2006/12/12/tuckey-urlrewrite_3-querystring-problem.html#Feedback" target="_blank" style="text-decoration:none;">å‘表评论</a></div>]]></description></item><item><title>SpringXmlrpcServiceExporter for xmlrpc3.xhttp://www.aygfsteel.com/rory/archive/2006/10/22/spring_xmlrpc3_service_exporter.html莫多莫多Sun, 22 Oct 2006 08:12:00 GMThttp://www.aygfsteel.com/rory/archive/2006/10/22/spring_xmlrpc3_service_exporter.htmlhttp://www.aygfsteel.com/rory/comments/76628.htmlhttp://www.aygfsteel.com/rory/archive/2006/10/22/spring_xmlrpc3_service_exporter.html#Feedback0http://www.aygfsteel.com/rory/comments/commentRss/76628.htmlhttp://www.aygfsteel.com/rory/services/trackbacks/76628.html      我们的项目用åˆîCº†xmlrpc,ä¸è¿‡˜q˜æ˜¯ç”¨çš„2.x版本的。由于xmlrpc3.x地推出。æä¾›äº†NULL,Serializable½{‰çš„æ”¯æŒåQŒå°†åŽŸæ¥çš„Hashtableæ”ÒŽ(gu¨©)ˆäº†Map,Vectoræ”ÒŽ(gu¨©)ˆäº†List。都是ä¸é”™çš„˜q›æ­¥ã€‚所以我们决定从xmlrpc2.xå‡çñ”到xmlrpc3.x.
      在springé‡Œé¢æœ‰å‡ ä¸ªServiceExporteråQŒorg.springframework.remoting.rmi.RmiServiceExporterã€org.springframework.remoting.caucho.HessianServiceExporterã€org.springframework.remoting.caucho.BurlapServiceExporter。丘q‡æ²¡æœ‰xmlrpcçš„serviceExporteråQŒåŽŸæ¥æˆ‘们是自己ž®è£…çš„XmlRpcServer,用servletæä¾›æœåŠ¡ã€?eg:http://localhost:8080/community/service/xmlrpc)没有和spring集æˆè™½ç„¶ç”¨äº†springã€?br />    考虑到spring的便利以å?qi¨¢ng)é…¾|®çš„åŒæ„我决定将xmlrpcService攑օ¥spring中。xmlrpc3.xå’Œxmlrpc2.x的代ç åŸºæœ¬ä¸Šæ²¡æœ‰ä¸€æ ïL(f¨¥ng)š„。改了很多东è¥Ñ€‚除了类型å˜åŒ–之外,˜q˜æ·»åŠ äº†å¯¹å¼‚å¸¸çš„æ”¯æŒã€‚详¾l†ä¿¡æ¯è¯·å‚ç…§xmlrpc3.xæºä»£ç ã€?br />XmlRpcServiceExporter.java

package  com.jdkcn.xmlrpc;

import  javax.servlet.ServletException;

/**
 * 
@author  <a href="mailto:rory.cn@gmail.com">somebody</a>
 * 
@since  2006-9-27 03:59:22 pm
 * 
@version  $Id XmlRpcServiceExporter.java$
 
*/
public   class  XmlRpcServiceExporter  extends  RemoteExporter  implements
        Controller, InitializingBean {
    
    
private  XmlRpcServletServer server;
    
    
public  String serviceName;
    
    
public  Resource configFile;
    
    
public  Boolean enabledForExtensions;
    
    
public   void  setEnabledForExtensions(Boolean enabledForExtensions) {
        
this .enabledForExtensions  =  enabledForExtensions;
    }

    
public   void  setConfigFile(Resource configFile) {
        
this .configFile  =  configFile;
    }

    
public  String getServiceName() {
        
return  serviceName;
    }

    
public   void  setServiceName(String serviceName) {
        
this .serviceName  =  serviceName;
    }

    
public  XmlRpcServletServer getXmlRpcServletServer() {
        
return  server;
    }
    
    
/*  (non-Javadoc)
     * @see org.springframework.web.servlet.mvc.Controller#handleRequest(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
     
*/
    
public  ModelAndView handleRequest(HttpServletRequest request,
            HttpServletResponse response) 
throws  Exception {
        
if  ( ! WebContentGenerator.METHOD_POST.equals(request.getMethod())) {
            
throw   new  ServletException( " XmlRpcServiceExporter only supports POST requests " );
        }
        server.execute(request, response);
        
return   null ;
    }

    
/*  (non-Javadoc)
     * @see org.springframework.beans.factory.InitializingBean#afterPropertiesSet()
     
*/
    
public   void  afterPropertiesSet()  throws  Exception {
        server 
=   new  XmlRpcServletServer();
        server.setHandlerMapping(newXmlRpcHandlerMapping());
        
if  (enabledForExtensions != null ) {
            ((XmlRpcServerConfigImpl) server.getConfig()).setEnabledForExtensions(enabledForExtensions.booleanValue());
        }
        
    }

    
/**  Creates a new handler mapping. The default implementation loads
     * a property file from the resource
     * 
     
*/
    
protected  XmlRpcHandlerMapping newXmlRpcHandlerMapping()  throws  XmlRpcException {
        
        SpringHandlerMapping mapping 
=   new  SpringHandlerMapping(getServiceInterface());
        mapping.addHandler(getServiceName(), getServiceInterface());
        mapping.setTagetObject(getProxyForService());
        
return  mapping;
    }
    
}

springé…置文äšg
    <bean id="accountService"  class="com.jdkcn.service.impl.AccountServiceImpl">
    
</bean>
        
<bean name="rpcAccountService" class="com.jdkcn.xmlrpc.XmlRpcServiceExporter">
        
<property name="service">
            
<ref bean="accountService"/>
        
</property>
        
<property name="serviceName">
            
<value>jdkcn.accountService</value>
        
</property>
        
<property name="enabledForExtensions">
            
<value>true</value>
        
</property>
        
<property name="serviceInterface">
            
<value>com.jdkcn.service.AccountService</value>
        
</property>
    
</bean>
ç„¶åŽæ˜ å°„一个地倞®±å¯ä»¥é€šè¿‡xmlrpc讉K—®æœåŠ¡äº?br />
    <bean id="urlMapping" class="org.springframework.web.servlet.handler.SimpleUrlHandlerMapping">
        
<property name="mappings">
            
<props> 
                
<prop key="/account">rpcAccountService</prop>
            
</props>
        
</property>
    
</bean>
web.xml
    <context-param>
        
<param-name>contextConfigLocation</param-name>
        
<param-value>
            classpath:spring/global.xml
        
</param-value>
    
</context-param>
    
    
<listener>
        
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
    
</listener>

        
<servlet>
            
<servlet-name>service</servlet-name>
            
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
        
</servlet>

        
<servlet-mapping>
            
<servlet-name>service</servlet-name>
            
<url-pattern>/service/xmlrpc3/*</url-pattern>
        
</servlet-mapping>
ç„¶åŽæˆ‘们的service地倞®±æ˜¯˜q™æ ·çš„http://localhost:8080/service/xmlrpc3/account

希望对大家有用,˜q™é‡Œæä¾›project下è²ã€‚包å«ä¸€ä¸ªclient½E‹åºã€‚com.jdkcn.xmlrpc.Client

点击下è²å®Œæ•´ä»£ç 

创造共用åè®?¾|²å,éžå•†ä¸?ä¿æŒä¸€è‡? src=   除ç»ç‰¹åˆ«æ³¨æ˜Žå¤?本文章版æƒå½’莫多泡æˆö所æœ?
¾|²å,éžå•†ä¸šç”¨é€?ä¿æŒä¸€è‡?   somebody(莫多)

莫多 2006-10-22 16:12 å‘表评论
]]>
关于Hibernate3çš„escape解决æ–ÒŽ(gu¨©)³•http://www.aygfsteel.com/rory/archive/2006/10/16/hibernate3_escape.html莫多莫多Mon, 16 Oct 2006 15:29:00 GMThttp://www.aygfsteel.com/rory/archive/2006/10/16/hibernate3_escape.htmlhttp://www.aygfsteel.com/rory/comments/75503.htmlhttp://www.aygfsteel.com/rory/archive/2006/10/16/hibernate3_escape.html#Feedback1http://www.aygfsteel.com/rory/comments/commentRss/75503.htmlhttp://www.aygfsteel.com/rory/services/trackbacks/75503.html
SELECT * FROM t_user where nickname like '%Goo\_D' escape '\'
˜q™é‡Œå¯¹_˜q›è¡Œè½¬ä¹‰äº†ã€‚因为用æˆäh˜µ¿U°åŒ…å«ä¸‹åˆ’线åQŒå¦‚果丘q›è¡Œè½¬ä¹‰ž®Þp¡¨½CÞZ¸€ä¸ªä“Qæ„å­—½W¦ã€‚有时候我们å¯èƒ½è¿˜éœ€è¦å¯¹%˜q›è¡Œè½¬ä¹‰ã€‚åŒæ ïL(f¨¥ng)š„æ–ÒŽ(gu¨©)³•åœ?å‰åŠ \% 但是比è“v普通的like语å¥ã€‚多了一个声明è{义符的语å¥ã€‚所以我们会(x¨¬)惛_ˆ°˜q™æ ·çš„语å?br />
DetachedCriteria criteria = DetachedCriteria.forClass(User.class);
criteria.add(Restrictions.like(
"nickname", user.getNickname()+"' escape'\"));
但是˜q™æ ·æ˜¯ä¸½Ž¡ç”¨çš„ã€?br />接下æ¥å¯èƒ½ä¼š(x¨¬)惛_ˆ°ä½¿ç”¨Hibernate3的原生sql查询åQŒå…¶å®žæˆ‘们ä¸éœ€è¦è¿™æ ·åšã€‚我们还是ä‹É用Criteriaæ¡äšg查询ã€?br />
criteria.add(Restrictions.sqlRestriction("{alias}.nickname like ? escape'/'", StringUtil.escapeSQLLike(user.getNickname()), Hibernate.STRING));
˜q™æ ·Hibernate产生的语å¥å°±æ˜¯æˆ‘们想è¦çš„语å¥äº†ã€?br />
    /**
     * 转义like语å¥ä¸­çš„
     * <code>'_'</code><code>'%'</code>
     * ž®?lt;code>'?'</code>转æˆsqlçš?lt;code>'/_'</code>
     * ž®?lt;code>'%'</code>转æˆsqlçš?lt;code>'/%'</code>
     * <p>
     *   例如æœçƒ¦<code>?aa*bb?c_d%f</code>ž®†è{化æˆ<br/>
     *   <code>_aa%bb_c/_d/%f</code>
     * </p>
     * 
@param likeStr
     * 
@return
     * 
@author <a href="http://jdkcn.com">somebody</a>
     
*/
    
public static String escapeSQLLike(String likeStr) {
        String str 
= StringUtils.replace(likeStr, "_", "/_");
        str 
= StringUtils.replace(str, "%",    "/%");
        str 
= StringUtils.replace(str, "?", "_");
        str 
= StringUtils.replace(str, "*", "%");
        
return str;
    }

创造共用åè®?¾|²å,éžå•†ä¸?ä¿æŒä¸€è‡? src=   除ç»ç‰¹åˆ«æ³¨æ˜Žå¤?本文章版æƒå½’莫多泡æˆö所æœ?
¾|²å,éžå•†ä¸šç”¨é€?ä¿æŒä¸€è‡?   somebody(莫多)

莫多 2006-10-16 23:29 å‘表评论
]]>
关于springå¯åŠ¨çš„ä¼˜åŒ–çš„é—®é¢˜http://www.aygfsteel.com/rory/archive/2006/08/10/speed_up_spring_problem.html莫多莫多Thu, 10 Aug 2006 02:59:00 GMThttp://www.aygfsteel.com/rory/archive/2006/08/10/speed_up_spring_problem.htmlhttp://www.aygfsteel.com/rory/comments/62740.htmlhttp://www.aygfsteel.com/rory/archive/2006/08/10/speed_up_spring_problem.html#Feedback2http://www.aygfsteel.com/rory/comments/commentRss/62740.htmlhttp://www.aygfsteel.com/rory/services/trackbacks/62740.html  jspark 的这½‹‡æ–‡ç« ã€?a class="postTitle2" id="viewpost1_TitleUrl" href="/jspark/archive/2006/07/29/60712.html">å¼€å‘阶ŒDµeclipse下é¢çš„spring容器的å¯åŠ¨ä¼˜åŒ?/a> 》讲到如何加快springçš„å¯åŠ¨é€Ÿåº¦ã€‚éžå¸¸æ„Ÿè°?span style="FONT-WEIGHT: bold">jspark. 一下是引用的原文:(x¨¬)

  最˜q‘在负责一个大™å¹ç›®åQŒé¡¹ç›®ç»„æˆå‘˜åŒ…括™å¹ç›®¾lç†å¤§æ¦‚10个ähå·¦å³ã€‚项目技术用struts+spring+hibernate实现。项目的规模相对æ¥è¯´æ˜¯æ¯”较大的,æ€Õd…±æœ?0大模å—,æ¯ä¸ªå¤§æ¨¡å—åˆåˆ†äØ“(f¨´)有å几个ã€ç”šè‡›_‡ å个ž®æ¨¡å—。开å‘å·¥å…ïL(f¨¥ng)”¨eclipseåQŒç”±äºŽåœ¨å¼€å‘阶ŒDµï¼Œ™å¹ç›®å¼€å‘æˆå‘˜éœ€è¦é¢‘¾Jé‡å¯æœåŠ¡å™¨ã€‚åœ¨å¯åЍæœåŠ¡å™¨çš„æ—¶å€™ï¼Œæ¯æ¬¡å¯åŠ¨æ—‰™—´æ€ÀL˜¯ä¼?x¨¬)è¶…˜q?分钟。记得以å‰åœ¨åšå¦å¤–一个项目时åQŒå¯åŠ¨æ—¶é—´ä¸åˆ?¿U’é’ŸåQŒç›¸å·®äº†10å€ï¼Œè€Œä¸”™å¹ç›®è§„模是差ä¸å¤šçš„ã€?/span>

    ä»Žåˆæ­¥åˆ†æžæ¥è¯ß_(d¨¢)¼Œåº”该是hibernate解释hbm.xml时花è´ÒŽ(gu¨©)—¶é—ß_(d¨¢)¼Œæˆ–者å¯èƒ½æ˜¯spring容器å¯åЍòq¶è§£é‡Šæ‰€æœ‰çš„beané…置文äšg。诊断了一下,å‘现1分钟消耗的旉™—´ä¸»è¦åˆ†å¸ƒåœ¨hibernate解释hbm.xmlèŠÞp´¹5¿U’ï¼›spring容器从å¯åŠ¨åˆ°è§£é‡Šbeané…置文äšg竟然èŠ×ƒº†58¿U’,真是太嚣张了。当旉™žå¸¸æ€€ç–‘spring的效率问题。ä¼å›¾ä»Ž¾|‘上æœçƒ¦ç›¸å…³èµ„æ–™åQŒçœ‹çœ‹æœ‰ä»€ä¹ˆä¼˜åŒ–措施ã€?/span>

    首先是找åˆîCº†hibernateçš„å¯åŠ¨ä¼˜åŒ?http://www.hibernate.org/194.html  里é¢çš„ä¸»è¦æ€æƒ³æ˜¯é€šè¿‡ž®†xmlåºåˆ—花到本地的文仉™‡ŒåQŒæ¯‹Æ¡è¯»å–çš„æ—¶å€™æ ¹æ®æƒ…况,从本地文件读å–åÆˆååºåˆ—化åQŒèŠ‚çœäº†hibernate xmlçš„è§£æžæ—¶é—´ã€‚æŒ‰ç…§è¿™ä¸ªæ–¹å¼æµ‹è¯•了一下,å‘现hibernateçš„å¯åŠ¨æ—¶é—´ä»Ž5¿U’é™ä½Žåˆ°3¿U’,但是˜q™ä¸ªä¼˜åŒ–对于整个å¯åЍ˜q‡ç¨‹æ˜¯æ¯æ°´èžR薪的åQŒæ¯«æ— ç”¨å¤„ã€?/span>

    没办法,åˆä»”¾l†æŸ¥çœ‹äº†spring的资料,¾lˆäºŽå‘现spring的容器是æä¾›äº†lazy-load的,å³é»˜è®¤çš„¾~ºçœè®„¡½®æ˜¯bean没有lazy- loadåQŒè¯¥å±žæ€§å¤„于false状æ€ï¼Œ˜q™æ ·å¯ÆD‡´spring在å¯åŠ¨è¿‡½E‹å¯¼è‡´åœ¨å¯åŠ¨æ—¶å€™ï¼Œä¼?x¨¬)默认加载整个对象实例图åQŒä»Žåˆå§‹åŒ–ACTIONé…ç½®ã€åˆ° serviceé…置到daoé…ç½®ã€ä¹ƒè‡›_ˆ°æ•°æ®åº“连接ã€äº‹åŠ¡ç­‰½{‰ã€‚这么庞大的规模åQŒé𾿀ªspringçš„å¯åŠ¨æ—¶é—´è¦èб将˜q?分钟。å°è¯•了一下,把beansçš?default-lazy-initæ”¹äØ“(f¨´)truež®±ï¼Œå†æ¬¡å¯åЍåQŒé€Ÿåº¦ä»ŽåŽŸæ¥çš„55¿U’,é™åˆ°8¿U’é’ŸåQï¼GreatåQ虽然是éžå¸¸ž®ä¸€ä¸ªæ”¹åŠ¨ï¼Œä½†æ˜¯å½±å“¼‹®å®žéžå¸¸å¤§ã€‚一个项目组10个ähåQŒå‡è‹¥æ¯ä¸ªäh一天åã^å‡éœ€è¦åœ¨eclipse下å¯åŠ¨æµ‹è¯•æœåС噍50‹Æ¡ã€‚那么一天项目组需è¦é‡å?00‹Æ¡ï¼Œæ¯æ¬¡èŠ‚çœ50¿U’çš„è¯ï¼Œž®±æ˜¯ 25000¿U’,ž®†è¿‘几个ž®æ—¶åQŒå·®ä¸å¤šä¸€ä¸ªå·¥ä½œæ—¥åQŒå¤šä¹ˆå¯è§‚的数字åQ?/span>

   ä¸è¿‡åœ¨è¿è¡ŒæœŸé—´ç¬¬ä¸€‹Æ¡ç‚¹™åµé¢çš„æ—¶å€™ï¼Œç”׃ºŽspringåšäº†lazy-loadåQŒçŽ°åœ¨å°±éœ€è¦å¯åŠ¨ä¸€éƒ¨åˆ†éœ€è¦çš„beansåQŒæ‰€ä»¥ç¨å¾®æ…¢2åQ?¿U’é’ŸåQŒä½†æ˜¯æ˜Žæ˜¾æ¯”½{‰å‡ åç§’è¦å¿«å¾ˆå¤šåQŒå€¼å¾—一鉴ã€?/span>

    以上是针对开å‘阶ŒD늚„spring容器å¯åŠ¨ä¼˜åŒ–åQŒåœ¨éƒ¨çÖv到实际环境中åQŒå€’是没必è¦è®¾¾|®äØ“(f¨´)lazy-load。毕竟部¾|²åˆ°å®žé™…çŽ¯å¢ƒä¸­ä¸æ˜¯ç»å¸¸çš„äº‹ï¼Œæ¯æ¬¡å¯åЍ1åˆ†é’Ÿå€’ä¸æ˜¯å¤§é—®é¢˜ã€?

æˆ‘è¿™é‡Œè¦æé†’çš„æ˜¯ä¸æ˜¯è¯´æœ‰çš„beans都能讄¡½®default-lazy-initæˆäØ“(f¨´)true.对于schedulerçš„beanä¸èƒ½ç”¨lazy-init

< beans  default-lazy-init ="true" >
    
    
< bean  class ="org.springframework.scheduling.quartz.SchedulerFactoryBean" >
        
< property  name ="triggers" >
            
< list >
                
< ref  bean ="buildHtmlTrigger" />
                
< ref  bean ="askTrigger" />
                
< ref  bean ="mailSenderTrigger" />
                
< ref  bean ="topicDetailBuildTrigger" />
                
< ref  bean ="forumBuildTrigger" />
                
< ref  bean ="topicBuildTrigger" />
            
</ list >
        
</ property >
    
</ bean >
</ beans >




˜q™æ ·çš„è¯ã€‚所有的schedulerž®±éƒ½ä¸ç®¡ç”¨äº†ã€‚æ‰€ä»¥è¯·å¤§å®¶è¦æ³¨æ„ã€?br />

< beans >
    
    
< bean  class ="org.springframework.scheduling.quartz.SchedulerFactoryBean" >
        
< property  name ="triggers" >
            
< list >
                
< ref  bean ="buildHtmlTrigger" />
                
< ref  bean ="askTrigger" />
                
< ref  bean ="mailSenderTrigger" />
                
< ref  bean ="topicDetailBuildTrigger" />
                
< ref  bean ="forumBuildTrigger" />
                
< ref  bean ="topicBuildTrigger" />
            
</ list >
        
</ property >
    
</ bean >
</ beans >


 



]]>
˜q˜æ˜¯ä¹Þq é—®é¢˜http://www.aygfsteel.com/rory/archive/2006/07/22/59567.html莫多莫多Sat, 22 Jul 2006 10:13:00 GMThttp://www.aygfsteel.com/rory/archive/2006/07/22/59567.htmlhttp://www.aygfsteel.com/rory/comments/59567.htmlhttp://www.aygfsteel.com/rory/archive/2006/07/22/59567.html#Feedback4http://www.aygfsteel.com/rory/comments/commentRss/59567.htmlhttp://www.aygfsteel.com/rory/services/trackbacks/59567.html     虽然™å¹ç›®å…¨éƒ¨é‡‡ç”¨äº†UTF-8¾~–ç åQŒæ‰€æœ‰çš„æºæ–‡ä»?.java,*.jsc,*.html,*.ftl都采用了UTF-8¾~–ç ã€‚坿˜¯è¿˜æ˜¯å‡ºçŽîCº†ä¹Þq é—®é¢˜ã€‚很是ä¸çˆ½ï¼ŒåŽæ¥æ‰‘Öˆ°äº†tomcatåQŒå’Œresin的酾|®ã€?/p>
  1. Tomcat的酾|®ã€?conf/server.xml)
        <!-- Define a non-SSL HTTP/1.1 Connector on port 8080 -->
        
    <Connector port="80" maxHttpHeaderSize="8192"
                   maxThreads
    ="150" minSpareThreads="25" maxSpareThreads="75"
                   enableLookups
    ="false" redirectPort="8443" acceptCount="100"
                   connectionTimeout
    ="20000" disableUploadTimeout="true" URIEncoding="UTF-8"/>
  2. Resin的酾|®ã€?conf/resin.conf)

    character-encoding

    Resin 1.1
    child of: resin, server, host-default, host, web-app-default, web-app
    default: The default value is ISO-8859-1.

    Specifies the default character encoding for the environment.

    <web-app id='/'>
      <character-encoding>shift_jis</character-encoding>
      ...
    
    </web-app>
    

     ˜q™ä¸ªæ˜¯resin doc里é¢çš„æˆ‘是在web-app-default里é¢åŠ ä¸Šäº†encoding的酾|?/p>

     < web-app-default >
      
< character-encoding > UTF-8 </ character-encoding >
      
    
</ web-app-default >

希望对你的项目有帮助�/p>

创造共用åè®?¾|²å,éžå•†ä¸?ä¿æŒä¸€è‡? src=    除ç»ç‰¹åˆ«æ³¨æ˜Žå¤?本文章版æƒå½’莫多泡æˆö所æœ?
¾|²å,éžå•†ä¸šç”¨é€?ä¿æŒä¸€è‡?   somebody(莫多)  



莫多 2006-07-22 18:13 å‘表评论
]]>
关于Resin虚拟目录é…置的问é¢?/title><link>http://www.aygfsteel.com/rory/archive/2006/07/18/58838.html</link><dc:creator>莫多</dc:creator><author>莫多</author><pubDate>Tue, 18 Jul 2006 11:41:00 GMT</pubDate><guid>http://www.aygfsteel.com/rory/archive/2006/07/18/58838.html</guid><wfw:comment>http://www.aygfsteel.com/rory/comments/58838.html</wfw:comment><comments>http://www.aygfsteel.com/rory/archive/2006/07/18/58838.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.aygfsteel.com/rory/comments/commentRss/58838.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/rory/services/trackbacks/58838.html</trackback:ping><description><![CDATA[™å¹ç›®ä¸­å¤šä¸ªé¡¹ç›®éœ€è¦åŒæ—¶å¼•ç”¨ä¸€ä¸ªé™æ€èµ„æºï¼Œæ‰€ä»¥å°±æƒ›_ˆ°é…ç½®ä¸åŒçš„虚拟目录指到åŒä¸€ä¸ªç›®å½•。于是有下é¢çš„é…¾|?<br /><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"><span style="COLOR: #000000">    </span><span style="COLOR: #008000"><!--</span><span style="COLOR: #008000"> configures the default host, matching any host name </span><span style="COLOR: #008000">--></span><span style="COLOR: #000000"><br />    </span><span style="COLOR: #0000ff"><</span><span style="COLOR: #800000">host </span><span style="COLOR: #ff0000">id</span><span style="COLOR: #0000ff">=""</span><span style="COLOR: #ff0000"> root-directory</span><span style="COLOR: #0000ff">="."</span><span style="COLOR: #0000ff">></span><span style="COLOR: #000000"><br />      </span><span style="COLOR: #008000"><!--</span><span style="COLOR: #008000"><br />         - configures an explicit root web-app matching the<br />         - webapp's ROOT<br />        </span><span style="COLOR: #008000">--></span><span style="COLOR: #000000"><br />      </span><span style="COLOR: #0000ff"><</span><span style="COLOR: #800000">web-app </span><span style="COLOR: #ff0000">id</span><span style="COLOR: #0000ff">="/"</span><span style="COLOR: #ff0000"> document-directory</span><span style="COLOR: #0000ff">="webapps/ROOT"</span><span style="COLOR: #0000ff">/></span><span style="COLOR: #000000"><br />      </span><span style="COLOR: #0000ff"><</span><span style="COLOR: #800000">web-app </span><span style="COLOR: #ff0000">id</span><span style="COLOR: #0000ff">="/community/jsvm2"</span><span style="COLOR: #ff0000"> document-directory</span><span style="COLOR: #0000ff">="D:\\projects\\FelooComponents\\jsvm2"</span><span style="COLOR: #0000ff">/></span><span style="COLOR: #000000"><br />      </span><span style="COLOR: #0000ff"><</span><span style="COLOR: #800000">web-app </span><span style="COLOR: #ff0000">id</span><span style="COLOR: #0000ff">="/passport/jsvm2"</span><span style="COLOR: #ff0000"> document-directory</span><span style="COLOR: #0000ff">="D:\\projects\\FelooComponents\\jsvm2"</span><span style="COLOR: #0000ff">/></span><span style="COLOR: #000000"><br />    </span><span style="COLOR: #0000ff"></</span><span style="COLOR: #800000">host</span><span style="COLOR: #0000ff">></span></div><p>       但是å‘现˜q™æ ·åªæœ‰åŽé¢ä¸€ä¸ªç®¡ç”?<a href="http://localhost:8080/passport/jsvm2">http://localhost:8080/passport/jsvm2</a>)˜q™ä¸ªæ˜¯å¯ä»?坿˜¯(<a href="http://localhost:8080/community/jsvm2">http://localhost:8080/community/jsvm2</a>)ž®×ƒ¸è¡?很是éƒé—·ã€‚åªè¦åŽé¢çš„document-directory䏿˜¯åŒä¸€ä¸ªç›®å½•å°±æˆã€?br />       åŽæ¥åœ¨resinçš„doc里é¢çœ‹åˆ°path的酾|?/p><h4>path-mapping</h4><div id="wmqeeuq" class="desc"><b>child of:</b> web-app-default, web-app<br /><p>Maps url patterns to real paths. If using a server like IIS, you may need to match the server's path aliases.</p><p></p><table class="deftable" cellspacing="0" cellpadding="2" width="90%" border="1"><tbody><tr><th>Attribute</th><th>Meaning</th><th>default</th></tr><tr><td><span id="wmqeeuq" class="meta">url-pattern</span></td><td>A pattern matching the url: <span id="wmqeeuq" class="meta">/foo/*</span>, <span id="wmqeeuq" class="meta">/foo</span>, or <span id="wmqeeuq" class="meta">*.foo</span></td></tr><tr><td>url-regexp</td><td>A regular expression matching the url </td></tr><tr><td>real-path</td><td>The prefix of the real path. When used with <span id="wmqeeuq" class="meta">url-regexp</span>, allows substitution variables like <span id="wmqeeuq" class="meta">$1</span>. </td></tr></tbody></table><p></p><table class="egpad" cellspacing="0" width="90%"><tbody><tr><td class="example" bgcolor="#ffeecc"><pre><web-app id='/'> <path-mapping url-pattern='/resin/*' real-path='e:\resin'/> <path-mapping url-regexp='/~([^/]*)' real-path='e:\home$1'/> </web-app> </pre></td></tr></tbody></table></div><p>æ”ÒŽ(gu¨©)­£˜q™æ ·çš„é…¾|®å°±ok了ã€?/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"><span style="COLOR: #000000">        </span><span style="COLOR: #0000ff"><</span><span style="COLOR: #800000">web-app </span><span style="COLOR: #ff0000">id</span><span style="COLOR: #0000ff">="/community"</span><span style="COLOR: #ff0000"> document-directory</span><span style="COLOR: #0000ff">="D:\\projects\\FelooCommunityWeb"</span><span style="COLOR: #0000ff">></span><span style="COLOR: #000000"><br />          </span><span style="COLOR: #0000ff"><</span><span style="COLOR: #800000">path-mapping </span><span style="COLOR: #ff0000">url-pattern</span><span style="COLOR: #0000ff">='jsvm2/*'<br />              </span><span style="COLOR: #ff0000">real-path</span><span style="COLOR: #0000ff">='D:\\projects\\FelooComponents\\jsvm2'/><br />      </span><span style="COLOR: #ff0000"></web-app</span><span style="COLOR: #0000ff">></span><span style="COLOR: #000000"><br />      <br />            </span><span style="COLOR: #0000ff"><</span><span style="COLOR: #800000">web-app </span><span style="COLOR: #ff0000">id</span><span style="COLOR: #0000ff">="/passport"</span><span style="COLOR: #ff0000"> document-directory</span><span style="COLOR: #0000ff">="D:\\projects\\FelooPassportWeb"</span><span style="COLOR: #0000ff">></span><span style="COLOR: #000000"><br />          </span><span style="COLOR: #0000ff"><</span><span style="COLOR: #800000">path-mapping </span><span style="COLOR: #ff0000">url-pattern</span><span style="COLOR: #0000ff">='jsvm2/*'<br />              </span><span style="COLOR: #ff0000">real-path</span><span style="COLOR: #0000ff">='D:\\projects\\FelooComponents\\jsvm2'/><br />      </span><span style="COLOR: #ff0000"></web-app</span><span style="COLOR: #0000ff">></span></div><a target="_blank"><img height="31" alt="创造共用åè®?¾|²å,éžå•†ä¸?ä¿æŒä¸€è‡? src="http://leaf.jdk.cn/rights.gif" width="88" border="0" /></a>   除ç»ç‰¹åˆ«æ³¨æ˜Žå¤?本文章版æƒå½’<strong><a class="" title="" target=""><font color="#6b6b52">莫多泡æˆö</font></a></strong>所æœ? <br /><font color="#ff0000">¾|²å,éžå•†ä¸šç”¨é€?ä¿æŒä¸€è‡?</font>   somebody(莫多)<img src ="http://www.aygfsteel.com/rory/aggbug/58838.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/rory/" target="_blank">莫多</a> 2006-07-18 19:41 <a href="http://www.aygfsteel.com/rory/archive/2006/07/18/58838.html#Feedback" target="_blank" style="text-decoration:none;">å‘表评论</a></div>]]></description></item><item><title>关于DWR2.0的酾|®é—®é¢?/title><link>http://www.aygfsteel.com/rory/archive/2006/07/17/58484.html</link><dc:creator>莫多</dc:creator><author>莫多</author><pubDate>Sun, 16 Jul 2006 18:11:00 GMT</pubDate><guid>http://www.aygfsteel.com/rory/archive/2006/07/17/58484.html</guid><wfw:comment>http://www.aygfsteel.com/rory/comments/58484.html</wfw:comment><comments>http://www.aygfsteel.com/rory/archive/2006/07/17/58484.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.aygfsteel.com/rory/comments/commentRss/58484.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/rory/services/trackbacks/58484.html</trackback:ping><description><![CDATA[<p>自从æ¢å·¥ä½œä¹‹åŽå°±æ²¡æœ‰ç ”ç©¶˜q‡DWR了。下载了最新的DWR2.0M2版本ã€?.0加了很多东西åQŒä¹Ÿæœ‰ä¸ž®‘å˜åŒ–的地方。最å®ÒŽ(gu¨©)˜“看到的å˜åŒ–就是包åçš„å˜åŒ–äº?ç”?<strong>uk.ltd.getahead </strong>å˜æˆäº?<strong>org.directwebremoting </strong>ã€?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"> <span style="COLOR: #000000">    </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">servlet</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />        </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">servlet-name</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000">dwr-invoker</span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">servlet-name</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />        </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">servlet-class</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000">org.directwebremoting.servlet.DwrServlet</span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">servlet-class</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />        </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">init-param</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />          </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">param-name</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000">debug</span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">param-name</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />          </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">param-value</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000">true</span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">param-value</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />        </span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">init-param</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />        </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">load-on-startup</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000">1</span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">load-on-startup</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />    </span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">servlet</span> <span style="COLOR: #0000ff">></span> </div> <p>å¯åЍæœåŠ¡åQŒæŠ±é”™äº†ã€?/p> <p>java.lang.IllegalArgumentExcep<wbr></wbr>tion: DefaultContainer can't find a classes<br />       at org.directwebremoting.impl<wbr></wbr>.DefaultContainer.getBean(DefaultContainer.java:216)<br />       at org.directwebremoting.annotati<wbr></wbr>ons.AnnotationsConfigurator<wbr></wbr>.configure(AnnotationsConfigurator.java:50)<br />       at org.directwebremoting.servlet<wbr></wbr>.DwrServlet.init(DwrServlet.java:121)</p> <p>      在DWRçš„Maillisté‡Œé¢æœçƒ¦äº†ä¸€ä¸‹ï¼Œ˜q˜æœ‰½{”案åQŒåŽŸæ¥DWR2.0 加入了JDK5的注é‡?<span id="wmqeeuq" class="st" id="st" name="st">annotations</span>).DwrServletåˆå§‹åŒ–的时候会(x¨¬)åŽÀL£€æŸ¥æ³¨é‡Šçš„¾c»ï¼Œæ‰¾ä¸åˆ°å°±æŠ±é”™äº†ã€‚如果你ä¸ç”¨annotations也å¯ä»¥å¿½ç•¥æŽ‰˜q™ä¸ªé”™è¯¯ã€‚丘q‡çœ‹èµäh¥æ€ÀL˜¯ä¸çˆ½ã€‚有人æå‡ÞZº†æ–ÒŽ(gu¨©)¡ˆã€‚这样就ok了ã€?/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"> <span style="COLOR: #000000">    </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">servlet</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />        </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">servlet-name</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000">dwr-invoker</span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">servlet-name</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />        </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">servlet-class</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000">org.directwebremoting.servlet.DwrServlet</span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">servlet-class</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />        </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">init-param</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />          </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">param-name</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000">debug</span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">param-name</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />          </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">param-value</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000">true</span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">param-value</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />        </span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">init-param</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />        </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">init-param</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />           </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">param-name</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000">classes</span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">param-name</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />           </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">param-value</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000">java.lang.Object</span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">param-value</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />        </span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">init-param</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />        </span> <span style="COLOR: #0000ff"><</span> <span style="COLOR: #800000">load-on-startup</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000">100</span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">load-on-startup</span> <span style="COLOR: #0000ff">></span> <span style="COLOR: #000000"> <br />    </span> <span style="COLOR: #0000ff"></</span> <span style="COLOR: #800000">servlet</span> <span style="COLOR: #0000ff">></span> </div> <p> <a target="_blank"> <img height="31" alt="创造共用åè®?¾|²å,éžå•†ä¸?ä¿æŒä¸€è‡? src="http://leaf.jdk.cn/rights.gif" width="88" border="0" /> </a>   除ç»ç‰¹åˆ«æ³¨æ˜Žå¤?本文章版æƒå½’<strong><a class="" title="" target=""><font color="#6b6b52">莫多泡æˆö</font></a></strong>所æœ? <br /><font color="#ff0000">¾|²å,éžå•†ä¸šç”¨é€?ä¿æŒä¸€è‡?</font>   somebody(莫多)   </p><img src ="http://www.aygfsteel.com/rory/aggbug/58484.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/rory/" target="_blank">莫多</a> 2006-07-17 02:11 <a href="http://www.aygfsteel.com/rory/archive/2006/07/17/58484.html#Feedback" target="_blank" style="text-decoration:none;">å‘表评论</a></div>]]></description></item><item><title>关于Freemarker生æˆé™æ€æ–‡ä»¶çš„问题http://www.aygfsteel.com/rory/archive/2006/06/21/54134.html莫多莫多Wed, 21 Jun 2006 02:46:00 GMThttp://www.aygfsteel.com/rory/archive/2006/06/21/54134.htmlhttp://www.aygfsteel.com/rory/comments/54134.htmlhttp://www.aygfsteel.com/rory/archive/2006/06/21/54134.html#Feedback0http://www.aygfsteel.com/rory/comments/commentRss/54134.htmlhttp://www.aygfsteel.com/rory/services/trackbacks/54134.html使用FreeMarker生æˆHtml陿€æ–‡ä»?实例)ã€?br />      在我们的™å¹ç›®ä¸­ä¹Ÿç”¨åˆ°äº†Freemarker生æˆé™æ€æ–‡ä»¶ã€‚丘q‡è¿™é‡Œæˆ‘è¦è¯´çš„æ˜¯¾~–ç çš„问题。我们的™å¹ç›®ä½¿ç”¨çš„都是UTF-8¾~–ç åQŒæˆ‘直接使用 飞云ž®ä¾  æä¾›çš„æ–¹æ³•生æˆçš„æ–‡äšg在UTF-8¾~–ç ä¸‹å¯Ÿçœ‹æ˜¯ä¹Þq åQŒè€ŒGBK正常(åŽæ¥å‘çŽ°å› äØ“(f¨´)我用的中文æ“作系¾lŸæ‰€ä»¥ç”¨GBK查看正常)ã€?br />      当然我把Freemarker的酾|®éƒ½æ”ÒŽ(gu¨©)ˆäº†UTF-8åQŒæˆ‘的模版文件也是UTF-8¾~–ç çš„ã€‚ä¸‹é¢æ˜¯åŽŸæ¥çš„代ç ?br />
    public void setTemplatePath(Resource templatePath) {
        
this.templatePath = templatePath;
        
//讄¡½®freemarkerçš„å‚æ•?/span>
        freemarkerCfg = new Configuration();
        
try {
            freemarkerCfg.setDirectoryForTemplateLoading(
this.templatePath.getFile());
            freemarkerCfg.setObjectWrapper(
new DefaultObjectWrapper());
            freemarkerCfg.setDefaultEncoding(
"UTF-8");
        } 
catch (IOException ex) {
            
throw new SystemException("No Directory found,please check you config.");
        }
    }
    /**
     * 生æˆé™æ€æ–‡ä»?br />     * 
@param templateFileName 模版åç§°eg:(biz/order.ftl)
     * 
@param propMapÂ ç”¨äºŽå¤„ç†æ¨¡æ¿çš„属性Object映射 
     * 
@param htmlFilePath è¦ç”Ÿæˆçš„陿€æ–‡ä»¶çš„路径,相对讄¡½®ä¸­çš„æ ¹èµ\å¾?例如 "/biz/2006/5/" 
     * 
@param htmlFileName è¦ç”Ÿæˆçš„æ–‡äšgå?例如 "123.htm" 
     * 
@return
     
*/
    
private boolean buildHtml(String templateFileName,Map propMap, String htmlFilePath,String htmlFileName){
        
try {
            Template template 
= freemarkerCfg.getTemplate(templateFileName);
            template.setEncoding(
"UTF-8");
            
//创å¾ç”Ÿæˆæ–‡äšg目录
            creatDirs(buildPath.getFilename(),htmlFilePath);
            File htmlFile 
= new File(buildPath + htmlFilePath + htmlFileName);
            Writer out 
= new BufferedWriter(new OutputStreamWriter(new FileOutputStream(htmlFile)));
            template.process(propMap,out);
            out.flush();
            
return true;
        } 
catch (TemplateException ex){
            log.error(
"Build Error"+templateFileName,ex);
            
return false;
        } 
catch (IOException e) {
            log.error(
"Build Error"+templateFileName,e);
            
return false;
        }
        
    }
䏋颿˜¯ä¿®æ”¹ä¹‹åŽçš„代ç 
    /**
     * 生æˆé™æ€æ–‡ä»?br />     * 
@param templateFileName 模版åç§°eg:(biz/order.ftl)
     * 
@param propMapÂ ç”¨äºŽå¤„ç†æ¨¡æ¿çš„属性Object映射 
     * 
@param htmlFilePath è¦ç”Ÿæˆçš„陿€æ–‡ä»¶çš„路径,相对讄¡½®ä¸­çš„æ ¹èµ\å¾?例如 "/biz/2006/5/" 
     * 
@param htmlFileName è¦ç”Ÿæˆçš„æ–‡äšgå?例如 "123.htm" 
     * 
@return
     
*/
    
private boolean buildHtml(String templateFileName,Map propMap, String htmlFilePath,String htmlFileName){
        
try {
            Template template 
= freemarkerCfg.getTemplate(templateFileName);
            template.setEncoding(
"UTF-8");
            
//创å¾ç”Ÿæˆæ–‡äšg目录
            creatDirs(buildPath.getFilename(),htmlFilePath);
            File htmlFile 
= new File(buildPath + htmlFilePath + htmlFileName);
            Writer out 
= new BufferedWriter(new OutputStreamWriter(new FileOutputStream(htmlFile),"UTF-8"));
            template.process(propMap,out);
            out.flush();
            
return true;
        } 
catch (TemplateException ex){
            log.error(
"Build Error"+templateFileName,ex);
            
return false;
        } 
catch (IOException e) {
            log.error(
"Build Error"+templateFileName,e);
            
return false;
        }
        
    }
原因ž®±åœ¨äºŽOutputStreamWriterçš„ä¸åŒæž„造方æ³?br />
OutputStreamWriter(OutputStream out)
          创å¾ä½¿ç”¨é»˜è®¤å­—符¾~–ç çš?OutputStreamWriterã€?br />
OutputStreamWriter(OutputStream out, String charsetName)
          创å¾ä½¿ç”¨æŒ‡å®šå­—符集的 OutputStreamWriterã€?br />
 
˜q™ä¸ªæ˜¯ä¸­æ–‡JDK的文档说明,刚开始我使用默认的构造函敎ͼŒæ‰€ä»¥ä‹É用了¾pÈ»Ÿé»˜è®¤çš„ç¼–ç ï¼ŒGBKåQŒæ‰€ä»¥åœ¨ç”Ÿæˆé™æ€æ–‡ä»¶çš„æ—¶å€™æŠŠUTF-8内容用GBK¾~–ç å†™å…¥äº†ï¼Œæ‰€ä»¥åœ¨UTF-8下æµè§ˆå°±æœ‰é—®é¢˜ã€?br />
˜q˜æœ‰å…³äºŽä¿®æ”¹æ¨¡ç‰ˆæ–‡äšgåŒæ ·ä¹Ÿè¦æ³¨æ„˜q™ä¸ªé—®é¢˜ã€?br />
    public String loadTemplate(String templateName) {
        StringBuffer sb 
= new StringBuffer();
        
try {
            File file 
= new File(templatePath+"/"+templateName);
            BufferedReader reader 
= new BufferedReader(new InputStreamReader(new FileInputStream(file),"UTF-8"));
            String line 
= reader.readLine();
            
while(line != null)    {
                sb.append(line);
                sb.append(
"\r\n");
                line 
= reader.readLine();
            }
            reader.close();
        } 
catch (IOException e) {
            
throw new SystemException("Loading template Error:",e);
        }
        
return sb.toString();
    }
    public void saveTemplate(String templateName, String templateContent) {
        
try {
            File file 
= new File(templatePath + "/" + templateName);
            Writer out 
= new BufferedWriter(new OutputStreamWriter(new FileOutputStream(file),"UTF-8"));
            out.write(templateContent);
            out.flush();
            
//扔出templatesave事äšg
            TemplateSaveEvent evt = new TemplateSaveEvent();
            evt.setTemplateName(templateName);
            dispatchTemplateEvent(evt);
        } 
catch (IOException e) {
            
throw new SystemException("Write template Error",e);
        }
    }



莫多 2006-06-21 10:46 å‘表评论
]]>
Ö÷Õ¾Ö©Öë³ØÄ£°å£º ÎäÇåÇø| ÓàÇìÏØ| »ÆÆ½ÏØ| ÓÈÏªÏØ| ¹«Ö÷ÁëÊÐ| ÓÎÏ·| ÈÚË®| Íû¶¼ÏØ| ¸ÓÓÜÏØ| ºÏɽÊÐ| ÓÀ´ºÏØ| ¼ÃÑôÏØ| ÓÀ¼ÃÊÐ| äÒÖÐÏØ| ÖîôßÊÐ| ¤Î÷ÏØ| Èð½ðÊÐ| °àÂêÏØ| ´óÆÒÏØ| ɳÍåÏØ| ¾°µÂÕòÊÐ| ·ï»ËÏØ| ¾°ºéÊÐ| ¹ØÁë| ºôÂ×±´¶ûÊÐ| ÀÈ·»ÊÐ| ½ðÉ½Çø| ËþºÓÏØ| °²ÒåÏØ| µ±ÑôÊÐ| ºÊÔóÊÐ| ¹ã·áÏØ| ¹àÔÆÏØ| ¼ªÁÖÊ¡| ÀúÊ·| ÖÐɽÊÐ| Çå·áÏØ| èëÄÏÏØ| ÑÓ¼ªÊÐ| ³¤°×| èï´¨ÏØ|