<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>On the way to be great...</title>
	<atom:link href="http://liangwu.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://liangwu.wordpress.com</link>
	<description>Coding with passion and discipline</description>
	<lastBuildDate>Thu, 30 Jul 2009 04:33:35 +0000</lastBuildDate>
	<generator>http://wordpress.com/</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<cloud domain='liangwu.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://www.gravatar.com/blavatar/f73bbce255055d8bb4b46b5de2f26857?s=96&#038;d=http://s.wordpress.com/i/buttonw-com.png</url>
		<title>On the way to be great...</title>
		<link>http://liangwu.wordpress.com</link>
	</image>
			<item>
		<title>Implement ELMAH For Error logging</title>
		<link>http://liangwu.wordpress.com/2009/05/20/implement-elmah-for-error-logging/</link>
		<comments>http://liangwu.wordpress.com/2009/05/20/implement-elmah-for-error-logging/#comments</comments>
		<pubDate>Wed, 20 May 2009 18:23:28 +0000</pubDate>
		<dc:creator>liangwu</dc:creator>
				<category><![CDATA[ASP.NET]]></category>

		<guid isPermaLink="false">http://liangwu.wordpress.com/2009/05/20/implement-elmah-for-error-logging/</guid>
		<description><![CDATA[Following the suggestion from Scott and Jeff, I decide to have ELMAH implemented in my current ASP.NET application as well. The whole progress is really straightforward and painless. Most of the work is to modify the application’s web.config file. 


Download the latest version of bin, currently 1.0 version, from project’s web site, hosted on Google [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=103&subd=liangwu&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>Following the suggestion from <a href="http://www.hanselman.com/blog/ELMAHErrorLoggingModulesAndHandlersForASPNETAndMVCToo.aspx" target="_blank">Scott</a> and <a href="http://www.codinghorror.com/blog/archives/001239.html" target="_blank">Jeff</a>, I decide to have <a href="http://code.google.com/p/elmah/" target="_blank">ELMAH</a> implemented in my current ASP.NET application as well. The whole progress is really straightforward and painless. Most of the work is to modify the application’s web.config file. </p>
<ul>
<ul>
<li>Download the latest version of bin, currently 1.0 version, from project’s web site, <a href="http://code.google.com/p/elmah/" target="_blank">hosted on Google code</a>. </li>
<li>Based on the version of your ASP.NET application, reference the corresponding Elmah.dll from the subfolder. You might need to reference SQLite.dll if you need to use SQLLite for the log storage. </li>
<li>Modify the Web.config based on the sample Web.config file coming with the sample. You can <a href="http://code.google.com/p/elmah/source/browse/trunk/samples/web.config" target="_blank">check it</a> from here as well. </li>
</ul>
</ul>
<p>&#160;</p>
<p>That is it! Then you can find the unhandled exception by access <a href="http://yourwebsite/elmah.axd">http://yourwebsite/elmah.axd</a>. You will see the error page is something like </p>
<p><a href="http://liangwu.files.wordpress.com/2009/05/elmah-axdwitherror.png"><img title="elmah.axd-with-error" style="display:inline;border-width:0;" height="227" alt="elmah.axd-with-error" src="http://liangwu.files.wordpress.com/2009/05/elmah-axdwitherror_thumb.png?w=403&#038;h=227" width="403" border="0" /></a> </p>
<p>From what I see so far, ELMAH is</p>
<ul>
<li>Easy to implement and set it up </li>
<li>Flexible to offer multiple log storage providers, including SQL Server, SQLLite, Oracle, XML, and In-memory. </li>
<li>Readable, the log is formatted in a HTML table, which can be also export to CVS file and be queried by Microsoft’s <a href="http://support.microsoft.com/kb/910447" target="_blank">Log Parser</a> tool. </li>
<li>Reliable, it provides multiple notification channels, including Email, RSS and even Tweet. </li>
</ul>
<p>Just as Jeff Atwood said in his blog above, the main purpose of setting up ELMAH in our application is to find out the accurate, valuable and real time “feedback” of the applications we built automatically. </p>
<p>Happy coding, till next time!</p>
  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/liangwu.wordpress.com/103/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/liangwu.wordpress.com/103/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/liangwu.wordpress.com/103/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/liangwu.wordpress.com/103/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/liangwu.wordpress.com/103/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/liangwu.wordpress.com/103/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/liangwu.wordpress.com/103/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/liangwu.wordpress.com/103/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/liangwu.wordpress.com/103/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/liangwu.wordpress.com/103/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=103&subd=liangwu&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://liangwu.wordpress.com/2009/05/20/implement-elmah-for-error-logging/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/ef7572a12f8c9796fc7d604d6bd0476a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">liangwu</media:title>
		</media:content>

		<media:content url="http://liangwu.files.wordpress.com/2009/05/elmah-axdwitherror_thumb.png" medium="image">
			<media:title type="html">elmah.axd-with-error</media:title>
		</media:content>
	</item>
		<item>
		<title>Really Useful Windows Shortcuts</title>
		<link>http://liangwu.wordpress.com/2009/04/24/really-useful-windows-shortcuts/</link>
		<comments>http://liangwu.wordpress.com/2009/04/24/really-useful-windows-shortcuts/#comments</comments>
		<pubDate>Sat, 25 Apr 2009 02:14:20 +0000</pubDate>
		<dc:creator>liangwu</dc:creator>
				<category><![CDATA[Productivity]]></category>

		<guid isPermaLink="false">http://liangwu.wordpress.com/?p=77</guid>
		<description><![CDATA[One the of the tips I heard to become a productive developer is to use mouse as few as possible, put the fingers on the keyboard.
Mouse clicking is sort of distraction from we are doing. Combining with any of the launcher tool, such as Slickrun, you will find you can definitely accomplish your work faster, [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=77&subd=liangwu&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p><a href="http://liangwu.files.wordpress.com/2009/05/keyboard.jpg"><img title="Keyboard" src="http://liangwu.files.wordpress.com/2009/05/keyboard_thumb.jpg?w=244&#038;h=192" border="0" alt="Keyboard" width="244" height="192" align="right" /></a>One the of the tips I heard to become a productive developer is to use mouse as few as possible, put the fingers on the keyboard.</p>
<p>Mouse clicking is sort of distraction from we are doing. Combining with any of the launcher tool, such as <a href="http://www.bayden.com/SlickRun/">Slickrun,</a> you will find you can definitely accomplish your work faster, more effectively and a lot fun!</p>
<p>Don’t try to memorize all of them at once. When you feel you need to use mouse, just do some search to see if any shortcut available. Here is the list I am using a lot as a .NET developer (visual studio and Resharper, of course!)</p>
<p>Here are some of the window-based shortcuts I collected and use very often. Hope it will help.</p>
<ul>
<li><a href="#visialstudio">Visual Studio shortcut keys</a></li>
<li><a href="http://www.jetbrains.com/resharper/docs/ReSharper45DefaultKeymap.pdf">Resharper shortcut keys (visual studio schema)</a></li>
<li><a href="#basicpc">Window common shortcut keys</a></li>
<li><a href="#webcommon">Web browser common Shortcut keys</a></li>
<li><a href="#firefox">Firefox shortcut keys</a></li>
<li><a href="#ie">Microsoft IE shortcut keys</a></li>
<li><a href="excel">Microsoft Excel shortcut keys</a></li>
<li><a href="word">Microsoft Word shortcut keys</a></li>
</ul>
<p><h3><a name="visialstudio">Visual Studio Shortcut Keys</a></h3>
<table border="1" cellspacing="0" cellpadding="1" width="447">
<tbody>
<tr>
<td width="212" valign="top">Shortcut Keys</td>
<td width="233" valign="top">Description</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + X</td>
<td width="233" valign="top">Cut the current selected item to clipboard</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + C</td>
<td width="233" valign="top">Copies the current selected item to the clipboard</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + V</td>
<td width="233" valign="top">Pastes the item in the clipboard at the cursor</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Z</td>
<td width="233" valign="top">Undo previous editing action</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Y</td>
<td width="233" valign="top">Redo the previous undo action</td>
</tr>
<tr>
<td width="212" valign="top">Esc</td>
<td width="233" valign="top">Closes a menu or dialog, cancels an operation in progress, or places focus in the current document window</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + S</td>
<td width="233" valign="top">Saves the selected files in the current project (usually the file that is being edited)</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + S</td>
<td width="233" valign="top">Saves all documents and projects</td>
</tr>
<tr>
<td width="212" valign="top">Shift + F12</td>
<td width="233" valign="top">Finds a reference to the selected item or the item under the cursor</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + End</td>
<td width="233" valign="top">Moves the cursor to the end of the document</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Home</td>
<td width="233" valign="top">Moves the cursor to the start of the document</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + G</td>
<td width="233" valign="top">Displays the Go to Line dialog</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Right Arrow</td>
<td width="233" valign="top">Moves the cursor one word to the right</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Left Arrow</td>
<td width="233" valign="top">Moves the cursor one word to the left</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + K, Ctrl + C</td>
<td width="233" valign="top">Marks the current line or selected lines of code as a comment</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + K, Ctrl + U</td>
<td width="233" valign="top">Removes the comment syntax from the current line or currently selected lines of code</td>
</tr>
<tr>
<td width="212" valign="top">Ctl + J</td>
<td width="233" valign="top">Lists members for statement completion when editing code</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + R, Ctrl + W</td>
<td width="233" valign="top">Shows or hides spaces and tab marks</td>
</tr>
<tr>
<td width="212" valign="top">Shift-Left Arrow</td>
<td width="233" valign="top">Moves the cursor to the left one character, extending the selection</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + End</td>
<td width="233" valign="top">Moves the cursor to the end of the document, extending the selection</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + Home</td>
<td width="233" valign="top">Moves the cursor to the start of the document, extending the selection</td>
</tr>
<tr>
<td width="212" valign="top">Shift + Down Arrow</td>
<td width="233" valign="top">Moves the cursor down one line, extending the selection</td>
</tr>
<tr>
<td width="212" valign="top">Shift + End</td>
<td width="233" valign="top">Moves the cursor to the end of the current line, extending the selection</td>
</tr>
<tr>
<td width="212" valign="top">Shift + Home</td>
<td width="233" valign="top">Moves the cursor to the start of the line, extending the selection</td>
</tr>
<tr>
<td width="212" valign="top">Shift + Up Arrow</td>
<td width="233" valign="top">Moves the cursor up one line, extending the selection</td>
</tr>
<tr>
<td width="212" valign="top">Shift + Page Down</td>
<td width="233" valign="top">Extends selection down one page</td>
</tr>
<tr>
<td width="212" valign="top">Shift + Page Up</td>
<td width="233" valign="top">Extends selection up one page</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + A</td>
<td width="233" valign="top">Selects everything in the current document</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + Page Down</td>
<td width="233" valign="top">Moves the cursor to the last line in view, extending the selection</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + Page Up</td>
<td width="233" valign="top">Moves the cursor to the top of the current window,</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + Alt + Right Arrow</td>
<td width="233" valign="top">Moves the cursor to the right one word, extending the column selection</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + Left + Arrow</td>
<td width="233" valign="top">Moves the cursor one word to the left, extending the selection</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + B</td>
<td width="233" valign="top">Build the solution</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + N</td>
<td width="233" valign="top">Display the New Project dialog</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + O</td>
<td width="233" valign="top">Display open the file dialog</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + O</td>
<td width="233" valign="top">Display open project dialog</td>
</tr>
<tr>
<td width="212" valign="top">Shift + Alt + A</td>
<td width="233" valign="top">Display the Add Existing Item dialog</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + A</td>
<td width="233" valign="top">Display the Add New Item dialog</td>
</tr>
<tr>
<td width="212" valign="top">Shift + Alt + Enter</td>
<td width="233" valign="top">Toggles full screen mode</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Tab</td>
<td width="233" valign="top">Cycles through the MDI child windows one by one</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + F</td>
<td width="233" valign="top">Display the Find dialog</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + F</td>
<td width="233" valign="top">Display the Find in Files dialog</td>
</tr>
<tr>
<td width="212" valign="top">F3</td>
<td width="233" valign="top">Find Next</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + H</td>
<td width="233" valign="top">Display the Replace dialog</td>
</tr>
<tr>
<td width="212" valign="top">Ctrl + Shift + H</td>
<td width="233" valign="top">Display the Replace in Files dialog</td>
</tr>
</tbody>
</table>
<p><a name="basicpc"><br />
</a></p>
<h3><a name="basicpc">Basic Windows shortcut keys</a></h3>
<table border="1" cellspacing="0" cellpadding="2" width="446">
<tbody>
<tr>
<td width="203" valign="top">Shortcut Keys</td>
<td width="241" valign="top">Description</td>
</tr>
<tr>
<td width="205" valign="top">Alt+F</td>
<td width="241" valign="top">File menu options in current program.</td>
</tr>
<tr>
<td width="206" valign="top">Alt+E</td>
<td width="241" valign="top">Edit options in current program</td>
</tr>
<tr>
<td width="207" valign="top">F1</td>
<td width="241" valign="top">Universal Help in almost every Windows program.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+A</td>
<td width="241" valign="top">Select all text.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+X</td>
<td width="241" valign="top">Cut selected item.</td>
</tr>
<tr>
<td width="208" valign="top">Shift+Del</td>
<td width="241" valign="top">Cut selected item.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+C</td>
<td width="241" valign="top">Copy selected item.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+Ins</td>
<td width="241" valign="top">Copy selected item</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+V</td>
<td width="241" valign="top">Paste</td>
</tr>
<tr>
<td width="208" valign="top">Shift+Ins</td>
<td width="241" valign="top">Paste</td>
</tr>
<tr>
<td width="208" valign="top">Home</td>
<td width="241" valign="top">Goes to beginning of current line.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+Home</td>
<td width="241" valign="top">Goes to beginning of document.</td>
</tr>
<tr>
<td width="208" valign="top">End</td>
<td width="241" valign="top">Goes to end of current line.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+End</td>
<td width="241" valign="top">Goes to end of document.</td>
</tr>
<tr>
<td width="208" valign="top">Shift+Home</td>
<td width="241" valign="top">Highlights from current position to beginning of line.</td>
</tr>
<tr>
<td width="208" valign="top">Shift+End</td>
<td width="241" valign="top">Highlights from current position to end of line.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+Left arrow</td>
<td width="241" valign="top">Moves one word to the left at a time.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+Right arrow</td>
<td width="241" valign="top">Moves one word to the right at a time.</td>
</tr>
<tr>
<td width="208" valign="top">Alt+Tab</td>
<td width="241" valign="top">Switch between open applications.</td>
</tr>
<tr>
<td width="208" valign="top">Alt+Shift+Tab</td>
<td width="241" valign="top">Switch backwards between open applications.</td>
</tr>
<tr>
<td width="208" valign="top">Alt+double-click</td>
<td width="241" valign="top">Display the properties of the object you double-click on.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+Tab</td>
<td width="241" valign="top">Switches between program groups or document windows in applications</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+Shift+Tab</td>
<td width="241" valign="top">Same as above but backwards.</td>
</tr>
<tr>
<td width="208" valign="top">Alt+Print Screen</td>
<td width="241" valign="top">Create a screen shot only for the program you are currently in.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+Alt+Del</td>
<td width="241" valign="top">Reboot the computer and/or bring up the Windows task manager.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+Esc</td>
<td width="241" valign="top">Bring up the Windows Start menu.</td>
</tr>
<tr>
<td width="208" valign="top">Alt+Esc</td>
<td width="241" valign="top">Switch Between open applications on taskbar.</td>
</tr>
<tr>
<td width="208" valign="top">Alt+F4</td>
<td width="241" valign="top">Closes Current open program.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+F4</td>
<td width="241" valign="top">Closes Window in Program.</td>
</tr>
<tr>
<td width="208" valign="top">Shift + Del</td>
<td width="241" valign="top">Delete programs/files without throwing them into the recycle bin.</td>
</tr>
<tr>
<td width="208" valign="top">Holding Shift</td>
<td width="241" valign="top">Boot Safe Mode or by pass system files as the computer is booting</td>
</tr>
<tr>
<td width="208" valign="top">Holding Shift</td>
<td width="241" valign="top">When putting in an audio CD, will prevent CD Player from playing.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+F9</td>
<td width="241" valign="top">Minimize current window.</td>
</tr>
<tr>
<td width="208" valign="top">Ctrl+F10</td>
<td width="241" valign="top">Maximize currently selected window.</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo</td>
<td width="241" valign="top">Start menu</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+R</td>
<td width="241" valign="top">Run dialog box</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+M</td>
<td width="241" valign="top">Minimize all</td>
</tr>
<tr>
<td width="208" valign="top">SHIFT+Windows Logo+M</td>
<td width="241" valign="top">Undo minimize all</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+F1</td>
<td width="241" valign="top">Help</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+E</td>
<td width="241" valign="top">Windows Explorer</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+F</td>
<td width="241" valign="top">Find files or folders</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+D</td>
<td width="241" valign="top">Minimizes all open windows and displays the desktop</td>
</tr>
<tr>
<td width="208" valign="top">CTRL+Windows Logo+F</td>
<td width="241" valign="top">Find computer</td>
</tr>
<tr>
<td width="208" valign="top">CTRL+Windows Logo+TAB</td>
<td width="241" valign="top">Moves focus from Start, to the Quick Launch toolbar, to the system tray</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+TAB</td>
<td width="241" valign="top">Cycle through taskbar buttons</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+Break</td>
<td width="241" valign="top">System Properties dialog box</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+L</td>
<td width="241" valign="top">Log off Windows</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+P</td>
<td width="241" valign="top">Starts Print Manager</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+C</td>
<td width="241" valign="top">Opens Control Panel</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+V</td>
<td width="241" valign="top">Starts Clipboard</td>
</tr>
<tr>
<td width="208" valign="top">Windows Logo+R</td>
<td width="241" valign="top">Open and Run Window</td>
</tr>
</tbody>
</table>
<p><a name="webcommon"><br />
</a></p>
<h3><a name="webcommon">Web Browser common shortcut Keys</a></h3>
<table border="1" cellspacing="0" cellpadding="2" width="450">
<tbody>
<tr>
<td width="202" valign="top">Shortcut Key</td>
<td width="246" valign="top">Description</td>
</tr>
<tr>
<td width="203" valign="top">Ctrl + N</td>
<td width="246" valign="top">Open a new window</td>
</tr>
<tr>
<td width="203" valign="top">Ctrl + T</td>
<td width="246" valign="top">Open a new tab</td>
</tr>
<tr>
<td width="203" valign="top">Ctrl + W</td>
<td width="246" valign="top">Close the current window</td>
</tr>
<tr>
<td width="203" valign="top">Ctrl + R</td>
<td width="246" valign="top">Refresh</td>
</tr>
<tr>
<td width="203" valign="top">Esc</td>
<td width="246" valign="top">Stop</td>
</tr>
<tr>
<td width="203" valign="top">Alt + &lt;-</td>
<td width="246" valign="top">Back</td>
</tr>
<tr>
<td width="203" valign="top">Alt + -&gt;</td>
<td width="246" valign="top">Forward</td>
</tr>
<tr>
<td width="203" valign="top">Alt + Home</td>
<td width="246" valign="top">Go to your homepage</td>
</tr>
<tr>
<td width="203" valign="top">Alt + D</td>
<td width="246" valign="top">Move focus to the address bar to type URL</td>
</tr>
<tr>
<td width="203" valign="top">Ctrl + Enter</td>
<td width="246" valign="top">Add &#8220;<a href="http://www.&quot;">http://www.&#8221;</a> and &#8220;.com&#8221; around an address</td>
</tr>
</tbody>
</table>
<p><a name="firefox"><br />
</a></p>
<h3><a name="firefox">Mozilla Firefox shortcut Keys</a></h3>
<table border="1" cellspacing="0" cellpadding="2" width="457">
<tbody>
<tr>
<td width="200" valign="top">Shortcut Keys</td>
<td width="255" valign="top">Description</td>
</tr>
<tr>
<td width="197" valign="top">Alt + Home</td>
<td width="258" valign="top">Home</td>
</tr>
<tr>
<td width="195" valign="top">Alt + Left Arrow</td>
<td width="260" valign="top">Back a page.</td>
</tr>
<tr>
<td width="194" valign="top">Backspace</td>
<td width="261" valign="top">Back a page.</td>
</tr>
<tr>
<td width="193" valign="top">Alt + Right Arrow</td>
<td width="262" valign="top">Forward a page.</td>
</tr>
<tr>
<td width="192" valign="top">F5</td>
<td width="263" valign="top">Refresh current page, frame, or tab.</td>
</tr>
<tr>
<td width="192" valign="top">F11</td>
<td width="263" valign="top">Display the current website in full screen mode. Pressing F11 again will exit this mode.</td>
</tr>
<tr>
<td width="192" valign="top">F3</td>
<td width="263" valign="top">Find Again</td>
</tr>
<tr>
<td width="192" valign="top">Esc</td>
<td width="263" valign="top">Stop page or download from loading.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + (- or +)</td>
<td width="263" valign="top">Increase or decrease the font size, pressing &#8216;-&#8217; will decrease and &#8216;+&#8217; will increase.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + Enter</td>
<td width="263" valign="top">Quickly complete an address. For example, type computerhope in the address bar and press CTRL + ENTER to get http://www.computerhope.com</td>
</tr>
<tr>
<td width="192" valign="top">Shift + Enter</td>
<td width="263" valign="top">Complete a .net instead of a .com address.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + Shift + Enter</td>
<td width="263" valign="top">Complete a .org address.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + Shift + Del</td>
<td width="263" valign="top">Open the Clear Data window to quickly clear private data.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + W</td>
<td width="263" valign="top">Close the current window or tab</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + D</td>
<td width="263" valign="top">Add a bookmark for the page currentlys opened.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + I</td>
<td width="263" valign="top">Display available bookmarks.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + J</td>
<td width="263" valign="top">Display the download window.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + N</td>
<td width="263" valign="top">Open New browser window.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + P</td>
<td width="263" valign="top">Print current page / frame.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + T</td>
<td width="263" valign="top">Opens a new tab.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + F4</td>
<td width="263" valign="top">Closes the currently selected tab.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + Shift + T</td>
<td width="263" valign="top">Undo the close of a window.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + Tab</td>
<td width="263" valign="top">Moves through each of the open tabs.</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + Shift + Tab</td>
<td width="263" valign="top">Swich to the previous tab</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + G</td>
<td width="263" valign="top">Find the previous occurrence of a search phrase</td>
</tr>
<tr>
<td width="192" valign="top">Ctrl + K</td>
<td width="263" valign="top">Move cursor to the Web Search Widget (top right of the screen)</td>
</tr>
<tr>
<td width="192" valign="top">Spacebar</td>
<td width="263" valign="top">Moves down a page at a time.</td>
</tr>
<tr>
<td width="192" valign="top">Shift + Spacebar</td>
<td width="263" valign="top">Moves up a page at a time.</td>
</tr>
<tr>
<td width="192" valign="top">Alt + Down arrow</td>
<td width="263" valign="top">Display all previous text entered in a text box and/or available options on drop down menu.</td>
</tr>
</tbody>
</table>
<p><a name="ie"><br />
</a></p>
<h3><a name="ie">Internet Explorer Shortcut</a></h3>
<table border="1" cellspacing="0" cellpadding="1" width="454">
<tbody>
<tr>
<td width="190" valign="top">Shortcut Keys</td>
<td width="262" valign="top">Description</td>
</tr>
<tr>
<td width="188" valign="top">Alt + Left Arrow</td>
<td width="264" valign="top">Back a page</td>
</tr>
<tr>
<td width="187" valign="top">Backspace</td>
<td width="265" valign="top">Back a page</td>
</tr>
<tr>
<td width="186" valign="top">Alt + Right Arrow</td>
<td width="266" valign="top">Forward a page.</td>
</tr>
<tr>
<td width="185" valign="top">F5</td>
<td width="267" valign="top">Refresh current page, frame, or tab.</td>
</tr>
<tr>
<td width="185" valign="top">F11</td>
<td width="267" valign="top">Display the current website in full screen mode</td>
</tr>
<tr>
<td width="185" valign="top">Esc</td>
<td width="267" valign="top">Stop page or download from loading.</td>
</tr>
<tr>
<td width="185" valign="top">Ctrl + (- or +)</td>
<td width="267" valign="top">Increase or decrease the font size, pressing &#8216;-&#8217; will decrease and &#8216;+&#8217; will increase.</td>
</tr>
<tr>
<td width="185" valign="top">Ctrl + Enter</td>
<td width="267" valign="top">Quickly complete an address. For example, type computerhope in the address bar and press CTRL + ENTER to get http://www.computerhope.com.</td>
</tr>
<tr>
<td width="185" valign="top">Ctrl + D</td>
<td width="267" valign="top">Add a Favorite for the page currently opened.</td>
</tr>
<tr>
<td width="185" valign="top">Ctrl + I</td>
<td width="267" valign="top">Display available bookmarks.</td>
</tr>
<tr>
<td width="185" valign="top">Ctrl + N</td>
<td width="267" valign="top">Open New browser window.</td>
</tr>
<tr>
<td width="185" valign="top">Ctrl + P</td>
<td width="267" valign="top">Print current page / frame.</td>
</tr>
<tr>
<td width="185" valign="top">Ctrl + T</td>
<td width="267" valign="top">Opens a new tab.</td>
</tr>
<tr>
<td width="185" valign="top">Ctrl + F4</td>
<td width="267" valign="top">Closes the currently selected tab.</td>
</tr>
<tr>
<td width="185" valign="top">Ctrl + Tab</td>
<td width="267" valign="top">Moves through each of the open tabs.</td>
</tr>
<tr>
<td width="185" valign="top">Spacebar</td>
<td width="267" valign="top">Moves down a page at a time.</td>
</tr>
<tr>
<td width="185" valign="top">Shift + Spacebar</td>
<td width="267" valign="top">Moves up a page at a time.</td>
</tr>
<tr>
<td width="185" valign="top">Alt + Down arrow</td>
<td width="267" valign="top">Display all previous text entered in a text box and/or available options on drop down menu.</td>
</tr>
</tbody>
</table>
<p><a name="excel"></a></p>
<h3><a name="excel">Microsoft Excel</a></h3>
<table border="1" cellspacing="0" cellpadding="1" width="453">
<tbody>
<tr>
<td width="186" valign="top">Shortcut Keys</td>
<td width="265" valign="top">Description</td>
</tr>
<tr>
<td width="186" valign="top">F2</td>
<td width="265" valign="top">Edit the selected cell.</td>
</tr>
<tr>
<td width="186" valign="top">F5</td>
<td width="265" valign="top">Goto a specific cell. For example, C6.</td>
</tr>
<tr>
<td width="186" valign="top">F7</td>
<td width="265" valign="top">Spell check selected text and/or document.</td>
</tr>
<tr>
<td width="186" valign="top">F11</td>
<td width="265" valign="top">Create chart.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Shift + ;</td>
<td width="265" valign="top">Enter the current time.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + ;</td>
<td width="265" valign="top">Enter the current date.</td>
</tr>
<tr>
<td width="186" valign="top">Alt + Shift + F1</td>
<td width="265" valign="top">Insert New Worksheet.</td>
</tr>
<tr>
<td width="186" valign="top">Shift + F3</td>
<td width="265" valign="top">Open the Excel formula window.</td>
</tr>
<tr>
<td width="186" valign="top">Shift + F5</td>
<td width="265" valign="top">Bring up search box.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + A</td>
<td width="265" valign="top">Select all contents of the worksheet.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + B</td>
<td width="265" valign="top">Bold highlighted selection.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + I</td>
<td width="265" valign="top">Italic highlighted selection.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + K</td>
<td width="265" valign="top">Insert link.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + U</td>
<td width="265" valign="top">Underline highlighted selection.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + 5</td>
<td width="265" valign="top">Strikethrough highlighted selection.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + P</td>
<td width="265" valign="top">Bring up the print dialog box to begin printing.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Z</td>
<td width="265" valign="top">Undo last action.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + F6</td>
<td width="265" valign="top">Switch between open workbooks / windows.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Page up</td>
<td width="265" valign="top">Move between Excel work sheets in the same Excel document.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Page down</td>
<td width="265" valign="top">Move between Excel work sheets in the same Excel document.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Tab</td>
<td width="265" valign="top">Move between Two or more open Excel files.</td>
</tr>
<tr>
<td width="186" valign="top">Alt + =</td>
<td width="265" valign="top">Create a formula to sum all of the above cells</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + &#8216;</td>
<td width="265" valign="top">Insert the value of the above cell into cell currently selected.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Shift + !</td>
<td width="265" valign="top">Format number in comma format.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Shift + $</td>
<td width="265" valign="top">Format number in currency format.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Shift + #</td>
<td width="265" valign="top">Format number in date format.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Shift + %</td>
<td width="265" valign="top">Format number in percentage format.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Shift + ^</td>
<td width="265" valign="top">Format number in scientific format.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Shift + @</td>
<td width="265" valign="top">Format number in time format.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Arrow key</td>
<td width="265" valign="top">Move to next section of text.</td>
</tr>
<tr>
<td width="186" valign="top">Ctrl + Space</td>
<td width="265" valign="top">Select entire column.</td>
</tr>
<tr>
<td width="186" valign="top">Shift + Space</td>
<td width="265" valign="top">Select entire row.</td>
</tr>
</tbody>
</table>
<h3><a name="word">Microsoft Word</a></h3>
<table border="1" cellspacing="0" cellpadding="1" width="455">
<tbody>
<tr>
<td width="188" valign="top">Shortcut Keys</td>
<td width="265" valign="top">Description</td>
</tr>
<tr>
<td width="188" valign="top">Ctrl + A</td>
<td width="265" valign="top">Select all contents of the page.</td>
</tr>
<tr>
<td width="188" valign="top">Ctrl + B</td>
<td width="265" valign="top">Bold highlighted selection.</td>
</tr>
<tr>
<td width="188" valign="top">Ctrl + C</td>
<td width="265" valign="top">Copy selected text.</td>
</tr>
<tr>
<td width="188" valign="top">Ctrl + X</td>
<td width="265" valign="top">Cut selected text.</td>
</tr>
<tr>
<td width="188" valign="top">Ctrl + P</td>
<td width="265" valign="top">Open the print window.</td>
</tr>
<tr>
<td width="188" valign="top">Ctrl + F</td>
<td width="265" valign="top">Open find box.</td>
</tr>
<tr>
<td width="188" valign="top">Ctrl + I</td>
<td width="265" valign="top">Italic highlighted selection.</td>
</tr>
<tr>
<td width="188" valign="top">Ctrl + K</td>
<td width="265" valign="top">Insert link.</td>
</tr>
<tr>
<td width="188" valign="top">Ctrl + U</td>
<td width="265" valign="top">Underline highlighted selection.</td>
</tr>
<tr>
<td width="188" valign="top">Ctrl + V</td>
<td width="265" valign="top">Paste.</td>
</tr>
<tr>
<td width="188" valign="top">Ctrl + Y</td>
<td width="265" valign="top">Redo the last action performed.</td>
</tr>
<tr>
<td width="188" valign="top">Ctrl + Z</td>
<td width="265" valign="top">Undo last action.</td>
</tr>
</tbody>
</table>
  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/liangwu.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/liangwu.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/liangwu.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/liangwu.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/liangwu.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/liangwu.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/liangwu.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/liangwu.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/liangwu.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/liangwu.wordpress.com/77/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=77&subd=liangwu&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://liangwu.wordpress.com/2009/04/24/really-useful-windows-shortcuts/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/ef7572a12f8c9796fc7d604d6bd0476a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">liangwu</media:title>
		</media:content>

		<media:content url="http://liangwu.files.wordpress.com/2009/05/keyboard_thumb.jpg" medium="image">
			<media:title type="html">Keyboard</media:title>
		</media:content>
	</item>
		<item>
		<title>Functional programming in C# 3.0 &#8211; (1)</title>
		<link>http://liangwu.wordpress.com/2008/01/22/functional-programming-in-c-3-0-1/</link>
		<comments>http://liangwu.wordpress.com/2008/01/22/functional-programming-in-c-3-0-1/#comments</comments>
		<pubDate>Tue, 22 Jan 2008 20:30:50 +0000</pubDate>
		<dc:creator>liangwu</dc:creator>
				<category><![CDATA[C#]]></category>

		<guid isPermaLink="false">http://liangwu.wordpress.com/?p=66</guid>
		<description><![CDATA[I had a lot of fun to read Tomas Petricek&#8217;s article, &#34;Concepts behind the C# 3.0 language&#34;. Instead of listing all of the new syntax changes as most of other tutorials, Tomas shed some lights on the details about influence of the development of C# 3.0 from other languages, especially how Functional programming plays in [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=66&subd=liangwu&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>I had a lot of fun to read Tomas Petricek&#8217;s article, &quot;<a href="http://tomasp.net/blog/csharp3-concepts.aspx">Concepts behind the C# 3.0 language</a>&quot;. Instead of listing all of the new syntax changes as most of other tutorials, Tomas shed some lights on the details about influence of the development of C# 3.0 from other languages, especially how Functional programming plays in C# 3.0. Actually, Lambda Expression and LINQ are really part of that.</p>
<p>So what is functional programming? Quote from Wikipedia:</p>
<p>&quot;<b>Functional programming</b> is a <a href="http://en.wikipedia.org/wiki/Programming_paradigm">programming paradigm</a> that treats <a href="http://en.wikipedia.org/wiki/Computation">computation</a> as the evaluation of <a href="http://en.wikipedia.org/wiki/Function_%28mathematics%29">mathematical functions</a> and avoids <a href="http://en.wikipedia.org/wiki/Program_state">state</a> and <a href="http://en.wikipedia.org/wiki/Immutable_object">mutable</a> data. It emphasizes the application of functions, in contrast with the <a href="http://en.wikipedia.org/wiki/Imperative_programming">imperative programming</a> style that emphasizes changes in state.<sup><a href="http://en.wikipedia.org/wiki/Functional_programming#_note-0">[1]</a> </sup>&quot;</p>
<p>So what it really tells us? I think the main point is &quot;function is data&quot; which means function can be use to be passed as an parameter or returned argument or modified as any other data in our application. Do we gain benefit for that? Sure, we do.</p>
<p>1. Functional programming can help model data operation. Here is the sample:</p>
<div class="wlWriterSmartContent" style="display:inline;float:none;width:528px;margin:0;padding:0;">
<pre style="font-size:11px;overflow:auto;font-family:consolas;background-color:white;">
<div><span style="color:#008080;">1</span> <span style="color:#0000ff;">private</span><span style="color:#000000;"> </span><span style="color:#0000ff;">static</span><span style="color:#000000;"> </span><span style="color:#0000ff;">long</span><span style="color:#000000;"> Watch</span><span style="color:#000000;">&lt;</span><span style="color:#000000;">T</span><span style="color:#000000;">&gt;</span><span style="color:#000000;">(Action</span><span style="color:#000000;">&lt;</span><span style="color:#000000;">T</span><span style="color:#000000;">&gt;</span><span style="color:#000000;"> act, T arg)
</span><span style="color:#008080;">2</span> <span style="color:#000000;">{
</span><span style="color:#008080;">3</span> <span style="color:#000000;">        Stopwatch watch </span><span style="color:#000000;">=</span><span style="color:#000000;"> </span><span style="color:#0000ff;">new</span><span style="color:#000000;"> Stopwatch();
</span><span style="color:#008080;">4</span> <span style="color:#000000;">        watch.Start();
</span><span style="color:#008080;">5</span> <span style="color:#000000;">        act(arg);
</span><span style="color:#008080;">6</span> <span style="color:#000000;">        watch.Stop();
</span><span style="color:#008080;">7</span> <span style="color:#000000;">        </span><span style="color:#0000ff;">return</span><span style="color:#000000;"> watch.ElapsedMilliseconds;
</span><span style="color:#008080;">8</span> <span style="color:#000000;">}</span></div>
</pre>
<p><!-- Code inserted with Steve Dunn's Windows Live Writer Code Formatter Plugin.  http://dunnhq.com --></p>
</div>
<p>This Watch function is totally decoupled with the Action, which could be &quot;reading the data from database&quot;, or &quot;processing the data from a file&quot;. It leads a clean design that Watch function and the Action function can be tested separately.</p>
<p>2. Parallel programming. If you have been worked on Multi-thread programming. You know how hard it is. The limitation of imperative language like C# focuses on the state change. But functional programming is passing function as argument as we mentioned above. The state actually is only closed in the function boundary. So there is no other thread can access that data. Microsoft has released <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=e848dc1d-5be3-4941-8705-024bc7f180ba&amp;displaylang=en">PLINQ</a>, a parallel programming add-on to current .NET framework 3.5. It will be a huge benefit for any .NET who will take advantage of multi-processor computers.</p>
<p>So far, so good, right? from next one, I will illustrate the functional programming features in C# 3.0. Definitely will show more code. Please stay tune.</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/liangwu.wordpress.com/66/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/liangwu.wordpress.com/66/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/liangwu.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/liangwu.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/liangwu.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/liangwu.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/liangwu.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/liangwu.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/liangwu.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/liangwu.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/liangwu.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/liangwu.wordpress.com/66/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=66&subd=liangwu&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://liangwu.wordpress.com/2008/01/22/functional-programming-in-c-3-0-1/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/ef7572a12f8c9796fc7d604d6bd0476a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">liangwu</media:title>
		</media:content>
	</item>
		<item>
		<title>Create DTO with NHibernate</title>
		<link>http://liangwu.wordpress.com/2007/03/13/create-dto-with-nhibernate/</link>
		<comments>http://liangwu.wordpress.com/2007/03/13/create-dto-with-nhibernate/#comments</comments>
		<pubDate>Tue, 13 Mar 2007 15:16:37 +0000</pubDate>
		<dc:creator>liangwu</dc:creator>
				<category><![CDATA[DDD]]></category>
		<category><![CDATA[NHibernate]]></category>

		<guid isPermaLink="false">http://liangwu.wordpress.com/2007/03/13/create-dto-with-nhibernate/</guid>
		<description><![CDATA[My previous blog is about using DTO in UI/Presenter layers. Just studying Nhibernate source code now, I find a very interesting approach to populate DTO object directly from Nhibernate with Criteria and Projections.
Here is the code:

   1:  IList resultWithAliasedBean = s.CreateCriteria(typeof(Enrolment))
   2:   .CreateAlias("Student", "st")
   3:  [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=19&subd=liangwu&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>My <a href="http://liangwu.wordpress.com/2007/02/13/dto-data-transfer-object-in-domain-driven-design/?csspreview=true">previous blog</a> is about using DTO in UI/Presenter layers. Just studying Nhibernate source code now, I find a very interesting approach to populate DTO object directly from Nhibernate with Criteria and Projections.<br />
Here is the code:</p>
<div class="csharpcode">
<pre><span class="lnum">   1:  </span>IList resultWithAliasedBean = s.CreateCriteria(<span class="kwrd">typeof</span>(Enrolment))</pre>
<pre><span class="lnum">   2:  </span> .CreateAlias(<span class="str">"Student"</span>, <span class="str">"st"</span>)</pre>
<pre><span class="lnum">   3:  </span> .CreateAlias(<span class="str">"Course"</span>, <span class="str">"co"</span>)</pre>
<pre><span class="lnum">   4:  </span> .SetProjection(Projections.ProjectionList()</pre>
<pre><span class="lnum">   5:  </span> .Add(Projections.Property(<span class="str">"st.Name"</span>), <span class="str">"studentName"</span>)</pre>
<pre><span class="lnum">   6:  </span> .Add(Projections.Property(<span class="str">"co.Description"</span>), <span class="str">"courseDescription"</span>)</pre>
<pre><span class="lnum">   7:  </span>)</pre>
<pre><span class="lnum">   8:  </span>.AddOrder(Order.Desc(<span class="str">"studentName"</span>))</pre>
<pre><span class="lnum">   9:  </span>.SetResultTransformer(NHibernate.Transform.Transformers
  10.  .AliasToBean(<span class="kwrd">typeof</span>(StudentDTO)))</pre>
<pre><span class="lnum">  11:  </span>.List();</pre>
</div>
<p>The Element and StudentDTO is simple enough.</p>
<div class="csharpcode">
<pre><span class="lnum">   1:  </span>        [Serializable]</pre>
<pre><span class="lnum">   2:  </span>    <span class="kwrd">public</span> <span class="kwrd">class</span> Enrolment</pre>
<pre><span class="lnum">   3:  </span></pre>
<pre><span class="lnum">   4:  </span>        <span class="kwrd">private</span> Student student;</pre>
<pre><span class="lnum">   5:  </span>        <span class="kwrd">public</span> <span class="kwrd">virtual</span> Student Student</pre>
<pre><span class="lnum">   6:  </span>        {</pre>
<pre><span class="lnum">   7:  </span>            get { <span class="kwrd">return</span> student; }</pre>
<pre><span class="lnum">   8:  </span>            set { student = <span class="kwrd">value</span>; }</pre>
<pre><span class="lnum">   9:  </span>        }</pre>
<pre><span class="lnum">  10:  </span></pre>
<pre><span class="lnum">  11:  </span>        <span class="kwrd">private</span> Course course;</pre>
<pre><span class="lnum">  12:  </span>        <span class="kwrd">public</span> <span class="kwrd">virtual</span> Course Course</pre>
<pre><span class="lnum">  13:  </span>        {</pre>
<pre><span class="lnum">  14:  </span>            get { <span class="kwrd">return</span> course; }</pre>
<pre><span class="lnum">  15:  </span>            set { course = <span class="kwrd">value</span>; }</pre>
<pre><span class="lnum">  16:  </span>        }</pre>
<pre><span class="lnum">  17:  </span></pre>
<pre><span class="lnum">  18:  </span>        <span class="kwrd">private</span> <span class="kwrd">long</span> studentNumber;</pre>
<pre><span class="lnum">  19:  </span>        <span class="kwrd">public</span> <span class="kwrd">virtual</span> <span class="kwrd">long</span> StudentNumber</pre>
<pre><span class="lnum">  20:  </span>        {</pre>
<pre><span class="lnum">  21:  </span>            get { <span class="kwrd">return</span> studentNumber; }</pre>
<pre><span class="lnum">  22:  </span>            set { studentNumber = <span class="kwrd">value</span>; }</pre>
<pre><span class="lnum">  23:  </span>        }</pre>
<pre><span class="lnum">  24:  </span></pre>
<pre><span class="lnum">  25:  </span>        <span class="kwrd">private</span> <span class="kwrd">string</span> courseCode = <span class="kwrd">string</span>.Empty;</pre>
<pre><span class="lnum">  26:  </span>        <span class="kwrd">public</span> <span class="kwrd">virtual</span> <span class="kwrd">string</span> CourseCode</pre>
<pre><span class="lnum">  27:  </span>        {</pre>
<pre><span class="lnum">  28:  </span>            get { <span class="kwrd">return</span> courseCode; }</pre>
<pre><span class="lnum">  29:  </span>            set { courseCode = <span class="kwrd">value</span>; }</pre>
<pre><span class="lnum">  30:  </span>        }</pre>
<pre><span class="lnum">  31:  </span></pre>
<pre><span class="lnum">  32:  </span>        <span class="kwrd">private</span> <span class="kwrd">short</span> year;</pre>
<pre><span class="lnum">  33:  </span>        <span class="kwrd">public</span> <span class="kwrd">virtual</span> <span class="kwrd">short</span> Year</pre>
<pre><span class="lnum">  34:  </span>        {</pre>
<pre><span class="lnum">  35:  </span>            get { <span class="kwrd">return</span> year; }</pre>
<pre><span class="lnum">  36:  </span>            set { year = <span class="kwrd">value</span>; }</pre>
<pre><span class="lnum">  37:  </span>        }</pre>
<pre><span class="lnum">  38:  </span></pre>
<pre><span class="lnum">  39:  </span>        <span class="kwrd">private</span> <span class="kwrd">short</span> semester;</pre>
<pre><span class="lnum">  40:  </span>        <span class="kwrd">public</span> <span class="kwrd">virtual</span> <span class="kwrd">short</span> Semester</pre>
<pre><span class="lnum">  41:  </span>        {</pre>
<pre><span class="lnum">  42:  </span>            get { <span class="kwrd">return</span> semester; }</pre>
<pre><span class="lnum">  43:  </span>            set { semester = <span class="kwrd">value</span>; }</pre>
<pre><span class="lnum">  44:  </span>        }</pre>
<pre><span class="lnum">  45:  </span></pre>
<pre><span class="lnum">  46:  </span>        <span class="kwrd">public</span> <span class="kwrd">override</span> <span class="kwrd">bool</span> Equals(<span class="kwrd">object</span> obj)</pre>
<pre><span class="lnum">  47:  </span>        {</pre>
<pre><span class="lnum">  48:  </span>            Enrolment that = obj <span class="kwrd">as</span> Enrolment;</pre>
<pre><span class="lnum">  49:  </span>            <span class="kwrd">if</span> (that == <span class="kwrd">null</span>)</pre>
<pre><span class="lnum">  50:  </span>                <span class="kwrd">return</span> <span class="kwrd">false</span>;</pre>
<pre><span class="lnum">  51:  </span>            <span class="kwrd">return</span> studentNumber == that.StudentNumber &amp;&amp; courseCode.Equals(that.CourseCode);</pre>
<pre><span class="lnum">  52:  </span>        }</pre>
<pre><span class="lnum">  53:  </span></pre>
<pre><span class="lnum">  54:  </span>        <span class="kwrd">public</span> <span class="kwrd">override</span> <span class="kwrd">int</span> GetHashCode()</pre>
<pre><span class="lnum">  55:  </span>        {</pre>
<pre><span class="lnum">  56:  </span>            <span class="kwrd">return</span> courseCode.GetHashCode();</pre>
<pre><span class="lnum">  57:  </span>        }</pre>
<pre><span class="lnum">  58:  </span>    }</pre>
<pre><span class="lnum">  59:  </span><span class="kwrd">public</span> <span class="kwrd">class</span> StudentDTO</pre>
<pre><span class="lnum">  60:  </span>    {</pre>
<pre><span class="lnum">  61:  </span>        <span class="kwrd">private</span> <span class="kwrd">string</span> studentName;</pre>
<pre><span class="lnum">  62:  </span>        <span class="kwrd">private</span> <span class="kwrd">string</span> courseDescription;</pre>
<pre><span class="lnum">  63:  </span></pre>
<pre><span class="lnum">  64:  </span>        <span class="kwrd">public</span> StudentDTO() { }</pre>
<pre><span class="lnum">  65:  </span></pre>
<pre><span class="lnum">  66:  </span>        <span class="kwrd">public</span> <span class="kwrd">string</span> Name</pre>
<pre><span class="lnum">  67:  </span>        {</pre>
<pre><span class="lnum">  68:  </span>            get { <span class="kwrd">return</span> studentName; }</pre>
<pre><span class="lnum">  69:  </span>        }</pre>
<pre><span class="lnum">  70:  </span></pre>
<pre><span class="lnum">  71:  </span>        <span class="kwrd">public</span> <span class="kwrd">string</span> Description</pre>
<pre><span class="lnum">  72:  </span>        {</pre>
<pre><span class="lnum">  73:  </span>            get { <span class="kwrd">return</span> courseDescription; }</pre>
<pre><span class="lnum">  74:  </span>        }</pre>
<pre><span class="lnum">  75:  </span>    }</pre>
</div>
<p>What we can do is to retrieve StudentDTO from Presenter by querying from <a href="http://www.martinfowler.com/eaaCatalog/repository.html">Repository</a>. Code is elegant and beautiful. How sexy NHibernate is!!</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/liangwu.wordpress.com/19/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/liangwu.wordpress.com/19/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/liangwu.wordpress.com/19/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/liangwu.wordpress.com/19/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/liangwu.wordpress.com/19/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/liangwu.wordpress.com/19/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/liangwu.wordpress.com/19/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/liangwu.wordpress.com/19/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/liangwu.wordpress.com/19/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/liangwu.wordpress.com/19/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/liangwu.wordpress.com/19/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/liangwu.wordpress.com/19/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=19&subd=liangwu&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://liangwu.wordpress.com/2007/03/13/create-dto-with-nhibernate/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/ef7572a12f8c9796fc7d604d6bd0476a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">liangwu</media:title>
		</media:content>
	</item>
		<item>
		<title>DTO (Data Transfer Object) in Domain Driven Design</title>
		<link>http://liangwu.wordpress.com/2007/02/13/dto-data-transfer-object-in-domain-driven-design/</link>
		<comments>http://liangwu.wordpress.com/2007/02/13/dto-data-transfer-object-in-domain-driven-design/#comments</comments>
		<pubDate>Tue, 13 Feb 2007 14:03:21 +0000</pubDate>
		<dc:creator>liangwu</dc:creator>
				<category><![CDATA[Architecture]]></category>
		<category><![CDATA[DDD]]></category>

		<guid isPermaLink="false">http://liangwu.wordpress.com/2007/03/13/dto-data-transfer-object-in-domain-driven-design/</guid>
		<description><![CDATA[DTO (Data Transfer Object)is a very common used pattern in enterprise applications. Martin Fowler also documented it in his class book &#8220;Pattern Enterprise Application Architecture&#8220;. In the meanwhile, DTO is also a very famous &#8220;Anti-Pattern&#8221;.  The pure OO purist think DTO is a devil. It is so easy to build. The object become nothing [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=7&subd=liangwu&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>DTO (<a href="http://en.wikipedia.org/wiki/DTO">Data Transfer Object</a>)is a very common used pattern in enterprise applications. Martin Fowler also documented <a href="http://martinfowler.com/eaaCatalog/dataTransferObject.html">it</a> in his class book &#8220;<a href="http://www.amazon.com/Patterns-Enterprise-Application-Architecture-Martin/dp/0321127420/sr=8-1/qid=1170910861/ref=pd_bbs_sr_1/102-7899207-7706513?ie=UTF8&amp;s=books">Pattern Enterprise Application Architecture</a>&#8220;. In the meanwhile, DTO is also a very famous &#8220;Anti-Pattern&#8221;.  The pure OO purist think DTO is a devil. It is so easy to build. The object become nothing but a simple data container, which represent the data in the tables instead of the real domain objects. The business logic embedded in the application is going to shift from middle domain logic tier to tables, most of time spreaded among the stored procedures, which is leading to a unmaintainable solution.</p>
<p>So should we give up DTO totally in our application design? Absolutely not, in the other end, I find DTO still useful especially in UI and UI process layers. For example, we have a complex searching page to find customer by first name, last name, SSN, address, phone, email, and so on. those information may stay in different domain objects. It is also very hard to design a method with a very long list of parameters, not just ugly but also unmaintainable. My approach is to design DTO object pass data between UI and UI process (Presenter or Controller). Then access the service objects, and domain objects from presenter/controller. So I can design domain entity with the interfere from the special requirement of UI. Again it is important to implement MVP pattern to protect the domain object, which is also one of the important principles I heard from DDD: don&#8217;t leak business logic out of the domain object layer.</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/liangwu.wordpress.com/7/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/liangwu.wordpress.com/7/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/liangwu.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/liangwu.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/liangwu.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/liangwu.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/liangwu.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/liangwu.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/liangwu.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/liangwu.wordpress.com/7/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/liangwu.wordpress.com/7/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/liangwu.wordpress.com/7/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=7&subd=liangwu&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://liangwu.wordpress.com/2007/02/13/dto-data-transfer-object-in-domain-driven-design/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/ef7572a12f8c9796fc7d604d6bd0476a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">liangwu</media:title>
		</media:content>
	</item>
		<item>
		<title>Astronaut Pen</title>
		<link>http://liangwu.wordpress.com/2007/02/09/astronaut-pen/</link>
		<comments>http://liangwu.wordpress.com/2007/02/09/astronaut-pen/#comments</comments>
		<pubDate>Fri, 09 Feb 2007 14:02:56 +0000</pubDate>
		<dc:creator>liangwu</dc:creator>
		
		<guid isPermaLink="false">http://liangwu.wordpress.com/2007/03/13/astronaut-pen/</guid>
		<description><![CDATA[I read a story today which make me falling into deep thinking&#8230;
&#8220;During the space race back in the 1960&#8217;s, NASA was faced with a major problem. The astronaut needed a pen that would write in the vacuum of space. NASA went to work. At a cost of $1.5 million they developed the &#8220;Astronaut Pen&#8221;. Some [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=6&subd=liangwu&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>I read a story today which make me falling into deep thinking&#8230;</p>
<p>&#8220;During the space race back in the 1960&#8217;s, NASA was faced with a major problem. The astronaut needed a pen that would write in the vacuum of space. NASA went to work. At a cost of $1.5 million they developed the &#8220;Astronaut Pen&#8221;. Some of you may remember. It enjoyed minor success on the commercial market.</p>
<p>The Russians were faced with the same dilemma. They used a pencil. &#8220;</p>
<p>from <a href="http://www.snopes.com/business/genius/spacepen.asp">here</a>.</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/liangwu.wordpress.com/6/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/liangwu.wordpress.com/6/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/liangwu.wordpress.com/6/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/liangwu.wordpress.com/6/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/liangwu.wordpress.com/6/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/liangwu.wordpress.com/6/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/liangwu.wordpress.com/6/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/liangwu.wordpress.com/6/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/liangwu.wordpress.com/6/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/liangwu.wordpress.com/6/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/liangwu.wordpress.com/6/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/liangwu.wordpress.com/6/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=6&subd=liangwu&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://liangwu.wordpress.com/2007/02/09/astronaut-pen/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/ef7572a12f8c9796fc7d604d6bd0476a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">liangwu</media:title>
		</media:content>
	</item>
		<item>
		<title>How to implement Domain model (object) in DDD?</title>
		<link>http://liangwu.wordpress.com/2007/01/10/how-to-implement-domain-model-object-in-ddd/</link>
		<comments>http://liangwu.wordpress.com/2007/01/10/how-to-implement-domain-model-object-in-ddd/#comments</comments>
		<pubDate>Wed, 10 Jan 2007 14:03:33 +0000</pubDate>
		<dc:creator>liangwu</dc:creator>
				<category><![CDATA[Architecture]]></category>
		<category><![CDATA[DDD]]></category>

		<guid isPermaLink="false">http://liangwu.wordpress.com/2007/03/13/how-to-implement-domain-model-object-in-ddd/</guid>
		<description><![CDATA[Inspired by Eric Even&#8217;s excellent book, Domain Driven Design,
I have been studying and using domain driven design for a while. There have a lot of advantages offered by implementing DDD in enterprise applications. I will continue to blog what I learned from DDD later. Among those advantage, one of the most important is to clearly [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=8&subd=liangwu&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>Inspired by Eric Even&#8217;s excellent book, Domain Driven Design,<br />
I have been studying and using domain driven design for a while. There have a lot of advantages offered by implementing DDD in enterprise applications. I will continue to blog what I learned from DDD later. Among those advantage, one of the most important is to clearly lay out the resposibilites for the classs in the doma layer, such as Entity, Value Object, Service, Repository and Fractory. There has a question always in my mind that if we have move application operations to service class. What methods we need to implement for Entity class? We are trying to avoid <a href="http://www.martinfowler.com/bliki/AnemicDomainModel.html">AnemicDomainModel</a>. So how do we design our Entity class? Here comes the answer:</p>
<blockquote><p>&#8220;The best definition of &#8220;domain object&#8221; I&#8217;ve found in literature is in Chapter<br />
11 of <a href="http://c2.com/cgi/wiki?TimHoward">TimHoward</a>&#8217;s book <a href="http://c2.com/cgi/wiki?TheSmalltalkDevelopersGuideToVisualWorks">TheSmalltalkDevelopersGuideToVisualWorks</a><br />
pp.379-381:</p>
<p>&#8220;a domain object is a logical container of purely domain<br />
information, usually represents a logical entity in the problem domain space &#8230;<br />
In general, domain objects should know how to<br />
recognize which [of their]<br />
references indicate aggregation and which ones indicate association<br />
copy<br />
themselves<br />
maintain business logic<br />
compare themselves to other domain<br />
objects of the same type<br />
facilitate other objects that choose to print or<br />
display them<br />
conduct tests on their domain information&#8221;<br />
To this list I<br />
would add<br />
identify themselves<br />
validate themselves<br />
&#8211;<a href="http://c2.com/cgi/wiki?RandyStafford">RandyStafford</a><br />
I would also<br />
add<br />
domain objects direct their persistence<br />
there may be collections of<br />
Domain objects<br />
domain object may contain references to other domain objects<br />
(this is assumed by the first one above).<br />
&#8211;Fritz Schenk &#8220;</p></blockquote>
<p><span style="font-family:courier new;font-size:85%;">Quote from <a href="http://c2.com/cgi/wiki?DomainObject">http://c2.com/cgi/wiki?DomainObject</a></span></p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/liangwu.wordpress.com/8/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/liangwu.wordpress.com/8/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/liangwu.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/liangwu.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/liangwu.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/liangwu.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/liangwu.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/liangwu.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/liangwu.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/liangwu.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/liangwu.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/liangwu.wordpress.com/8/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=8&subd=liangwu&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://liangwu.wordpress.com/2007/01/10/how-to-implement-domain-model-object-in-ddd/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/ef7572a12f8c9796fc7d604d6bd0476a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">liangwu</media:title>
		</media:content>
	</item>
		<item>
		<title>NAnt tip</title>
		<link>http://liangwu.wordpress.com/2006/11/22/nant-tip/</link>
		<comments>http://liangwu.wordpress.com/2006/11/22/nant-tip/#comments</comments>
		<pubDate>Wed, 22 Nov 2006 15:18:07 +0000</pubDate>
		<dc:creator>liangwu</dc:creator>
				<category><![CDATA[Auto Build]]></category>

		<guid isPermaLink="false">http://liangwu.wordpress.com/2006/11/22/nant-tip/</guid>
		<description><![CDATA[Currntly I am working on a NAnt script to update all of our open source project source. Basically I need to use checkout and update taskes for SVN and CVS. Using and is smooth, if you have the lastest Subversion (currently 1.4.2) installed . But and  will cause issues since it seems that cannot [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=24&subd=liangwu&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>Currntly I am working on a NAnt script to update all of our open source project source. Basically I need to use checkout and update taskes for SVN and CVS. Using and is smooth, if you have the lastest Subversion (currently 1.4.2) installed . But and  will cause issues since it seems that cannot work nicely with . I got a problem that I cannot successfully login to the server. After done some research, here is the workaround.<br />
1. Dowonload the lastest CVSNT.<br />
2. Put cvs.exe into the Nant bin folder.<br />
3. Turn attribute &#8220;usesharpcvslib&#8221; to false.<br />
Example:</p>
<p><a href="http://liangwu.files.wordpress.com/2007/03/nantsample.png" title="nantsample.png"><img src="http://liangwu.files.wordpress.com/2007/03/nantsample.png" alt="nantsample.png" /></a></p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/liangwu.wordpress.com/24/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/liangwu.wordpress.com/24/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/liangwu.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/liangwu.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/liangwu.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/liangwu.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/liangwu.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/liangwu.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/liangwu.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/liangwu.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/liangwu.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/liangwu.wordpress.com/24/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=24&subd=liangwu&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://liangwu.wordpress.com/2006/11/22/nant-tip/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/ef7572a12f8c9796fc7d604d6bd0476a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">liangwu</media:title>
		</media:content>

		<media:content url="http://liangwu.files.wordpress.com/2007/03/nantsample.png" medium="image">
			<media:title type="html">nantsample.png</media:title>
		</media:content>
	</item>
		<item>
		<title>Best posts from Jeremy Miller</title>
		<link>http://liangwu.wordpress.com/2006/08/08/best-posts-from-jeremy-miller/</link>
		<comments>http://liangwu.wordpress.com/2006/08/08/best-posts-from-jeremy-miller/#comments</comments>
		<pubDate>Tue, 08 Aug 2006 14:03:45 +0000</pubDate>
		<dc:creator>liangwu</dc:creator>
				<category><![CDATA[Agile]]></category>
		<category><![CDATA[TDD]]></category>

		<guid isPermaLink="false">http://liangwu.wordpress.com/2007/03/13/best-posts-from-jeremy-miller/</guid>
		<description><![CDATA[Jeremy has organized his best posts in the last three years. Please check it out frm there. I think I have learned a lot from Jeremy&#8217;s postes. Great stuff include MVP pattern, TDD (Test-Driven Development), Mock Object, Depencency Injection, and so on. Every single post from his is worth reading. By the way, just happen [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=9&subd=liangwu&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>Jeremy has organized his best posts in the last three years. Please check it out frm <a href="http://codebetter.com/blogs/jeremy.miller/archive/2006/08/07/148071.aspx">there</a>. I think I have learned a lot from Jeremy&#8217;s postes. Great stuff include MVP pattern, TDD (Test-Driven Development), Mock Object, Depencency Injection, and so on. Every single post from his is worth reading. By the way, just happen to know he is goint to write a book. It must be a MUST READ.</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/liangwu.wordpress.com/9/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/liangwu.wordpress.com/9/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/liangwu.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/liangwu.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/liangwu.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/liangwu.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/liangwu.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/liangwu.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/liangwu.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/liangwu.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/liangwu.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/liangwu.wordpress.com/9/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=9&subd=liangwu&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://liangwu.wordpress.com/2006/08/08/best-posts-from-jeremy-miller/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/ef7572a12f8c9796fc7d604d6bd0476a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">liangwu</media:title>
		</media:content>
	</item>
		<item>
		<title>Data Transfer Object (DTO) in MVP pattern</title>
		<link>http://liangwu.wordpress.com/2006/08/02/data-transfer-object-dto-in-mvp-pattern/</link>
		<comments>http://liangwu.wordpress.com/2006/08/02/data-transfer-object-dto-in-mvp-pattern/#comments</comments>
		<pubDate>Wed, 02 Aug 2006 14:05:24 +0000</pubDate>
		<dc:creator>liangwu</dc:creator>
				<category><![CDATA[Architecture]]></category>
		<category><![CDATA[DDD]]></category>

		<guid isPermaLink="false">http://liangwu.wordpress.com/2007/03/13/data-transfer-object-dto-in-mvp-pattern/</guid>
		<description><![CDATA[Jean-Paul Boodhoo from ThoughtWorks has published an excellent article regarding how to implement MVP (Model-View-Presenter) pattern in ASP.NET. It acutally has very similar implementation I am using currently. The only difference is I declear event in the view, so that ASP.NET page use event to notify the presenters, which makes more loosely coupled between ASP.NE [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=10&subd=liangwu&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p><a href="http://www.jpboodhoo.com/blog/default.aspx">Jean-Paul Boodhoo </a>from ThoughtWorks has published an excellent <a href="http://msdn.microsoft.com/msdnmag/issues/06/08/DesignPatterns/default.aspx">article</a> regarding how to implement MVP (Model-View-Presenter) pattern in ASP.NET. It acutally has very similar implementation I am using currently. The only difference is I declear event in the view, so that ASP.NET page use event to notify the presenters, which makes more loosely coupled between ASP.NE page and presenter. I also use DTO (Data Transfer Object) to pass the data through. Although DTO seems as a <a href="http://java.sun.com/blueprints/corej2eepatterns/Patterns/TransferObject.html">Core J2EE Pattern</a>, I still have a concern to use it extensively, becasue DTO is totally against the Object-Oriented principals. It promotes a FLAT object, a really value object. Since I have developed my domain objects with <a href="http://www.hibernate.org/343.html">NHibernate</a>/<a href="http://www.castleproject.org/index.php/ActiveRecord">Castle ActiveRecord</a>, it duplicates the efforts as well. The main purpose of using DTO is to utilize the ASP.NET databinding features. Paul Wilson seems to work on a solution to map domain objects to UI. It seesm very intertesting. But I have not seen any sample code yet. Anybody has a better solution?</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/liangwu.wordpress.com/10/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/liangwu.wordpress.com/10/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/liangwu.wordpress.com/10/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/liangwu.wordpress.com/10/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/liangwu.wordpress.com/10/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/liangwu.wordpress.com/10/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/liangwu.wordpress.com/10/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/liangwu.wordpress.com/10/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/liangwu.wordpress.com/10/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/liangwu.wordpress.com/10/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/liangwu.wordpress.com/10/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/liangwu.wordpress.com/10/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=liangwu.wordpress.com&blog=807949&post=10&subd=liangwu&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://liangwu.wordpress.com/2006/08/02/data-transfer-object-dto-in-mvp-pattern/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/ef7572a12f8c9796fc7d604d6bd0476a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">liangwu</media:title>
		</media:content>
	</item>
	</channel>
</rss>