<?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>MIH SWAT &#187; oo</title>
	<atom:link href="http://www.mihswat.com/tag/oo/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.mihswat.com</link>
	<description>MIH SWAT - the official blog of MIH's Strategic Worldwide Applications and Technology Team.</description>
	<lastBuildDate>Mon, 06 Sep 2010 10:24:26 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Vacancies at SWAT</title>
		<link>http://www.mihswat.com/2009/11/03/vacancies-at-swat/</link>
		<comments>http://www.mihswat.com/2009/11/03/vacancies-at-swat/#comments</comments>
		<pubDate>Tue, 03 Nov 2009 11:27:04 +0000</pubDate>
		<dc:creator>Jacques van Niekerk</dc:creator>
				<category><![CDATA[Design]]></category>
		<category><![CDATA[SWAT]]></category>
		<category><![CDATA[Semantic web]]></category>
		<category><![CDATA[Technical]]></category>
		<category><![CDATA[Web 2.0]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[AJAX]]></category>
		<category><![CDATA[architects]]></category>
		<category><![CDATA[architecture]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[developers]]></category>
		<category><![CDATA[digital TV]]></category>
		<category><![CDATA[geeks]]></category>
		<category><![CDATA[html]]></category>
		<category><![CDATA[IP-TV]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Microsoft .Net]]></category>
		<category><![CDATA[oo]]></category>
		<category><![CDATA[REST]]></category>
		<category><![CDATA[Sao Paulo]]></category>
		<category><![CDATA[SOAP]]></category>
		<category><![CDATA[Social Graph]]></category>
		<category><![CDATA[Twitter]]></category>
		<category><![CDATA[uml]]></category>
		<category><![CDATA[VOD]]></category>
		<category><![CDATA[Zend Framework]]></category>

		<guid isPermaLink="false">http://www.mihswat.com/?p=977</guid>
		<description><![CDATA[Would you like to work at SWAT ? We have a few positions vacant at the moment &#8211; have a look: In Sao Paulo, Brazil &#8211; we need a junior front-end developer. You are highly skilled in front-end development, with specific skills in CSS, HTML and Javascript. You are a competent programmer, but you prefer [...]]]></description>
			<content:encoded><![CDATA[<p>Would you like to work at SWAT ?<span id="more-977"></span></p>
<p>We have a few positions vacant at the moment &#8211; have a look:</p>
<p>In Sao Paulo, Brazil &#8211; we need a<strong> junior front-end developer</strong>. You are highly skilled in front-end development, with specific skills in CSS, HTML and Javascript. You are a competent programmer, but you prefer to work on the front-end. You will be working under the guidance of an experienced and expert engineer.  You like working with bright and clever people, and you are passionate about the web. The successful candidate will speak English, and will be a paulistano, or be willing to relocate to Sao Paulo.</p>
<p>In Johannesburg &#8211; we are looking for a <strong>senior technical architect</strong>. You will have the opportunity to establish the blueprint and create the framework for truly cutting edge media delivery platforms that will change the face of media in South Africa. And that is no exaggeration. You should have outstanding technical skills, including the ability to code as and when required. You must be able to interact with a team of highly skilled professionals. You will ideally have experience of VOD, digital TV, IP-TV and related technologies. A background as a developer is essential &#8211; you will have in-depth knowledge of the Microsoft .Net platform, but also wider knowledge of open source platforms and languages. You are comfortable dealing with executives and senior managers. You&#8217;re not only an ubergeek, but also an inspirational tech leader. This is a challenging position &#8211; but it represents a massive opportunity to the right person. Detailed requirements <a href="http://www.mihswat.com/wp-content/uploads/2009/11/Lead-Architect1.pdf">here.</a></p>
<p>In Cape Town &#8211; we are looking for a <strong>junior tester</strong>, who will devote a great deal of time to ensuring that a large corporate social network meets the right quality standards. You will be part of the SWAT core team &#8211; you must be prepared to work with some of the best developers, architects, geeks and web-heads you are ever likely to meet. Can you execute tasks on your own initiative, prepare and execute test plans ? More details on the position can be found <a href="http://www.mihswat.com/wp-content/uploads/2009/11/Junior-Tester.pdf">here. </a></p>
<p>Cape Town &#8211; we are looking for someone to play the role of <strong>Internet Evangelist</strong>. This role is available to anyone who is absolutely passionate about the web, who is capable of conveying this passion to diverse audiences, who learns quickly &#8230; and who can teach others. Your role will be to evangelise the use of Web technologies (and other Internet related technologies) into the larger group &#8211; the challenge is to make people from all non-internet businesses see the Internet as an opportunity not a threat. In addition you will perform tasks as assistant community manager for the corporate social network, and you will assist the Analyst in the team with research tasks. You must be willing to travel in South Africa and abroad, as required. To apply for this job, you will have to demonstrate passion, interest and knowledge of the Web and related technologies. You are a well-spoken, confident geek, web-head and proud to be a Web addict. </p>
<p>Finally, and also in Cape Town &#8211; we want to recruit a <strong>PHP developer</strong>. You will be have outstanding technical skills, wide experience in web based development, and you will be able to hold your own amongst an elite group of developers and architects. Javascript, Zend Framework, AJAX, OO, Web 2.0, REST, SOAP and UML will be old news to you. You are passionate about the web. If you think Twitter is silly, you don&#8217;t need to apply. More information <a href="http://www.mihswat.com/wp-content/uploads/2009/11/PHP-Developer1.pdf">here.</a></p>
<p>If you are interested in any of these positions, please send your CV to <a href="mailto:mkoch@mihinternet.com">Melanie Koch</a>. We look forward to hearing from you.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mihswat.com/2009/11/03/vacancies-at-swat/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Dependency Inversion: Killing Gorillas and Butterflies</title>
		<link>http://www.mihswat.com/2008/10/21/dependency-inversion-killing-gorillas-and-butterflies/</link>
		<comments>http://www.mihswat.com/2008/10/21/dependency-inversion-killing-gorillas-and-butterflies/#comments</comments>
		<pubDate>Tue, 21 Oct 2008 10:05:15 +0000</pubDate>
		<dc:creator>Otavio Ferreira</dc:creator>
				<category><![CDATA[development]]></category>
		<category><![CDATA[architecture]]></category>
		<category><![CDATA[dependency]]></category>
		<category><![CDATA[object]]></category>
		<category><![CDATA[oo]]></category>
		<category><![CDATA[oop]]></category>
		<category><![CDATA[software]]></category>
		<category><![CDATA[technique]]></category>

		<guid isPermaLink="false">http://www.mihswat.com/?p=309</guid>
		<description><![CDATA[In a previous post we met object orientation’s worst enemy (i.e. strong, unplanned dependencies among classes). It is now time to have a closer look at Dependency Inversion, which is one of the most efficient OOP techniques available with which to fight our adversary.Our aim with this discussion is to avoid having the already discussed [...]]]></description>
			<content:encoded><![CDATA[<p>In a previous post we met <a href="http://www.mihswat.com/2008/10/14/the-object-orientations-worst-enemy/" target="_self">object orientation’s worst enemy</a> (i.e. strong, unplanned dependencies among classes). It is now time to have a closer look at <em>Dependency Inversion</em>, which is one of the most efficient <a href="http://en.wikipedia.org/wiki/Object-oriented_programming" target="_self">OOP</a> techniques available with which to fight our adversary.<span id="more-309"></span>Our aim with this discussion is to avoid having the already discussed Domino Effect, Butterfly Effect, and Banana-Gorilla Effect. Please refer to the <a href="http://www.mihswat.com/2008/10/14/the-object-orientations-worst-enemy/" target="_self">initial article</a> if you are unfamiliar with these concepts. The following concrete example makes use of <a href="http://uml.org/" target="_self">UML</a>, and addresses a real-case scenario within the e-commerce domain.</p>
<p><a href="http://www.mihswat.com/wp-content/uploads/2008/10/diagram1.gif"><img class="alignnone size-medium wp-image-323" title="diagram1" src="http://www.mihswat.com/wp-content/uploads/2008/10/diagram1.gif" alt="" width="288" height="48" /></a></p>
<p>Obviously, the schema presented here is just part of a complete software architecture &#8211; for the purposes of this discussion we assume that all orders issued are stored in a <a href="http://en.wikipedia.org/wiki/Relational_database" target="_self">relational database</a> instance (<a href="http://www.mysql.com/" target="_self">MySQL</a> more specifically). The natural way of thinking leads the architect to model a dependency from Order to MySQL, mainly because the former class is the one responsible for deciding when database transactions begin. However, the resulting dependency leads to at least three undesirable consequences, as follows:</p>
<ul>
<li><strong>Business objects and rules start depending on purely technical matters such as database manipulation.</strong> We all know that what is cutting-edge technology at the moment, is likely to become obsolete in a few month&#8217;s time. Business concepts, on the other hand, tend towards stability &#8211; an order will always be an order, potentially keeping the same attributes in the long-run. It’s important to notice that the undesirable direction of the dependency may force the developers to change business objects whenever the database technology they are using changes.</li>
<li><strong>The architecture assumes that storage will always be handled by a specific relational database.</strong> This is a risky assumption, since the development team may decide to swap out the database provider. Moreover, alternative storage mechanisms like the file system itself may come up as a viable option in the future.</li>
<li><strong>Unit testing becomes painful.</strong> This sort of dependency makes it difficult to use the <a href="http://en.wikipedia.org/wiki/Mock_object" target="_self">mock objects</a> technique, which is quite common within <a href="http://en.wikipedia.org/wiki/Unit_testing" target="_self">unit testing</a> methods.</li>
</ul>
<p>We can address these issues by placing an interface between the classes, and therefore inverting the related dependency. As demonstrated below, we have just succeeded in decoupling storage manipulation from business objects.</p>
<p><a href="http://www.mihswat.com/wp-content/uploads/2008/10/diagram2.gif"><img class="alignnone size-medium wp-image-324" title="diagram2" src="http://www.mihswat.com/wp-content/uploads/2008/10/diagram2-300x37.gif" alt="" width="300" height="37" /></a></p>
<p>The dependency inversion technique has addressed all the problems we identified. People usually think of an interface as just a simple set of common functions, but it’s not. Instead, a strategically applied interface contributes desirable outcomes such as mobility, flexibility, reusability, and maintainability.</p>
<p>OK, but wait a minute, the business object <em>Order</em> still needs to send messages to the data access layer, doesn’t it? Yes, it does, but interfaces do not exist at runtime, only objects do. Therefore, IStorage is replaced by an object defined by a class that realizes this interface, the MySQL class in our example. It’s now clear that we could also have realizations to other database providers and storage mechanisms (<a href="http://www.oracle.com/technology/software/products/database/" target="_self">Oracle</a>, <a href="http://www.microsoft.com/sqlserver/" target="_self">MSSQL</a>, <a href="http://www.postgresql.org/" target="_self">PostgreSQL</a>, and File System).</p>
<p>Visualizing the dependency inversion is even easier when we deal with components, instead of classes. The first <a href="http://en.wikipedia.org/wiki/Component_diagram" target="_self">component diagram</a> below does <span style="text-decoration: underline;">not</span> take advantage of the technique we just learned.</p>
<p><a href="http://www.mihswat.com/wp-content/uploads/2008/10/diagram3.gif"><img class="alignnone size-medium wp-image-325" title="diagram3" src="http://www.mihswat.com/wp-content/uploads/2008/10/diagram3-300x107.gif" alt="" width="300" height="107" /></a></p>
<p>Unlikely the previous diagram, the following schema turns over the dependency between the components, making the business component independent, and enabling new data providers.</p>
<p><a href="http://www.mihswat.com/wp-content/uploads/2008/10/diagram4.gif"><img class="alignnone size-medium wp-image-326" title="diagram4" src="http://www.mihswat.com/wp-content/uploads/2008/10/diagram4-300x192.gif" alt="" width="300" height="192" /></a></p>
<p>The <a href="http://en.wikipedia.org/wiki/Black_box" target="_self">black-box notation</a> makes things even clearer:</p>
<p><a href="http://www.mihswat.com/wp-content/uploads/2008/10/diagram5.gif"><img class="alignnone size-medium wp-image-327" title="diagram5" src="http://www.mihswat.com/wp-content/uploads/2008/10/diagram5.gif" alt="" width="288" height="48" /></a></p>
<p>Again, the dependency inversion:</p>
<p><a href="http://www.mihswat.com/wp-content/uploads/2008/10/diagram6.gif"><img class="alignnone size-medium wp-image-328" title="diagram6" src="http://www.mihswat.com/wp-content/uploads/2008/10/diagram6.gif" alt="" width="288" height="56" /></a></p>
<p>Techniques such as the one presented by this post prevent the <a href="http://en.wikipedia.org/wiki/Active_record_pattern">Active Record</a> pattern from being a complete failure. Now I bet you realize how powerful dependency inversion is, right? So back to your dashboard and take your interfaces to the next level!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mihswat.com/2008/10/21/dependency-inversion-killing-gorillas-and-butterflies/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
