<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments for Pivotal Labs</title>
	<atom:link href="http://pivotallabs.com/comments/feed/" rel="self" type="application/rss+xml" />
	<link>http://pivotallabs.com</link>
	<description>Agility Developed</description>
	<lastBuildDate>Fri, 24 May 2013 19:39:53 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
	<item>
		<title>Comment on Method Modeling: A Refactoring by Russen Guggemos</title>
		<link>http://pivotallabs.com/method-modeling-a-refactoring/#comment-31306</link>
		<dc:creator>Russen Guggemos</dc:creator>
		<pubDate>Fri, 24 May 2013 19:39:53 +0000</pubDate>
		<guid isPermaLink="false">http://pivotallabs.com/?p=19340#comment-31306</guid>
		<description><![CDATA[Thanks for the great refactoring write up! I like how you went through the steps, illustrating how a &#039;fair-minded&#039; principle can save you from the &quot;failure-by-strict-ideals&quot; problem. 

I don&#039;t like defining new classes with Struct.new( some_symbols), but I do occasionally use OpenStruct as the base for a model. Your AwesomeResource seems like a nice compromise between the two: your attributes are dynamic, but accessing non-existent ones raises an error.

Then I started to poke around in irb until I came up with this:

https://gist.github.com/russen/5645979

The &#039;if/else&#039; isn&#039;t as OOP as your approach, but since the function is only 4 lines, it does pass Sandi Metz&#039;s 4 rules :)  (https://gist.github.com/henrik/4509394)

I had fun trying out this different solution, and am completely interested in any +/- feedback you have!]]></description>
		<content:encoded><![CDATA[<p>Thanks for the great refactoring write up! I like how you went through the steps, illustrating how a &#8216;fair-minded&#8217; principle can save you from the &#8220;failure-by-strict-ideals&#8221; problem. </p>
<p>I don&#8217;t like defining new classes with Struct.new( some_symbols), but I do occasionally use OpenStruct as the base for a model. Your AwesomeResource seems like a nice compromise between the two: your attributes are dynamic, but accessing non-existent ones raises an error.</p>
<p>Then I started to poke around in irb until I came up with this:</p>
<p><a href="https://gist.github.com/russen/5645979" rel="nofollow">https://gist.github.com/russen/5645979</a></p>
<p>The &#8216;if/else&#8217; isn&#8217;t as OOP as your approach, but since the function is only 4 lines, it does pass Sandi Metz&#8217;s 4 rules :)  (<a href="https://gist.github.com/henrik/4509394" rel="nofollow">https://gist.github.com/henrik/4509394</a>)</p>
<p>I had fun trying out this different solution, and am completely interested in any +/- feedback you have!</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Method Modeling: A Refactoring by Matthew Parker</title>
		<link>http://pivotallabs.com/method-modeling-a-refactoring/#comment-31295</link>
		<dc:creator>Matthew Parker</dc:creator>
		<pubDate>Fri, 24 May 2013 14:24:06 +0000</pubDate>
		<guid isPermaLink="false">http://pivotallabs.com/?p=19340#comment-31295</guid>
		<description><![CDATA[Great points! The answer is, of course, that bad things will happen. I may have to use `define_method` in the end.]]></description>
		<content:encoded><![CDATA[<p>Great points! The answer is, of course, that bad things will happen. I may have to use `define_method` in the end.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Method Modeling: A Refactoring by Matthew Parker</title>
		<link>http://pivotallabs.com/method-modeling-a-refactoring/#comment-31294</link>
		<dc:creator>Matthew Parker</dc:creator>
		<pubDate>Fri, 24 May 2013 14:23:31 +0000</pubDate>
		<guid isPermaLink="false">http://pivotallabs.com/?p=19340#comment-31294</guid>
		<description><![CDATA[Nice Idea! At the moment, I&#039;m not sure how much I want to commit to depending on active_support; it can make working with multiple versions of Rails trickier.]]></description>
		<content:encoded><![CDATA[<p>Nice Idea! At the moment, I&#8217;m not sure how much I want to commit to depending on active_support; it can make working with multiple versions of Rails trickier.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Method Modeling: A Refactoring by Matthew Parker</title>
		<link>http://pivotallabs.com/method-modeling-a-refactoring/#comment-31293</link>
		<dc:creator>Matthew Parker</dc:creator>
		<pubDate>Fri, 24 May 2013 14:22:15 +0000</pubDate>
		<guid isPermaLink="false">http://pivotallabs.com/?p=19340#comment-31293</guid>
		<description><![CDATA[Thanks Pat!

When you call attr_* methods on class, you define methods for all instances of that class, not just the current instance. You&#039;d probably want to use `define_method` if you go that route. The main reason I didn&#039;t use `define_method` is because once you save a resource, the server responds with the new authoritative attributes for that resource. If those attributes are different from what you sent, you have to undefine the methods. Not the end of the world, but it&#039;s some manual work that I&#039;ve decided to avoid for now.

-Parker]]></description>
		<content:encoded><![CDATA[<p>Thanks Pat!</p>
<p>When you call attr_* methods on class, you define methods for all instances of that class, not just the current instance. You&#8217;d probably want to use `define_method` if you go that route. The main reason I didn&#8217;t use `define_method` is because once you save a resource, the server responds with the new authoritative attributes for that resource. If those attributes are different from what you sent, you have to undefine the methods. Not the end of the world, but it&#8217;s some manual work that I&#8217;ve decided to avoid for now.</p>
<p>-Parker</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Method Modeling: A Refactoring by Matthew Parker</title>
		<link>http://pivotallabs.com/method-modeling-a-refactoring/#comment-31292</link>
		<dc:creator>Matthew Parker</dc:creator>
		<pubDate>Fri, 24 May 2013 14:19:15 +0000</pubDate>
		<guid isPermaLink="false">http://pivotallabs.com/?p=19340#comment-31292</guid>
		<description><![CDATA[Hi Quinn,

Thanks for the question. The main reason I didn&#039;t explicitly define methods is because after a save, the response that comes back from the server is the new authoritative version of that resource, and if the attributes are different from what you sent, you&#039;ll have to go back and undefine the old attributes and define new attributes. 

Thanks!
-Parker]]></description>
		<content:encoded><![CDATA[<p>Hi Quinn,</p>
<p>Thanks for the question. The main reason I didn&#8217;t explicitly define methods is because after a save, the response that comes back from the server is the new authoritative version of that resource, and if the attributes are different from what you sent, you&#8217;ll have to go back and undefine the old attributes and define new attributes. </p>
<p>Thanks!<br />
-Parker</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Method Modeling: A Refactoring by Kurtis Rainbolt-Greene</title>
		<link>http://pivotallabs.com/method-modeling-a-refactoring/#comment-31279</link>
		<dc:creator>Kurtis Rainbolt-Greene</dc:creator>
		<pubDate>Fri, 24 May 2013 06:46:59 +0000</pubDate>
		<guid isPermaLink="false">http://pivotallabs.com/?p=19340#comment-31279</guid>
		<description><![CDATA[This looks a lot like my refactor of ostruct, astruct: http://github.com/krainboltgreene/astruct]]></description>
		<content:encoded><![CDATA[<p>This looks a lot like my refactor of ostruct, astruct: <a href="http://github.com/krainboltgreene/astruct" rel="nofollow">http://github.com/krainboltgreene/astruct</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on JavaScript constructors, prototypes, and the `new` keyword by Minal Gandhi</title>
		<link>http://pivotallabs.com/javascript-constructors-prototypes-and-the-new-keyword/#comment-31278</link>
		<dc:creator>Minal Gandhi</dc:creator>
		<pubDate>Fri, 24 May 2013 06:38:23 +0000</pubDate>
		<guid isPermaLink="false">http://pivotallabs.com/javascript-constructors-prototypes-and-the-new-keyword/#comment-31278</guid>
		<description><![CDATA[such great explanation....
I like it.....!!]]></description>
		<content:encoded><![CDATA[<p>such great explanation&#8230;.<br />
I like it&#8230;..!!</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Finding the middle for designers and developers by David Varvel</title>
		<link>http://pivotallabs.com/finding-the-middle-for-designers-and-developers/#comment-31273</link>
		<dc:creator>David Varvel</dc:creator>
		<pubDate>Fri, 24 May 2013 04:50:31 +0000</pubDate>
		<guid isPermaLink="false">http://pivotallabs.com/?p=19503#comment-31273</guid>
		<description><![CDATA[Amen.  Wireframe checks between designers and developers are some of the most productive conversations that I&#039;ve ever seen, for all the reasons that you mention.  Even if the designer is an amazing coder, it&#039;s important to get the perspective of someone who lives in the guts of the product on a daily basis.  Talking about wireframes also helps the developers get a better sense of how designers are thinking, which can be extraordinarily helpful when it comes time to implement things.

Also as you called out, mutual respect is crucial through every step of the process.  An abundance of mutual respect is one of the reasons I love working at Pivotal Labs.  Products are always better when the designers and developers realize that they&#039;re all on the same team.

Thanks for sharing!  Looking forward to reading more of your posts.]]></description>
		<content:encoded><![CDATA[<p>Amen.  Wireframe checks between designers and developers are some of the most productive conversations that I&#8217;ve ever seen, for all the reasons that you mention.  Even if the designer is an amazing coder, it&#8217;s important to get the perspective of someone who lives in the guts of the product on a daily basis.  Talking about wireframes also helps the developers get a better sense of how designers are thinking, which can be extraordinarily helpful when it comes time to implement things.</p>
<p>Also as you called out, mutual respect is crucial through every step of the process.  An abundance of mutual respect is one of the reasons I love working at Pivotal Labs.  Products are always better when the designers and developers realize that they&#8217;re all on the same team.</p>
<p>Thanks for sharing!  Looking forward to reading more of your posts.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Method Modeling: A Refactoring by Diego Alonso</title>
		<link>http://pivotallabs.com/method-modeling-a-refactoring/#comment-31265</link>
		<dc:creator>Diego Alonso</dc:creator>
		<pubDate>Fri, 24 May 2013 03:35:32 +0000</pubDate>
		<guid isPermaLink="false">http://pivotallabs.com/?p=19340#comment-31265</guid>
		<description><![CDATA[I am with you, Pat. That&#039;s what I would have implemented. It passes the specs, and it&#039;s concise and clear.]]></description>
		<content:encoded><![CDATA[<p>I am with you, Pat. That&#8217;s what I would have implemented. It passes the specs, and it&#8217;s concise and clear.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Method Modeling: A Refactoring by James Gary</title>
		<link>http://pivotallabs.com/method-modeling-a-refactoring/#comment-31255</link>
		<dc:creator>James Gary</dc:creator>
		<pubDate>Thu, 23 May 2013 21:25:05 +0000</pubDate>
		<guid isPermaLink="false">http://pivotallabs.com/?p=19340#comment-31255</guid>
		<description><![CDATA[`method_missing?` struck me as a round-about way of implementing this behavior. Using define_method` feels more explicitly about what you&#039;re trying to do. Here&#039;s my passing implementation: https://gist.github.com/jamesgary/5639529 (inspired by examples in http://apidock.com/ruby/Module/define_method)]]></description>
		<content:encoded><![CDATA[<p>`method_missing?` struck me as a round-about way of implementing this behavior. Using define_method` feels more explicitly about what you&#8217;re trying to do. Here&#8217;s my passing implementation: <a href="https://gist.github.com/jamesgary/5639529" rel="nofollow">https://gist.github.com/jamesgary/5639529</a> (inspired by examples in <a href="http://apidock.com/ruby/Module/define_method" rel="nofollow">http://apidock.com/ruby/Module/define_method</a>)</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk: basic (Feed is rejected)
Page Caching using apc
Database Caching using apc
Object Caching 453/498 objects using apc

 Served from: pivotallabs.com @ 2013-05-25 08:02:13 by W3 Total Cache -->