<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Wed, 22 May 2013 16:47:46 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Wojciech Sznapka: Is Symfony2 a MVC framework?]]></title>
      <guid>http://www.phpdeveloper.org/news/18696</guid>
      <link>http://www.phpdeveloper.org/news/18696</link>
      <description><![CDATA[<p>
In his latest post <i>Wojciech Sznapka</i> wonders if <a href="http://blog.sznapka.pl/is-symfony2-a-mvc-framework/">Symfony2 is actually MVC</a> or if it's just the "C" and "V" in the equation with the "M" (Model) layer being left wide open.
</p>
<blockquote>
The question is: where is Model layer in Symfony2? My answer is: there's ain't one and it's good.. Symfony2 isn't hardly bounded with Model layer, as it could have been seen in first version. We can see many Active Record model implementations in modern web frameworks such as Ruby on Rails, Django and symfony 1. I'm not saying those solutions are bad. The main problem was, that big systems maintained by plenty of developers changing over time tends to have a messy codebase. The common place to locate business logic were Model layer. The result of that approach were huge model classes, randomly structured Table/Peer classes full of static method and general feeling that system is hardly impossible to maintain anymore.
</blockquote>
<p>
He talks about the main problem that comes from this style of coding - overly complex systems - and one possible way to help mitigate them using domain-driven design practices. He lists a few of the things that Symfony2 comes with that could be helpful for this method including the dependency injection container, the use of entities, repositories and value objects.
</p>]]></description>
      <pubDate>Mon, 05 Nov 2012 10:18:44 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Nicolas B&eacute;rard-Nault's Blog: The unknown value of Value Objects]]></title>
      <guid>http://www.phpdeveloper.org/news/16131</guid>
      <link>http://www.phpdeveloper.org/news/16131</link>
      <description><![CDATA[<p>
<i>Nicolas B&eacute;rard-Nault</i> has put together a new post looking at the role that Value Objects play in application development and, more specifically, how they fit in with domain driven design (DDD). He looks to explain the <a href="http://nicobn.wordpress.com/2011/03/29/the-unknown-value-of-value-objects/">unknown value of Value Objects</a> to developers that might not know how helpful they really can be.
</p>
<blockquote>
One of the main rules of DDD is that value objects are immutable. This is often not as self-evident as it seems, as many programmers are not even aware of the state they leak and create. Sadly, state is often positively correlated with entropy. Hence, taking steps to contain and to limit state is one of the keys to taming complexity in an application.
</blockquote>
<p>
He notes that even outside of DDD Value Objects can be quite useful. He gives an example of a "RationalNumber" class with methods for basic things like addition and subtraction. He shows the more traditional mutable version that most developers would start with and uses it in several examples to show its flaws. He finishes up the post with a look at the "more correct" immutable version of the class and a sample call that would result in the correct output of a simple matematical operation.
</p>]]></description>
      <pubDate>Thu, 31 Mar 2011 12:12:46 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Bradley Holt's Blog: Immutable Value Objects in PHP]]></title>
      <guid>http://www.phpdeveloper.org/news/15217</guid>
      <link>http://www.phpdeveloper.org/news/15217</link>
      <description><![CDATA[<p>
<i>Bradley Holt</i> has a new post to his blog about a subject he's recently been learning about, Domain-Driven Design, and how <a href="http://bradley-holt.com/2010/09/immutable-value-objects-in-php/">immutable value objects could be useful in PHP</a>.
</p>
<blockquote>
Yesterday I <a href="http://twitter.com/BradleyHolt/status/25911903352">tweeted</a>: Modern object-oriented programming languages need support for immutable Value Objects. #DDD The "DDD" in that tweet stands for <a href="http://en.wikipedia.org/wiki/Domain-driven_design">Domain-Driven Design</a>. There were several interesting responses to this tweet.
</blockquote>
<p>
Responses to his tweet included comments from <a href="http://paste2.org/p/1009796">Matthew Weier O'Phinney</a>, <a href="http://gist.github.com/603496">Ralph Schindler</a>, <a href="http://twitter.com/nicolasbn/status/25942269645">Nicolas Berard-Nault</a> and <a href="http://twitter.com/giorgiosironi/status/25914287997">Giorgio Sironi</a>. He notes that, while all of the suggestions are good, they're only half of the issue. They make it immutable when defined but not during execution. Currently PHP lacks this functionality, but something like this could be worked in with the concept of a "final" class.
</p>]]></description>
      <pubDate>Fri, 01 Oct 2010 11:15:40 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Federico Cargnelutti's Blog: Domain-Driven Design with Zend Framework]]></title>
      <guid>http://www.phpdeveloper.org/news/12195</guid>
      <link>http://www.phpdeveloper.org/news/12195</link>
      <description><![CDATA[<p>
<i>Federico Cargnelutti</i> has posted <a href="http://blog.fedecarg.com/2009/03/22/zend-framework-domain-driven-design/">the latest article</a> in his "domain-driven design" series using the Zend Framework. This time he focuses on putting some of his ideas into practice.
</p>
<blockquote>
Some of the Domain-driven design concepts explained in my previous posts are applied in this sample application. I'm also going to use the Zend Framework infrastructure to speed up some development tasks.
</blockquote>
<p>
His example sets up a domain layer to interface user information for the system from a centralized repository. On top of that he builds his model extended from an abstract class called Zf_Domain_Entity. He also sets up a User collection, a User DAO and the user repository 
</p>]]></description>
      <pubDate>Tue, 24 Mar 2009 10:23:20 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Federico Cargnelutti's Blog: Domain-Driven Design (Series)]]></title>
      <guid>http://www.phpdeveloper.org/news/12151</guid>
      <link>http://www.phpdeveloper.org/news/12151</link>
      <description><![CDATA[<p>
<i>Federico Cargnelutti</i> has been posting a series of articles to his blog recently about domain-driven design, a method for organizing your code for maximum reuse between domains. He focuses on the "M" (model) in the MVC structure (model/view/controller) and how it can be separated out into a layer all its own - the domain layer. Here's the parts of his series so far:
</p>
<ul>
<li><a href="http://blog.fedecarg.com/2009/03/11/domain-driven-design-and-mvc-architectures/">Domain-Driven Design and MVC Architectures</a> - an introduction to the domain-driven concept and some definition of terms that he'll be using.
<li><a href="http://blog.fedecarg.com/2009/03/12/domain-driven-design-and-data-access-strategies/">Domain-Driven Design: Data Access Strategies</a> - a look at some of the different data access methods (like Active Record, Data Transfer Objects and generic Data Access Objects)
<li><a href="http://blog.fedecarg.com/2009/03/15/domain-driven-design-the-repository/">Domain-Driven Design: The Repository</a> - illustrating how the user-created code would interface with a DAO instead of directly working with the database itself. It provides another abstraction layer that is more specific to your current application instance.
</ul>]]></description>
      <pubDate>Tue, 17 Mar 2009 10:22:57 -0500</pubDate>
    </item>
  </channel>
</rss>
