I just read a nice blog entry from Segio Bossa giving an example of the DDD Specification pattern. I wanted to keep his article in here so I could reference it in the future.
Following the specification discussion, in his book, Eric explores the Specification pattern more in depth and analyze the possibilities of doing composite Specifications. Then I remembered something I saw a while back on the Apache Commons project. The org.apache.commons.collections package (I wonder why is it there?) has a Predicate interface that fit's nicely with these concepts. Instead of a .isSatifiedBy() method you are given a evaluate(object) method.
I haven't really explored the idea in code by you could inherit a specifications interface and use the supplied AndPredicate, NotPredicate, etc to make composite Specifications.
Friday, February 17, 2006
DDD Specification pattern
Subscribe to:
Post Comments (Atom)
3 comments:
Very good idea Roni, I've elaborated your thoughts in my blog:
http://sbtourist.blogspot.com/2006/02/implementing-specifications-with.html
Take a look if you care.
Regards!
Sergio B.
This is the link ;)
Hello! Good forum roniburd.blogspot.com! Thank you!
hydrocodone
http://www11.asphost4free.com/tramadolrx/Tramadol.html tramadol [url=http://www11.asphost4free.com/tramadolrx/Tramadol.html]tramadol[/url]
Post a Comment