<?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>Evolving Software &#187; interfaces</title>
	<atom:link href="http://evolving-software.co.uk/blog/tag/interfaces/feed/" rel="self" type="application/rss+xml" />
	<link>http://evolving-software.co.uk/blog</link>
	<description>General tidbits about Domain Driven Design and TrueView</description>
	<lastBuildDate>Tue, 06 Dec 2011 21:29:29 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=abc</generator>
		<item>
		<title>Update to DomainTypes library</title>
		<link>http://evolving-software.co.uk/blog/2010/02/20/update-to-domaintypes-library/</link>
		<comments>http://evolving-software.co.uk/blog/2010/02/20/update-to-domaintypes-library/#comments</comments>
		<pubDate>Sat, 20 Feb 2010 13:18:24 +0000</pubDate>
		<dc:creator>Vijay</dc:creator>
				<category><![CDATA[New releases]]></category>
		<category><![CDATA[c# library]]></category>
		<category><![CDATA[domaintypes]]></category>
		<category><![CDATA[interfaces]]></category>
		<category><![CDATA[source code]]></category>

		<guid isPermaLink="false">http://evolving-software.co.uk/blog/?p=350</guid>
		<description><![CDATA[The initial release of DomainTypes was heavily influenced by the existing TrueView framework.  After spending much time working with a current client, it&#8217;s clear that a more &#8216;POCO&#8217; approach has significantly more benefits. Based on my findings (and questions over at StackOverflow), here are the major changes: Refined and enhanced most of the interfaces Removed [...]]]></description>
			<content:encoded><![CDATA[<p>The initial release of <em>DomainTypes</em> was heavily influenced by the existing TrueView framework.  After spending much time working with a current client, it&#8217;s clear that a more &#8216;POCO&#8217; approach has significantly more benefits.</p>
<p>Based on my findings (and <a href="http://stackoverflow.com/questions/tagged/domain-driven-design">questions over at StackOverflow</a>), here are the major changes:</p>
<ul>
<li>Refined and enhanced most of the interfaces</li>
<li>Removed the concept of <strong>persistent</strong> and <strong>transient</strong> classes</li>
<li><strong>Domain Services</strong> and <strong>Application Services</strong> have explicit interfaces</li>
<li>Domain Objects no longer implement <strong>IDependencyAware</strong></li>
<li>Removed the <strong>ITrackable</strong> interface</li>
</ul>
<p>I&#8217;ve also added more examples to clarify how you might use the interfaces.</p>
<p>You can <a href="http://evolving-software.co.uk/downloads/DomainTypes.zip">download the code here</a>.  All comments are welcome.</p>
<p><strong>P.S.</strong> Note that this library is <strong>NOT </strong>compatible with the current TrueView framework.  Watch this space for the new version!</p>
<div id="_mcePaste" style="overflow: hidden; position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px;">http://evolving-software.co.uk/blog/wp-admin/post-new.php</div>
]]></content:encoded>
			<wfw:commentRss>http://evolving-software.co.uk/blog/2010/02/20/update-to-domaintypes-library/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Domain Types &#8211; Interfaces</title>
		<link>http://evolving-software.co.uk/blog/2009/11/24/domain-types-interfaces/</link>
		<comments>http://evolving-software.co.uk/blog/2009/11/24/domain-types-interfaces/#comments</comments>
		<pubDate>Tue, 24 Nov 2009 18:20:30 +0000</pubDate>
		<dc:creator>Vijay</dc:creator>
				<category><![CDATA[Useful info]]></category>
		<category><![CDATA[ddd]]></category>
		<category><![CDATA[domaintypes]]></category>
		<category><![CDATA[download]]></category>
		<category><![CDATA[interfaces]]></category>
		<category><![CDATA[library]]></category>
		<category><![CDATA[source code]]></category>

		<guid isPermaLink="false">http://evolving-software.co.uk/blog/?p=313</guid>
		<description><![CDATA[In the last post, I published the DomainTypes library: a set of .NET interfaces &#38; base classes to provide the building blocks for DDD (source code included). In this post I&#8217;ll describe the interfaces and supporting design decisions. IDomainObject Represents any type of object within the Domain model. Currently this is simply used as a [...]]]></description>
			<content:encoded><![CDATA[<p>In the <a href="http://evolving-software.co.uk/blog/2009/11/19/free-net-type-library-for-domain-driven-design-source-code/">last post</a>, I published the <a href="http://evolving-software.co.uk/downloads/DomainTypes.zip">DomainTypes library</a>: a set of .NET interfaces &amp; base classes to provide the building blocks for DDD (source code included).</p>
<p>In this post I&#8217;ll describe the interfaces and supporting design decisions.</p>
<h3>IDomainObject</h3>
<p>Represents any type of object within the Domain model. Currently this is simply used as a marker, signalling to developers that the implementation has DDD semantics.</p>
<h3>IEntity</h3>
<p>Represents a unique Entity within the system.  The <strong>ID </strong>property is used to identify the instance during it&#8217;s lifetime.  Using a GUID allows identity to be established without having to talk to a persistence store (i.e. database).</p>
<h3>IValueObject</h3>
<p>Represents a non-unique object within the system.  Note that it&#8217;s an object, and not a struct.  Structs may seem like a better semantic fit with DDD, but too many instances can cause memory problems (structs &#8211; like value types &#8211; are created on the stack).</p>
<div>The <strong>Clone() </strong>method is used to create copies.  The implementing class can decide whether to create new instances, or use the <em>FlyWeight</em> pattern.</div>
<h3>IList&lt;T&gt;</h3>
<p>Represents a list of Domain Objects.  It&#8217;s crucial that the implementing class raises events <em>before </em>items are added or removed from the list.  This allows consumer code to execute any domain rules, and cancel the action if necessary.</p>
<h3>IEvent</h3>
<p>This is one that <a href="http://domaindrivendesign.org/library/evans_2009_1">Eric Evans mentioned earlier this year</a>.  It is used to record &amp; identify <strong>domain events</strong>, and must be immutable. For example, a child&#8217;s birth should be captured, be identifiable, but never modified.</p>
<h3>IAggregateRoot</h3>
<p>Most people understand Aggregate Roots as a cluster of closely associated entities.  However, there are 2 additional concerns that an Aggregate Root has:</p>
<ol>
<li>It knows how to validate the entire aggregate</li>
<li>It is used to lock it&#8217;s contents in a multi-user environment</li>
</ol>
<p>The <strong>IsConsistent()</strong> method is a placeholder for all rules/invariants that apply to the aggregate.  The locking concerns are handled by<strong> IRepository&lt;T&gt; </strong>(see below).</p>
<h3>IFactory&lt;T&gt;</h3>
<p>Used to create Domain Objects/Entities/Aggregate Roots that are complex to build.  Only use factories when the code within your constructors becomes unweildy.</p>
<h3>IRepository&lt;T&gt;</h3>
<p>Used as a facade to a persistence store.  Strictly speaking, repositories should only deal with Aggregate Roots &#8211; to access other entities you would navigate through the Aggregate.</p>
<p>In addition to the typical <strong>Load()</strong>/<strong>Save()</strong>/<strong>Delete() </strong>methods, I&#8217;ve also included <strong>Lock()</strong> and <strong>Unlock</strong>() methods.  This is a crucial function in a multi-user system, and should be considered when designing your Aggregates.</p>
<h3>IService</h3>
<p>Currently this is simply used as a marker.  Only consider using Services if :</p>
<ol>
<li>Try as you might, <em>you can&#8217;t decide</em> on which Domain Object to place your logic</li>
<li>The logic requires the use of several unassociated Domain Objects</li>
<li>You&#8217;re communicating with another module/tier/component</li>
</ol>
<p>The remaining interfaces aren&#8217;t DDD specific, but are to aid real-world implementations.  I&#8217;ll discuss those in the near future.</p>
<p><a href="http://evolving-software.co.uk/downloads/DomainTypes.zip">Download the source code</a></p>
]]></content:encoded>
			<wfw:commentRss>http://evolving-software.co.uk/blog/2009/11/24/domain-types-interfaces/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

