<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" 
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
<title>簡睿隨筆 《科技篇》-編程生涯</title>
<link>http://blog.roodo.com/emisjerry/archives/cat_4462.html</link>
<description>
  
    
      學習過程的各項紀錄與備忘
:::看不到圖請連我
的Xuite主站::
      
      
      
       
      
    
    
      





      
 

      

      
        
          
            
              
              輸
入您的搜尋字詞
              
            
          
        
        提
交搜尋表單
      
      
    
  





_uacct = &quot;UA-123122-2&quot;;
urchinTracker();

</description>
<language>zh-tw</language>
<generator>Roodo Blog System</generator>
<copyright>All Rights Reserved</copyright>
<atom:link href="http://blog.roodo.com/emisjerry/archives/cat_4462.xml" rel="self" type="application/rss+xml" />
<item>
	<title>DZone推出了超美觀速查表網站</title>
	<description><![CDATA[
			 沒想到看來毫不起眼的速查表（Cheat Sheet）也能做到如此專業與美觀！DZone Network推出了REFCARDZ網站，由多名書籍作 者操刀，彙集了多種電腦資訊領域的速查表，雖說是為了推銷網站上的電腦書籍（Manning Publications的in Action系列），但仍有值得參考與可觀之處。以下列出幾個我有興趣的速查表： IntelliJ IDEA：有7頁jQuery Selectors：有6頁Design PatternsNetBeans IDE 6.1 Java EditorWindows PowerShellSpring configurationGetting Started with Ajax．．．似乎是每周推出一個表，Core CSS 2排到9月22日了 取得的方法很簡單：到Dzone註冊一下， 再登入就能點選要下載的速查表，DZone會把速查表PDF檔寄到你填的信箱裡。  ## 
		]]>
	</description>
	<content:encoded><![CDATA[
			 <img style="border: 0px solid ; width: 272px; height: 343px; float: left" src="http://1eddqg.bay.livefilestore.com/y1pHEFKvXGUobqwq-bS3tjje8xz6xaz88WRDOCoFE55EIPLpdo7eBwm4OdYWCS1K84E9yMJ8MVMX2M8XOGar5Q8yw/refcard.png" alt="Refcardz" hspace="30" />沒想到看來毫不起眼的速查表（Cheat Sheet）也能做到如此專業與美觀！<a href="http://www.dzone.com/" target="_blank">DZone Network</a>推出了<a href="http://refcardz.dzone.com/" target="_blank">REFCARDZ</a>網站，由多名書籍作 者操刀，彙集了多種電腦資訊領域的速查表，雖說是為了推銷網站上的電腦書籍（Manning Publications的in Action系列），但仍有值得參考與可觀之處。以下列出幾個我有興趣的速查表：<br /> <ul><li>IntelliJ IDEA：有7頁</li><li>jQuery Selectors：有6頁</li><li>Design Patterns</li><li>NetBeans IDE 6.1 Java Editor</li><li>Windows PowerShell</li><li>Spring configuration</li><li>Getting Started with Ajax</li><li>．．．</li><li>似乎是每周推出一個表，Core CSS 2排到9月22日了</li></ul> 取得的方法很簡單：到<a href="http://www.dzone.com/" target="_blank">Dzone</a>註冊一下， 再登入就能點選要下載的速查表，DZone會把速查表PDF檔寄到你填的信箱裡。<br /> <br /> ## 
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/6930615.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/6930615.html</guid>
	<category>編程生涯</category>
	<pubDate>Fri, 22 Aug 2008 22:51:45 +0800</pubDate>
</item>
<item>
	<title>原來IntelliJ IDEA也有中文的網站</title>
	<description><![CDATA[
			我使用的主力開發語言是Java，使用得最久的IDE就是IntelliJ IDEA了，一直以為有關IDEA的資訊都只有英文版，沒想到昨天為了查JSP Debug的問題而發現到了一個的IntelliJ IDEA中文愛好者的簡體網站，這個網站以中文介紹了許多與IDEA相關的文章，也推薦了不少方便的Plugins，如果你也有使用IDEA，這個網站值得參訪，不過，要耐心點，點線速度有些慢。  ##  
		]]>
	</description>
	<content:encoded><![CDATA[
			我使用的主力開發語言是Java，使用得最久的IDE就是<a href="http://www.jetbrains.com/" target="_blank">IntelliJ IDEA</a>了，一直以為有關IDEA的資訊都只有英文版，沒想到昨天為了查JSP Debug的問題而發現到了一個的<a href="http://www.intellij.org.cn/portal/" target="_blank">IntelliJ IDEA中文愛好者</a>的簡體網站，這個網站以中文介紹了許多與IDEA相關的文章，也推薦了不少方便的Plugins，如果你也有使用IDEA，這個網站值得參訪，不過，要耐心點，點線速度有些慢。<br /> <br /> ##<br />  
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/6928295.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/6928295.html</guid>
	<category>編程生涯</category>
	<pubDate>Fri, 22 Aug 2008 21:38:38 +0800</pubDate>
</item>
<item>
	<title>幾篇值得注意的Subversion相關文章</title>
	<description><![CDATA[
			今天看到的幾篇值得注意的Subversion相關文章，先留個紀錄：Subversion branching in my experienceSubversion Cheat SheetLearning how to resolve conflicts within Subversion (SVN) using TortoiseSVNHow To Upgrade WordPress Using SubversionIntroduction to Subversion for .NET Developers## 
		]]>
	</description>
	<content:encoded><![CDATA[
			今天看到的幾篇值得注意的<a href="http://subversion.tigris.org/" target="_blank">Subversion</a>相關文章，先留個紀錄：<br /><ul><li><h3><a rel="bookmark" href="http://www.javalinux.it/wordpress/?p=32" target="_blank" title="Permanent Link: Subversion branching in my experience">Subversion branching in my experience</a></h3></li><li><h3><a href="http://www.addedbytes.com/cheat-sheets/subversion-cheat-sheet/" target="_blank">Subversion Cheat Sheet</a></h3></li><li><h3><a href="http://dimecasts.net/Casts/CastDetails/34" target="_blank">Learning how to resolve conflicts within Subversion (SVN) using TortoiseSVN</a></h3></li><li><h3><a rel="bookmark" href="http://www.geeksaresexy.net/2008/08/05/how-to-upgrade-wordpress-using-subversion/" title="Permanent Link to How To Upgrade WordPress Using Subversion">How To Upgrade WordPress Using Subversion</a></h3></li><li><h3><a rel="bookmark" href="http://gojko.net/2008/08/04/introduction-to-subversion-for-net-developers/">Introduction to Subversion for .NET Developers</a></h3></li></ul>## 
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/6749849.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/6749849.html</guid>
	<category>編程生涯</category>
	<pubDate>Sun, 10 Aug 2008 20:58:42 +0800</pubDate>
</item>
<item>
	<title>Java I18N國際化工具：JRC-Editor</title>
	<description><![CDATA[
			 Java的I18N(Internationalization)大抵是以讀取不同語言的Resource Bundle來達成，例如預設的語言訊息檔Messages.properties，美國英文語言檔是Messages_en_US.properties，繁體中文是Messages_zh_TW.properties，簡體中文則是Messages_zh_CN.properties。很清楚的可以看到語言包檔名以附加 _語言_地區 的方法來區分不同的語言內容。分別編輯不同的語言檔並轉換成Unicode是繁瑣且單調的工作，幸而JRC-Editor協助我們簡化了程序。由功能表 【Edit&rarr;New Langauge】就能建立新的語言檔，不同的語言設定會顯示在右側，以方便一次輸入所有的訊息內容；底部則能建立新的鍵值。如果你的Java程式也必須國際化的話，JRC-Editor是個必備的工具。  ##  
		]]>
	</description>
	<content:encoded><![CDATA[
			 <div class="viewer"><img src="http://b.blog.xuite.net/b/3/a/c/11893557/blog_10351/txt/16014666/0.png" alt="" title="JRC-Editor" hspace="15" align="left" />Java的I18N(Internationalization)大抵是以讀取不同語言的Resource Bundle來達成，例如預設的語言訊息檔<strong>Messages.properties</strong>，美國英文語言檔是<strong>Messages_en_US.properties</strong>，繁體中文是<strong>Messages_zh_TW.properties</strong>，簡體中文則是<strong>Messages_zh_CN.properties</strong>。很清楚的可以看到語言包檔名以附加 _語言_地區 的方法來區分不同的語言內容。分別編輯不同的語言檔並轉換成Unicode是繁瑣且單調的工作，幸而<a href="http://www.zaval.org/products/jrc-editor/" target="_blank" title="外部連結至 http://www.zaval.org/products/jrc-editor/" class="externalLink">JRC-Editor</a>協助我們簡化了程序。<br /><br />由功能表 【Edit&rarr;New Langauge】就能建立新的語言檔，不同的語言設定會顯示在右側，以方便一次輸入所有的訊息內容；底部則能建立新的鍵值。<br /><br />如果你的Java程式也必須國際化的話，<a href="http://www.zaval.org/products/jrc-editor/" target="_blank" title="外部連結至 http://www.zaval.org/products/jrc-editor/" class="externalLink">JRC-Editor</a>是個必備的工具。<br /> <br /> ##<br /> </div> 
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/5619813.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/5619813.html</guid>
	<category>編程生涯</category>
	<pubDate>Sun, 02 Mar 2008 00:52:26 +0800</pubDate>
</item>
<item>
	<title>我的Subversion與Trac使用經驗</title>
	<description><![CDATA[
			對於每一個開發團隊而言，正確且順暢的溝通協調運作機制是不可或缺的，少了這些協同機制，就像在交響樂團裡的走調雜音，或像團體裡我行我素的獨行俠，都會 使團隊戰力大打折扣，畢竟現今的軟體開發已經複雜到無法依賴單打獨鬥的曠世天才而能完成的。只要體認到開發不能只依靠少數人、必須群策群力、互相配合、遵 循共同的流程規定，那麼像Tracking system、Version control system等就必然變成開發人員的好朋友，無法離開它們而能順利運作的了。然而現實的狀況是：功能強大且完整的協同軟體不是每天在生存線上掙扎的台灣小軟體公司能用得起的，導入與使用費用之高都令人咋舌，因而導入Open source的工具再搭配部份自訂流程就變成不得不的選擇。我們最早的版本控制工具是微軟的Visual SourceSafe，但當開發團隊分散兩地時，Visual SourceSafe就陣亡了，雖然有第三方廠商的Source OffSite讓Visual SourceSafe能在Internet上使用，但所費不貲，最終才使用了CVS+WinCVS的組合，在CVS上我們開發了重要的產品和許多個大小專案，期間也是跌跌撞撞，歷經許多錯誤嘗試。接著是Bug/Issue tracking system的導入，用以補足問題的自動追蹤功能與任務的線上分派。最早使用的是Track+，選用它的原因是它是以Java撰寫的，而Java正是我們的主力開發語言且2.X版時能下載程式碼，因而給了我們自行修改的機會（現在3.x版已經沒辦法修改原始碼了），再者Track+具備國際化(I18N)的能力，約在2003年我在珠海趁晚上和假日完成了繁體中文語言包，再經幾個小專案的測試後推動到所有專案。CVS用了幾年後，因為Subversion提供更快速的存取與相容CVS的操作方式，在這兩三年裡就逐步由CVS+WinCVS轉移到Subversion+TortoiseSVN，轉移的策略是舊的專案或較少變動的專案就保留在CVS上，新的專案與更新頻繁的專案就移到Subversion上。而2007年又開始試用Trac，嘗試把Wiki、Tracking、Subversion整合在一起，以下是我們使用Trac的幾個試驗： 在Wiki首頁放置一個公佈欄：PM、SA要公佈的開發事項以日期排序，以通知專案成員。以前大多是用E-Mail聯絡通知，但新成員是沒辦法看到的，全部放在Wiki上就不怕有疏漏的狀況。 任務分派用Ticket發送：SA透過Trac分派給PG(Programmer)要撰寫的作業，開始日期與期望完成日期皆有紀錄，PG的作業狀況與績效都能追蹤考核。 透過異動歷程了解開發活動：每天PM透過異動歷程能大致了解PG的進度與程式撰寫狀況。 我們把Trac的Component存模組代碼，再增加模組報表，如此便能輕易地知道各個模組作業的完成進度。Subversion 則是所有文件與程式碼的統一窗口，所有專案成員皆以Subversion上的檔案為準，這樣以前用Mail寄來寄去，或透過File Server取檔導致版本不一致的問題就消弭於無形了。一般專案開發組織裡，我們尚有測試組的配置，當PG經由Trac通知測試人員開始測試時，測試人員 由Subversion取出程式，在他的本地端編譯、測試，以確保測試的版本是正確、一致的，若有差錯也能立即被發現。這裡再分享幾個推動上的小經驗。 中文化是必須的：要能順利推動某個工具，一定要有中文介面，缺少中文介面一定都會大打折扣，且會給成員推拖的藉口。尤其是大陸同事，看到英文心就亂一半，要他們用非中文工具，簡直是比登天還難。 要循序漸進、不可躁進：推行此類會影響作業流程的工具時，切忌一開始就全面推動，若不先經小範圍測試再逐步修改調整，可能對團隊帶來翻天覆地的混亂感受，從而增加推行失敗的機率。 主管要堅持，成員要配合：導入初期的不適應，勢必引起反彈，但只要是對的政策就應該堅持，主管、成員都要敞開心胸，針對扞格不合之處做調整與修正，最終才能磨合成適合環境的較理想運作模式。事 實上，Tracking system與Version control system僅是專案運作的基本功而已，但這些基礎都無法運作順利，遑論其他更因人而異的管理機制了。從以上的推動描述可以看出我們對於推動新的流程與控 管機制是抱持慎重其事的心態，因為一個機制的變更影響到的是許多聰明、又有想法的開發人員，最終還是要讓這些機制內化成每天的標準動作，而這樣的流程也才 有執行的必要。以上小小經驗與大家分享。##
		]]>
	</description>
	<content:encoded><![CDATA[
			對於每一個開發團隊而言，正確且順暢的溝通協調運作機制是不可或缺的，少了這些協同機制，就像在交響樂團裡的走調雜音，或像團體裡我行我素的獨行俠，都會 使團隊戰力大打折扣，畢竟現今的軟體開發已經複雜到無法依賴單打獨鬥的曠世天才而能完成的。只要體認到開發不能只依靠少數人、必須群策群力、互相配合、遵 循共同的流程規定，那麼像Tracking system、Version control system等就必然變成開發人員的好朋友，無法離開它們而能順利運作的了。<br /><br />然而現實的狀況是：功能強大且完整的協同軟體不是每天在生存線上掙扎的台灣小軟體公司能用得起的，導入與使用費用之高都令人咋舌，因而導入Open source的工具再搭配部份自訂流程就變成不得不的選擇。我們最早的版本控制工具是微軟的Visual SourceSafe，但當開發團隊分散兩地時，Visual SourceSafe就陣亡了，雖然有第三方廠商的Source OffSite讓Visual SourceSafe能在Internet上使用，但所費不貲，最終才使用了<a href="http://www.cvsnt.org/" target="_blank" title="外部連結至 http://www.cvsnt.org" class="externalLink">CVS</a>+<a href="http://www.wincvs.org/" target="_blank" title="外部連結至 http://www.wincvs.org" class="externalLink">WinCVS</a>的組合，在CVS上我們開發了重要的產品和許多個大小專案，期間也是跌跌撞撞，歷經許多錯誤嘗試。<br /><br />接著是Bug/Issue tracking system的導入，用以補足問題的自動追蹤功能與任務的線上分派。最早使用的是<a href="http://www.trackplus.com/" target="_blank" title="外部連結至 http://www.trackplus.com" class="externalLink">Track+</a>，選用它的原因是它是以Java撰寫的，而Java正是我們的主力開發語言且2.X版時能下載程式碼，因而給了我們自行修改的機會（現在3.x版已經沒辦法修改原始碼了），再者Track+具備國際化(I18N)的能力，約在2003年我在珠海趁晚上和假日完成了繁體中文語言包，再經幾個小專案的測試後推動到所有專案。<br /><br />CVS用了幾年後，因為<a href="http://subversion.tigris.org/" target="_blank" title="外部連結至 http://subversion.tigris.org" class="externalLink">Subversion</a>提供更快速的存取與相容CVS的操作方式，在這兩三年裡就逐步由CVS+WinCVS轉移到Subversion+<a href="http://tortoisesvn.tigris.org/" target="_blank" title="外部連結至 http://tortoisesvn.tigris.org" class="externalLink">TortoiseSVN</a>，轉移的策略是舊的專案或較少變動的專案就保留在CVS上，新的專案與更新頻繁的專案就移到Subversion上。而2007年又開始試用Trac，嘗試把Wiki、Tracking、Subversion整合在一起，以下是我們使用Trac的幾個試驗：<br /><ul><li> 在Wiki首頁放置一個公佈欄：PM、SA要公佈的開發事項以日期排序，以通知專案成員。以前大多是用E-Mail聯絡通知，但新成員是沒辦法看到的，全部放在Wiki上就不怕有疏漏的狀況。</li><li> 任務分派用Ticket發送：SA透過Trac分派給PG(Programmer)要撰寫的作業，開始日期與期望完成日期皆有紀錄，PG的作業狀況與績效都能追蹤考核。</li><li> 透過異動歷程了解開發活動：每天PM透過異動歷程能大致了解PG的進度與程式撰寫狀況。</li><li> 我們把Trac的Component存模組代碼，再增加模組報表，如此便能輕易地知道各個模組作業的完成進度。</li></ul>Subversion 則是所有文件與程式碼的統一窗口，所有專案成員皆以Subversion上的檔案為準，這樣以前用Mail寄來寄去，或透過File Server取檔導致版本不一致的問題就消弭於無形了。一般專案開發組織裡，我們尚有測試組的配置，當PG經由Trac通知測試人員開始測試時，測試人員 由Subversion取出程式，在他的本地端編譯、測試，以確保測試的版本是正確、一致的，若有差錯也能立即被發現。<br /><br />這裡再分享幾個推動上的小經驗。<br /><ul><li> 中文化是必須的：要能順利推動某個工具，一定要有中文介面，缺少中文介面一定都會大打折扣，且會給成員推拖的藉口。尤其是大陸同事，看到英文心就亂一半，要他們用非中文工具，簡直是比登天還難。</li><li> 要循序漸進、不可躁進：推行此類會影響作業流程的工具時，切忌一開始就全面推動，若不先經小範圍測試再逐步修改調整，可能對團隊帶來翻天覆地的混亂感受，從而增加推行失敗的機率。</li><li> 主管要堅持，成員要配合：導入初期的不適應，勢必引起反彈，但只要是對的政策就應該堅持，主管、成員都要敞開心胸，針對扞格不合之處做調整與修正，最終才能磨合成適合環境的較理想運作模式。</li></ul>事 實上，Tracking system與Version control system僅是專案運作的基本功而已，但這些基礎都無法運作順利，遑論其他更因人而異的管理機制了。從以上的推動描述可以看出我們對於推動新的流程與控 管機制是抱持慎重其事的心態，因為一個機制的變更影響到的是許多聰明、又有想法的開發人員，最終還是要讓這些機制內化成每天的標準動作，而這樣的流程也才 有執行的必要。<br /><br />以上小小經驗與大家分享。<br /><br />##
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/4968601.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/4968601.html</guid>
	<category>編程生涯</category>
	<pubDate>Sat, 12 Jan 2008 15:17:00 +0800</pubDate>
</item>
<item>
	<title>[Java] 在jar檔裡搜尋特定類別的工具</title>
	<description><![CDATA[
			 初學Java時因不諳ClassPath的觀念與用法，經常會因為找不到jar檔而出現ClassNotFoundException或NoClassDefFoundError的例外狀況。LibraryFinder就是一個讓我們指定特定目錄以搜尋類別是置放在那個jar檔裡的工具。使用範例  java -jar LibraryFinderv1.2.1.jar c:\jdk1.6\lib com.sun.* 先指定要找那個資料夾，再指定要找那些類別 類別可以用星號下載 請由這裡下載 在這個網站裡除了項說明外，也有示範的影像可以觀看 這個小工具有提供IntelliJ IDEA的插件，Eclipse與NetBeans的版本則尚在準備開發階段
		]]>
	</description>
	<content:encoded><![CDATA[
			 初學<a href="http://java.sun.com/" target="_blank" title="外部連結至 http://java.sun.com" class="externalLink">Java</a>時因不諳<strong>ClassPath</strong>的觀念與用法，經常會因為找不到jar檔而出現<strong>ClassNotFoundException</strong>或<strong>NoClassDefFoundError</strong>的例外狀況。<strong>LibraryFinder</strong>就是一個讓我們指定特定目錄以搜尋類別是置放在那個jar檔裡的工具。<br /><h3>使用範例</h3><pre>  java -jar LibraryFinderv1.2.1.jar c:\jdk1.6\lib com.sun.*<br /></pre><ul><li> 先指定要找那個資料夾，再指定要找那些類別</li><li> 類別可以用星號</li></ul><h3>下載</h3><ul><li> 請由<a href="http://code.google.com/p/libraryfinder/" target="_blank" title="外部連結至 http://code.google.com/p/libraryfinder/" class="externalLink">這裡</a>下載</li><li> 在<a href="http://code.google.com/p/libraryfinder/" target="_blank" title="外部連結至 http://code.google.com/p/libraryfinder/" class="externalLink">這個網站</a>裡除了項說明外，也有示範的影像可以觀看</li><li> 這個小工具有提供<a href="http://www.jetbrains.com/" target="_blank" title="外部連結至 http://www.jetbrains.com" class="externalLink">IntelliJ IDEA</a>的插件，<a href="http://www.eclipse.org/" target="_blank" title="外部連結至 http://www.eclipse.org" class="externalLink">Eclipse</a>與<a href="http://www.netbeans.org/" target="_blank" title="外部連結至 http://www.netbeans.org" class="externalLink">NetBeans</a>的版本則尚在準備開發階段</li></ul>
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/4074693.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/4074693.html</guid>
	<category>編程生涯</category>
	<pubDate>Mon, 03 Sep 2007 22:18:14 +0800</pubDate>
</item>
<item>
	<title>最近看到的有趣電腦詞彙</title>
	<description><![CDATA[
			雖然腦袋裡被飛天遁地的光明界和黑暗界的超凡人佔據著，還是在《幽巡了幾個詞 彙，因其趣味特予誌之。  溫徹斯特硬碟：原本以為是因地名來命名的，結果在譯註裡看到說明。以下這段文字和Wikipedia裡的說明幾乎一模一樣，看來本書譯者太偷懶 了，要整段抄也不多加調整。或許Wikipedia已經成了翻譯者們重要的參考依據了： 《幽巡者》77頁譯註：一九七三年IBM 3340硬碟問世，綽號「溫徹斯特」，源自它有兩個30MB的儲存量，恰是當時出名的「溫徹斯特來福槍」的口徑和填彈量。Wikipedia：1973年IBM 3340問世，他擁有「溫徹斯特」這個綽號，來源於他兩個30MB的儲存單元，恰是當時出名的「溫徹斯特來福槍」的口徑和填彈量。  Cygnus的起源：Cygnus的創始人之一的Michael Tiemann為了推廣自由軟體之父史托曼的GNU軟體，準備成立公司，有網友從字典裡找出含有GNU的單 字，Cygnus是最沒有猥褻含意的一個，因此Cygnus 就問市了。 SourceForge網站的來由：Internet上有一個名 為「鮮肉」(Fresh Meat)的網站，專門發佈Open source軟體的消息，VA Research購入FreshMeat的 母公司後又設了一個「冷藏」(Cold Storage)網站，用來存放「鮮肉」發佈新聞裡的軟體；後來VA Research合併了「鮮肉」和「冷藏」，又加上論壇、FTP等功能後，形成新的「原始碼熔爐」(Source Forge)，於2001年1月4日起免費服務 Open source的開發專案。老外真是有趣，幾個名詞生動活潑，又息息相關 :-) Linux裡的「美酒」(Wine) 是在Linux裡模擬Windows環境的軟體；Wine有兩個涵義：  WINdows Emulator Wine Is Not Emulator     Python原因是來自英國廣播公司連續劇《Python的空中飛人馬戲團》，這齣劇是Python作者Guido Rossum最喜歡的電視劇   
		]]>
	</description>
	<content:encoded><![CDATA[
			雖然腦袋裡被飛天遁地的光明界和黑暗界的超凡人佔據著，還是在《幽巡了幾個詞 彙，因其趣味特予誌之。<br /> <ul><li> 溫徹斯特硬碟：原本以為是因地名來命名的，結果在譯註裡看到說明。以下這段文字和<a href="http://zh.wikipedia.org/wiki/%E7%A1%AC%E7%9B%98" target="_blank" title="外部連結至 http://zh.wikipedia.org/wiki/%E7%A1%AC%E7%9B%98" class="externalLink">Wikipedia裡的說明</a>幾乎一模一樣，看來本書譯者太偷懶 了，要整段抄也不多加調整。或許Wikipedia已經成了翻譯者們重要的參考依據了：</li></ul> <pre>《幽巡者》77頁譯註：<br />一九七三年IBM 3340硬碟問世，綽號「溫徹斯特」，源自它有兩個30MB的儲存量，恰是當時出名的「溫徹斯特來福槍」的口徑和填彈量。<br /><br />Wikipedia：<br />1973年IBM 3340問世，他擁有「溫徹斯特」這個綽號，來源於他兩個30MB的儲存單元，恰是當時出名的「溫徹斯特來福槍」的口徑和填彈量。<br /></pre> <ul><li> <a href="http://blog.xuite.net/emisjerry/tech/9684998" target="_blank" title="外部連結至 http://blog.xuite.net/emisjerry/tech/9684998" class="externalLink">Cygnus</a>的起源：Cygnus的創始人之一的Michael Tiemann為了推廣自由軟體之父史托曼的<a href="http://zh.wikipedia.org/w/index.php?title=GNU&amp;variant=zh-tw" target="_blank" title="外部連結至 http://zh.wikipedia.org/w/index.php?title=GNU&amp;variant=zh-tw" class="externalLink">GNU軟體</a>，準備成立公司，有網友從字典裡找出含有GNU的單 字，Cygnus是最沒有猥褻含意的一個，因此Cy<span style="color: #cc3300">gnu</span>s 就問市了。<br /></li><li> <a href="http://www.sf.net/" target="_blank" title="外部連結至 http://www.sf.net" class="externalLink">SourceForge</a>網站的來由：Internet上有一個名 為「鮮肉」(<a href="http://freshmeat.net/" target="_blank" title="外部連結至 http://freshmeat.net/" class="externalLink">Fresh Meat</a>)的網站，專門發佈Open source軟體的消息，VA Research購入<a href="http://freshmeat.net/" target="_blank" title="外部連結至 http://freshmeat.net/" class="externalLink">FreshMeat</a>的 母公司後又設了一個「冷藏」(Cold Storage)網站，用來存放「鮮肉」發佈新聞裡的軟體；後來VA Research合併了「鮮肉」和「冷藏」，又加上論壇、FTP等功能後，形成新的「原始碼熔爐」(<a href="http://www.sf.net/" target="_blank" title="外部連結至 http://www.sf.net" class="externalLink">Source Forge</a>)，於2001年1月4日起免費服務 Open source的開發專案。老外真是有趣，幾個名詞生動活潑，又息息相關 :-)<br /></li><li> Linux裡的「美酒」(<a href="http://zh.wikipedia.org/wiki/Wine" target="_blank" title="外部連結至 http://zh.wikipedia.org/wiki/Wine" class="externalLink">Wine</a>) 是在Linux裡模擬Windows環境的軟體；Wine有兩個涵義： <ol><li> <span style="color: #cc3300">WIN</span>dows <span style="color: #cc3300">E</span>mulator</li><li> <span style="color: #cc3300">W</span>ine <span style="color: #cc3300">I</span>s <span style="color: #cc3300">N</span>ot <span style="color: #cc3300">E</span>mulator</li></ol> </li></ul> <blockquote><img src="http://upload.wikimedia.org/wikipedia/zh/a/aa/Winehq_top_logo.png" alt="" title="alt_text" /><br /> </blockquote> <ul><li> Python原因是來自英國廣播公司連續劇《Python的空中飛人馬戲團》，這齣劇是Python作者Guido Rossum最喜歡的電視劇</li></ul> <blockquote><img src="http://upload.wikimedia.org/wikipedia/en/thumb/0/06/Python_logo.svg/150px-Python_logo.svg.png" alt="" title="alt_text" /> </blockquote> 
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/4044929.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/4044929.html</guid>
	<category>編程生涯</category>
	<pubDate>Wed, 29 Aug 2007 21:35:48 +0800</pubDate>
</item>
<item>
	<title>EasyEclipse: 化繁為簡的Eclipse</title>
	<description><![CDATA[
			學習Java時，最多人提及的整合開發環境非Eclipse莫屬，但對於初學者而言，從安裝、設定、學習到能發揮生產力，是一段漫長的摸索與錯誤嘗試的艱苦過程。EasyEclipse的出現簡化了這整個辛苦的程序。EasyEclipse依開發類型而分門別類的分成了Expert、Desktop、Server、Mobile等不同的安裝版本。下載：http://www.easyeclipse.org/site/distributions/index.html
		]]>
	</description>
	<content:encoded><![CDATA[
			學習Java時，最多人提及的整合開發環境非<a href="http://www.eclipse.org/" target="_blank">Eclipse</a>莫屬，但對於初學者而言，從安裝、設定、學習到能發揮生產力，是一段漫長的摸索與錯誤嘗試的艱苦過程。<a rel="tag" href="http://www.easyeclipse.org/site/home/">EasyEclipse</a>的出現簡化了這整個辛苦的程序。<br /><br />EasyEclipse依開發類型而分門別類的分成了Expert、Desktop、Server、Mobile等不同的安裝版本。<br /><br />下載：<a href="http://www.easyeclipse.org/site/distributions/index.html" target="_blank">http://www.easyeclipse.org/site/distributions/index.html</a>
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/3524095.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/3524095.html</guid>
	<category>編程生涯</category>
	<pubDate>Sun, 24 Jun 2007 23:12:04 +0800</pubDate>
</item>
<item>
	<title>試用正規運算式(Regular Expression)工具</title>
	<description><![CDATA[
			
正規運算式(Regular
Expression)對於動態腳本的程式撰寫用處頗多，但我卻沒有很仔細的學習，總是要用到時才翻書查閱、尋找類似的Pattern再套用。今天找了些
輔助工具，希望能透過這些工具讓自己對於正規運算式能瞭解得更透徹，在使用上能更得心應手。





工
具名稱
下
載
試
用狀況


The
Regex Coach 0.9
 http://weitz.de/files/regex-coach.exe
功能齊
全，但執行時效能很差


reWork:
a regular expression workbench

http://osteele.com/tools/rework/
網站。
我的首選


Expresso
2.1
http://www.ultrapico.com/Expresso.htm
運行
在.NET上。但跑一個運算式時無法通過剖析，但以上兩個卻可以




##


		]]>
	</description>
	<content:encoded><![CDATA[
			
<p><span style="font-weight: bold;">正規運算式</span>(Regular
Expression)對於動態腳本的程式撰寫用處頗多，但我卻沒有很仔細的學習，總是要用到時才翻書查閱、尋找類似的Pattern再套用。今天找了些
輔助工具，希望能透過這些工具讓自己對於正規運算式能瞭解得更透徹，在使用上能更得心應手。
<input type="hidden" value="regular expression tool" id="mytag" /></p>

<table cellspacing="1" cellpadding="2" border="0" style="text-align: left; background-color: rgb(153, 153, 153); width: 90%;">
<tbody>
<tr>
<td style="text-align: center; background-color: rgb(0, 153, 0); color: rgb(255, 255, 255);">工
具名稱</td>
<td style="text-align: center; background-color: rgb(0, 153, 0); color: rgb(255, 255, 255);">下
載</td>
<td style="text-align: center; background-color: rgb(0, 153, 0); color: rgb(255, 255, 255);">試
用狀況</td>
</tr>
<tr>
<td style="background-color: rgb(204, 255, 255);">The
Regex Coach 0.9</td>
<td style="background-color: rgb(204, 255, 255);"> <a href="http://weitz.de/files/regex-coach.exe" target="_blank">http://weitz.de/files/regex-coach.exe</a></td>
<td style="background-color: rgb(204, 255, 255);">功能齊
全，但執行時效能很差</td>
</tr>
<tr>
<td style="background-color: rgb(255, 255, 204);">reWork:
a regular expression workbench
</td>
<td style="background-color: rgb(255, 255, 204);"><a target="_blank" href="http://osteele.com/tools/rework/">http://osteele.com/tools/rework/</a></td>
<td style="background-color: rgb(255, 255, 204);">網站。
我的首選</td>
</tr>
<tr>
<td style="background-color: rgb(204, 255, 255);">Expresso
2.1</td>
<td style="background-color: rgb(204, 255, 255);"><a target="_blank" href="http://www.ultrapico.com/Expresso.htm">http://www.ultrapico.com/Expresso.htm</a></td>
<td style="background-color: rgb(204, 255, 255);">運行
在.NET上。但跑一個運算式時無法通過剖析，但以上兩個卻可以</td>
</tr>
</tbody>
</table>
<br />
##<br />


		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/3010673.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/3010673.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/3010673.html</guid>
	<category>編程生涯</category>
	<pubDate>Sun, 15 Apr 2007 21:07:55 +0800</pubDate>
</item>
<item>
	<title>初試AJAX：中文的傳遞與接收</title>
	<description><![CDATA[
			

為
了要讓網頁的頁面與資料傳遞能夠做到更理想，開始研究AJAX，試看看是否能透過AJAX來解決部份以GET方式而受到的限制能有所突破。以下將測試環境
與程式按步就班地呈現出來，測試的過程裡，特別針對中文的傳入與傳回做了較詳盡的反覆測試。

測試環境：

  作業系統：Windows 2003 Server
  瀏覽器：IE 6.0.3790.0、FireFox 2.0.0.2
  Application Server：Resin 2.12、Resin 3.0.21

首先撰寫啟始的前端網頁文件，命名為 ajax.html，
網頁裡放三個控制項，一個用來輸入文字的TEXT1、
觸發AJAX執行的按鈕btnOK1和
接收Server回應的文字框RESULT，
呈現頁面如圖2。

  
    
      &lt;form
id="idForm"&gt;
&nbsp; &lt;input type="text" name="TEXT1" id="TEXT1"&gt;
&nbsp; &lt;input type="button" name="btnOK1" id="btnOK1" value=" TEST
1 "&gt;
&nbsp; &lt;textarea name="RESULT" id="RESULT" rows=10
cols=50&gt;&lt;/textarea&gt;
&lt;/form&gt;
    
  



  
    
      圖2
    
    
      
    
  


把按鈕RESULT的 onclick 事件放在window.onload裡：&nbsp;

  
    
      &nbsp;
window.onload = function() {
&nbsp;&nbsp;&nbsp;
document.getElementById("btnOK1").onclick = function() {
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; request =
httpRequest();
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
document.getElementById("RESULT").innerHTML = "";
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; request.open("POST",
"ajax2.jsp", true);
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
request.onreadystatechange = handleResponse;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
request.setRequestHeader("Content-Type",
"application/x-www-form-urlencoded;");
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
request.send("TEXT1=" + document.getElementById("TEXT1").value +
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
"&amp;TEXT2=中文傳到Server");
&nbsp;&nbsp;&nbsp; }&nbsp; //~ btnOK1
&nbsp; } //~ window.onload
      
    
  


幾個說明如下：

  XMLHttpRequest物件建立後，變數名稱是request
  用了避免傳遞的參數有字數長度的限制，因此用POST的方式傳參數；使用POST傳遞參數時，必須有
request.setRequestHeader，此處必須特別注意的是：request.setRequestHeader
必須寫在request.open後面，否則 IE 會有"錯誤:
無法指出的錯誤"，而FireFox會有"uncaught exception"錯誤
  Query String會以問號開頭，而使用request.send傳送時不能用問號開頭！
  Server的處理程式檔名為 ajax2.jsp
  Server處理完畢後會被執行的函數是
handleResponse，把接收回的字串寫入RESULT文字框

Server上的 ajax2.jsp 主要邏輯如下：

  
    
      &lt;%@
page contentType="text/html;charset=UTF-8"%&gt;
&lt;%
&nbsp; //response.setContentType("text/html;charset=UTF-8");
&nbsp; //response.setHeader("Charset", "Big5");
&nbsp; request.setCharacterEncoding("UTF-8");
&nbsp; out.println("由Server輸出回網頁.....");
&nbsp; String _sText1 = request.getParameter("TEXT1");
&nbsp; out.println("TEXT1=" + _sText1);
%&gt;
    
  


重點說明：

  XMLHttpRequest傳出與接收的編碼都是UTF-8，
因此JSP的反應編碼(第一行)與接收傳入參數的request(第5行)都使用UTF-8，如此接進來的參數與傳回的輸出，才能正確的被
XMLHttpRequest
處理
  有的網站會把request參數用ISO8859-1再編碼成UTF-8，或用
response.setCharacterEncoding設定UTF-8，其實只要用說明1的方法就能都解決了；另外，若使用的
Application Server使用的是JSDK
2.3的話，是無法使用response.setCharacterEncoding的，這個method是JSDK 2.4後才增加的

再來把 ajax1.html &nbsp;的Server換用Servlet來處理(xxx換成自己的Webapp名稱)：

  
    
      request.open("POST",
"/xxx/servlet/ajax_Servlet2", true);
    
  


ajax_Server2的主要邏輯是：

  
    
      &nbsp;
protected void doPost(HttpServletRequest request, HttpServletResponse
response) 
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; throws ServletException, IOException {
&nbsp;&nbsp;&nbsp; response.setContentType("text/html;
charset=UTF-8");
&nbsp;&nbsp;&nbsp; request.setCharacterEncoding("UTF-8");
      
&nbsp;&nbsp;&nbsp; PrintWriter out = response.getWriter();
      
&nbsp;&nbsp;&nbsp; String _sText1 =
request.getParameter("TEXT1");
&nbsp;&nbsp;&nbsp; String _sText2 =
request.getParameter("TEXT2");
      
      &nbsp;&nbsp;&nbsp; //_sTEXT1 = new
String(_sTEXT1.geresponse.setCharacterEncodingtBytes("ISO-8859-1"),
"UTF-8");
      
&nbsp;&nbsp;&nbsp; StringBuffer buf = new StringBuffer();
&nbsp;&nbsp;&nbsp; buf.append("訊息1=" + _sText1);
&nbsp;&nbsp;&nbsp; buf.append("訊息2=" + _sText2);
&nbsp;&nbsp;&nbsp; out.println(buf.toString());
&nbsp;&nbsp;&nbsp; out.close();
&nbsp; }
      
    
  


response和request都使用UTF-8就
對了。

完整的 ajax1.html列表在下：

&lt;html&gt;
&lt;body&gt;
&lt;form id="idForm"&gt;
&nbsp; &lt;input type="text" name="TEXT1"
id="TEXT1"&gt;
&nbsp; &lt;input type="button" name="btnOK1" id="btnOK1"
value=" TEST 1 "&gt;
&nbsp; &lt;textarea name="RESULT" id="RESULT" rows=10
cols=50&gt;&lt;/textarea&gt;
&lt;/form&gt;
&lt;span
id='spaParam'&gt;&lt;/span&gt;
&lt;/body&gt;
&lt;/html&gt;
&lt;script&gt;
&nbsp; var request;
&nbsp; function httpRequest() {
&nbsp;&nbsp;&nbsp; var req;
&nbsp;&nbsp;&nbsp; if (window.XMLHttpRequest) {&nbsp;
// Mozilla-based browsers
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; req = new
XMLHttpRequest();
&nbsp;&nbsp;&nbsp; } else if (window.ActiveXObject)
{&nbsp; // IE 5, IE 6
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; req = new
ActiveXObject("Msxml2.XMLHTTP");
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (!req)
{
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
req = new ActiveXObject("Microsoft.XMLHTTP");
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }
&nbsp;&nbsp;&nbsp; }
&nbsp;&nbsp;&nbsp; return req;
&nbsp; } //~ httpRequest
&nbsp; function handleResponse() {
&nbsp;&nbsp;&nbsp; if (request.readyState == 4)
{
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (request.status
== 200) {
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
//!! innerText在FF裡竟然不行!
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
document.getElementById("RESULT").innerHTML =
request.responseText;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; } else
{
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
alert("Error: " + request.status + " " +
request.statusText);
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }
&nbsp;&nbsp;&nbsp; }
&nbsp; } //~ handleResponse
&nbsp; window.onload = function() {
&nbsp;&nbsp;&nbsp;
document.getElementById("btnOK1").onclick = function()
{
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; request =
httpRequest();
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
document.getElementById("RESULT").innertext = "";
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; request.open("POST",
"/mis/servlet/ajax_Servlet2", true);
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
//request.open("POST", "ajax2.jsp", true);
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
request.onreadystatechange = handleResponse;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
request.setRequestHeader("Content-Type",
"application/x-www-form-urlencoded;");
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
request.send("TEXT1=" + document.getElementById("TEXT1").value
+
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
"&amp;TEXT2=中文傳到Server");
&nbsp;&nbsp;&nbsp; }&nbsp; //~ btnOK1
&nbsp; } //~ window.onload
&lt;/script&gt;

##




 dp.SyntaxHighlighter.HighlightAll('code'); 

		]]>
	</description>
	<content:encoded><![CDATA[
			<input id="mytag" value="AJAX XMLHttpRequest"
 type="hidden" />
<img style="width: 277px; height: 173px; float: left;"
 alt="AJAX diagram"
 src="http://b.blog.xuite.net/b/3/a/c/11893557/blog_10351/txt/10593763/6.jpg"
 hspace="30" vspace="5">
<p>為
了要讓網頁的頁面與資料傳遞能夠做到更理想，開始研究AJAX，試看看是否能透過AJAX來解決部份以GET方式而受到的限制能有所突破。以下將測試環境
與程式按步就班地呈現出來，測試的過程裡，特別針對中文的傳入與傳回做了較詳盡的反覆測試。</p>
<br>
測試環境：<br>
<ul>
  <li>作業系統：Windows 2003 Server</li>
  <li>瀏覽器：IE 6.0.3790.0、FireFox 2.0.0.2</li>
  <li>Application Server：Resin 2.12、Resin 3.0.21</li>
</ul>
首先撰寫啟始的前端網頁文件，命名為 <span style="font-weight: bold;">ajax.html</span>，
網頁裡放三個控制項，一個用來輸入文字的<span style="font-weight: bold;">TEXT1</span>、
觸發AJAX執行的按鈕<span style="font-weight: bold;">btnOK1</span>和
接收Server回應的文字框<span style="font-weight: bold;">RESULT</span>，
呈現頁面如圖2。<br>
<table
 style="text-align: left; font-family: Courier New; background-color: rgb(102, 102, 102); width: 100%;"
 border="0" cellpadding="2" cellspacing="1">
  <tbody>
    <tr>
      <td style="background-color: rgb(255, 255, 204);">&lt;form
id="idForm"&gt;<br>
&nbsp; &lt;input type="text" name="TEXT1" id="<span
 style="font-weight: bold;">TEXT1</span>"&gt;<br>
&nbsp; &lt;input type="button" name="btnOK1" id="<span
 style="font-weight: bold;">btnOK1</span>" value=" TEST
1 "&gt;<br>
&nbsp; &lt;textarea name="RESULT" id="<span
 style="font-weight: bold;">RESULT</span>" rows=10
cols=50&gt;&lt;/textarea&gt;<br>
&lt;/form&gt;</td>
    </tr>
  </tbody>
</table>
<br>
<table style="text-align: left; width: 60%;" border="0"
 cellpadding="2" cellspacing="2">
  <tbody>
    <tr align="center">
      <td>圖2</td>
    </tr>
    <tr>
      <td><img
 style="padding-top: 5px; padding-bottom: 5px; padding-right: 5px; width: 513px; height: 420px; float: left;"
 alt="FireFox AJAX"
 src="http://b.blog.xuite.net/b/3/a/c/11893557/blog_10351/txt/10593763/0.jpg"></td>
    </tr>
  </tbody>
</table>
<br>
把按鈕RESULT的 onclick 事件放在window.onload裡：&nbsp;
<table
 style="text-align: left; font-family: Courier New; background-color: rgb(102, 102, 102); width: 100%;"
 border="0" cellpadding="2" cellspacing="1">
  <tbody>
    <tr>
      <td style="background-color: rgb(255, 255, 204);">&nbsp;
window.onload = function() {<br>
&nbsp;&nbsp;&nbsp;
document.getElementById("btnOK1").onclick = function() {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; request =
httpRequest();<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
document.getElementById("RESULT").innerHTML = "";<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; request.open("POST",
"ajax2.jsp", true);<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
request.onreadystatechange = handleResponse;<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
request.setRequestHeader("Content-Type",
"application/x-www-form-urlencoded;");<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
request.send("TEXT1=" + document.getElementById("TEXT1").value +<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
"&amp;TEXT2=中文傳到Server");<br>
&nbsp;&nbsp;&nbsp; }&nbsp; //~ btnOK1<br>
&nbsp; } //~ window.onload<br>
      </td>
    </tr>
  </tbody>
</table>
<br>
幾個說明如下：<br>
<ol>
  <li>XMLHttpRequest物件建立後，變數名稱是request</li>
  <li>用了避免傳遞的參數有字數長度的限制，因此用POST的方式傳參數；使用POST傳遞參數時，必須有
request.setRequestHeader，此處必須特別注意的是：<span
 style="font-weight: bold; color: rgb(255, 0, 0);">request.setRequestHeader
必須寫在request.open後面</span>，否則 IE 會有"錯誤:
無法指出的錯誤"，而FireFox會有"uncaught exception"錯誤</li>
  <li>Query String會以問號開頭，而使用request.send傳送時<span
 style="font-weight: bold; color: rgb(255, 0, 0);">不能用問號開頭</span>！</li>
  <li>Server的處理程式檔名為 <span style="font-weight: bold;">ajax2.jsp</span></li>
  <li>Server處理完畢後會被執行的函數是<span style="font-weight: bold;">
handleResponse</span>，把接收回的字串寫入RESULT文字框</li>
</ol>
Server上的 ajax2.jsp 主要邏輯如下：<br>
<table
 style="text-align: left; font-family: Courier New; background-color: rgb(102, 102, 102); width: 100%;"
 border="0" cellpadding="2" cellspacing="1">
  <tbody>
    <tr>
      <td style="background-color: rgb(255, 255, 204);">&lt;%@
page contentType="text/html;charset=UTF-8"%&gt;<br>
&lt;%<br>
&nbsp; //response.setContentType("text/html;charset=UTF-8");<br>
&nbsp; //response.setHeader("Charset", "Big5");<br>
&nbsp; request.setCharacterEncoding("UTF-8");<br>
&nbsp; out.println("由Server輸出回網頁.....");<br>
&nbsp; String _sText1 = request.getParameter("TEXT1");<br>
&nbsp; out.println("TEXT1=" + _sText1);<br>
%&gt;</td>
    </tr>
  </tbody>
</table>
<br>
重點說明：<br>
<ol>
  <li>XMLHttpRequest傳出與接收的編碼都是<span style="font-weight: bold;">UTF-8</span>，
因此JSP的反應編碼(第一行)與接收傳入參數的request(第5行)都使用UTF-8，如此接進來的參數與傳回的輸出，才能正確的被
XMLHttpRequest
處理</li>
  <li>有的網站會把request參數用ISO8859-1再編碼成UTF-8，或用
response.setCharacterEncoding設定UTF-8，其實只要用說明1的方法就能都解決了；另外，若使用的
Application Server使用的是JSDK
2.3的話，是無法使用response.setCharacterEncoding的，這個method是JSDK 2.4後才增加的</li>
</ol>
再來把 ajax1.html &nbsp;的Server換用Servlet來處理(xxx換成自己的Webapp名稱)：<br>
<table
 style="text-align: left; font-family: Courier New; background-color: rgb(102, 102, 102); width: 100%;"
 border="0" cellpadding="2" cellspacing="1">
  <tbody>
    <tr>
      <td style="background-color: rgb(255, 255, 204);">request.open("POST",
"/xxx/servlet/ajax_Servlet2", true);</td>
    </tr>
  </tbody>
</table>
<br>
ajax_Server2的主要邏輯是：<br>
<table
 style="text-align: left; font-family: Courier New; background-color: rgb(102, 102, 102); width: 100%;"
 border="0" cellpadding="2" cellspacing="1">
  <tbody>
    <tr>
      <td style="background-color: rgb(255, 255, 204);">&nbsp;
protected void doPost(HttpServletRequest request, HttpServletResponse
response) <br>
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; throws ServletException, IOException {<br>
&nbsp;&nbsp;&nbsp; response.setContentType("text/html;
charset=UTF-8");<br>
&nbsp;&nbsp;&nbsp; request.setCharacterEncoding("UTF-8");<br>
      <br>
&nbsp;&nbsp;&nbsp; PrintWriter out = response.getWriter();<br>
      <br>
&nbsp;&nbsp;&nbsp; String _sText1 =
request.getParameter("TEXT1");<br>
&nbsp;&nbsp;&nbsp; String _sText2 =
request.getParameter("TEXT2");<br>
      <br>
      <small>&nbsp;&nbsp;&nbsp; //_sTEXT1 = new
String(_sTEXT1.geresponse.setCharacterEncodingtBytes("ISO-8859-1"),
"UTF-8");<br>
      </small><br>
&nbsp;&nbsp;&nbsp; StringBuffer buf = new StringBuffer();<br>
&nbsp;&nbsp;&nbsp; buf.append("訊息1=" + _sText1);<br>
&nbsp;&nbsp;&nbsp; buf.append("訊息2=" + _sText2);<br>
&nbsp;&nbsp;&nbsp; out.println(buf.toString());<br>
&nbsp;&nbsp;&nbsp; out.close();<br>
&nbsp; }<br>
      </td>
    </tr>
  </tbody>
</table>
<br>
response和request都使用<span
 style="font-weight: bold; color: rgb(255, 0, 0);">UTF-8</span>就
對了。<br>
<br>
完整的 ajax1.html列表在下：<br>
<textarea name="code" class="javascript:collapse"
 rows="15" cols="120">
&lt;html&gt;
&lt;body&gt;
&lt;form id="idForm"&gt;
&nbsp; &lt;input type="text" name="TEXT1"
id="TEXT1"&gt;
&nbsp; &lt;input type="button" name="btnOK1" id="btnOK1"
value=" TEST 1 "&gt;
&nbsp; &lt;textarea name="RESULT" id="RESULT" rows=10
cols=50&gt;&lt;/textarea&gt;
&lt;/form&gt;
&lt;span
id='spaParam'&gt;&lt;/span&gt;
&lt;/body&gt;
&lt;/html&gt;
&lt;script&gt;
&nbsp; var request;
&nbsp; function httpRequest() {
&nbsp;&nbsp;&nbsp; var req;
&nbsp;&nbsp;&nbsp; if (window.XMLHttpRequest) {&nbsp;
// Mozilla-based browsers
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; req = new
XMLHttpRequest();
&nbsp;&nbsp;&nbsp; } else if (window.ActiveXObject)
{&nbsp; // IE 5, IE 6
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; req = new
ActiveXObject("Msxml2.XMLHTTP");
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (!req)
{
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
req = new ActiveXObject("Microsoft.XMLHTTP");
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }
&nbsp;&nbsp;&nbsp; }
&nbsp;&nbsp;&nbsp; return req;
&nbsp; } //~ httpRequest
&nbsp; function handleResponse() {
&nbsp;&nbsp;&nbsp; if (request.readyState == 4)
{
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (request.status
== 200) {
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
//!! innerText在FF裡竟然不行!
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
document.getElementById("RESULT").innerHTML =
request.responseText;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; } else
{
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
alert("Error: " + request.status + " " +
request.statusText);
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }
&nbsp;&nbsp;&nbsp; }
&nbsp; } //~ handleResponse
&nbsp; window.onload = function() {
&nbsp;&nbsp;&nbsp;
document.getElementById("btnOK1").onclick = function()
{
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; request =
httpRequest();
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
document.getElementById("RESULT").innertext = "";
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; request.open("POST",
"/mis/servlet/ajax_Servlet2", true);
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
//request.open("POST", "ajax2.jsp", true);
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
request.onreadystatechange = handleResponse;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
request.setRequestHeader("Content-Type",
"application/x-www-form-urlencoded;");
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
request.send("TEXT1=" + document.getElementById("TEXT1").value
+
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
"&amp;TEXT2=中文傳到Server");
&nbsp;&nbsp;&nbsp; }&nbsp; //~ btnOK1
&nbsp; } //~ window.onload
&lt;/script&gt;
</textarea><br>
##<br>
<br>
<link type="text/css" rel="stylesheet"
 href="http://emisjerry.googlepages.com/SyntaxHighlighter.css">
<script language="javascript"
 src="http://emisjerry.googlepages.com/shCore.js"></script>
<script language="javascript"
 src="http://emisjerry.googlepages.com/shBrushJScript.js"></script>
<script> dp.SyntaxHighlighter.HighlightAll('code'); </script>

		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/2863005.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/2863005.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/2863005.html</guid>
	<category>編程生涯</category>
	<pubDate>Fri, 16 Mar 2007 23:41:50 +0800</pubDate>
</item>
<item>
	<title>程式人員的線上工具箱：http://www.thepeoplestoolbox.com</title>
	<description><![CDATA[
			
Ths Peoples Toolbox是很方便的線上工具箱網站。它區分成Tools for Programmers與Tools for Web Designers兩大類，每類裡又有多種不同的技術網站，可以很簡便的瀏覽。在註冊後能自行組織需要參考的連結。
##


		]]>
	</description>
	<content:encoded><![CDATA[
			
<a href="http://www.thepeoplestoolbox.com/" target="_blank">Ths Peoples Toolbox</a>是很方便的線上工具箱網站。它區分成<span style="font-weight: bold;">Tools for Programmers</span>與<span style="font-weight: bold;">Tools for Web Designers</span>兩大類，每類裡又有多種不同的技術網站，可以很簡便的瀏覽。<br /><br />在註冊後能自行組織需要參考的連結。<br /><br /><br /><img border="0" src="http://b.blog.xuite.net/b/3/a/c/11893557/blog_10351/txt/10256202/0.jpg" />
<br />##<br />


		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/2748511.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/2748511.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/2748511.html</guid>
	<category>編程生涯</category>
	<pubDate>Tue, 20 Feb 2007 17:29:59 +0800</pubDate>
</item>
<item>
	<title>Excel讀取CSV數值字串的解決方法</title>
	<description><![CDATA[
			
在產生讓Excel讀取的CSV(Comma Separated Values)檔案時，由於Excel的自動轉換功能，導致想要保持原樣的欄位也被強迫轉錯了。例如字串的&quot;00123&quot;會被Excel自動轉成數值的 123。真是傷腦筋。還好，最後在這裡找到解決方法。原來只要加上等號就可以了，也就是是把 &quot;00123&quot; 寫成 =&quot;00123&quot; 就解決了。##


		]]>
	</description>
	<content:encoded><![CDATA[
			
在產生讓Excel讀取的CSV(Comma Separated Values)檔案時，由於Excel的自動轉換功能，導致想要保持原樣的欄位也被強迫轉錯了。例如字串的&quot;00123&quot;會被Excel自動轉成數值的 123。真是傷腦筋。<br /><br />還好，最後在<a href="http://www.creativyst.com/Doc/Articles/CSV/CSV01.htm" target="_blank">這裡</a>找到解決方法。原來只要加上等號就可以了，也就是是把<span style="color: rgb(255, 0, 0); font-weight: bold;"> &quot;00123&quot; </span>寫成<span style="color: rgb(255, 0, 0); font-weight: bold;"> =&quot;00123&quot; </span>就解決了。<br /><br />##<br />


		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/2598976.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/2598976.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/2598976.html</guid>
	<category>編程生涯</category>
	<pubDate>Mon, 25 Dec 2006 22:25:07 +0800</pubDate>
</item>
<item>
	<title>[SVN] JavaSVN改名並推出新版本</title>
	<description><![CDATA[
			
如果說TortoiseSVN是Windows環境下的Subversion
client之王的話，那麼JavaSVN就是Java環境裡的冠軍了；它的網站上列舉使用其程式庫的軟
體：





SmartSVN
- Standalone Pure Java Subversion GUI Client.

IntelliJ
IDEA - Java IDE developed by JetBrains.

TeamCity
- Collaborative Team Environment developed by JetBrains..

JDeveloper
- Oracle's Java IDE Subversion integration.

&lt;oXygen/&gt;
- XML Editor and XSLT Debugger.

Subclipse
- Eclipse Subversion plugin.

Pulse
- Automated Build Server.

Subversive
- Eclipse Subversion plugin developed by Polarion. 
SVN Web Client
- Subversion Web Client developed by Polarion.

Sventon
- Pure Java Subversion repository web browser.

TrackStudio
Enterprise - Hierarchical issue tracking and bug tracking
system.

Atlassian JIRA
- Bug tracking system (Subversion
plugin page).

Shotoku
- Content management framework, developed at JBoss labs.

Kosmos
- Software project monitoring portlets, developed at JBoss labs.

VCS
Report - generates statistic on repository, supports major
Java IDEs.





不知為何，原先的JavaSVN名稱也跟著新版的推出而換成了SVNKit。新版本已經支援Subversion 1.4.2了，原先更新過TortoiseSVN並更新了.svn目錄結構後，造成大部份的IDE都無法存取的狀況，應該算是解除了。順便安裝SmartSVN 2.1 RC5後，確實已能讀取新的檔案結構了。##

		]]>
	</description>
	<content:encoded><![CDATA[
			
<p>如果說<a target="_blank" href="http://tortoisesvn.tigris.org">TortoiseSVN</a>是Windows環境下的<a target="_blank" href="http://subversion.tigris.org">Subversion</a>
client之王的話，那麼<a target="_blank" href="http://svnkit.com">JavaSVN</a>就是Java環境裡的冠軍了；它的網站上列舉使用其程式庫的軟
體：</p>
<p>
<table cellspacing="1" cellpadding="5" border="0" style="width: 100%;">
<tbody>
<tr>
<td width="5%" bgcolor="silver"><br /></td>
<td style="background-color: rgb(255, 255, 204);"><a href="http://smartcvs.com/smartsvn/index.html" id="normal">SmartSVN</a>
- Standalone Pure Java Subversion GUI Client.
<br />
<a href="http://www.jetbrains.com/idea/" id="normal">IntelliJ
IDEA</a> - Java IDE developed by <a href="http://jetbrains.com/" id="normal">JetBrains</a>.
<br />
<a href="http://www.jetbrains.com/teamcity/" id="normal">TeamCity</a>
- Collaborative Team Environment developed by <a href="http://jetbrains.com/" id="normal">JetBrains</a>..
<br />
<a href="http://www.oracle.com/technology/products/jdev/index.html" id="normal">JDeveloper</a>
- Oracle's Java IDE Subversion <a href="http://www.oracle.com/technology/products/jdev/htdocs/partners/addins/exchange/subversion/subversion.html">integration</a>.
<br />
<a href="http://www.oxygenxml.com/" id="normal">&lt;oXygen/&gt;</a>
- XML Editor and XSLT Debugger.
<br />
<a href="http://subclipse.tigris.org/" id="normal">Subclipse</a>
- Eclipse Subversion plugin.
<br />
<a href="http://zutubi.com/" id="normal">Pulse</a>
- Automated Build Server.
<br />
<a href="http://www.polarion.org/p_subversive.php" id="normal">Subversive</a>
- Eclipse Subversion plugin developed by <a href="http://www.polarion.com/">Polarion</a>. <br />
<a href="http://polarion.org/svnwebclient.php" id="normal">SVN Web Client</a>
- Subversion Web Client developed by <a href="http://www.polarion.com/">Polarion</a>.
<br />
<a href="http://sventon.berlios.de/" id="normal">Sventon</a>
- Pure Java Subversion repository web browser.
<br />
<a href="http://www.trackstudio.com/" id="normal">TrackStudio
Enterprise</a> - Hierarchical issue tracking and bug tracking
system.
<br />
<a href="http://www.atlassian.com/software/jira/" id="normal">Atlassian JIRA</a>
- Bug tracking system (<a href="http://confluence.atlassian.com/display/JIRAEXT/JIRA+Subversion+plugin" id="normal">Subversion
plugin page</a>).
<br />
<a href="http://labs.jboss.com/shotoku" id="normal">Shotoku</a>
- Content management framework, developed at JBoss labs.
<br />
<a href="http://labs.jboss.com/projects/kosmos/" id="normal">Kosmos</a>
- Software project monitoring portlets, developed at JBoss labs.
<br />
<a href="http://vcsreport.sf.net/" id="normal">VCS
Report</a> - generates statistic on repository, supports major
Java IDEs.
</td>
</tr>
</tbody>
</table>
</p>
不知為何，原先的JavaSVN名稱也跟著新版的推出而換成了SVNKit。新版本已經支援Subversion 1.4.2了，原先更新過TortoiseSVN並更新了.svn目錄結構後，造成大部份的IDE都無法存取的狀況，應該算是解除了。順便安裝<a target="_blank" href="http://www.syntevo.com/smartsvn/index.jsp">SmartSVN 2.1 RC5</a>後，確實已能讀取新的檔案結構了。<br /><br /><img src="http://svnkit.com/img/svnkit_logo.jpg" alt="svnkit" style="width: 415px; height: 97px;" /><br /><br />##<br /><br />

		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/2484018.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/2484018.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/2484018.html</guid>
	<category>編程生涯</category>
	<pubDate>Thu, 16 Nov 2006 22:51:31 +0800</pubDate>
</item>
<item>
	<title>SVNbook繁體中文版復活</title>
	<description><![CDATA[
			
《Version Control with Subversion》繁體中文版「失聯」許久，終於在svnbook 復活中看到又重出江湖了。新的網址是：http://svn.stu.edu.tw/svnbook/book.html##


		]]>
	</description>
	<content:encoded><![CDATA[
			
《Version Control with Subversion》繁體中文版「失聯」許久，終於<a href="http://plasma.z6i.org/archives/005559.html">在svnbook 復活</a>中看到又重出江湖了。新的網址是：<a target="_blank" href="http://svn.stu.edu.tw/svnbook/book.html">http://svn.stu.edu.tw/svnbook/book.html</a><br /><br />##


		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/2385428.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/2385428.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/2385428.html</guid>
	<category>編程生涯</category>
	<pubDate>Sun, 29 Oct 2006 23:03:12 +0800</pubDate>
</item>
<item>
	<title>使用WinMerge以忽略$Header$與$Id$的檔案比對方法</title>
	<description><![CDATA[
			
為了顯示版本，我們的程式開頭一般都會加CVS或Subversion的關鍵字，如：


	
	
		
			
				&lt;!--
				$Header:
				/repository/www/test/test.jsp,v 1.28 2005/10/21 02:46:52 Jerry
				Exp $
			
		
	


或

	
	
		
			
				&lt;!-- $Id:
				test.jsp 790 2006-05-10 11:24:13Z jerry $
			
		
	


(內容中有$Header或$Id，且以
$ 結尾)

不管是$Header$或$Id$，都含有版本號碼在其內，導致不同版本的檔案在比對時，這幾列都會被視為不同內容而被標示出來，因此每次比對都會出現一堆只有不同版本編號的相同檔案，造成比對上的許多困擾。

以下是解決此困擾的方法：使用WinMerge的列濾鏡(Line
Filter)。

由http://winmerge.org
	下載WinMerge
	【工具→濾鏡】，選列濾鏡頁籤，勾選「忽略列符合下列的樣式」
	
	在輸入框裡輸入下列內容：\$Id:*\$\$Id:.*\$			(反斜線
	$Id 冒號
	點 星號 反斜線 Dollar-sign)\$Header:$\$\$Header:.*\$


     如此設定後，比對時就會忽略這兩個關鍵字當列了。

$Log$是多列的內容，以上Filter規則無法套用。


參考：C:\Program
	Files\WinMerge\Docs\Manual\filters.html


##


		]]>
	</description>
	<content:encoded><![CDATA[
			
<p lang="zh-TW" style="margin-bottom: 0cm;">為了顯示版本，我們的程式開頭一般都會加<font face="Times New Roman, serif">CVS</font>或<font face="Times New Roman, serif">Subversion</font>的關鍵字，如：</p>

<table width="100%" cellspacing="0" cellpadding="5" bordercolor="#000000" border="1">
	<col width="256*" />
	<thead>
		<tr>
			<td width="100%" valign="top" bgcolor="#ffff00">
				<p><font face="Times New Roman, serif"><font size="2" style="font-size: 11pt;">&lt;!--
				<b><font color="#ff0000">$Header</font></b>:
				/repository/www/test/test.jsp,v 1.28 2005/10/21 02:46:52 Jerry
				Exp <font color="#ff0000">$</font></font></font></p>
			</td>
		</tr>
	</thead>
</table>

<p lang="zh-TW" style="margin-bottom: 0cm;">或</p>
<table width="100%" cellspacing="0" cellpadding="5" bordercolor="#000000" border="1">
	<col width="256*" />
	<thead>
		<tr>
			<td width="100%" valign="top" bgcolor="#ffff00">
				<p><font face="Times New Roman, serif">&lt;!-- <b><font color="#ff0000">$Id:</font></b>
				test.jsp 790 2006-05-10 11:24:13Z jerry <b><font color="#ff0000">$</font></b></font></p>
			</td>
		</tr>
	</thead>
</table>

<p lang="zh-TW" style="margin-bottom: 0cm;"><font face="Times New Roman, serif">(</font>內容中有<font face="Times New Roman, serif">$Header</font>或<font face="Times New Roman, serif">$Id</font>，且以
<font face="Times New Roman, serif">$ </font>結尾<font face="Times New Roman, serif">)</font></p>

<p lang="zh-TW" style="margin-bottom: 0cm;">不管是<font face="Times New Roman, serif">$Header$</font>或<font face="Times New Roman, serif">$Id$</font>，都含有版本號碼在其內，導致不同版本的檔案在比對時，這幾列都會被視為不同內容而被標示出來，因此每次比對都會出現一堆只有不同版本編號的相同檔案，造成比對上的許多困擾。</p>

<p lang="zh-TW" style="margin-bottom: 0cm;">以下是解決此困擾的方法：使用<font face="Times New Roman, serif">WinMerge</font>的列濾鏡<font face="Times New Roman, serif">(Line
Filter)</font>。</p>

<ol><li><p lang="zh-TW" style="margin-bottom: 0cm;">由<font face="Times New Roman, serif"><a href="http://winmerge.org/">http://winmerge.org</a>
	</font>下載<font face="Times New Roman, serif">WinMerge</font></p>
	</li><li><p lang="zh-TW" style="margin-bottom: 0cm;">【工具→濾鏡】，選列濾鏡頁籤，勾選「忽略列符合下列的樣式」</p>
	</li><li>
	<p lang="zh-TW" style="margin-bottom: 0cm;">在輸入框裡輸入下列內容：<font face="Times New Roman, serif"><br />\$Id:*\$<br />\$Id:.*\$			(</font>反斜線
	<font face="Times New Roman, serif">$Id </font><b><font color="#ff0000">冒號
	點</font></b> 星號 反斜線 <font face="Times New Roman, serif">Dollar-sign)<br />\$Header:$\$<br />\$Header:.*\$</font></p>
</li></ol>

<p lang="zh-TW" style="margin-bottom: 0cm;">     如此設定後，比對時就會忽略這兩個關鍵字當列了。</p>

<ol start="4"><li><p style="margin-bottom: 0cm;"><font face="Times New Roman, serif">$Log$</font>是多列的內容，以上<font face="Times New Roman, serif">Filter</font>規則無法套用。<span lang="zh-TW"></span><span lang="zh-TW"></span></p>
</li></ol>

<ul><li><p lang="zh-TW" style="margin-bottom: 0cm;">參考：<font face="Times New Roman, serif">C:\Program
	Files\WinMerge\Docs\Manual\filters.html</font></p>
</li></ul>

<p style="margin-bottom: 0cm;">##
</p>

		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/2126062.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/2126062.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/2126062.html</guid>
	<category>編程生涯</category>
	<pubDate>Sun, 10 Sep 2006 00:11:55 +0800</pubDate>
</item>
<item>
	<title>新版IDEA無法Debug的異常</title>
	<description><![CDATA[
			
幾個月前把用了許久的IDEA 5.0.1升級到5.0.2，但遇到需要remote
debug的狀況時，IDEA的debug卻無絲毫反應，在設定了中斷點的地方，應該中斷卻沒停住，將游標移到中斷點的紅點上，顯示出：Invalid
breakpoint; source had been changed。各個設定都重新調整過，卻仍然無法正常。

後來只得移除掉，再安裝5.1.1與5.1.2，卻同樣失效，最後重新安裝回一開始的5.0.1才恢復正常。這...到底是怎麼回事，由Forum上看似
乎這個狀況在許久前就發生，且在5.0就修正了，但為何我升級到Bug-fix的版本卻會異常呢? 算了，只好繼續用5.0.1了。

##



		]]>
	</description>
	<content:encoded><![CDATA[
			
幾個月前把用了許久的IDEA 5.0.1升級到5.0.2，但遇到需要remote
debug的狀況時，IDEA的debug卻無絲毫反應，在設定了中斷點的地方，應該中斷卻沒停住，將游標移到中斷點的紅點上，顯示出：Invalid
breakpoint; source had been changed。各個設定都重新調整過，卻仍然無法正常。<br />
<br />
後來只得移除掉，再安裝5.1.1與5.1.2，卻同樣失效，最後重新安裝回一開始的5.0.1才恢復正常。這...到底是怎麼回事，由Forum上看似
乎這個狀況在許久前就發生，且在5.0就修正了，但為何我升級到Bug-fix的版本卻會異常呢? 算了，只好繼續用5.0.1了。<br />
<br />
##<br />



		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/1974704.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1974704.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1974704.html</guid>
	<category>編程生涯</category>
	<pubDate>Fri, 04 Aug 2006 22:48:59 +0800</pubDate>
</item>
<item>
	<title>[PSPad] PSPad的Scripting功能初探</title>
	<description><![CDATA[
			由於Java IDE通常都很龐大，開啟時會耗費許多系統資源與載入時間，因此有些小程式或修改幅度不大的程式，經常都是使用PSPad之類的文書編輯系統來直接修改，修改、測試完成後就複製到實際運行環境，先前發表的[Windows] 部署相同目錄結構檔案的簡便方法就是為了方便複製檔案而寫的小Script，因為PSPad由4.3版開始就提供了透過WScrip執行的Script環境，所以特別的研究要如何簡化複製程式的作法。PSPad
安裝目錄的Scripts資料夾與功能表的Scripts是對應的，我們把要執行的VBScript或JavaScript放到對應的資料夾裡，再透過
Scripts功能表裡的【重新編譯 Scripts】來重新產生其下的功能表與各Script檔；例如功能表上的VBScript
sample對應的檔案就是C:\Program Files\PSPad\Scripts\VBScript\Sample.vbs，VBScript Sample的子功能選項就是Sample.vbs裡的多個副常式(Sub routine)。PSPad的Script有幾個固定的格式必須遵守：開頭標明程式名稱（稱為module_name），其名稱必須唯一必須有Init副常式，在Init裡以addMenuItem將可供執行的副常式加到功能表上；addMenuItem最多可有４個參數：功能選項字串：顯示在功能表上的標題文字上層功能選項名稱：若為空白則該副常式在Scripts功能表獨立一項，若有別的字串，則為該字串的子功能選項副常式名稱字串執行此常式的快速鍵字串（選項，可有可無）Sample.vbs範例如下(其結果由PSPad的Scripts可看到)：const module_name  = &quot;VBSample&quot;         'this name must be unique !!!const module_ver   = &quot;0.001a&quot;            'version' name &quot;Init&quot; is required, its called automatically during initialization to create menu itemssub Init  addMenuItem &quot;Print all files&quot;,&quot;&quot;, &quot;PrintAll&quot;, &quot;Shift+Ctrl+P&quot;     ' 自己佔獨立一列，無子功能表; 定義了快速鍵  addMenuItem &quot;Main method&quot;, &quot;VBscript sample&quot;, &quot;Main&quot;    ' 在VBscript sample項目下的子功能選項  addMenuItem &quot;PSPad version&quot;,&quot;VBscript sample&quot;, &quot;Demo1&quot;  addMenuItem &quot;Script module version&quot;,&quot;VBscript sample&quot;, &quot;Demo2&quot;  addMenuItem &quot;Open script file&quot;,&quot;VBscript sample&quot;, &quot;Demo3&quot;   addMenuItem &quot;LOG Access&quot;,&quot;VBscript sample&quot;, &quot;DemoLog&quot; end sub複製檔案到以網路磁碟機連結的主機的程式如下：const module_name  = &quot;duplicate&quot;         'this name must be unique !!!const module_ver   = &quot;0.001a&quot;            'versionsub Init  addMenuItem &quot;同步到主機&quot;, &quot;&quot;, &quot;duplicate&quot;, &quot;CTRL+M&quot;end subsub duplicate  dim oEditor, sSource, sTarget, sDrive    set oEditor = newEditor()           'new editor object  oEditor.assignActiveEditor     ' 把oEditor設定成編輯中的檔案  sSource = oEditor.fileName()   '取出檔案全名(含路徑)  sTarget = Mid(sSource,2,99)   ' 去掉磁碟機代號  if InStr(sSource, &quot;\xyz\&quot;) &gt; 0 then   ' 檔名中有\xyz\則複製到m:，否則複製到o:    sDrive = &quot;m&quot;  else    sDrive = &quot;o&quot;  end if  sTarget = sDrive + sTarget  oEditor.saveFileAs(sTarget)   ' 另存檔案到主機同名目錄  msgBox(sSource + &quot; 同步到==&gt; &quot; + sTarget)  'oEditor.closeFile  oEditor.openFile(sSource)  ' 檔名已變成主機的檔名，必須再重新開回原來檔名end sub程式很簡單，應該很容易看懂。PSPad script能使用的函數可由其【幫助】的&quot;Script&quot;查到。##

		]]>
	</description>
	<content:encoded><![CDATA[
			由於Java IDE通常都很龐大，開啟時會耗費許多系統資源與載入時間，因此有些小程式或修改幅度不大的程式，經常都是使用<a target="_blank" href="http://www.pspad.com/en/">PSPad</a>之類的文書編輯系統來直接修改，修改、測試完成後就複製到實際運行環境，先前發表的<strong></strong><strong><a href="http://blog.roodo.com/emisjerry/archives/40803.html" class="normal">[Windows] 部署相同目錄結構檔案的簡便方法</a></strong>就是為了方便複製檔案而寫的小Script，因為PSPad由4.3版開始就提供了透過WScrip執行的Script環境，所以特別的研究要如何簡化複製程式的作法。<br /><br />PSPad
安裝目錄的Scripts資料夾與功能表的Scripts是對應的，我們把要執行的VBScript或JavaScript放到對應的資料夾裡，再透過
Scripts功能表裡的【重新編譯 Scripts】來重新產生其下的功能表與各Script檔；例如功能表上的VBScript
sample對應的檔案就是C:\Program Files\PSPad\Scripts\VBScript<span style="font-weight: bold;">\Sample.vbs</span>，VBScript Sample的子功能選項就是Sample.vbs裡的多個副常式(Sub routine)。<br /><br />PSPad的Script有幾個固定的格式必須遵守：<br /><ol><li>開頭標明程式名稱（稱為module_name），其名稱必須唯一</li><li>必須有Init副常式，在Init裡以addMenuItem將可供執行的副常式加到功能表上；addMenuItem最多可有４個參數：<br /><ol><li>功能選項字串：顯示在功能表上的標題文字</li><li>上層功能選項名稱：若為空白則該副常式在Scripts功能表獨立一項，若有別的字串，則為該字串的子功能選項</li><li>副常式名稱字串</li><li>執行此常式的快速鍵字串（選項，可有可無）</li></ol></li></ol>Sample.vbs範例如下(其結果由PSPad的Scripts可看到)：<table cellspacing="1" cellpadding="2" border="0" style="text-align: left; background-color: rgb(51, 51, 255); width: 90%;"><tbody><tr><td style="background-color: rgb(255, 255, 204);">const module_name  = &quot;VBSample&quot;         'this name must be unique !!!<br />const module_ver   = &quot;0.001a&quot;            'version<br /><br />' name &quot;Init&quot; is required, its called automatically during initialization to create menu items<br />sub Init<br />  addMenuItem &quot;Print all files&quot;,&quot;&quot;, &quot;PrintAll&quot;, &quot;Shift+Ctrl+P&quot;     ' 自己佔獨立一列，無子功能表; 定義了快速鍵<br />  addMenuItem &quot;Main method&quot;, &quot;VBscript sample&quot;, &quot;Main&quot;    ' 在VBscript sample項目下的子功能選項<br />  addMenuItem &quot;PSPad version&quot;,&quot;VBscript sample&quot;, &quot;Demo1&quot;<br />  addMenuItem &quot;Script module version&quot;,&quot;VBscript sample&quot;, &quot;Demo2&quot;<br />  addMenuItem &quot;Open script file&quot;,&quot;VBscript sample&quot;, &quot;Demo3&quot; <br />  addMenuItem &quot;LOG Access&quot;,&quot;VBscript sample&quot;, &quot;DemoLog&quot; <br />end sub</td></tr></tbody></table><br />複製檔案到以網路磁碟機連結的主機的程式如下：<br /><table cellspacing="1" cellpadding="2" border="0" style="text-align: left; background-color: rgb(51, 51, 255); width: 90%;"><tbody><tr><td style="background-color: rgb(255, 255, 204);">const module_name  = &quot;duplicate&quot;         'this name must be unique !!!<br />const module_ver   = &quot;0.001a&quot;            'version<br /><br />sub Init<br />  addMenuItem &quot;同步到主機&quot;, &quot;&quot;, &quot;duplicate&quot;, &quot;CTRL+M&quot;<br />end sub<br /><br />sub duplicate<br />  dim oEditor, sSource, sTarget, sDrive<br />  <br />  set oEditor = newEditor()           'new editor object<br />  oEditor.assignActiveEditor     ' 把oEditor設定成編輯中的檔案<br />  sSource = oEditor.fileName()   '取出檔案全名(含路徑)<br />  sTarget = Mid(sSource,2,99)   ' 去掉磁碟機代號<br />  if InStr(sSource, &quot;\xyz\&quot;) &gt; 0 then   ' 檔名中有\xyz\則複製到m:，否則複製到o:<br />    sDrive = &quot;m&quot;<br />  else<br />    sDrive = &quot;o&quot;<br />  end if<br />  sTarget = sDrive + sTarget<br />  oEditor.saveFileAs(sTarget)   ' 另存檔案到主機同名目錄<br />  msgBox(sSource + &quot; 同步到==&gt; &quot; + sTarget)<br />  'oEditor.closeFile<br />  oEditor.openFile(sSource)  ' 檔名已變成主機的檔名，必須再重新開回原來檔名<br />end sub<br /><br /></td></tr></tbody></table><br />程式很簡單，應該很容易看懂。PSPad script能使用的函數可由其【幫助】的&quot;Script&quot;查到。<br /><br />##<br />

		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/1734091.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1734091.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1734091.html</guid>
	<category>編程生涯</category>
	<pubDate>Sat, 10 Jun 2006 00:23:23 +0800</pubDate>
</item>
<item>
	<title>推薦&quot;十年自學程式設計&quot;一文</title>
	<description><![CDATA[
			十年自學程式設計：有發人深省的評論，值得初入軟體開發的新人或電腦相關科系的同學們一讀。##
		]]>
	</description>
	<content:encoded><![CDATA[
			<a target="_blank" href="http://www.open-asm.com/article/tenyears.htm">十年自學程式設計</a>：有發人深省的評論，值得初入軟體開發的新人或電腦相關科系的同學們一讀。<br /><br />##<br />
		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/1690319.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1690319.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1690319.html</guid>
	<category>編程生涯</category>
	<pubDate>Wed, 31 May 2006 21:56:30 +0800</pubDate>
</item>
<item>
	<title>程式語言的搜尋引擎：Koders.com</title>
	<description><![CDATA[
			Koders.com提供了程式語言的搜尋功能，目前有Eclipse與Visual Studio的Plugin，可以在這兩個IDE裡直接使用；如果不是使用這兩種IDE的，也可以增加成FireFox的搜尋引擎。我用createStatement做測試，以下是其中的輸出網頁：##
		]]>
	</description>
	<content:encoded><![CDATA[
			<a target="_blank" href="http://www.koders.com">Koders.com</a>提供了程式語言的搜尋功能，目前有Eclipse與Visual Studio的Plugin，可以在這兩個IDE裡直接使用；如果不是使用這兩種IDE的，也可以增加成FireFox的搜尋引擎。<br /><br /><img src="http://www.koders.com/Special/AdServer/?action=serveimage&flight=62&imageurl=AB4KH4BR43N8V57R1WNZZ1UPFW6GH1PPSN58CVYPQ558C2UQY53VG1QRSL3GGZFQT56MZZARPN7RZX3QQBQPD6ASUBPAD1ARR53A&random=632846551487624968" alt="www.koders.com" /><br /><br />我用createStatement做測試，以下是其中的輸出網頁：<br /><br /><img src="http://b.blog.xuite.net/b/3/a/c/11893557/blog_10351/txt/6639959/0.jpg" alt="Koders.com sample" /><br /><br />##<br />
		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/1690276.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1690276.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1690276.html</guid>
	<category>編程生涯</category>
	<pubDate>Wed, 31 May 2006 21:52:27 +0800</pubDate>
</item>
<item>
	<title>把應用系統移植到WebSphere 6.0</title>
	<description><![CDATA[
			為了把應用系統移植到IBM WebSphere 6.0上，努力了研究、測試了好幾天，幸好最終還是成功了。WebSphere自從3.0之後，就再也沒用過，一開始被IBM式的術語搞得昏頭轉向，什麼profile、cell、node等的，把整個目錄架構弄得非常複雜，適應起來也很困難。原本是想把程式直接複製到已有的應用系統裡，試了許久都無法成功，最好只好乖乖的用管理主控台的部署功能來按部就班的安裝，才順利的運行起來。WebSphere的新應用系統安裝必須使用EAR、WAR或JAR檔，因為NetBeans 5.0裡有Deploy Project的功能，剛好能產生WAR檔，因此就能產生好給WebSphere讀取部署。另外有幾點必須修改：WebSphere似乎對於MS950編碼的處理有點問題，所有的XML與TLD檔若使用到encoding=&quot;MS950&quot;都必須換掉，否則會出現編碼錯誤的訊息；但奇怪的JSP卻又能使用MS950編碼。被include的JSP檔案也必須加上額外的編碼指引，否則中文會變成亂碼##
		]]>
	</description>
	<content:encoded><![CDATA[
			<p>為了把應用系統移植到<a href="http://www.ibm.com/software/websphere" target="_blank">IBM WebSphere 6.0</a>上，努力了研究、測試了好幾天，幸好最終還是成功了。</p><p>WebSphere自從3.0之後，就再也沒用過，一開始被IBM式的術語搞得昏頭轉向，什麼profile、cell、node等的，把整個目錄架構弄得非常複雜，適應起來也很困難。原本是想把程式直接複製到已有的應用系統裡，試了許久都無法成功，最好只好乖乖的用管理主控台的部署功能來按部就班的安裝，才順利的運行起來。</p><p>WebSphere的新應用系統安裝必須使用EAR、WAR或JAR檔，因為<a href="http://www.netbeans.org/" target="_blank">NetBeans 5.0</a>裡有Deploy Project的功能，剛好能產生WAR檔，因此就能產生好給WebSphere讀取部署。</p><p>另外有幾點必須修改：</p><ul><li>WebSphere似乎對於MS950編碼的處理有點問題，所有的XML與TLD檔若使用到encoding=&quot;MS950&quot;都必須換掉，否則會出現編碼錯誤的訊息；但奇怪的JSP卻又能使用MS950編碼。</li><li>被include的JSP檔案也必須加上額外的編碼指引，否則中文會變成亂碼</li></ul><p>##</p>
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1319851.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1319851.html</guid>
	<category>編程生涯</category>
	<pubDate>Sun, 26 Mar 2006 12:42:33 +0800</pubDate>
</item>
<item>
	<title>Resin 3.0.18與其PHP引擎</title>
	<description><![CDATA[
			上周Caucho公司釋出了最新版的Resin 3.0.18。由Resin 3.0.17開始，Resin裡多了一個稱為Quercus的東西，Quercus其實就是用Java實作的PHP語言模組。Resin的原作者Scott Ferguson說：Quercus is Caucho's cleanroom implementation of the PHP language written in Java. As a Java PHP implementation, it provides three primary benefits: allowing Resin to run PHP applications natively, giving PHP applications the stability and security of a Java application server, and letting Java applications use PHP as a presentation layer.因此除了原有的XTP、JSP以外，我們也能在Resin上使用PHP來當做另一種展示層，而且「據說」Resin的PHP執行效能比Apache/mod_php高上數倍，另外，Caucho的論壇(http://forum.caucho.com)、Wiki(http://wiki.caucho.com)全部都是用Quercus在運作的，Wiki更是使用Mediawiki的PHP在執行的。在Resin裡使用PHP的設定很簡單，就是設定一個QuercusServlet，再設一個Servlet-mapping以將*.php交給QuercusServlet處理即可。設定範例如下：在webapps\ROOT\WEB-INF目錄裡增加web.xml檔案，內容為：＜web-app xmlns=&quot;http://caucho.com/ns/resin&quot;&gt;  ＜servlet-mapping url-pattern=&quot;*.php&quot;    servlet-class=&quot;com.caucho.quercus.servlet.QuercusServlet&quot;&gt;  ＜/servlet-mapping&gt;＜/web-app&gt;在webapps\ROOT裡新增HelloWorld.php檔案，內容為：＜?php  echo &quot;Hello World&quot;;?&gt;在瀏覽器網址裡以 http://localhost:8080/HelloWorld.php 測試其實是相當簡單的。這樣，似乎就能把Java和PHP整合起來了。## 
		]]>
	</description>
	<content:encoded><![CDATA[
			<p>上周Caucho公司釋出了最新版的<a href="http://www.caucho.com/resin-3.0/features/changes.xtp" target="_blank">Resin 3.0.18</a>。由Resin 3.0.17開始，Resin裡多了一個稱為<big><span style="FONT-WEIGHT: bold">Quercus</span></big>的東西，Quercus其實就是用Java實作的<span style="FONT-WEIGHT: bold">PHP</span>語言模組。Resin的原作者Scott Ferguson說：</p><p><table style="WIDTH: 100%; BACKGROUND-COLOR: rgb(255,255,204); TEXT-ALIGN: left" cellspacing="0" cellpadding="2" border="0"><tbody><tr><td>Quercus is Caucho's cleanroom implementation of the PHP language written in Java. As a Java PHP implementation, it provides three primary benefits: allowing Resin to run PHP applications natively, giving PHP applications the stability and security of a Java application server, and letting Java applications use PHP as a presentation layer.</td></tr></tbody></table></p><p>因此除了原有的XTP、JSP以外，我們也能在Resin上使用PHP來當做另一種展示層，而且「據說」Resin的PHP執行效能比Apache/mod_php高上數倍，另外，Caucho的<a href="http://forum.caucho.com/" target="_blank">論壇</a>(http://forum.caucho.com)、<a href="http://wiki.caucho.com/" target="_blank">Wiki</a>(http://wiki.caucho.com)全部都是用Quercus在運作的，Wiki更是使用<a href="http://www.mediawiki.com/" target="_blank">Mediawiki</a>的PHP在執行的。</p><p>在Resin裡使用PHP的設定很簡單，就是設定一個QuercusServlet，再設一個Servlet-mapping以將*.php交給QuercusServlet處理即可。設定範例如下：</p><ol><li>在webapps\ROOT\WEB-INF目錄裡增加web.xml檔案，內容為：<br /><table style="WIDTH: 100%; BACKGROUND-COLOR: rgb(51,51,255); TEXT-ALIGN: left" cellspacing="1" cellpadding="2" border="0"><tbody><tr><td style="BACKGROUND-COLOR: rgb(255,255,204)">＜web-app xmlns=&quot;http://caucho.com/ns/resin&quot;&gt;<br />  ＜servlet-mapping url-pattern=&quot;*.php&quot;<br />    servlet-class=&quot;com.caucho.quercus.servlet.QuercusServlet&quot;&gt;<br />  ＜/servlet-mapping&gt;<br />＜/web-app&gt;</td></tr></tbody></table></li><li>在webapps\ROOT裡新增HelloWorld.php檔案，內容為：<br /><table style="WIDTH: 100%; BACKGROUND-COLOR: rgb(51,51,255); TEXT-ALIGN: left" cellspacing="1" cellpadding="2" border="0"><tbody><tr><td style="BACKGROUND-COLOR: rgb(255,255,204)">＜?php<br />  echo &quot;Hello World&quot;;<br />?&gt;<br /></td></tr></tbody></table></li><li>在瀏覽器網址裡以 http://localhost:8080/HelloWorld.php 測試</li></ol><p>其實是相當簡單的。這樣，似乎就能把Java和PHP整合起來了。<br />## </p>
		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/1175158.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1175158.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1175158.html</guid>
	<category>編程生涯</category>
	<pubDate>Sun, 26 Feb 2006 14:47:02 +0800</pubDate>
</item>
<item>
	<title>[NetBeans] 兩個Matisse GUI的展示</title>
	<description><![CDATA[
			在More Matisse Flash Demos文章裡展示了兩個Flash的Matise GUI操作展示，簡單易懂。在圖形上按鈕即可開啟展示。 ##
		]]>
	</description>
	<content:encoded><![CDATA[
			<p>在<strong><a href="http://blogs.sun.com/roller/page/johnc?entry=more_matisse_flash_demos" target="_blank">More Matisse Flash Demos</a></strong>文章裡展示了兩個Flash的Matise GUI操作展示，簡單易懂。在圖形上按鈕即可開啟展示。</p><p><a href="http://testwww.netbeans.org/kb/50/gui_sample_project/find_form_demo.html" target="_blank"><img src="http://testwww.netbeans.org/images/screenshots/5.0/gui_sample_find.png" /></a></p><p><a href="http://testwww.netbeans.org/kb/50/gui_sample_project/antenna_form_demo.html" target="_blank"><img src="http://testwww.netbeans.org/images/screenshots/5.0/gui_sample_antenna.png" /></a> </p><p>##</p>
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1154754.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1154754.html</guid>
	<category>編程生涯</category>
	<pubDate>Tue, 21 Feb 2006 22:15:59 +0800</pubDate>
</item>
<item>
	<title>NetBeans的Subversion設定的最後一個步驟</title>
	<description><![CDATA[
			由於Widnows登錄壞掉了，然後又安裝NetBeans 5.0正式版，在更新了Subversion的Plugin後－Subversion竟然就無法使用了：Command &quot;LIST_CMD&quot; has failed. Execution string: cmd /X /C &quot;cd /D \&quot;C:\working_copy\&quot;&amp;&amp;svn status -v  -N --no-ignore&quot;The error output follows, check Runtime for the full output of the command.原先懷疑是checkout下來的working copy有問題，前前後後測試比對了許久，最後回想先前似乎有把svn.exe的目錄加到PATH環境變數，因此試著重新加回，再次啟動 NetBeans，Bingo!，就這樣解決了。因此NetBeans裡的Subversion設定最後的步驟就是把PATH 環境變數設定正確，千萬不要漏了這個動作。##
		]]>
	</description>
	<content:encoded><![CDATA[
			<!--StartFragment -->由於<a href="http://blog.xuite.net/emisjerry/tech/5049021" target="_blank">Widnows登錄壞掉了</a>，然後又安裝<a href="http://blog.xuite.net/emisjerry/tech/5044794" target="_blank">NetBeans 5.0正式版</a>，在更新了<a href="http://blog.xuite.net/emisjerry/tech/4924155" target="_blank">Subversion的Plugin</a>後－Subversion竟然就無法使用了：<table style="FONT-WEIGHT: bold; WIDTH: 100%; HEIGHT: 96px; BACKGROUND-COLOR: rgb(51,51,255); TEXT-ALIGN: left" cellspacing="1" cellpadding="2" border="0"><tbody><tr><td style="BACKGROUND-COLOR: rgb(255,255,153)">Command &quot;LIST_CMD&quot; has failed. Execution string: cmd /X /C &quot;cd /D \&quot;C:\working_copy\&quot;&amp;&amp;svn status -v  -N --no-ignore&quot;<br />The error output follows, check Runtime for the full output of the command.</td></tr></tbody></table><p><span class="titlename">原先懷疑是checkout下來的working copy有問題，前前後後測試比對了許久，最後回想先前似乎有把svn.exe的目錄加到PATH環境變數，因此試著重新加回，再次啟動 NetBeans，Bingo!，就這樣解決了。</span></p><p><span class="titlename">因此NetBeans裡的Subversion設定最後的步驟就是把PATH 環境變數設定正確，千萬不要漏了這個動作。</span></p><p><span class="titlename">##</span></p>
		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/1079898.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1079898.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1079898.html</guid>
	<category>編程生涯</category>
	<pubDate>Fri, 03 Feb 2006 23:18:08 +0800</pubDate>
</item>
<item>
	<title>NetBeans 5.0釋出了!</title>
	<description><![CDATA[
			NetBeans 5.0終於脫離測試正式釋出了。Matisse(馬諦斯)自然是最大的加強，5.0的文件也一併提供了一些。##
		]]>
	</description>
	<content:encoded><![CDATA[
			<p><a href="http://www.netbeans.org/" target="_blank">NetBeans 5.0</a>終於脫離測試正式釋出了。</p><p>Matisse(馬諦斯)自然是最大的加強，5.0的文件也一併提供了一些。</p><p>##</p>
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1076121.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1076121.html</guid>
	<category>編程生涯</category>
	<pubDate>Thu, 02 Feb 2006 22:48:59 +0800</pubDate>
</item>
<item>
	<title>NetBeans 5.0和亨利．馬諦斯(Matisse)</title>
	<description><![CDATA[
			使用了NetBeans 5.0 RC2後，名為Matisse的新GUI Builder是最令人驚艷的特出功能。簡單、直覺的使用直比操作Delphi的拖拉經驗。Eclipse並用使用過太久，因而無法比較，但Matisse確實是比IDEA的GUI 編修功能方便多了。Matisse的示範可以參考GUI Building in NetBeans IDE 5.0這篇教學文章，他的教學錄影彙總如下：Getting Familiar with the GUI Builderhttp://testwww.netbeans.org/kb/50/quickstart-gui_swfs/001_gui_builder_ui.html Adding Components: The Basicshttp://testwww.netbeans.org/kb/50/quickstart-gui_swfs/002_add_components_basic.htmlAdding Individual Components to the Formhttp://testwww.netbeans.org/kb/50/quickstart-gui_swfs/003_add_individual_components.htmlAdding Multiple Components to the Formhttp://testwww.netbeans.org/kb/50/quickstart-gui_swfs/004_add_multi_components.htmlInserting Componentshttp://testwww.netbeans.org/kb/50/quickstart-gui_swfs/005_insert_components.htmlComponent Alignmenthttp://testwww.netbeans.org/kb/50/quickstart-gui_swfs/006_align_components.htmlBaseline Alignmenthttp://testwww.netbeans.org/kb/50/quickstart-gui_swfs/007_insert_baseline.htmlAdding, Aligning, and Anchoringhttp://testwww.netbeans.org/kb/50/quickstart-gui_swfs/008_add_align_anchor.htmlComponent Sizinghttp://testwww.netbeans.org/kb/50/quickstart-gui_swfs/009_size_components.htmlIndentationhttp://testwww.netbeans.org/kb/50/quickstart-gui_swfs/010_add_indent_components.htmlMaking the Final Adjustments http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/011_preview_gui.html「Matisse」的這個Code name則令我困擾了一會，搜索了NetBeans網站也找不到答案，由Google查則發現Matisse是法國野獸派畫派大師Henri Mattise的姓氏（中譯亨利．馬諦斯），我猜測：可能Matisse是NetBeans GUI開發人員喜愛的畫家，因此才有了這個名稱。由blogs.sun.com裡得到佐證：http://blogs.sun.com/roller/page/theaquarium?entry=matisse_netbeans_derby_and_glassfish，這篇文章裡用了馬諦斯的自畫像。1906 自畫像1933 照片今天下午到台北市立美術館參觀「美好年代－巴黎市立現代美術館收藏展」，剛巧有展示馬諦斯的兩幅畫作，真是無巧不成書。##
		]]>
	</description>
	<content:encoded><![CDATA[
			<p><!--StartFragment -->使用了<a href="http://www.netbeans.org/">NetBeans 5.0 RC2</a>後，名為Matisse的新GUI Builder是最令人驚艷的特出功能。簡單、直覺的使用直比操作Delphi的拖拉經驗。<br /><br /><a href="http://www.eclipse.org/">Eclipse</a>並用使用過太久，因而無法比較，但Matisse確實是比<a href="http://www.intellij.com/">IDEA</a>的GUI 編修功能方便多了。Matisse的示範可以參考<a href="http://www.netbeans.org/kb/50/quickstart-gui.html">GUI Building in NetBeans IDE 5.0</a>這篇教學文章，他的教學錄影彙總如下：<br /><br /><table style="WIDTH: 98%; BACKGROUND-COLOR: rgb(0,153,0); TEXT-ALIGN: left" cellspacing="1" cellpadding="2" border="0"><tbody><tr><td style="WIDTH: 304px; BACKGROUND-COLOR: rgb(255,255,204)">Getting Familiar with the GUI Builder</td><td style="WIDTH: 574px; BACKGROUND-COLOR: rgb(255,255,204)"><a href="http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/001_gui_builder_ui.html">http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/001_gui_builder_ui.html</a> </td></tr><tr><td style="WIDTH: 304px; BACKGROUND-COLOR: rgb(255,255,204)"><a href="http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/001_gui_builder_ui.html">Adding Components: The Basics</a></td><td style="WIDTH: 574px; BACKGROUND-COLOR: rgb(255,255,204)"><a href="http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/001_gui_builder_ui.html">http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/002_add_components_basic.html</a></td></tr><tr><td style="WIDTH: 304px; BACKGROUND-COLOR: rgb(255,255,204)">Adding Individual Components to the Form</td><td style="WIDTH: 574px; BACKGROUND-COLOR: rgb(255,255,204)"><a href="http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/003_add_individual_components.html">http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/003_add_individual_components.html</a></td></tr><tr><td style="WIDTH: 304px; BACKGROUND-COLOR: rgb(255,255,204)">Adding Multiple Components to the Form</td><td style="WIDTH: 574px; BACKGROUND-COLOR: rgb(255,255,204)"><a href="http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/004_add_multi_components.html">http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/004_add_multi_components.html</a></td></tr><tr><td style="WIDTH: 304px; BACKGROUND-COLOR: rgb(255,255,204)">Inserting Components</td><td style="WIDTH: 574px; BACKGROUND-COLOR: rgb(255,255,204)"><a href="http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/005_insert_components.html">http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/005_insert_components.html</a></td></tr><tr><td style="WIDTH: 304px; BACKGROUND-COLOR: rgb(255,255,204)">Component Alignment</td><td style="WIDTH: 574px; BACKGROUND-COLOR: rgb(255,255,204)"><a href="http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/006_align_components.html">http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/006_align_components.html</a></td></tr><tr><td style="WIDTH: 304px; BACKGROUND-COLOR: rgb(255,255,204)">Baseline Alignment</td><td style="WIDTH: 574px; BACKGROUND-COLOR: rgb(255,255,204)"><a href="http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/007_insert_baseline.html">http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/007_insert_baseline.html</a></td></tr><tr><td style="WIDTH: 304px; BACKGROUND-COLOR: rgb(255,255,204)">Adding, Aligning, and Anchoring</td><td style="WIDTH: 574px; BACKGROUND-COLOR: rgb(255,255,204)"><a href="http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/008_add_align_anchor.html">http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/008_add_align_anchor.html</a></td></tr><tr><td style="WIDTH: 304px; BACKGROUND-COLOR: rgb(255,255,204)">Component Sizing</td><td style="WIDTH: 574px; BACKGROUND-COLOR: rgb(255,255,204)"><a href="http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/009_size_components.html">http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/009_size_components.html</a></td></tr><tr><td style="WIDTH: 304px; BACKGROUND-COLOR: rgb(255,255,204)">Indentation</td><td style="WIDTH: 574px; BACKGROUND-COLOR: rgb(255,255,204)"><a href="http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/010_add_indent_components.html">http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/010_add_indent_components.html</a></td></tr><tr><td style="WIDTH: 304px; BACKGROUND-COLOR: rgb(255,255,204)">Making the Final Adjustments </td><td style="WIDTH: 574px; BACKGROUND-COLOR: rgb(255,255,204)"><a href="http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/011_preview_gui.html">http://testwww.netbeans.org/kb/50/quickstart-gui_swfs/011_preview_gui.html</a></td></tr></tbody></table><br /><br /><span style="FONT-WEIGHT: bold">「Matisse」</span>的這個Code name則令我困擾了一會，搜索了NetBeans網站也找不到答案，由Google查則發現Matisse是法國野獸派畫派大師Henri Mattise的姓氏（中譯<strong>亨<span style="FONT-WEIGHT: bold">利．馬諦斯</span></strong>），我猜測：可能Matisse是NetBeans GUI開發人員喜愛的畫家，因此才有了這個名稱。由blogs.sun.com裡得到佐證：<a href="http://blogs.sun.com/roller/page/theaquarium?entry=matisse_netbeans_derby_and_glassfish">http://blogs.sun.com/roller/page/theaquarium?entry=matisse_netbeans_derby_and_glassfish</a>，這篇文章裡用了馬諦斯的自畫像。<br /><br /><table style="WIDTH: 100px; BACKGROUND-COLOR: rgb(0,153,0); TEXT-ALIGN: left" cellspacing="1" cellpadding="4" border="0"><tbody><tr><td style="BACKGROUND-COLOR: rgb(255,255,204)"><img style="WIDTH: 179px; HEIGHT: 216px" alt="1906 Self-Portrait" src="http://b.blog.xuite.net/b3/ac/11893557/blog_10351/txt/5022197/0.jpg" /></td><td style="BACKGROUND-COLOR: rgb(255,255,204)"><img style="WIDTH: 180px; HEIGHT: 220px" alt="1933 Photo" src="http://b.blog.xuite.net/b3/ac/11893557/blog_10351/txt/5022197/1.jpg" /></td></tr><tr><td style="BACKGROUND-COLOR: rgb(255,255,204); TEXT-ALIGN: center">1906 自畫像</td><td style="BACKGROUND-COLOR: rgb(255,255,204); TEXT-ALIGN: center">1933 照片</td></tr></tbody></table><br />今天下午到<a href="http://www.tfam.gov.tw/">台北市立美術館</a>參觀<a class="news" href="http://www.tfam.gov.tw/exhibit/exh_01.asp?exhibit_no=204&Item=now">「美好年代－巴黎市立現代美術館收藏展」</a>，剛巧有展示馬諦斯的兩幅畫作，真是無巧不成書。<br /><br />##</p>
		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/1066855.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1066855.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1066855.html</guid>
	<category>編程生涯</category>
	<pubDate>Tue, 31 Jan 2006 00:35:44 +0800</pubDate>
</item>
<item>
	<title>參考：Netbeans as a J2EE teaching IDE</title>
	<description><![CDATA[
			Eclipse和NetBeans兩大陣營始終各有一批死忠者，經常在網路上打起孰優孰劣的筆戰，不過，大多是Eclipse獲勝，由其用戶之多可見一斑。但在這篇&quot;Netbeans as a J2EE teaching IDE&quot;裡，作者以整合性提出了他的不同看法，請大家參考看看。##
		]]>
	</description>
	<content:encoded><![CDATA[
			<p><a href="http://www.eclipse.org/" target="_blank">Eclipse</a>和<a href="http://www.netbeans.org/" target="_blank">NetBeans</a>兩大陣營始終各有一批死忠者，經常在網路上打起孰優孰劣的筆戰，不過，大多是Eclipse獲勝，由其用戶之多可見一斑。</p><p>但在這篇<a href="http://home.izforge.com/index.php/2006/01/04/204-netbeans-as-a-j2ee-teaching-ide" target="_blank">&quot;Netbeans as a J2EE teaching IDE&quot;</a>裡，作者以整合性提出了他的不同看法，請大家參考看看。<br /></p><p>##</p>
		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/1035483.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1035483.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1035483.html</guid>
	<category>編程生涯</category>
	<pubDate>Sun, 22 Jan 2006 15:01:08 +0800</pubDate>
</item>
<item>
	<title>[NetBeans] 安裝與設定NetBeans內的Subversion</title>
	<description><![CDATA[
			NetBeans 5.0內建CVS做為程式的版本管理之用，若要使用CVS以外的版本管理系統，則要由NetBeans Update Center裡額外安裝，以下是安裝Subversion的步驟：點選【Tools→Update Center】，按【Next】，記得要勾選NetBeans Update Center Beta由要安裝的模組中選Subversion profile for Generic VCS後按【Add】，系統會將Subversion需要用的模組檔案加到右側，按【Next】，選【Accept】後就開始下載。下載完成後按【Next】與【Finish】由【Tools→Module manager】確認內建的CVS已被取消掉，而由剛裝的Subversion取代由【Versioning→Versioning Manager】選定Subversion的控制目錄，將目錄和Subversion的Repository URL建立正確關聯如果VCS Output頁籤出現LIST_CMD的錯誤，則可能是Subversion的目錄裡有某個目錄的.svn目錄消失了，由Subversion重新取出後即告正常當您由Projects view裡看到的目錄圖示前顯示了勾選的符號，表示IDE已經和Subversion連接成功了。## 
		]]>
	</description>
	<content:encoded><![CDATA[
			<!--StartFragment --><a href="http://www.netbeans.org/">NetBeans 5.0</a>內建CVS做為程式的版本管理之用，若要使用CVS以外的版本管理系統，則要由NetBeans Update Center裡額外安裝，以下是安裝<a href="http://subversion.tigris.org/">Subversion</a>的步驟：<ol><li>點選【Tools→Update Center】，按【Next】，記得要勾選NetBeans Update Center <span style="FONT-WEIGHT: bold">Beta</span></li><li><span style="FONT-WEIGHT: bold"></span>由要安裝的模組中選<span style="FONT-WEIGHT: bold">Subversion profile for Generic VCS</span>後按【Add】，系統會將Subversion需要用的模組檔案加到右側，按【Next】，選【Accept】後就開始下載。下載完成後按【Next】與【Finish】</li><li>由【Tools→Module manager】確認內建的CVS已被取消掉，而由剛裝的Subversion取代</li><li>由【Versioning→Versioning Manager】選定Subversion的控制目錄，將目錄和Subversion的Repository URL建立正確關聯<br /><br />如果VCS Output頁籤出現<span style="FONT-WEIGHT: bold">LIST_CMD</span>的錯誤，則可能是Subversion的目錄裡有某個目錄的.svn目錄消失了，由Subversion重新取出後即告正常</li></ol>當您由Projects view裡看到的目錄圖示前顯示了勾選的符號，表示IDE已經和Subversion連接成功了。<br />## 
		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/1032965.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1032965.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1032965.html</guid>
	<category>編程生涯</category>
	<pubDate>Sat, 21 Jan 2006 21:13:31 +0800</pubDate>
</item>
<item>
	<title>[NetBeans] 5.0 RC2新推出</title>
	<description><![CDATA[
			在短短的一周裡，NetBeans開發團隊連續推出5.0的RC1與RC2，5.0正式版的推出日期應該日子不遠了。##
		]]>
	</description>
	<content:encoded><![CDATA[
			<p>在短短的一周裡，NetBeans開發團隊連續推出5.0的RC1與<a href="http://www.netbeans.info/downloads/download.php?type=5.0rc2" target="_blank">RC2</a>，5.0正式版的推出日期應該日子不遠了。</p><p>##</p>
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1032905.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1032905.html</guid>
	<category>編程生涯</category>
	<pubDate>Sat, 21 Jan 2006 20:55:50 +0800</pubDate>
</item>
<item>
	<title>微軟推出新版的JDBC Driver</title>
	<description><![CDATA[
			微軟發佈了新版的JDBC Driver(for SQL Server 2000與2005)，可由此處下載。不過，我還是推薦jTDS。##
		]]>
	</description>
	<content:encoded><![CDATA[
			<p>微軟發佈了新版的JDBC Driver(for SQL Server 2000與2005)，可由<a title="MS download" href="http://www.microsoft.com/downloads/details.aspx?familyid=e22bc83b-32ff-4474-a44a-22b6ae2c4e17&displaylang=en" target="_blank">此處下載</a>。不過，我還是推薦<a title="jTDS" href="http://jtds.sf.net" target="_blank">jTDS</a>。</p><p>##</p>
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1031727.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1031727.html</guid>
	<category>編程生涯</category>
	<pubDate>Sat, 21 Jan 2006 14:16:55 +0800</pubDate>
</item>
<item>
	<title>[NetBenas] 遠端除錯</title>
	<description><![CDATA[
			 NetBeans的遠端除錯很容易操作，以下是簡要的執行步驟：以下列參數啟動Resin Server，使之進入遠端除錯模式：-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005由NetBeans的【Run→Attach Debugger...】顯示Attach視窗，指定使用的Port(與步驟1用的Port相同即可)，若有Attach成功則在左下角會出現：User program running文字：在要除錯的程式處設定中斷點執行網頁，當執行到有設定中斷點的程式時，會自動切換至NetBeans該行，接著就可以開始進行除錯了## 
		]]>
	</description>
	<content:encoded><![CDATA[
			<!--StartFragment --> NetBeans的遠端除錯很容易操作，以下是簡要的執行步驟：<br /><ol><li>以下列參數啟動Resin Server，使之進入遠端除錯模式：<br /><table style="WIDTH: 100%; HEIGHT: 52px; BACKGROUND-COLOR: rgb(255,255,153); TEXT-ALIGN: left" cellspacing="2" cellpadding="2" border="1"><tbody><tr><td>-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005</td></tr></tbody></table></li><li>由NetBeans的【Run→Attach Debugger...】顯示Attach視窗，指定使用的Port(與步驟1用的Port相同即可)，若有Attach成功則在左下角會出現：User program running文字：<br /><img style="WIDTH: 100%; HEIGHT: 299px" alt="NetBeans Debugger" src="http://b.blog.xuite.net/b3/ac/11893557/blog_10351/txt/4916761/0.jpg" /><br /></li><li>在要除錯的程式處設定中斷點<br /></li><li>執行網頁，當執行到有設定中斷點的程式時，會自動切換至NetBeans該行，接著就可以開始進行除錯了</li></ol>## 
		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/1030084.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1030084.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1030084.html</guid>
	<category>編程生涯</category>
	<pubDate>Sat, 21 Jan 2006 00:44:05 +0800</pubDate>
</item>
<item>
	<title>[NetBeans] 在IDE裡執行資料庫連線與查詢</title>
	<description><![CDATA[
			NetBeans 5.0 RC1剛剛推出，決定再給它一次機會。今天測試了內建的資料庫存取功能。首先必須在Runtime視窗中找到Databases節點。在Databases節點裡的Driver按右鈕選Add Driver，加入新的JDBC Driver，並輸入需要的連線字串。在建立好的連線上按右鈕選 Execute Command...，則在編輯區會開啟一個新的頁籤，供輸入SQL敘述並顯示查詢結果。## 
		]]>
	</description>
	<content:encoded><![CDATA[
			<!--StartFragment --><a href="http://www.netbeans.org/">NetBeans 5.0 RC1</a>剛剛推出，決定再給它一次機會。今天測試了內建的資料庫存取功能。<br /><br /><ol><li>首先必須在<span style="FONT-WEIGHT: bold">Runtime</span>視窗中找到<span style="FONT-WEIGHT: bold">Databases</span>節點。</li><li>在Databases節點裡的<span style="FONT-WEIGHT: bold">Driver</span>按右鈕選Add Driver，加入新的JDBC Driver，並輸入需要的連線字串。<br /><img style="WIDTH: 100%; HEIGHT: 407px" alt="NetBeans Databases-1" src="http://b.blog.xuite.net/b3/ac/11893557/blog_10351/txt/4887563/0.jpg" /></li><li>在建立好的連線上按右鈕選 <span style="FONT-WEIGHT: bold">Execute Command...</span>，則在編輯區會開啟一個新的頁籤，供輸入SQL敘述並顯示查詢結果。<br /><img style="WIDTH: 100%; HEIGHT: 301px" alt="NetBeans-sql-2" src="http://b.blog.xuite.net/b3/ac/11893557/blog_10351/txt/4887563/1.jpg" /></li></ol>## 
		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/1016099.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/1016099.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/1016099.html</guid>
	<category>編程生涯</category>
	<pubDate>Wed, 18 Jan 2006 00:01:09 +0800</pubDate>
</item>
<item>
	<title>Resin的Profiler機制</title>
	<description><![CDATA[
			由Caucho的Wiki站看到新版的Resin(似乎是3.0.16開始)提供了Profiler的功能，由intrest-maillist裡看到這個功能原先是提供給Caucho的Platinum客戶使用的效能評量機制。雖然Wiki裡寫得算詳細，但類別名在3.0.17裡卻由com.caucho.profiler.ProfilerServlet改成com.caucho.tools.profiler.ProfilerServlet了(下載Source檢視後就清楚了)。掛載Profiler的步驟可直接看Wiki，我把我測試的步驟寫在這裡備忘：在resin.conf的某個要監測的Web應用系統裡加Servlet-mapping，以啟動Profiler機制：      &lt;servlet-mapping servlet-class=&quot;com.caucho.tools.profiler.ProfilerServlet&quot; url-pattern=&quot;/resin-profiler&quot;&gt;        &lt;init&gt;          &lt;profiler enabled=&quot;true&quot;/&gt;        &lt;/init&gt;        &lt;load-on-startup/&gt;      &lt;/servlet-mapping&gt;在resin.conf的某個要監測的Web應用系統裡加上Filter，以蒐集Request資訊：  &lt;filter&gt;        &lt;filter-name&gt;resin-profiler&lt;/filter-name&gt;        &lt;filter-class&gt;com.caucho.tools.profiler.ProfilerFilter&lt;/filter-class&gt;        &lt;init use-query=&quot;false&quot;/&gt;  &lt;/filter&gt;  &lt;filter-mapping filter-name=&quot;resin-profiler&quot; url-pattern=&quot;*&quot;&gt;        &lt;dispatcher&gt;REQUEST&lt;/dispatcher&gt;  &lt;/filter-mapping&gt;然後就開始執行Web系統的一般網頁，執行一段時間後用下列URL檢視Profiling數據：    http://localhost/myWeb/resin-profiler網頁呈現如下：基本上Profiler是把在Server上存取過的資源做了個統計，好讓開發人員分析效能。然而，因為我使用過Wily Technology的Introscope工具，深深覺得：Profiling也是門獨特與專精的學問，Introscope硬是比Resin的PRofiler強上太多了，一分錢一分貨真是至理名言。如果只是要簡單的Profiling功能，這個Resin Profiler應該也能發揮些功效吧。##
		]]>
	</description>
	<content:encoded><![CDATA[
			<!--StartFragment -->由<a href="http://wiki.caucho.com/Profiler" target="_blank">Caucho的Wiki站</a>看到新版的Resin(似乎是3.0.16開始)提供了Profiler的功能，由intrest-maillist裡看到這個功能原先是提供給<a href="http://www.caucho.com/" target="_blank">Caucho</a>的Platinum客戶使用的效能評量機制。雖然Wiki裡寫得算詳細，但類別名在3.0.17裡卻由com.caucho.profiler.ProfilerServlet改成<span style="FONT-WEIGHT: bold">com.caucho.tools.profiler.ProfilerServlet</span>了(下載Source檢視後就清楚了)。<br /><br />掛載Profiler的步驟可直接看Wiki，我把我測試的步驟寫在這裡備忘：<br /><ol><li>在resin.conf的某個要監測的Web應用系統裡加Servlet-mapping，以啟動Profiler機制：<br /><table style="WIDTH: 100%; HEIGHT: 137px; BACKGROUND-COLOR: rgb(255,255,153); TEXT-ALIGN: left" cellspacing="2" cellpadding="2" border="1"><tbody><tr><td>      &lt;servlet-mapping servlet-class=&quot;<span style="FONT-WEIGHT: bold">com.caucho.tools.profiler.ProfilerServlet</span>&quot; url-pattern=&quot;/resin-profiler&quot;&gt;<br />        &lt;init&gt;<br />          &lt;profiler enabled=&quot;true&quot;/&gt;<br />        &lt;/init&gt;<br />        &lt;load-on-startup/&gt;<br />      &lt;/servlet-mapping&gt;<br /></td></tr></tbody></table></li><li>在resin.conf的某個要監測的Web應用系統裡加上Filter，以蒐集Request資訊：<br /><table style="WIDTH: 100%; HEIGHT: 137px; BACKGROUND-COLOR: rgb(255,255,153); TEXT-ALIGN: left" cellspacing="2" cellpadding="2" border="1"><tbody><tr><td>  &lt;filter&gt;<br />        &lt;filter-name&gt;resin-profiler&lt;/filter-name&gt;<br />        &lt;filter-class&gt;<span style="FONT-WEIGHT: bold">com.caucho.tools.profiler.ProfilerFilter</span>&lt;/filter-class&gt;<br />        &lt;init use-query=&quot;false&quot;/&gt;<br />  &lt;/filter&gt;<br />  &lt;filter-mapping filter-name=&quot;resin-profiler&quot; url-pattern=&quot;*&quot;&gt;<br />        &lt;dispatcher&gt;REQUEST&lt;/dispatcher&gt;<br />  &lt;/filter-mapping&gt;<br /><br /></td></tr></tbody></table></li></ol>然後就開始執行Web系統的一般網頁，執行一段時間後用下列URL檢視Profiling數據：<br /><table style="WIDTH: 434px; BACKGROUND-COLOR: rgb(255,255,153); TEXT-ALIGN: left" cellspacing="2" cellpadding="2" border="1"><tbody><tr><td style="WIDTH: 424px"><span style="FONT-WEIGHT: bold">    http://localhost/myWeb/resin-profiler</span></td></tr></tbody></table><br />網頁呈現如下：<br /><br /><img style="WIDTH: 100%; HEIGHT: 555px" alt="resin profiler screenshot" src="http://b.blog.xuite.net/b3/ac/11893557/blog_10351/txt/4808360/0.jpg" /><br /><br /><br />基本上Profiler是把在Server上存取過的資源做了個統計，好讓開發人員分析效能。然而，因為我使用過<a href="http://www.wilytech.com/" target="_blank">Wily Technology</a>的<a href="http://www.emis.tw/SI/Product/Page/Introscope_5.0.htm" target="_blank">Introscope工具</a>，深深覺得：Profiling也是門獨特與專精的學問，Introscope硬是比Resin的PRofiler強上太多了，一分錢一分貨真是至理名言。如果只是要簡單的Profiling功能，這個Resin Profiler應該也能發揮些功效吧。<br /><br />##<br />
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/974085.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/974085.html</guid>
	<category>編程生涯</category>
	<pubDate>Sun, 08 Jan 2006 21:56:53 +0800</pubDate>
</item>
<item>
	<title>Resin Professional 3.0.17的Bug</title>
	<description><![CDATA[
			昨天開始測試Caucho於2005/12/22釋出的Resin 3.0.17 Professional版，很奇怪的有一些網頁只會寫回部份內容，因而造成網頁錯誤。也許是這個版本有Bug吧，於是再去下載最新的2006/01/06 Snap版本，但卻是出現同樣問題。3.0.14 Professional則是一切正常。最後到它的BugTracks才確認是程式的Bug(編號0000805)，依據說明把License檔案拿掉，讓3.0.17啟動成Open-Source版後，原先出現的問題就消失了，由此判斷確實是Professional 的JNI寫檔時造成的問題。Resin的Professional除了需要註冊購買外，在功能上多出了下列幾項：Load balance的支援一年的免費升級以JNI讀寫檔，效率比Open-Source版為高結果重要功能之一就失效了，希望能很快修改完畢。##
		]]>
	</description>
	<content:encoded><![CDATA[
			<p>昨天開始測試<a title="caucho" href="http://www.caucho.com/" target="_blank">Caucho</a>於2005/12/22釋出的<a title="resin download" href="http://www.caucho.com/download/" target="_blank">Resin 3.0.17 Professional版</a>，很奇怪的有一些網頁只會寫回部份內容，因而造成網頁錯誤。也許是這個版本有Bug吧，於是再去下載最新的2006/01/06 Snap版本，但卻是出現同樣問題。3.0.14 Professional則是一切正常。</p><p>最後到它的<a title="BugTrack" href="http://bugs.caucho.com/" target="_blank">BugTracks</a>才確認是程式的Bug(<a title="bug0000805" href="http://bugs.caucho.com/view.php?id=805" target="_blank">編號0000805</a>)，依據說明把License檔案拿掉，讓3.0.17啟動成Open-Source版後，原先出現的問題就消失了，由此判斷確實是Professional 的JNI寫檔時造成的問題。</p><p>Resin的Professional除了需要註冊購買外，在功能上多出了下列幾項：</p><ul><li>Load balance的支援</li><li>一年的免費升級</li><li>以JNI讀寫檔，效率比Open-Source版為高</li></ul><p>結果重要功能之一就失效了，希望能很快修改完畢。</p><p>##</p>
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/973463.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/973463.html</guid>
	<category>編程生涯</category>
	<pubDate>Sun, 08 Jan 2006 19:29:06 +0800</pubDate>
</item>
<item>
	<title>Resin 3.x與JMX的使用測試</title>
	<description><![CDATA[
			 由於Resin 3已經支援JMX(Java Management Extensions)了，但以前並沒有關注過這項議題，今天趁空粗略的測試了一次。JMX是定義成統一的監控與管理JVM的標準，JDK 5.0也已內建(參考：Monitoring and Management for the JavaTM Platform) ，用來監控JMX的兩種模式是：讓Resin進入JMX本地端管理狀態：httpd.exe  -Dcom.sun.management.jmxremote讓Resin進入JMX遠端管理狀態：httpd.exe -Dcom.sun.management.jmxremote.port=9004本地端管理是最簡單的，讓Resin啟動後，用JDK 5.0\bin\jconsole.exe就可以來管理Resin Server，一進入jconsole就可以看到已經啟動好的Resin Server，按Connect即可進入管理畫面。jconsole管理畫面有Summary、Memory、Threads、Classes、MBeans與VM等六個頁籤，透過這六個功能畫面能清楚看到Resin Server的內部狀況，在MBeans並能透過提供的Method來停止或啟動Resin Server或其中的某個Web應用系統。以下便是在jconsole裡可以用start、stop等操作來控制Resin Server裡的某一個Web應用系統，當然整個Resin Server也可透過此種方式控制。遠端的JXM管理則手續複雜得多，我們可以先把認證和SSL的功能關閉，以快速測試：httpd -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9004 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false在jconsole的登入對話窗切換到Remote並輸入主機名稱或IP與Port再按Connect即可連接成功。接著忽略SSL的設定，只利用密碼檔的認證來管理。JMX使用的密碼檔必須只有Owner能存取，因此必須放置在NTFS上，無法放在FAT32上(參考：JConsole: remoting, notifications and log control)。複製密碼檔：cd \JDK1.5\jre\lib\managementcopy jmxremote.password.template jmxremote.password修改密碼檔，加入要登入的使用者帳號與密碼修改權限，讓使用者只剩下啟動Resin Server的使用者，同時用進階將權限只有一名使用者(把從「...父項繼承權...」的勾選拿掉)在同目錄內的jmxremote.access加入新加帳號與其存取權限(readonly或readwrite)若密碼檔權限未設定完整，則啟動Resin時會出現錯誤訊息：    Error: Password file read access must be restricted: C:\JDK1.5\jre\lib\managemet\jmxremote.password除了使用jconsole外，也可以用Open-Source的MC4J Management Console來管理。MC4J console的結果類似jconsole，只是呈現的方式不同而已，由其網站得知此程式是建立在NetBeans之上的應用，因此其操作介面與 NetBeans相當雷同。先下載MX4J(MC4J是建立在MX4J的 Client)，再把MX4J\lib裡的所有jar檔複製到Resin的Lib目錄。啟動Resin Server啟動MC4J Management Console如下列畫面建立連線並登入MC4JMC4J的功能與jconsole類似，操作介面與NetBeans雷同。在MBeans上按右鈕也可以開啟Dashboard視窗(Basic MBean view)。## 
		]]>
	</description>
	<content:encoded><![CDATA[
			<p><!--StartFragment --> 由於<a href="http://www.caucho.com/">Resin 3</a>已經支援JMX(Java Management Extensions)了，但以前並沒有關注過這項議題，今天趁空粗略的測試了一次。<br /><br />JMX是定義成統一的監控與管理JVM的標準，JDK 5.0也已內建(參考：<a href="http://java.sun.com/j2se/1.5.0/docs/guide/management/">Monitoring and Management for the JavaTM Platform) </a>，用來監控JMX的兩種模式是：<br /></p><ul><li>讓Resin進入JMX本地端管理狀態：</li><ul style="FONT-WEIGHT: bold"><li>httpd.exe  -Dcom.sun.management.jmxremote</li></ul><li>讓Resin進入JMX遠端管理狀態：</li><ul style="FONT-WEIGHT: bold"><li>httpd.exe -Dcom.sun.management.jmxremote.port=9004</li></ul></ul><p>本地端管理是最簡單的，讓Resin啟動後，用JDK 5.0\bin\jconsole.exe就可以來管理Resin Server，一進入jconsole就可以看到已經啟動好的Resin Server，按Connect即可進入管理畫面。<br /><br /><img style="WIDTH: 400px; HEIGHT: 300px" alt="jconsole login" src="http://b.blog.xuite.net/b3/ac/11893557/blog_10351/txt/4799028/0.jpg" /><br /><br />jconsole管理畫面有Summary、Memory、Threads、Classes、MBeans與VM等六個頁籤，透過這六個功能畫面能清楚看到Resin Server的內部狀況，在MBeans並能透過提供的Method來停止或啟動Resin Server或其中的某個Web應用系統。<br /><img style="WIDTH: 646px; HEIGHT: 512px" alt="jconsole" src="http://java.sun.com/j2se/1.5.0/docs/guide/management/images/memtab.jpg" /><br /><br />以下便是在jconsole裡可以用start、stop等操作來控制Resin Server裡的某一個Web應用系統，當然整個Resin Server也可透過此種方式控制。<br /><br /><img style="WIDTH: 648px; HEIGHT: 588px" alt="jconsole MBeans" src="http://b.blog.xuite.net/b3/ac/11893557/blog_10351/txt/4799028/6.jpg" /><br /><br />遠端的JXM管理則手續複雜得多，我們可以先把認證和SSL的功能關閉，以快速測試：<br /></p><ul><li><span style="FONT-WEIGHT: bold">httpd -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9004 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false</span></li></ul><p>在jconsole的登入對話窗切換到Remote並輸入主機名稱或IP與Port再按Connect即可連接成功。<br /><br /><img style="WIDTH: 234px; HEIGHT: 217px" alt="jconsole remote login" src="http://java.sun.com/j2se/1.5.0/docs/guide/management/images/connectrem.jpg" /><br /><br />接著忽略SSL的設定，只利用密碼檔的認證來管理。JMX使用的密碼檔必須只有Owner能存取，因此必須放置在NTFS上，無法放在FAT32上(參考：<a href="http://www.builderau.com.au/program/java/soa/JConsole_remoting_notifications_and_log_control/0,39024620,39194480,00.htm"><font class="contentText"><font class="headingTextBigBold">JConsole: remoting, notifications and log control</font></font></a>)。<br /><br /></p><ol><li>複製密碼檔：</li><table style="WIDTH: 598px; BACKGROUND-COLOR: rgb(255,255,153); TEXT-ALIGN: left" cellspacing="2" cellpadding="2" border="1"><tbody><tr><td style="WIDTH: 588px">cd \JDK1.5\jre\lib\management<br />copy jmxremote.password.template jmxremote.password</td></tr></tbody></table><li>修改密碼檔，加入要登入的使用者帳號與密碼</li><li>修改權限，讓使用者只剩下啟動Resin Server的使用者，同時用進階將權限只有一名使用者(把從「...父項繼承權...」的勾選拿掉)</li><li>在同目錄內的jmxremote.access加入新加帳號與其存取權限(readonly或readwrite)</li></ol><p>若密碼檔權限未設定完整，則啟動Resin時會出現錯誤訊息：<br /><br /><span style="FONT-WEIGHT: bold">    Error: Password file read access must be restricted: C:\JDK1.5\jre\lib\managemet\jmxremote.password</span><br style="FONT-WEIGHT: bold" /><br />除了使用jconsole外，也可以用Open-Source的<a href="http://mc4j.org/confluence/display/MC4J/Tomcat">MC4J Management Console</a>來管理。MC4J console的結果類似jconsole，只是呈現的方式不同而已，由其網站得知此程式是建立在NetBeans之上的應用，因此其操作介面與 NetBeans相當雷同。<br /><br /></p><ol><li>先下載<a href="http://mx4j.sourceforge.net/">MX4J(</a>MC4J是建立在MX4J的 Client)，再把MX4J\lib裡的所有jar檔複製到Resin的Lib目錄。</li><li>啟動Resin Server</li><li>啟動MC4J Management Console</li><li>如下列畫面建立連線並登入MC4J</li></ol><p><img style="WIDTH: 617px; HEIGHT: 460px" alt="mc4j connection" src="http://b.blog.xuite.net/b3/ac/11893557/blog_10351/txt/4799028/8.jpg" /><br />MC4J的功能與jconsole類似，操作介面與NetBeans雷同。<br /><br /><img style="WIDTH: 100%; HEIGHT: 586px" alt="MC4J" src="http://b.blog.xuite.net/b3/ac/11893557/blog_10351/txt/4799028/7.jpg" /><br /><br />在MBeans上按右鈕也可以開啟Dashboard視窗(Basic MBean view)。<br /><br /><img style="WIDTH: 100%; HEIGHT: 580px" alt="mc4j MBean view" src="http://b.blog.xuite.net/b3/ac/11893557/blog_10351/txt/4800050/0.jpg" /><br /><br />## </p>
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/970584.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/970584.html</guid>
	<category>編程生涯</category>
	<pubDate>Sat, 07 Jan 2006 23:57:25 +0800</pubDate>
</item>
<item>
	<title>給Ant用的Subversion task</title>
	<description><![CDATA[
			CVS的tasks已內建在Ant系統裡，但Subversion仍必須由外部設定，先找到一個參考網站(SvnAnt)，先記錄下來：http://subclipse.tigris.org/servlets/ProjectDocumentView?documentID=23927&amp;showInfo=true##
		]]>
	</description>
	<content:encoded><![CDATA[
			<p>CVS的tasks已內建在Ant系統裡，但Subversion仍必須由外部設定，先找到一個參考網站(SvnAnt)，先記錄下來：</p><p><a href="http://subclipse.tigris.org/servlets/ProjectDocumentView?documentID=23927&showInfo=true">http://subclipse.tigris.org/servlets/ProjectDocumentView?documentID=23927&amp;showInfo=true</a></p><p>##</p>
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/916887.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/916887.html</guid>
	<category>編程生涯</category>
	<pubDate>Mon, 26 Dec 2005 23:46:40 +0800</pubDate>
</item>
<item>
	<title>[iReport] 奇偶列變換底色</title>
	<description><![CDATA[
			報表的奇數列與偶數列以不同的背景色彩呈現是常見的報表格式，今天研究了iReport的解決方法。在同一列上放相同欄位的TextField，一個不設背景（預設為白色），另一個設背景（淡黃色）白色背景的Print when expression輸入new Boolean((($V{PAGE_COUNT}.intValue()) % 2)==0)淡黃色背景的Print when expression輸入new Boolean((($V{PAGE_COUNT}.intValue()) % 2)==1)另一個方法是由JasperReports論壇中查到的：先在Detail Band上拉一個矩形，設其背景為淡黃色，設其Print when expression為new Boolean((($V{PAGE_COUNT}.intValue()) % 2)==1)，意即奇數列時才要印出這個淡黃底色的矩形。再設其前景為白色，使矩形邊界的黑框消失在矩形上放需要的Text Field，並將其Transparent打勾，意即此Text field是透明的不知是否有更簡便的方法？## 
		]]>
	</description>
	<content:encoded><![CDATA[
			<img style="WIDTH: 403px; HEIGHT: 338px" alt="iReport alternative background" hspace="0" src="http://mms.blog.xuite.net/b3/ac/11893557/blog_10351/txt/4497387/0.jpg" border="0" />報表的奇數列與偶數列以不同的背景色彩呈現是常見的報表格式，今天研究了iReport的解決方法。<br /><ul><li>在同一列上放相同欄位的TextField，一個不設背景（預設為白色），另一個設背景（淡黃色）<ul><li>白色背景的Print when expression輸入new Boolean((($V{PAGE_COUNT}.intValue()) % 2)==0)</li><li>淡黃色背景的Print when expression輸入new Boolean((($V{PAGE_COUNT}.intValue()) % 2)==1)</li></ul></li><li>另一個方法是由JasperReports論壇中查到的：<ul><li>先在Detail Band上拉一個矩形，設其背景為淡黃色，設其Print when expression為new Boolean((($V{PAGE_COUNT}.intValue()) % 2)==1)，意即奇數列時才要印出這個淡黃底色的矩形。再設其前景為白色，使矩形邊界的黑框消失</li></ul><ul><li>在矩形上放需要的Text Field，並將其Transparent打勾，意即此Text field是透明的</li></ul></li></ul>不知是否有更簡便的方法？<br /><br />## 
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/798509.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/798509.html</guid>
	<category>編程生涯</category>
	<pubDate>Tue, 29 Nov 2005 23:25:05 +0800</pubDate>
</item>
<item>
	<title>解決 iReport 升級後的問題</title>
	<description><![CDATA[
			將iReport升級由0.4.1升級到0.5.2後，陸續發生些狀況：原來執行正確的報表卻發生Error loading object from file的問題：查了半天才發現當iReport的相關JAR檔更新成新版後，舊版編譯好的.jasper檔案必須用新版的重新編譯才能正確執行 叫用JasperCompileManager.compileReportToFile()來編譯.jrxml時總是發生Language &quot;null&quot; not supported by this report compiler.錯誤；而這在0.4.1卻是能正常運行的。試了許久最後還是只能重新編譯它的原始檔，再用Debugger追蹤，最後只好改變寫法，直接把&quot;java&quot;指定為報表語言，這樣才能正確執行。以JasperReports 1.1.0為基礎的iReport 0.5.2除了能使用Java語法外，同時也接受Groovy與BeanShell為其表示語言，因此必須指定要使用那個語言。但文件中若未設定則預設使用Java，但編譯用的類別似乎不會把未設定的&quot;null&quot;自動轉成&quot;java&quot;，因此造成了上述的問題。##
		]]>
	</description>
	<content:encoded><![CDATA[
			<p>將<a href="http://blog.xuite.net/_manager/ireport.sf.net" target="_blank">iReport</a>升級由0.4.1升級到0.5.2後，陸續發生些狀況：</p><ul><li>原來執行正確的報表卻發生<em>Error loading object from file</em>的問題：查了半天才發現當iReport的相關JAR檔更新成新版後，舊版編譯好的.jasper檔案必須用新版的重新編譯才能正確執行 </li><li>叫用JasperCompileManager.compileReportToFile()來編譯.jrxml時總是發生<em>Language &quot;null&quot; not supported by this report compiler.</em>錯誤；而這在0.4.1卻是能正常運行的。試了許久最後還是只能重新編譯它的原始檔，再用Debugger追蹤，最後只好改變寫法，直接把&quot;java&quot;指定為報表語言，這樣才能正確執行。</li></ul><p>以<a href="http://blog.xuite.net/_manager/jasperreports.sf.net" target="_blank">JasperReports 1.1.0</a>為基礎的iReport 0.5.2除了能使用Java語法外，同時也接受Groovy與BeanShell為其表示語言，因此必須指定要使用那個語言。但文件中若未設定則預設使用Java，但編譯用的類別似乎不會把未設定的<em>&quot;null&quot;</em>自動轉成<em>&quot;java&quot;</em>，因此造成了上述的問題。</p><p>##</p>
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/767461.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/767461.html</guid>
	<category>編程生涯</category>
	<pubDate>Tue, 22 Nov 2005 22:48:01 +0800</pubDate>
</item>
<item>
	<title>試用iReport 0.5.2</title>
	<description><![CDATA[
			試了剛於11月2日釋出的iReport 0.5.2，介面做了頗多加強，也看到了Jasper Soft的名稱，感覺是越來越專業了。這次改版除了配合JasperReports 1.1.0外，主要修正了一些Bug。但是用Big5編碼的JRXML檔案，在第一次載入時可以正常操作，但儲存後會變成UTF-8，對檔案的讀寫造一些困擾。這個小暇疵不知何時能修正。##
		]]>
	</description>
	<content:encoded><![CDATA[
			<!--StartFragment -->試了剛於11月2日釋出的<a href="file:///D:/DOC/blog/ireport.sf.net">iReport 0.5.2</a>，介面做了頗多加強，也看到了Jasper Soft的名稱，感覺是越來越專業了。<br />這次改版除了配合<a href="http://jasperreports.sourceforge.net/">JasperReports 1.1.0</a>外，主要修正了一些Bug。但是用Big5編碼的JRXML檔案，在第一次載入時可以正常操作，但儲存後會變成UTF-8，對檔案的讀寫造一些困擾。這個小暇疵不知何時能修正。<br /><br /><img style="WIDTH: 170px; HEIGHT: 130px" alt="ireport" src="http://ireport.sourceforge.net/images/ireport52logo.jpg" /><br />##
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/735359.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/735359.html</guid>
	<category>編程生涯</category>
	<pubDate>Tue, 15 Nov 2005 23:28:30 +0800</pubDate>
</item>
<item>
	<title>IE擴充工具列：IE Developer Toolbar</title>
	<description><![CDATA[
			微軟推出了類似FireFox Web Developer擴充的工具：Internet Explorer Developer Toolbar，方便網頁設計與開發人員調整與除錯之用。此工具列有下列幾項功能：View DOM Disable View Outline Validate Image Resize Misc Show Ruler試用了一下，還挺齊全的。##
		]]>
	</description>
	<content:encoded><![CDATA[
			<p>微軟推出了類似FireFox Web Developer擴充的工具：<a href="http://www.microsoft.com/downloads/details.aspx?familyid=e59c3964-672d-4511-bb3e-2d5e1db91038&displaylang=en">Internet Explorer Developer Toolbar</a>，方便網頁設計與開發人員調整與除錯之用。</p><p>此工具列有下列幾項功能：</p><ul><li>View DOM </li><li>Disable </li><li>View </li><li>Outline </li><li>Validate </li><li>Image </li><li>Resize </li><li>Misc </li><li>Show Ruler</li></ul><p>試用了一下，還挺齊全的。</p><p>##</p>
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/493172.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/493172.html</guid>
	<category>編程生涯</category>
	<pubDate>Sat, 17 Sep 2005 12:35:43 +0800</pubDate>
</item>
<item>
	<title>[Java] JavaLobby發生狀況</title>
	<description><![CDATA[
			難得看到JavaLobby發生狀況，留圖做為記錄。原來JavaLobby是使用Resin 
3.0.11。


		]]>
	</description>
	<content:encoded><![CDATA[
			<p>難得看到<a href="http://www.javalobby.org/">JavaLobby</a>發生狀況，留圖做為記錄。原來JavaLobby是使用Resin 
3.0.11。</p>
<p><img src="http://blog.xuite.net/_users/b3/ac/11893557/blog_10351/txt/3749292/3749292_6.jpg" /></p>

		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/379959.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/379959.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/379959.html</guid>
	<category>編程生涯</category>
	<pubDate>Tue, 16 Aug 2005 21:59:47 +0800</pubDate>
</item>
<item>
	<title>[Java] IDEA 5.0觀看JSP檔案的不同View</title>
	<description><![CDATA[
			 IDEA 5.0的Structure工具有了大突破：除了一直都有的Java結構之外，XML、JSP、HTML等檔案格式都能顯示了，這些不同的View對於快速了解一個檔案的大綱、架構，和迅速移動到某個段落(快速瀏覽)，都帶來令人振奮的改進。以下是以JSP為觀點顯示出來的JSP View，顯示JSP檔案中所有的JSP元素。再來是HTML View，對於快速找到某段要修改的JavaScript很有幫助：最後是JSP檔案產生出的Java檔案的Java View：## 
		]]>
	</description>
	<content:encoded><![CDATA[
			<!--StartFragment --> IDEA 5.0的<span style="FONT-WEIGHT: bold">Structure</span>工具有了大突破：除了一直都有的Java結構之外，XML、JSP、HTML等檔案格式都能顯示了，這些不同的View對於快速了解一個檔案的大綱、架構，和迅速移動到某個段落(快速瀏覽)，都帶來令人振奮的改進。<br /><br />以下是以JSP為觀點顯示出來的<span style="FONT-WEIGHT: bold; TEXT-DECORATION: underline">JSP View</span>，顯示JSP檔案中所有的JSP元素。<br /><br /><img style="WIDTH: 480px; HEIGHT: 354px" alt="idea50-1" src="http://blog.xuite.net/_users/b3/ac/11893557/blog_10351/txt/3678418/3678418_8.jpg" /><br /><br />再來是<span style="FONT-WEIGHT: bold; TEXT-DECORATION: underline">HTML View</span>，對於快速找到某段要修改的JavaScript很有幫助：<br /><br /><img style="WIDTH: 483px; HEIGHT: 433px" alt="idea5-2" src="http://blog.xuite.net/_users/b3/ac/11893557/blog_10351/txt/3678418/3678418_9.jpg" /><br /><br />最後是JSP檔案產生出的Java檔案的<span style="FONT-WEIGHT: bold; TEXT-DECORATION: underline">Java View</span>：<br /><br /><img style="WIDTH: 484px; HEIGHT: 590px" alt="idea5-3" src="http://blog.xuite.net/_users/b3/ac/11893557/blog_10351/txt/3678418/3678418_10.jpg" /><br /><br />## 
		
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/340021.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/340021.html</guid>
	<category>編程生涯</category>
	<pubDate>Fri, 05 Aug 2005 01:05:26 +0800</pubDate>
</item>
<item>
	<title>[Java] IDEA 5.0正式釋出</title>
	<description><![CDATA[
			
剛剛由
The ServerSide得知IDEA 5.0已經正式發行了。馬上下載回來試看看。據說新版本對於JSP 2.0、HTML等的支援比4.5強很多。安裝時選擇由上一版本匯入設定，進入後就很順利的開啟在4.5設定的專案。感覺比EAP的版本順利且穩定許多。##
		]]>
	</description>
	<content:encoded><![CDATA[
			
剛剛由
<a href="http://www.theserverside.com">The ServerSide</a>得知<a href="http://www.jetbrains.com">IDEA 5.0</a>已經正式發行了。<br /><br />馬上下載回來試看看。據說新版本對於JSP 2.0、HTML等的支援比4.5強很多。<br /><br />安裝時選擇由上一版本匯入設定，進入後就很順利的開啟在4.5設定的專案。感覺比EAP的版本順利且穩定許多。<br /><br />##<br />
		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/332479.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/332479.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/332479.html</guid>
	<category>編程生涯</category>
	<pubDate>Tue, 02 Aug 2005 22:55:46 +0800</pubDate>
</item>
<item>
	<title>[Java] JasperReports終於成為1.0版了</title>
	<description><![CDATA[
			 JasperReports終於堂堂邁入1.0.0版了，接著就等iReport的新版。在名稱上二者有一個小差異：JasperReports 
(Report有s)、iReport (沒有s)。##

		]]>
	</description>
	<content:encoded><![CDATA[
			 <a href="http://jasperreports.sf.net/">JasperReports</a>終於堂堂邁入1.0.0版了，接著就等iReport的新版。<br /><br />在名稱上二者有一個小差異：JasperReports 
(Report有s)、iReport (沒有s)。<br /><br />##<br /><br />

		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/292288.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/292288.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/292288.html</guid>
	<category>編程生涯</category>
	<pubDate>Thu, 21 Jul 2005 20:34:23 +0800</pubDate>
</item>
<item>
	<title>持續更新的電子書：Spring Live</title>
	<description><![CDATA[
			
昨天收到來自http://www.sourcebeat.com的信件，通知我再去下載它的Spring Live一書的2005年7月更新版。這算是一種新型態的電子書經營方式吧。上周在其網站上購買並下載了5月版的Spring Live電子書，費用是US$29.95，更新期限是一年，較之實體的書本34.95元便宜了一些，不過好處是：電子書會持續更新，因此在這一年就能跟隨Spring Framework的演進而能獲得較新穎的資訊。在其Titles網頁列出了許多接著要出版的書籍，也有一些樣章可供下載，建議Java的技術人員逛逛。SourceBeat的書籍清單：JOnAS LiveApache Axis LiveEclipse LiveJakarta Struts LiveSpring LiveDesktop Java LivePlone LiveHibernate3 LiveGeronimo LiveWebWork LiveCastor LiveTapestry LiveJBosss Live

		]]>
	</description>
	<content:encoded><![CDATA[
			
昨天收到來自<a href="http://www.sourcebeat.com/">http://www.sourcebeat.com</a>的信件，通知我再去下載它的Spring Live一書的2005年7月更新版。<br /><br />這算是一種新型態的電子書經營方式吧。上周在其網站上購買並下載了5月版的Spring Live電子書，費用是US$29.95，更新期限是一年，較之實體的書本34.95元便宜了一些，不過好處是：電子書會持續更新，因此在這一年就能跟隨<a href="http://www.springframework.org/">Spring Framework</a>的演進而能獲得較新穎的資訊。<br /><br />在其<a href="http://www.sourcebeat.com/TitlesAction.do">Titles</a>網頁列出了許多接著要出版的書籍，也有一些樣章可供下載，建議Java的技術人員逛逛。<br /><br />SourceBeat的書籍清單：<br /><ol><li>JOnAS Live</li><li>Apache Axis Live</li><li>Eclipse Live</li><li>Jakarta Struts Live</li><li>Spring Live</li><li>Desktop Java Live</li><li>Plone Live</li><li>Hibernate3 Live</li><li>Geronimo Live</li><li>WebWork Live</li><li>Castor Live</li><li>Tapestry Live</li><li>JBosss Live<br /></li></ol><br />

		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/264831.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/264831.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/264831.html</guid>
	<category>編程生涯</category>
	<pubDate>Wed, 13 Jul 2005 09:14:08 +0800</pubDate>
</item>
<item>
	<title>loginfo.rb：自動寄送修改記錄信件</title>
	<description><![CDATA[
			
在CVS主機的Repository內有一個特殊的CVS控制目錄：CVSROOT，此目錄內存放著許多控制CVS操作行為的小檔案，或許可以簡化的稱為
CVS的Event
handler，例如：loginfo是
在commit、輸入Log message後會讀取的檔案。



loginfo內除了註解（井號開頭）外的每一列都會被CVS程式讀取，依開頭的樣式來決定此次commit的檔案是否要執行其後的命令。例如：







#
井號開頭是註解行
模組樣式    命令  [參數1 [參數2 [...參數n]...]]






模組樣式是使用正規運用式(Regular Expression)來示符合要執行的是那些模組，例如：







^inetpub

表
示以inetpub開頭的模組（目錄）


ALL
表示所有模組都符
合


DEFAULT
由可執行的第一列
開始都不符合的，最後會執行DEFAULT列的指令






模組樣式後面接的是要執行的命令。有一個相當好用的指令是Rob
Partington寫的loginfo.rb，一支用來產生mail的Ruby程式，將修改人、修改時間、修改程式等訊息寄給需要通知的相關人等。loginfo.rb的使用說明如下：


  
    
      # Usage: loginfo.rb CVSROOT USER 'CVS-LOG-STRING' MAIL_ADDRESSES
#     [-d HELO_DOMAIN] [-s SMTP_SERVER] [-p SUBJECT_PREFIX]
#     [-S SENDER_ADDRESS] [-R REPLY_TO_ADDRESS] [-x X_HEADER_PREFIX]
#     [-w CVSWEB_URL] [-C PATH_TO_CVS] [-qJ]
#
# -d    specify the domain to use in the SMTP session and in the mail header
#     (default: FQDN of the host)
# -s    specify the SMTP server to mail via
#     (default: &quot;localhost&quot;)
# -S    specify the sender address for the mail
#     (default: USER + &quot;@&quot; + HELO_DOMAIN)
# -R    specify the reply-to address for the mail
#     (default: none)
# -p    specify the prefix for the mail subject (which will be surrounded
#     by `[' and `]')
#     (default: &quot;cvs&quot;)
# -q    be quiet
# -x    specify the prefix for the CVS informative headers
#     (default: &quot;X-&quot;)
# -w    specify the URL of the CVSweb with two @'s, one for a path, and
#     the other for a query (e.g. &quot;'http://a.b/cvsweb.cgi@?cvsroot=xyz&amp;@'&quot;)
#     (default: none - no CVSweb links will be added)
# -C    specify the full path to cvs
#     (default: &quot;/usr/bin/cvs&quot;)
# -J    enable Japanese support (send mail in the JIS encoding)
#     (default: disabled)
    
  



使用範例：

  
    
      # 把inetpub與其子目錄內檔案的commit都寄通知給紅色字體的電子郵件帳號
# %s 是輸入的log message
^inetpub $CVSROOT/CVSROOT/loginfo.rb $CVSROOT $USER %s adam@hotmail.com,bill@gmail.com,cathy@pchome.com.tw -s mail.box.com.tw -S cvs_logingo@mail.box.com.tw
    
  


要使用loginfo.rb當然要安裝Ruby環境；另外，以上指令都是在Linux上執行的，Windows環境需要做些小修改。在Windows中有
一個叫做CVSMailer的Delphi程式，也可以用來寄送修改記錄，但我幾年前測試時始終無法正常運行，您也可以試看看。

如果想要對程式版本間的修改做更詳細的記錄與追蹤的話，可以自行撰寫程式，將修改程式、Log訊息等寫入資料庫，則日後就能使用SELECT敘述做查詢了。


		]]>
	</description>
	<content:encoded><![CDATA[
			
在CVS主機的Repository內有一個特殊的CVS控制目錄：CVSROOT，此目錄內存放著許多控制CVS操作行為的小檔案，或許可以簡化的稱為
CVS的<span style="font-weight: bold;">Event
handler</span>，例如：<span style="font-weight: bold;">loginfo</span>是
在commit、輸入Log message後會讀取的檔案。<br />

<br />

loginfo內除了註解（井號開頭）外的每一列都會被CVS程式讀取，依開頭的樣式來決定此次commit的檔案是否要執行其後的命令。例如：<br />

<br />

<table cellspacing="1" cellpadding="2" border="0" style="text-align: left; background-color: rgb(0, 102, 0); width: 100%;">

<tbody>
<tr>
<td style="background-color: rgb(255, 255, 204);">#
井號開頭是註解行<br />
模組樣式    命令  [參數1 [參數2 [...參數n]...]]</td>
</tr>
</tbody>
</table>

<br />

模組樣式是使用正規運用式(Regular Expression)來示符合要執行的是那些模組，例如：<br />

<br />

<table cellspacing="1" cellpadding="2" border="0" style="text-align: left; background-color: rgb(0, 102, 0); width: 100%;">

<tbody>
<tr>
<td style="background-color: rgb(255, 255, 204); width: 288px;">^inetpub<br />
</td>
<td style="width: 662px; background-color: rgb(255, 255, 204);">表
示以inetpub開頭的模組（目錄）</td>
</tr>
<tr>
<td style="background-color: rgb(204, 255, 255);">ALL</td>
<td style="background-color: rgb(204, 255, 255);">表示所有模組都符
合</td>
</tr>
<tr>
<td style="background-color: rgb(255, 255, 204);">DEFAULT</td>
<td style="background-color: rgb(255, 255, 204);">由可執行的第一列
開始都不符合的，最後會執行DEFAULT列的指令</td>
</tr>
</tbody>
</table>

<br />

模組樣式後面接的是要執行的命令。有一個相當好用的指令是<a href="http://frottage.org/rjp/ruby/loginfo.html">Rob
Partington寫的loginfo.rb</a>，一支用來產生mail的Ruby程式，將修改人、修改時間、修改程式等訊息寄給需要通知的相關人等。loginfo.rb的使用說明如下：<br />
<br />
<table cellspacing="1" cellpadding="2" border="0" style="text-align: left; background-color: rgb(0, 102, 0); width: 100%;">
  <tbody>
    <tr>
      <td style="background-color: rgb(255, 255, 204);"># Usage: loginfo.rb CVSROOT USER 'CVS-LOG-STRING' MAIL_ADDRESSES<br />
#     [-d HELO_DOMAIN] [-s SMTP_SERVER] [-p SUBJECT_PREFIX]<br />
#     [-S SENDER_ADDRESS] [-R REPLY_TO_ADDRESS] [-x X_HEADER_PREFIX]<br />
#     [-w CVSWEB_URL] [-C PATH_TO_CVS] [-qJ]<br />
#<br />
# -d    specify the domain to use in the SMTP session and in the mail header<br />
#     (default: FQDN of the host)<br />
# -s    specify the SMTP server to mail via<br />
#     (default: &quot;localhost&quot;)<br />
# -S    specify the sender address for the mail<br />
#     (default: USER + &quot;@&quot; + HELO_DOMAIN)<br />
# -R    specify the reply-to address for the mail<br />
#     (default: none)<br />
# -p    specify the prefix for the mail subject (which will be surrounded<br />
#     by `[' and `]')<br />
#     (default: &quot;cvs&quot;)<br />
# -q    be quiet<br />
# -x    specify the prefix for the CVS informative headers<br />
#     (default: &quot;X-&quot;)<br />
# -w    specify the URL of the CVSweb with two @'s, one for a path, and<br />
#     the other for a query (e.g. &quot;'http://a.b/cvsweb.cgi@?cvsroot=xyz&amp;@'&quot;)<br />
#     (default: none - no CVSweb links will be added)<br />
# -C    specify the full path to cvs<br />
#     (default: &quot;/usr/bin/cvs&quot;)<br />
# -J    enable Japanese support (send mail in the JIS encoding)<br />
#     (default: disabled)</td>
    </tr>
  </tbody>
</table>
<br />

使用範例：<br />
<table cellspacing="1" cellpadding="2" border="0" style="text-align: left; background-color: rgb(0, 102, 0); width: 100%;">
  <tbody>
    <tr>
      <td style="background-color: rgb(255, 255, 204);"># 把inetpub與其子目錄內檔案的commit都寄通知給紅色字體的電子郵件帳號<br />
# %s 是輸入的log message<br />
^inetpub $CVSROOT/CVSROOT/loginfo.rb $CVSROOT $USER %s<span style="font-weight: bold; color: rgb(255, 0, 0);"> adam@hotmail.com,bill@gmail.com,cathy@pchome.com.tw</span> -s mail.box.com.tw -S cvs_logingo@mail.box.com.tw</td>
    </tr>
  </tbody>
</table>
<br />
要使用loginfo.rb當然要安裝Ruby環境；另外，以上指令都是在Linux上執行的，Windows環境需要做些小修改。在Windows中有
一個叫做CVSMailer的Delphi程式，也可以用來寄送修改記錄，但我幾年前測試時始終無法正常運行，您也可以試看看。<br />
<br />
如果想要對程式版本間的修改做更詳細的記錄與追蹤的話，可以自行撰寫程式，將修改程式、Log訊息等寫入資料庫，則日後就能使用SELECT敘述做查詢了。<br />
<br />

		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/206411.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/206411.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/206411.html</guid>
	<category>編程生涯</category>
	<pubDate>Tue, 21 Jun 2005 00:46:26 +0800</pubDate>
</item>
<item>
	<title>JavaScript與JSR-223</title>
	<description><![CDATA[
			
我在iReport 0.5更新與Groovy提到了Groovy進入JSR，後來BeanScript也進了JSR-274，昨天在JavaLobby看到了一篇報導：
Multi-Languange Java Platform Becomes a Reality，文中說明JSR-223使用來自Mozilla.org的Rhino有了更新版。
看來Java裡的Scripting語言比我知道的還多得很多。報導中正反意見不一，有人贊成將JavaScript加入Java的JRE，也有人強力反對，總之，屆時使用者依需求自行決定要使用那種語言即可。

剛巧今天SlashDot有篇JavaScript發明人Brendan Eich在其Blog中發言的文章：JavaScript Inventor Speaks Out，有興趣請自行參考。
		]]>
	</description>
	<content:encoded><![CDATA[
			
我在<a href="http://blog.xuite.net/emisjerry/tech/273239">iReport 0.5更新與Groovy</a>提到了Groovy進入JSR，後來BeanScript也進了JSR-274，昨天在<a href="http://www.javalobby.org/">JavaLobby</a>看到了一篇報導：
<a href="http://www.javalobby.org/java/forums/t19072.html">Multi-Languange Java Platform Becomes a Reality</a>，文中說明JSR-223使用來自Mozilla.org的Rhino有了更新版。<br /><br />
看來Java裡的Scripting語言比我知道的還多得很多。報導中正反意見不一，有人贊成將JavaScript加入Java的JRE，也有人強力反對，總之，屆時使用者依需求自行決定要使用那種語言即可。<br /><br />

剛巧今天<a href="http://slashdot.org/">SlashDot</a>有篇JavaScript發明人Brendan Eich在其Blog中發言的文章：<a href="http://slashdot.org/article.pl?sid=05/06/15/2243224&from=rss">JavaScript Inventor Speaks Out</a>，有興趣請自行參考。<br /><br />
		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/196173.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/196173.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/196173.html</guid>
	<category>編程生涯</category>
	<pubDate>Thu, 16 Jun 2005 19:06:53 +0800</pubDate>
</item>
<item>
	<title>[iReport] 列印名條標籤</title>
	<description><![CDATA[
			上周五試著用iReport來產生名條標籤，但遇到重重意料外的困難。原本認為因為iReport能控制到Pixels，應該很容易對位，輸出會相當準確。由同事處得知有孔報表紙的一個孔為50 Pixels，要列印的報表一頁有6個名條，一個名條佔2個孔，亦即100 Pixels，因此報表頁高600 Pixels。依此規格製作iReport，列印後卻發現字體變大，整個頁面都變長了。仔細檢查設定後，初步結論是與印表機的解析度有關係。由於名條用粘貼式的標籤報表，因此必須用點矩陣印表機列印，而其解析度是180 DPIX180 DPI，與雷射印表機的300X300或600X600不同。看來似乎還必須將DPI (Dot Per Inch)的因素考量進去，再做換算才能準確。想的和實際做的結果確實有很大距離。目前尚未簡單的解決方法。

		]]>
	</description>
	<content:encoded><![CDATA[
			上周五試著用iReport來產生名條標籤，但遇到重重意料外的困難。<br /><br />原本認為因為iReport能控制到Pixels，應該很容易對位，輸出會相當準確。由同事處得知有孔報表紙的一個孔為50 Pixels，要列印的報表一頁有6個名條，一個名條佔2個孔，亦即100 Pixels，因此報表頁高600 Pixels。依此規格製作iReport，列印後卻發現字體變大，整個頁面都變長了。<br /><br />仔細檢查設定後，初步結論是與印表機的解析度有關係。由於名條用粘貼式的標籤報表，因此必須用點矩陣印表機列印，而其解析度是180 DPIX180 DPI，與雷射印表機的300X300或600X600不同。看來似乎還必須將DPI (Dot Per Inch)的因素考量進去，再做換算才能準確。<br /><br />想的和實際做的結果確實有很大距離。目前尚未簡單的解決方法。<br /><br />

		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/188788.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/188788.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/188788.html</guid>
	<category>編程生涯</category>
	<pubDate>Mon, 13 Jun 2005 23:47:39 +0800</pubDate>
</item>
<item>
	<title>語系/地區碼 zh-TW與zh-CN 中的zh代表什麼?</title>
	<description><![CDATA[
			
在Java中用來表示國家與地區或語系的代碼，英文有：en-US, en-UK等，分別表示美國與聯合王國(United Kingdom, 英國)。開頭的en是English的縮寫。 而用來代表中國(簡體中文)與台灣(正體中文)的是zh-CN與zh-TW，CN是China，TW是Taiwan，而這開頭的「zh」又是什麼意思呢？原來zh是ZhongHua(中華)的音譯。終於搞清楚了（後知後覺．．．）。2005/06/07 23:00 補記：根據網友提供的資料資訊，追查到FreeBSD Chinese HOWTO, locale的設定，再查到1998年公布的ISO 639，原來語言碼在639-2與639-1中有三碼與兩碼二種，華語三碼是&quot;chi&quot;或&quot;zho&quot;，兩碼是&quot;zh&quot;，看來&quot;zh&quot;是&quot;zho&quot;的前二字，但找不到明確說明zho是ZhongWen(中文)或ZhongHua(中華)，但由定義「語言」的編碼來推測，ZhongWen的可能性較高。
		]]>
	</description>
	<content:encoded><![CDATA[
			
<font color="#333333">在Java中用來表示國家與地區或語系的代碼，英文有：en-US, en-UK等，分別表示美國與聯合王國(United Kingdom, 英國)。開頭的en是English的縮寫。 </font><p /><p>而用來代表中國(簡體中文)與台灣(正體中文)的是<strong>zh-CN</strong>與<strong>zh-TW</strong>，CN是China，TW是Taiwan，而這開頭的<strong>「zh」</strong>又是什麼意思呢？</p><p /><p>原來zh是<strong>ZhongHua(中華)</strong>的音譯。</p><p>終於搞清楚了（後知後覺．．．）。<br /></p><p><span style="font-weight: bold;">2005/06/07 23:00 補記：</span><br /><span style="color: rgb(255, 0, 0);">根據網友提供的資料資訊，追查到</span><a style="color: rgb(255, 0, 0);" href="http://netlab.cse.yzu.edu.tw/~statue/freebsd/zh-tut/locale.html">FreeBSD Chinese HOWTO, locale的設定</a><span style="color: rgb(255, 0, 0);">，再查到1998年公布的ISO 639，原來語言碼在639-2與639-1中有三碼與兩碼二種，華語三碼是&quot;chi&quot;或&quot;zho&quot;，兩碼是&quot;zh&quot;，看來&quot;zh&quot;是&quot;zho&quot;的前二字，但找不到明確說明zho是ZhongWen(中文)或ZhongHua(中華)，但由定義「語言」的編碼來推測，ZhongWen的可能性較高。</span><br /></p>
		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/173308.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/173308.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/173308.html</guid>
	<category>編程生涯</category>
	<pubDate>Tue, 07 Jun 2005 13:27:16 +0800</pubDate>
</item>
<item>
	<title>IDEA的編輯web.xml的圖形介面</title>
	<description><![CDATA[
			
在試用NetBeans 4.1時，對它修改web.xml的圖形介面印象深刻，覺得這點倒是比IDEA強的新特點。沒想到今天在查Tag Library出現誤訊息的問題時意外發現：原來IDEA 4.5也有修改web.xml的圖形介面！ 這個操作不是在Settings裡設定，而是在Project  panel的J2EE頁籤上，在Web Modules的某個Web module上按右鈕，再按Edit便會顯示出編修web.xml的圖形介面。

		]]>
	</description>
	<content:encoded><![CDATA[
			
在試用NetBeans 4.1時，對它修改web.xml的圖形介面印象深刻，覺得這點倒是比IDEA強的新特點。沒想到今天在查Tag Library出現誤訊息的問題時意外發現：原來IDEA 4.5也有修改web.xml的圖形介面！<br /><br /> 這個操作不是在Settings裡設定，而是在Project  panel的J2EE頁籤上，在Web Modules的某個Web module上按右鈕，再按Edit便會顯示出編修web.xml的圖形介面。<br /><br /><img src="http://blog.xuite.net/_users/b3/ac/11893557/blog_2175/txt/335709/335709_0.jpg" />

		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/172949.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/172949.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/172949.html</guid>
	<category>編程生涯</category>
	<pubDate>Tue, 07 Jun 2005 09:11:25 +0800</pubDate>
</item>
<item>
	<title>[Java] 常用的IDEA Plugins</title>
	<description><![CDATA[
			除了在《滑鼠手勢症候群！方便的IDEA Mouse Gestures》這篇裡介紹的IDEA 4.5插件(Plugin)：IdeaMouseGestures 之外，我還使用了下列幾個別的插件：
CVS Bar
IDEA 4.5支援了強大的CVS功能，約有10多個命令選項，為了執行某個特定命令就必須拉出很長的功能表，在操作上不甚方便。CVS Bar能夠在IDEA標準的工具列上增加常用的CVS命令按鈕，這樣就可以只按一個按鈕就順利執行Edit或Commit了。
    
這個插件節省太多打開功能表的時間了，強力建議一定要安裝。下圖從右往左分別是：CVS
Diff、Checkout、Update、Commit、Unedit、Edit、Show history，再來是被Disable的Undo
Add、Add與左邊的黃色小魚圖示CVS Setup。
    
  TabOrder
為了讓IDEA一次可以同時編輯多支程式，我們會由Settings→IDE Settings→Editor→Limits將Tab Limits由預設的10個檔案放大到20或30，檔案開啟多後，檔案的排列順序就很難控制，結果變成要在多個頁籤(Tab)間尋找檔案，有時對寫程式的思考會造成中斷與停頓。
    
TabOrder就是用來決這個問題的「發明」。我們可以用拖放(Drag &amp; Drop)的方式將某個Tab拖到要放置的另一個Tab位置處後放掉，則第一個Tab就移動到第二個Tab的位置了。
    
不用滑鼠拖放的話，也可以將Active Tab用Ctrl-Alt-Shift-Left往左移動、或Ctrl-Alt-Shift-Right往右移動。
  JSP Format
IDEA能方便的重排Java程式的格式，但卻不支援JSP、HTML的重排，這個插件就是提供重排JSP、JSPF、JS、HTML或XML內容的功
能。重排的控制必須透過指定的Properties檔案來設定，目前並無GUI畫面來設定，各個設定的意義也必須閱讀其網站上的說明文件才能了解。
IDEA的插入統一在Settings→IDE Settings→Plugins裡做下載與設定，操作很一致且簡單，在此不再贅述。
如果您也有常用的插件，也請提出分享。

		]]>
	</description>
	<content:encoded><![CDATA[
			除了在《<a href="http://blog.xuite.net/emisjerry/tech/301454">滑鼠手勢症候群！方便的IDEA Mouse Gestures</a>》這篇裡介紹的<a href="http://www.intellij.com/">IDEA 4.5</a>插件(Plugin)：IdeaMouseGestures 之外，我還使用了下列幾個別的插件：<br />
<ol><li><span style="font-weight: bold;">CVS Bar</span><br />
IDEA 4.5支援了強大的CVS功能，約有10多個命令選項，為了執行某個特定命令就必須拉出很長的功能表，在操作上不甚方便。CVS Bar能夠在IDEA標準的工具列上增加常用的CVS命令按鈕，這樣就可以只按一個按鈕就順利執行Edit或Commit了。<br />
    <br />
這個插件節省太多打開功能表的時間了，強力建議一定要安裝。下圖從右往左分別是：CVS
Diff、Checkout、Update、Commit、Unedit、Edit、Show history，再來是被Disable的Undo
Add、Add與左邊的黃色小魚圖示CVS Setup。<br />
    <img src="http://blog.xuite.net/_users/b3/ac/11893557/blog_10351/txt/318188/318188_0.jpg" alt="CVS Bar" style="width: 296px; height: 54px;" /><br />
  </li><li><span style="font-weight: bold;">TabOrder</span><br />
為了讓IDEA一次可以同時編輯多支程式，我們會由<span style="font-weight: bold;">Settings→IDE Settings→Editor→Limits</span>將<span style="font-weight: bold;">Tab Limits</span>由預設的10個檔案放大到20或30，檔案開啟多後，檔案的排列順序就很難控制，結果變成要在多個頁籤(Tab)間尋找檔案，有時對寫程式的思考會造成中斷與停頓。<br />
    <br />
TabOrder就是用來決這個問題的「發明」。我們可以用拖放(<span style="font-weight: bold;">Drag &amp; Drop</span>)的方式將某個Tab拖到要放置的另一個Tab位置處後放掉，則第一個Tab就移動到第二個Tab的位置了。<br />
    <br />
不用滑鼠拖放的話，也可以將Active Tab用<span style="font-weight: bold;">Ctrl-Alt-Shift-Left</span>往左移動、或<span style="font-weight: bold;">Ctrl-Alt-Shift-Right</span>往右移動。<br />
  </li><li><span style="font-weight: bold;">JSP Format</span><br />
IDEA能方便的重排Java程式的格式，但卻不支援JSP、HTML的重排，這個插件就是提供重排JSP、JSPF、JS、HTML或XML內容的功
能。重排的控制必須透過指定的Properties檔案來設定，目前並無GUI畫面來設定，各個設定的意義也必須閱讀其網站上的說明文件才能了解。</li></ol>
IDEA的插入統一在Settings→<span style="font-weight: bold;">IDE Settings→Plugins</span>裡做下載與設定，操作很一致且簡單，在此不再贅述。<br />
如果您也有常用的插件，也請提出分享。

		<a class="acontinues" href="http://blog.roodo.com/emisjerry/archives/164532.html">(繼續閱讀...)</a>
		]]>
	</content:encoded>
	<link>http://blog.roodo.com/emisjerry/archives/164532.html</link>
	<guid>http://blog.roodo.com/emisjerry/archives/164532.html</guid>
	<category>編程生涯</category>
	<pubDate>Thu, 02 Jun 2005 22:39:48 +0800</pubDate>
</item>
</channel>
</rss>