<?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 on: Protected variables cause subtle bugs &#8211; don&#8217;t use them</title>
	<atom:link href="http://agilepainrelief.com/notesfromatooluser/2007/10/protected-varia.html/feed" rel="self" type="application/rss+xml" />
	<link>http://agilepainrelief.com/notesfromatooluser/2007/10/protected-varia.html?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=protected-varia</link>
	<description>Best practices for your goals</description>
	<lastBuildDate>Sat, 19 May 2012 03:39:00 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
	<item>
		<title>By: Greg</title>
		<link>http://agilepainrelief.com/notesfromatooluser/2007/10/protected-varia.html/comment-page-1#comment-227</link>
		<dc:creator>Greg</dc:creator>
		<pubDate>Tue, 30 Nov 1999 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">http://agilepainrelief.com/2007/10/protected-varia/#comment-227</guid>
		<description>State is part of the interface of a class. This is very frequently forgotten, since it doesn&#039;t get typed in most languages.

The only guarantee that derived classes adhere to that part of your interface is to make the state private. Protected accessor methods are better but no panacaea - the method must take responsibility for making sure state doesn&#039;t change in a way that breaks your interface.
</description>
		<content:encoded><![CDATA[<p>State is part of the interface of a class. This is very frequently forgotten, since it doesn&#8217;t get typed in most languages.</p>
<p>The only guarantee that derived classes adhere to that part of your interface is to make the state private. Protected accessor methods are better but no panacaea &#8211; the method must take responsibility for making sure state doesn&#8217;t change in a way that breaks your interface.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mark Levison</title>
		<link>http://agilepainrelief.com/notesfromatooluser/2007/10/protected-varia.html/comment-page-1#comment-228</link>
		<dc:creator>Mark Levison</dc:creator>
		<pubDate>Tue, 30 Nov 1999 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">http://agilepainrelief.com/2007/10/protected-varia/#comment-228</guid>
		<description>Greg - we&#039;re agreed in principle I&#039;m just tired of debugging code that doesn&#039;t obey the contract.

I find if we&#039;re paranoid fewer mistakes slip through the cracks.
</description>
		<content:encoded><![CDATA[<p>Greg &#8211; we&#8217;re agreed in principle I&#8217;m just tired of debugging code that doesn&#8217;t obey the contract.</p>
<p>I find if we&#8217;re paranoid fewer mistakes slip through the cracks.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Greg</title>
		<link>http://agilepainrelief.com/notesfromatooluser/2007/10/protected-varia.html/comment-page-1#comment-229</link>
		<dc:creator>Greg</dc:creator>
		<pubDate>Tue, 30 Nov 1999 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">http://agilepainrelief.com/2007/10/protected-varia/#comment-229</guid>
		<description>Urgh, I was unclear there: Protected accessors are better than protected variables, but that doesn&#039;t make them good. :) Private is the way. I try not to let state creep into my interfaces at all, but if you must have it, for sanity&#039;s sake don&#039;t let derivers touch it behind your back.
</description>
		<content:encoded><![CDATA[<p>Urgh, I was unclear there: Protected accessors are better than protected variables, but that doesn&#8217;t make them good. :) Private is the way. I try not to let state creep into my interfaces at all, but if you must have it, for sanity&#8217;s sake don&#8217;t let derivers touch it behind your back.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Curt Cox</title>
		<link>http://agilepainrelief.com/notesfromatooluser/2007/10/protected-varia.html/comment-page-1#comment-230</link>
		<dc:creator>Curt Cox</dc:creator>
		<pubDate>Tue, 30 Nov 1999 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">http://agilepainrelief.com/2007/10/protected-varia/#comment-230</guid>
		<description>I think we all pretty much agree here.  I think the best advice on this general topic is given in &quot;Effective Java&quot;.  Design  for inheritance and document it--or prohibit it.
</description>
		<content:encoded><![CDATA[<p>I think we all pretty much agree here.  I think the best advice on this general topic is given in &#8220;Effective Java&#8221;.  Design  for inheritance and document it&#8211;or prohibit it.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

