<?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/"
	>

<channel>
	<title>Jamie&#039;s Space</title>
	<atom:link href="http://www.jamiepenney.co.nz/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.jamiepenney.co.nz</link>
	<description>Thoughts and Works of a Junior Software Engineer</description>
	<lastBuildDate>Tue, 06 Jul 2010 04:39:48 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Dependency Viewer</title>
		<link>http://www.jamiepenney.co.nz/2010/03/24/dependency-viewer/</link>
		<comments>http://www.jamiepenney.co.nz/2010/03/24/dependency-viewer/#comments</comments>
		<pubDate>Wed, 24 Mar 2010 05:07:35 +0000</pubDate>
		<dc:creator>Jamie</dc:creator>
				<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://jamiepenney.co.nz/?p=69</guid>
		<description><![CDATA[A while back I posted a quick app I wrote to display dependencies between visual studio projects using GraphViz (here). I&#8217;ve done a bit more work on it since then, cleaning up the project and adding support for custom processing of the graph elements before they are rendered using extensions. I&#8217;ve also put the project [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: left;">A while back I posted a quick app I wrote to display dependencies between visual studio projects using GraphViz (<a href="http://jamiepenney.co.nz/2009/02/10/viewing-dependencies-between-projects-in-visual-studio/">here</a>). I&#8217;ve done a bit more work on it since then, cleaning up the project and adding support for custom processing of the graph elements before they are rendered using extensions. I&#8217;ve also put the project on GitHub for ease of updating. You can access that here: <a href="http://github.com/jamiepenney/VS-Dependency-Viewer">http://github.com/jamiepenney/VS-Dependency-Viewer</a></p>
<p style="text-align: left;">I&#8217;m going to talk about how the extension mechanism works. It uses the Managed Extension Framework (MEF), which you can read about here: <a href="http://www.codeplex.com/MEF">http://www.codeplex.com/MEF</a>. You don&#8217;t need to know a lot about MEF to write an extension &#8211; in fact you can get away without knowing anything apart from how to download it and which attribute to use on your extension class.</p>
<p style="text-align: left;">To create a custom graph processor, you&#8217;ll need to create a new Class Library project in Visual Studio. This project needs to reference Quickgraph.Graphviz.dll, System.ComponentModel.Composition, and DependencyViewer.Common.dll. The first two you can get from the lib directory in the Dependency Viewer project, and the Common dll you can get by building the DependencyViewer.Common project. Once you&#8217;ve got your project up and running, create a new class that implements DependencyViewer.Common.Interfaces.IGraphProcessor.</p>
<p style="text-align: left;">The IGraphProcessor interface is pretty basic so far. These are the important methods:</p>
<ul style="text-align: left;">
<li>PreProcessGraph
<ul>
<li style="text-align: justify;">This method lets you change formatting options on the graph before the other graph elements are processed. You could use this to set the size, background colour, etc.</li>
</ul>
</li>
<li>ProcessEdge
<ul>
<li>This method lets you change formatting options on a dependency connection after the defaults have been set (there aren&#8217;t any defaults yet though).</li>
</ul>
</li>
<li>ProcessVertex
<ul>
<li>This method lets you change formatting options on a project node after the defaults have been set. By default the Name is set to the name of the project and the shape is set to Ellipse.</li>
</ul>
</li>
</ul>
<p style="text-align: left;">You can have blank implementations of any methods you don&#8217;t need.</p>
<p style="text-align: left;">To get the main application to find your custom graph  processor, you just have to register it as an implementation of  IGraphProcessor by adding the Export attribute to your implementation.  So in this case, you&#8217;d put [Export(typeof(IGraphProcessor))] on your  class.</p>
<p style="text-align: left;">
<p style="text-align: left;">Once you&#8217;ve done that, build your project, copy the dll into the directory where you are running the main application, and then the magic happens. MEF will automatically pick up your implementation when you next render your solution.</p>
<p style="text-align: left;">
<p style="text-align: left;">There is an example implementation in the Dependency Viewer project called TestProjectProcessor. It finds non unit testing projects that reference NHibernate and colours them a different colour, so that you can see what projects refer to your data projects. I got the idea from Melle Koning&#8217;s <a href="http://www.mellekoning.nl/index.php/2010/03/11/project-references-in-ddd">blog post</a> on the subject here.</p>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden; text-align: left;">http://jamiepenney.co.nz/2009/02/10/viewing-dependencies-between-projects-in-visual-studio/</div>
]]></content:encoded>
			<wfw:commentRss>http://www.jamiepenney.co.nz/2010/03/24/dependency-viewer/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>NHibernate and the Repository Pattern</title>
		<link>http://www.jamiepenney.co.nz/2009/12/12/nhibernate-and-the-repository-pattern/</link>
		<comments>http://www.jamiepenney.co.nz/2009/12/12/nhibernate-and-the-repository-pattern/#comments</comments>
		<pubDate>Fri, 11 Dec 2009 20:43:43 +0000</pubDate>
		<dc:creator>Jamie</dc:creator>
				<category><![CDATA[Personal]]></category>
		<category><![CDATA[Unit Testing]]></category>

		<guid isPermaLink="false">http://jamiepenney.co.nz/?p=54</guid>
		<description><![CDATA[I&#8217;ve been writing a small time tracker web application to teach myself ASP.Net MVC, and am using NHibernate as the ORM.  I&#8217;m trying to use best practises while building this app, and one issue I was trying to deal with was whether to build a layer over the top of NHibernate. My first set of [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: left;">I&#8217;ve been writing a small time tracker web application to teach myself <a href="http://www.asp.net/mvc">ASP.Net MVC</a>, and am using NHibernate as the ORM.  I&#8217;m trying to use best practises while building this app, and one issue I was trying to deal with was whether to build a layer over the top of NHibernate. My first set of controller actions used NHibernate directly, with a dependency injected ISessionFactory. This was fine for simple queries (like get Task with id 1) but it meant more and more of my model concerns were leaking into my Controllers. I had thought that NHibernate provided enough of an abstraction over my model for this to not matter, but I was quite wrong.</p>
<p style="text-align: left;">Remembering I had seen some argument over whether using a generic repository was a good idea or not, I started searching around and found quite a few blogs saying it was a bad idea. They made sense, and one blog had a <a href="http://www.noctovis.net/blog/index.php/2009/01/22/my-thoughts-about-irepository/">great solution</a>: Create a Repository&lt;T, U&gt; abstract class for common CRUD style operations, inherit your specific Repository from that, and only expose meaningful methods in your interface to client code. The benefits of this approach are many &#8211; your client code can only see methods that are applicable to each model class, you don&#8217;t have to duplicate your common CRUD operations for each model class, and it is easy as pie to unit test.</p>
<p style="text-align: left;">This last point is the one worth mentioning in my books. The great thing about separation of concerns is it should make things easier to pull apart for unit testing. Because my Repository methods have meaningful names, and are pretty fine grained, my mocking setup looks almost readable. It is immediately obvious from reading my tests that TaskController.List(5) should call ITaskRepository.GetLatestTasks(5). Not only that, but most of the Controller actions have been reduced to &#8220;Get this from Repository, return to View&#8221; or &#8220;Save this thing to the Repository&#8221;. They are small, obvious methods, and that makes them easier to test, and easier to maintain.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamiepenney.co.nz/2009/12/12/nhibernate-and-the-repository-pattern/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Windows 7 Shortcut Keys</title>
		<link>http://www.jamiepenney.co.nz/2009/09/14/windows-7-shortcut-keys/</link>
		<comments>http://www.jamiepenney.co.nz/2009/09/14/windows-7-shortcut-keys/#comments</comments>
		<pubDate>Sun, 13 Sep 2009 23:19:29 +0000</pubDate>
		<dc:creator>Jamie</dc:creator>
				<category><![CDATA[Useful Information]]></category>

		<guid isPermaLink="false">http://jamiepenney.co.nz/?p=45</guid>
		<description><![CDATA[I found a great list of keyboard shortcuts for Windows 7 today here. The best part of this list were the keys for manipulating windows &#8211; Windows + ← (Left Arrow) will dock the window to the left hand side of the screen, much like if you drag the window to the side of the [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: left;">I found a great list of keyboard shortcuts for Windows 7 today <a href="http://www.mydigitallife.info/2009/07/31/windows-7-keyboard-shortcuts-accelerator-keys-or-hotkeys-full-listing/">here</a>. The best part of this list were the keys for manipulating windows &#8211; Windows + ← (Left Arrow) will dock the window to the left hand side of the screen, much like if you drag the window to the side of the screen. The right arrow also works like this.</p>
<p style="text-align: left;">If you have multiple monitors, using the mouse it doesn&#8217;t let you dock to the side connected to the other screen. So you can only dock to the far left and far right with the mouse. Not so with the keyboard. Each time you hit the keyboard combo, it will move it to the next dock position in that direction. That means you can have windows docked all over your extended desktop, like so:</p>
<p style="text-align: left;"><a href="http://jamiepenney.co.nz/wordpress/wp-content/uploads/2009/09/desktop.png"><img class="aligncenter size-medium wp-image-44" style="margin-top: 10px; margin-bottom: 10px;" title="Desktop" src="http://jamiepenney.co.nz/wordpress/wp-content/uploads/2009/09/desktop-300x106.png" alt="Desktop" width="300" height="106" /></a></p>
<p style="text-align: left;">I&#8217;ve got two windows on each screen (as you can see, the right hand screen has the task bar, so you should be able to see where the screens split).</p>
<p style="text-align: left;">This is pretty useful at home. Having huge screens is great, being able to have 4 docked windows without fiddling around with the mouse is fantastic.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamiepenney.co.nz/2009/09/14/windows-7-shortcut-keys/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fun with the Symbian Emulator</title>
		<link>http://www.jamiepenney.co.nz/2009/08/08/fun-with-the-symbian-emulator/</link>
		<comments>http://www.jamiepenney.co.nz/2009/08/08/fun-with-the-symbian-emulator/#comments</comments>
		<pubDate>Sat, 08 Aug 2009 00:52:16 +0000</pubDate>
		<dc:creator>Jamie</dc:creator>
				<category><![CDATA[Mobile Developement]]></category>
		<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://jamiepenney.co.nz/?p=38</guid>
		<description><![CDATA[The other night I stumbled on the PyS60 project, an open source port of the python runtime to Symbian S60 based phones. I own a Nokia N95, and I got kind of excited about this because I would like to mess around with development for it but can&#8217;t bring myself to work with C++ in [...]]]></description>
			<content:encoded><![CDATA[<p>The other night I stumbled on the PyS60 project, an open source port of the python runtime to Symbian S60 based phones. I own a Nokia N95, and I got kind of excited about this because I would like to mess around with development for it but can&#8217;t bring myself to work with C++ in my spare time.</p>
<p>I thought it would be pretty easy to develop for as Python is interpreted, I thought I could just edit text files on the phone and run them to test them out. Turns out you can&#8217;t do that (not easily anyway), you need to package them on your computer, then upload the package to the phone, then install it, then run it. That killed that idea.</p>
<p>I looked at the Symbian emulator, and the PyS60 team have a mod for it that installs the python runtime so you can just run script files on the emulated phone. &#8220;This is great!&#8221; I think, before actually trying it.</p>
<p>For starters, the python runtime doesn&#8217;t work in the emulator when the emulator is running on Windows 7 x64 &#8211; damn. I have a VPC image with Windows XP on it though, so I fire that up, install everything, then try run it. The emulator crashes after about 15 seconds of loading.</p>
<p>After browsing the Nokia forums for a while, I find out the problem. VPC is actually connecting to the virtual machine over RDP, and so the audio drivers are the RDP Remote Audio drivers.</p>
<p>What do audio drivers have to do with a phone emulator I hear you ask? Good question, but it is one the Nokia forum dwellers have no answer for. Many people have complained that the Symbian Emulator does not work when connecting to the machine hosting it via RDP. There are other issues with particular sound card drivers or applications also causing it to crash. This is a prime example of bad error handling. Why, if the audio part of the emulator cannot work with some drivers, does it crash instead of continuing without audio?</p>
<p>So that brought down my plans for making<a href="http://www.wired.com/gadgetlab/2008/12/iphone-fart-app/"> millions of dollars from fart applications</a> for Symbian based phones.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamiepenney.co.nz/2009/08/08/fun-with-the-symbian-emulator/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Strange Visual Studio lockup after debugging</title>
		<link>http://www.jamiepenney.co.nz/2009/07/20/strange-visual-studio-lockup-after-debugging/</link>
		<comments>http://www.jamiepenney.co.nz/2009/07/20/strange-visual-studio-lockup-after-debugging/#comments</comments>
		<pubDate>Mon, 20 Jul 2009 11:03:51 +0000</pubDate>
		<dc:creator>Jamie</dc:creator>
				<category><![CDATA[Useful Information]]></category>

		<guid isPermaLink="false">http://jamiepenney.co.nz/?p=33</guid>
		<description><![CDATA[I had been having an issue with VS 2008 on Windows 7 x64 today. After debugging an application the whole IDE would lock up, minimise itself, then bring itself back to the foreground. This was pretty disruptive and I was getting quite irritated with it, but I could not find any mention of it through [...]]]></description>
			<content:encoded><![CDATA[<p>I had been having an issue with VS 2008 on Windows 7 x64 today. After debugging an application the whole IDE would lock up, minimise itself, then bring itself back to the foreground. This was pretty disruptive and I was getting quite irritated with it, but I could not find any mention of it through Google.</p>
<p>I did happen to stumble upon a StackOverflow question (<a href="http://stackoverflow.com/questions/126472/how-to-stop-right-click-dead-locking-visual-studio-2008/344323#344323">here</a>) where a different problem was outlined, however this answer reminded me of an issue Scott Hanselman had with an app he was doing a demo with, so I thought I would give it the fix a shot. Strangely enough, I think it has fixed it, although I am not sure why (it seems unrelated). Anyway, here is the fix, just in case anyone else has a similar problem:</p>
<p><strong>Fix:</strong><br />
Disable checking of Publisher&#8217;s Certificate Revocation</p>
<ol>
<li>Go to Internet Options in Internet Explorer or Control Panel</li>
<li>Then go the Security Tab, scroll towards the bottom</li>
<li>Uncheck the &#8216;Check for Publisher&#8217;s Certificate Revocation&#8217;  checkbox</li>
<li>Click OK.</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://www.jamiepenney.co.nz/2009/07/20/strange-visual-studio-lockup-after-debugging/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>New Monitor</title>
		<link>http://www.jamiepenney.co.nz/2009/07/13/new-monitor/</link>
		<comments>http://www.jamiepenney.co.nz/2009/07/13/new-monitor/#comments</comments>
		<pubDate>Mon, 13 Jul 2009 10:20:35 +0000</pubDate>
		<dc:creator>Jamie</dc:creator>
				<category><![CDATA[Contracting]]></category>
		<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://jamiepenney.co.nz/2009/07/13/new-monitor/</guid>
		<description><![CDATA[Today I got a new 24&#8243; Samsung T240 for my office at home. I&#8217;ve been working from home a lot recently and have really been missing my dual monitor setup from work, even though it is only my laptop with an old 17&#8243; LCD. Two monitors definitely make a big difference to my productivity when [...]]]></description>
			<content:encoded><![CDATA[<p>Today I got a new 24&#8243; Samsung T240 for my office at home. I&#8217;ve been working from home a lot recently and have really been missing my dual monitor setup from work, even though it is only my laptop with an old 17&#8243; LCD. Two monitors definitely make a big difference to my productivity when coding. I already had a 22&#8243; Samsung 226BW, which now looks thoroughly inadequate next to the 24&#8243; as you can see from the photo below.</p>
<div id="attachment_27" class="wp-caption alignnone" style="width: 624px"><img class="size-large wp-image-27 " title="Desk" src="http://jamiepenney.co.nz/wordpress/wp-content/uploads/2009/07/13072009079-1024x768.jpg" alt="My New Desk Arrangement" width="614" height="461" /><p class="wp-caption-text">My New Desk Arrangement</p></div>
<p>Once I got used to the larger monitor I had a pretty productive day though. The T240 is a decent monitor for developing on, judging from one day&#8217;s usage. Text is clear, and after a little tweaking the colour looked about right, enough for my purposes anyway. Not to mention it is a nice looking monitor. All in all, it was well worth the money I/the business spent on it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamiepenney.co.nz/2009/07/13/new-monitor/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Twitter, or How I Learned to Stop Worrying and Love Short Messages</title>
		<link>http://www.jamiepenney.co.nz/2009/02/10/twitter-or-how-i-learned-to-stop-worrying-and-love-short-messages/</link>
		<comments>http://www.jamiepenney.co.nz/2009/02/10/twitter-or-how-i-learned-to-stop-worrying-and-love-short-messages/#comments</comments>
		<pubDate>Tue, 10 Feb 2009 07:10:00 +0000</pubDate>
		<dc:creator>Jamie</dc:creator>
				<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://65.99.219.219/wordpress/?p=23</guid>
		<description><![CDATA[Today I took a bold step, swallowed a chunk of my pride, and signed up for Twitter. I&#8217;m not usually a big fan of Social Networking, but Twitter is slightly different. For starters, I don&#8217;t think any of my friends are using it. Secondly, There&#8217;s no real &#34;profile&#34; like you get from Facebook or others. [...]]]></description>
			<content:encoded><![CDATA[<p>Today I took a bold step, swallowed a chunk of my pride, and signed up for <a href="http://www.twitter.com">Twitter</a>. I&#8217;m not usually a big fan of Social Networking, but Twitter is slightly different. For starters, I don&#8217;t think any of my friends are using it. Secondly, There&#8217;s no real &quot;profile&quot; like you get from Facebook or others.</p>
<p>I got the idea from <a href="http://ayende.com/Blog/Default.aspx">Ayende&#8217;s blog</a>, kindof. His blog is quite interesting to watch, because it is made up of lots of small updates. It almost seems like more of a note taking system than a blog sometimes, in a good way. For myself, I tend not to write blog posts because they take a little longer than I&#8217;m willing to give during the day to write, so Twitter&#8217;s 140 character limit could work for me. It&#8217;s just a trial anyway, if it doesn&#8217;t work out I&#8217;ll dump it.</p>
<p>So how I think I&#8217;ll work now is: Post short messages to Twitter like reminders, helpful hints, and status updates, and post longer information like information about side projects and interesting topics on my blog.</p>
<p>If anyone wants to follow me on twitter, here&#8217;s my page: <a href="http://twitter.com/jamiepenney">http://twitter.com/jamiepenney</a>. Be aware that there will be a bit more personal stuff there, my blog so far has just been technical but I&#8217;ll probably use Twitter for personal and work messages.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamiepenney.co.nz/2009/02/10/twitter-or-how-i-learned-to-stop-worrying-and-love-short-messages/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ook Interpreter, Written in C# and F#</title>
		<link>http://www.jamiepenney.co.nz/2009/02/10/ook-interpreter-written-in-c-and-f/</link>
		<comments>http://www.jamiepenney.co.nz/2009/02/10/ook-interpreter-written-in-c-and-f/#comments</comments>
		<pubDate>Tue, 10 Feb 2009 07:06:00 +0000</pubDate>
		<dc:creator>Jamie</dc:creator>
				<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://65.99.219.219/wordpress/?p=22</guid>
		<description><![CDATA[Another little short side project I worked on over the weekend was an interpreter for Ook, an odd little language &#8220;designed for Orangutans&#8221;. It only has a few syntax elements and 8 different statements so I figured it would be a fun use of my basic F# skills (I&#8217;ve been reading Fundamentals of F# and [...]]]></description>
			<content:encoded><![CDATA[<p>Another little short side project I worked on over the weekend was an interpreter for <a href="http://www.dangermouse.net/esoteric/ook.html">Ook</a>, an odd little language &#8220;designed for Orangutans&#8221;. It only has a few syntax elements and 8 different statements so I figured it would be a fun use of my basic F# skills (I&#8217;ve been reading Fundamentals of F# and Expert F# on Safari Books through work). Using the example files on <a href="http://bluesorcerer.net/esoteric/ook.html">bluesorcerer.net</a> as test files, I successfully got it running in half a day. I can&#8217;t say it is the fastest or most efficient interpreter for Ook, but it is my first interpreter so it was a learning experience. If you have any questions or comments on how I implemented it, please feel free to add them below.</p>
<p>Enough talk, here&#8217;s the GitHub project: <a href="http://github.com/jamiepenney/ook-sharp">http://github.com/jamiepenney/ook-sharp</a></p>
<p>You&#8217;ll need the latest <a href="http://www.microsoft.com/downloads/details.aspx?familyid=61ad6924-93ad-48dc-8c67-60f7e7803d3c&amp;displaylang=en">F# CTP</a> installed to open this project in Visual Studio 2008.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamiepenney.co.nz/2009/02/10/ook-interpreter-written-in-c-and-f/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Viewing Dependencies Between Projects in Visual Studio</title>
		<link>http://www.jamiepenney.co.nz/2009/02/10/viewing-dependencies-between-projects-in-visual-studio/</link>
		<comments>http://www.jamiepenney.co.nz/2009/02/10/viewing-dependencies-between-projects-in-visual-studio/#comments</comments>
		<pubDate>Tue, 10 Feb 2009 07:03:00 +0000</pubDate>
		<dc:creator>Jamie</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://65.99.219.219/wordpress/?p=21</guid>
		<description><![CDATA[A while ago there was a question on Stack Overflow about how one could go about mapping the dependencies between Visual Studio projects and solutions (see here: http://stackoverflow.com/questions/471154/how-can-i-map-out-which-visual-studio-solutions-use-which-projects). At the time I had been doing a little bit of work with GraphViz, and suggested that it could be used for the diagramming part. The problem [...]]]></description>
			<content:encoded><![CDATA[<p>A while ago there was a question on <a href="http://www.stackoverflow.com/">Stack Overflow</a> about how one could go about mapping the dependencies between Visual Studio projects and solutions (see here: <a title="http://stackoverflow.com/questions/471154/how-can-i-map-out-which-visual-studio-solutions-use-which-projects" href="http://stackoverflow.com/questions/471154/how-can-i-map-out-which-visual-studio-solutions-use-which-projects">http://stackoverflow.com/questions/471154/how-can-i-map-out-which-visual-studio-solutions-use-which-projects</a>). At the time I had been doing a little bit of work with GraphViz, and suggested that it could be used for the diagramming part. The problem itself seemed kind of interesting, so I decided to implement a solution myself for kicks.</p>
<p>My tool takes a visual studio solution, and produces a PNG image showing the dependencies between the projects in that solution. Pretty basic stuff, but it involves:</p>
<ol>
<li>Parsing a Visual Studio .sln file.</li>
<li>Parsing the .csproj files referenced in the .sln file. (I don&#8217;t think it is C# specific but have not tested it on other project types).</li>
<li>Creating an in memory representation of the solution structure.</li>
<li>Creating a graph in QuickGraph to represent that structure.</li>
<li>Creating a dot file for GraphViz from that graph.</li>
<li>Pass that file to GraphViz and display the output.</li>
</ol>
<p>This results in something like this:</p>
<p><img style="display: inline; border-width: 0px;" title="dv_output" src="http://lh4.ggpht.com/_TGyXpQbgdXc/SZ0EV6bDodI/AAAAAAAAABs/edRz8Pgnrbg/dv_output%5B5%5D.png?imgmax=800" border="0" alt="dv_output" width="314" height="168" /></p>
<p><span style="text-decoration: line-through;">The source code is <a href="https://sites.google.com/a/jamiepenney.co.nz/files/Home/DependencyViewerSource.zip?attredirects=0">here</a>. </span></p>
<p><em>Updated</em>: I&#8217;ve put this project on GitHub, and added Melle&#8217;s changes to it. You can find it <a href="http://github.com/jamiepenney/VS-Dependency-Viewer">here</a>.</p>
<p>Feel free to do what you like with it, it only took me about 3-4 hours to get it all working. However if you actually use it as part of another project, please leave a comment.</p>
<p>You&#8217;ll need the latest version of GraphViz, which can be downloaded from here: <a href="http://graphviz.org/Download_windows.php">http://graphviz.org/Download_windows.php</a>. I&#8217;ve been using the development snapshot, but the stable release should be fine. When my tool first runs, it&#8217;ll ask you for the location of graphviz. You need to specify the location of dot.exe, which by default is in %Program Files%\GraphViz 2.21\bin.</p>
<p>Standard disclaimer: I&#8217;m not responsible for anything that goes wrong when using this thing. You have the source, you should check it out before running it. If it wipes your system and kills your firstborn child feel free to let me know, but don&#8217;t expect me to do anything about it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamiepenney.co.nz/2009/02/10/viewing-dependencies-between-projects-in-visual-studio/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>TechEd 08 &#8211; Day 3</title>
		<link>http://www.jamiepenney.co.nz/2008/09/04/teched-08-day-3/</link>
		<comments>http://www.jamiepenney.co.nz/2008/09/04/teched-08-day-3/#comments</comments>
		<pubDate>Thu, 04 Sep 2008 07:01:00 +0000</pubDate>
		<dc:creator>Jamie</dc:creator>
				<category><![CDATA[Useful Information]]></category>

		<guid isPermaLink="false">http://65.99.219.219/wordpress/?p=20</guid>
		<description><![CDATA[DEV375: Reactive Programming &#8211; Ivan Towlson History of developing for windows clients Win16/Win32 &#8211; Procedural style (message loops) ActiveX/Visual Basic &#8211; Limited OO style, events + components Windows Forms &#8211; Component oriented style Common themes Write code to copy data from model to control Write code to detect changes in control data Write code to [...]]]></description>
			<content:encoded><![CDATA[<h3>DEV375: Reactive Programming &#8211; Ivan Towlson</h3>
<ul>
<li>History of developing for windows clients
<ul>
<li>Win16/Win32 &#8211; Procedural style (message loops) </li>
<li>ActiveX/Visual Basic &#8211; Limited OO style, events + components </li>
<li>Windows Forms &#8211; Component oriented style </li>
<li>Common themes
<ul>
<li>Write code to copy data from model to control </li>
<li>Write code to detect changes in control data </li>
<li>Write code to copy data from control to model </li>
<li>Detect changes in model data or use gatekeeper </li>
</ul>
</li>
</ul>
</li>
<li>What is better about WPF/Silverlight?
<ul>
<li>Enhanced component model encapsulates common plumbing. </li>
<li>Designer-developer workflow needs a declarative programming style to work well. </li>
<li>Hard to write robust OO/procedural code against a lookless model. </li>
</ul>
</li>
<li>Reactive programming is like binding values together. Think like how you can create formula&#8217;s in Excel &#8211; changing the value of one of the cells in a formula updates the result of the formula, and it keeps doing it. </li>
<li>Benefits
<ul>
<li>Remove plumbing code, no need to track changes in model and controls and copy data between </li>
<li>View/model relationship expressed in view instead of in controller/presenter code. Express the what, not the how. </li>
<li>Works well with the lookless approach &#8211; view reacts to model change, rather than the model manipulating the view. </li>
</ul>
</li>
<li>.Net works on a notification system (INotifyPropertyChanged) &#8211; when something changes, dependent values re-evaluate themselves. </li>
<li>Issues
<ul>
<li>We need to react to changes to derived data -&gt; use converters for this. </li>
<li>A reactive expression may produce unacceptable values (user input?). Solution is to use validation. </li>
</ul>
</li>
</ul>
<p>Bindable LINQ</p>
<ul>
<li>How do you query an ObservableCollection? How do you observably query an ObservableCollection? </li>
<li>LINQ queries don&#8217;t provide change notification! </li>
<li>Bindable LINQ is a community project to enable reactive controls to back easily onto LINQ queries </li>
<li>Key API : AsBindable() &#8211; extension method on IEnumerable&lt;T&gt; </li>
</ul>
<h3>SEC201: Do These Ten Things or Get Own3d &#8211; Steve Riley</h3>
<h4>1. Use precise terminology</h4>
<ul>
<li>Vulnerability &#8211; The problem
<ul>
<li>Code </li>
<li>Configuration </li>
<li>Circumvention &#8211; Security rules that are so draconian that they encourage people to actively try to get around it. </li>
</ul>
</li>
<li>Threat &#8211; The person that carries out the attack
<ul>
<li>External </li>
<li>Internal </li>
</ul>
</li>
<li>Exploit &#8211; the code that exploits the vulnerability </li>
<li>Exposure &#8211; The cost of the attack being carried out. </li>
<li>Risk </li>
</ul>
<h4>2. Accept that no one will like you</h4>
<h4>3. Think like a bad guy</h4>
<p>People will not like you for this either.</p>
<h4>4. Understand the science</h4>
<ul>
<li>Identity is not Authentication. </li>
<li>Encryption is not Integrity </li>
<li>Inspection is not Intent &#8211; Can&#8217;t tell intent by looking at someone&#8217;s stuff. </li>
<li>Secrecy is not Trust &#8211; just because you can make something a secret, doesn&#8217;t mean you can trust it. </li>
<li>People are not Technology &#8211; All the technology in the world will not solve your technology problem. </li>
<li>&quot;Defence in depth&quot; = &quot;I am a parrot&quot; </li>
<li>Stupidity is not Malice </li>
<li>Usability and Security are a tradeoff. </li>
</ul>
<h4>5. Protect your gear</h4>
<ul>
<li>Patch your stuff. </li>
<li>Use the firewall. </li>
<li>Don&#8217;t run as admin, or reduce number of admins. </li>
<li>Install anti-malware, or scan fileshares. </li>
<li>Don&#8217;t tweak. </li>
<li>Rebuild, don&#8217;t disinfect. </li>
</ul>
<h4>6. Swallow your pride</h4>
<ul>
<li>Read up
<ul>
<li>Microsoft </li>
<li><a href="http://www.sans.org">www.sans.org</a> </li>
<li><a href="http://www.securityfocus.com">www.securityfocus.com</a> </li>
<li><a href="http://searchsecurity.techtarget.com">http://searchsecurity.techtarget.com</a> </li>
</ul>
</li>
</ul>
<h4>7. Reconsidering the laws</h4>
<ul>
<li>Law 1: If a bad guy can persuade you to run his program on your computer, it is not yours anymore. </li>
<li>Law 2: If a bad guy can alter the operating system on your computer, it&#8217;s not yours anymore. </li>
<li>Law 3: If a bad guy has unrestricted physical access to your computer, it&#8217;s not your computer anymore. </li>
<li>Law 4: If you allow a bad guy to upload programs to your website, it&#8217;s not your website anymore. </li>
<li>Law 5: Weak passwords trump strong security. </li>
<li>Law 6: A computer is only as secure as the administrator is trustworthy. </li>
<li>Law 7: Encrypted data is only as secure as the decryption key. </li>
<li>Law 8: An out of date is <strike>only marginally better</strike> worse than no virus scanner at all. </li>
<li>Law 9: Absolute anonymity isn&#8217;t practical, in real life or on the web. </li>
<li>Law 10: Technology is not a panacea. </li>
</ul>
<h4>8. Classify, and classify again.</h4>
<ul>
<li>Access
<ul>
<li>Principle of least privilege &#8211; others and yourself. If this principle interferes with your business process and is part of the OS, email Steve. </li>
</ul>
</li>
<li>Data
<ul>
<li>Confidentiality, retention, recovery. </li>
</ul>
</li>
<li>Trust
<ul>
<li>Functions, directions. </li>
</ul>
</li>
</ul>
<h4>9. Don&#8217;t let your guard down.</h4>
<ul>
<li>People are always trying to sell you silver bullets/snake oil. </li>
<li>Trustworthy people will discuss the downsides of their software </li>
</ul>
<h4>10. Protection, not restriction.</h4>
]]></content:encoded>
			<wfw:commentRss>http://www.jamiepenney.co.nz/2008/09/04/teched-08-day-3/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
