<?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: Cocoa-Java Porting Step 2: Life Support</title>
	<atom:link href="http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support/feed" rel="self" type="application/rss+xml" />
	<link>http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support</link>
	<description>Mac &#38; Technology Writings by Daniel Jalkut</description>
	<lastBuildDate>Tue, 16 Mar 2010 05:50:31 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Scott Stevenson</title>
		<link>http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support/comment-page-1#comment-59984</link>
		<dc:creator>Scott Stevenson</dc:creator>
		<pubDate>Fri, 23 Feb 2007 06:41:46 +0000</pubDate>
		<guid isPermaLink="false">http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support#comment-59984</guid>
		<description>Fantastic post.</description>
		<content:encoded><![CDATA[<p>Fantastic post.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Richy</title>
		<link>http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support/comment-page-1#comment-59666</link>
		<dc:creator>Richy</dc:creator>
		<pubDate>Thu, 22 Feb 2007 12:02:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support#comment-59666</guid>
		<description>I&#039;d agree with the majority of replies that this is a good approach.  As a consultant I&#039;m often having to pick up code in all kinds of states and if it&#039;s working it&#039;s probably best to try and keep it that way.

A working app is an ideal substitute for a formal specification of just exactly how feature &#039;X&#039; is supposed to work, particularly if you weren&#039;t involved in the original design decisions, development cycle, bug fixing and so on.  It&#039;s easy to look at something and, based on your impressions of what it should do, write replacement code - however you can often end up throwing the baby out with the bathwater in doing so.

Martin Fowler describes code refactoring as &quot;a series of small behavior preserving transformations.&quot; (www.refactoring.com) and he&#039;s spent a lot more time analyzing, writing about and probably doing refactoring than most people.   This approach has consistently worked well for me over the years.</description>
		<content:encoded><![CDATA[<p>I&#8217;d agree with the majority of replies that this is a good approach.  As a consultant I&#8217;m often having to pick up code in all kinds of states and if it&#8217;s working it&#8217;s probably best to try and keep it that way.</p>
<p>A working app is an ideal substitute for a formal specification of just exactly how feature &#8216;X&#8217; is supposed to work, particularly if you weren&#8217;t involved in the original design decisions, development cycle, bug fixing and so on.  It&#8217;s easy to look at something and, based on your impressions of what it should do, write replacement code &#8211; however you can often end up throwing the baby out with the bathwater in doing so.</p>
<p>Martin Fowler describes code refactoring as &#8220;a series of small behavior preserving transformations.&#8221; (www.refactoring.com) and he&#8217;s spent a lot more time analyzing, writing about and probably doing refactoring than most people.   This approach has consistently worked well for me over the years.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Logan</title>
		<link>http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support/comment-page-1#comment-59426</link>
		<dc:creator>Logan</dc:creator>
		<pubDate>Wed, 21 Feb 2007 20:53:51 +0000</pubDate>
		<guid isPermaLink="false">http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support#comment-59426</guid>
		<description>@flight16:
NSClassFromString can also be used to look up Obj-C classes (for example, it is used in some Core Data examples) so it won&#039;t be deprecated entirely. The fact that it can look up a Java class is likely deprecated.

The Cocoa Java bridge is the Obj-C Java bridge. There is not a separate bridge. More specifically, Cocoa-Java uses the Obj-C Java bridge to do it&#039;s work.

As long as there is a Java SDK on Mac OS X you will be able to use JNI to get to Java from Obj-C since JNI is part of Java. I don&#039;t expect that to ever go away unless Apple drops Java entirely, which is extremely unlikely.

As far as the bridge is concerned, I believe Apple has stated that the bridge will still exist on Leopard, but there are no guarantees after that.  So it may or may not be included or work in 10.6, and users of the bridge best be prepared for it to not be available.</description>
		<content:encoded><![CDATA[<p>@flight16:<br />
NSClassFromString can also be used to look up Obj-C classes (for example, it is used in some Core Data examples) so it won&#8217;t be deprecated entirely. The fact that it can look up a Java class is likely deprecated.</p>
<p>The Cocoa Java bridge is the Obj-C Java bridge. There is not a separate bridge. More specifically, Cocoa-Java uses the Obj-C Java bridge to do it&#8217;s work.</p>
<p>As long as there is a Java SDK on Mac OS X you will be able to use JNI to get to Java from Obj-C since JNI is part of Java. I don&#8217;t expect that to ever go away unless Apple drops Java entirely, which is extremely unlikely.</p>
<p>As far as the bridge is concerned, I believe Apple has stated that the bridge will still exist on Leopard, but there are no guarantees after that.  So it may or may not be included or work in 10.6, and users of the bridge best be prepared for it to not be available.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: flight16</title>
		<link>http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support/comment-page-1#comment-59420</link>
		<dc:creator>flight16</dc:creator>
		<pubDate>Wed, 21 Feb 2007 20:23:50 +0000</pubDate>
		<guid isPermaLink="false">http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support#comment-59420</guid>
		<description>Is NSClassFromString deprecated?  Apple said they are no longer supporing the Cocoa Java bridge... but what about the Objective-C Java bridge?  People are now suggesting to use JNI if you need to use Java from Objective-C.  Is anyone know for sure if you will no longer be able to use Java from Objective-C?</description>
		<content:encoded><![CDATA[<p>Is NSClassFromString deprecated?  Apple said they are no longer supporing the Cocoa Java bridge&#8230; but what about the Objective-C Java bridge?  People are now suggesting to use JNI if you need to use Java from Objective-C.  Is anyone know for sure if you will no longer be able to use Java from Objective-C?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jon Trainer</title>
		<link>http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support/comment-page-1#comment-59285</link>
		<dc:creator>Jon Trainer</dc:creator>
		<pubDate>Wed, 21 Feb 2007 14:09:57 +0000</pubDate>
		<guid isPermaLink="false">http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support#comment-59285</guid>
		<description>Good stuff Daniel.  I think your chimera approach is a good way to attack your challenge.  It sounds like a good approach to pull out of the old toolbox for porting or when ever a major structural change to an app needs to be made.

I wonder how it could apply to a language that doesn&#039;t have an Objective-C bridge, like RealBasic or .NET via mono.</description>
		<content:encoded><![CDATA[<p>Good stuff Daniel.  I think your chimera approach is a good way to attack your challenge.  It sounds like a good approach to pull out of the old toolbox for porting or when ever a major structural change to an app needs to be made.</p>
<p>I wonder how it could apply to a language that doesn&#8217;t have an Objective-C bridge, like RealBasic or .NET via mono.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Logan</title>
		<link>http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support/comment-page-1#comment-59171</link>
		<dc:creator>Logan</dc:creator>
		<pubDate>Wed, 21 Feb 2007 06:35:19 +0000</pubDate>
		<guid isPermaLink="false">http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support#comment-59171</guid>
		<description>I have a Cocoa-Java app that I am slowly moving to Obj-C as well. This has been really interesting to see another perspective and some new techniques. It&#039;s quite lonely in Cocoa-Java land.

I&#039;ve found the &quot;keep it working&quot; approach to be better for me as well, especially since this is a side hobby project and I don&#039;t get very much time to work on it. I did some major refactoring a while back and the app wasn&#039;t runnable for a couple of months. I found that to be quite frustrating, especially when my planned refactorings brought on even more changes and I felt like I was getting farther behind with each step instead of making progress.

I&#039;m trying to avoid adding any new Java code, and doing everything new in Obj-C as much as I can. One approach I&#039;ve tried for the few times when I need to call from Java into Obj-C is to (ab)use notifications. It doesn&#039;t always feel right, but is easy to implement and keeps me away from bridget, which I am also loathe to use and have avoided thus far.

I am going to have to try this Chimera approach and see if I can make it work. I look forward to your porting tricks, as I have much porting still ahead of me.</description>
		<content:encoded><![CDATA[<p>I have a Cocoa-Java app that I am slowly moving to Obj-C as well. This has been really interesting to see another perspective and some new techniques. It&#8217;s quite lonely in Cocoa-Java land.</p>
<p>I&#8217;ve found the &#8220;keep it working&#8221; approach to be better for me as well, especially since this is a side hobby project and I don&#8217;t get very much time to work on it. I did some major refactoring a while back and the app wasn&#8217;t runnable for a couple of months. I found that to be quite frustrating, especially when my planned refactorings brought on even more changes and I felt like I was getting farther behind with each step instead of making progress.</p>
<p>I&#8217;m trying to avoid adding any new Java code, and doing everything new in Obj-C as much as I can. One approach I&#8217;ve tried for the few times when I need to call from Java into Obj-C is to (ab)use notifications. It doesn&#8217;t always feel right, but is easy to implement and keeps me away from bridget, which I am also loathe to use and have avoided thus far.</p>
<p>I am going to have to try this Chimera approach and see if I can make it work. I look forward to your porting tricks, as I have much porting still ahead of me.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gareth</title>
		<link>http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support/comment-page-1#comment-59143</link>
		<dc:creator>Gareth</dc:creator>
		<pubDate>Wed, 21 Feb 2007 04:46:16 +0000</pubDate>
		<guid isPermaLink="false">http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support#comment-59143</guid>
		<description>I agree 100% with the &quot;keep it working&quot; approach. There&#039;s nothing more frustrating than having to roll back a weeks worth of work because you cannot pinpoint where you made your fatal error and broke everything.

My approach to development is to do it incrementally, in the smallest functional working blocks at a time. It&#039;s not always possible, but when it is, it makes writing the code much easier.</description>
		<content:encoded><![CDATA[<p>I agree 100% with the &#8220;keep it working&#8221; approach. There&#8217;s nothing more frustrating than having to roll back a weeks worth of work because you cannot pinpoint where you made your fatal error and broke everything.</p>
<p>My approach to development is to do it incrementally, in the smallest functional working blocks at a time. It&#8217;s not always possible, but when it is, it makes writing the code much easier.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Stephan Cleaves</title>
		<link>http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support/comment-page-1#comment-59092</link>
		<dc:creator>Stephan Cleaves</dc:creator>
		<pubDate>Wed, 21 Feb 2007 00:51:49 +0000</pubDate>
		<guid isPermaLink="false">http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support#comment-59092</guid>
		<description>I think this is a wise approach. Without a &quot;live&quot; app its hard to know that the new method you just wrote does what you intended. I build new applications in this incremental manner as well. Try out my ideas with simple prototypes, and use some of the code from those, but generally more what I learned about the functionality to begin building the app. Then from there add on features while trying to keep a &quot;live&quot; app. Sometimes you&#039;ve got to change something that makes it hard to do that, but I always feel much better knowing that the app still works.</description>
		<content:encoded><![CDATA[<p>I think this is a wise approach. Without a &#8220;live&#8221; app its hard to know that the new method you just wrote does what you intended. I build new applications in this incremental manner as well. Try out my ideas with simple prototypes, and use some of the code from those, but generally more what I learned about the functionality to begin building the app. Then from there add on features while trying to keep a &#8220;live&#8221; app. Sometimes you&#8217;ve got to change something that makes it hard to do that, but I always feel much better knowing that the app still works.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Daniel Jalkut</title>
		<link>http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support/comment-page-1#comment-59063</link>
		<dc:creator>Daniel Jalkut</dc:creator>
		<pubDate>Tue, 20 Feb 2007 22:39:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support#comment-59063</guid>
		<description>Hi Darkshadow - it&#039;s more of an insurance that the &quot;roll back&quot; will only be a day or two of work, in the worst case scenario. If I was to tear everything apart and hope for the best, I&#039;d probably end up 2 or 3 weeks away from a stable product again. And yeah, chances are it would &quot;all work out&quot; eventually, but if it didn&#039;t, I&#039;d have to roll back 3 weeks!

Using the &quot;incremental and almost never broken&quot; technique, I just get a bit more security that I&#039;m not breaking things terribly, as I go. I would be more likely to be adventurous with a product that I knew extremely well. In this case I have the added pleasure of a continuous reference for functionality. I don&#039;t have to compare with the original product, to see if it behaves the same. I can constantly compare against my last checkin, to see if I busted anything.</description>
		<content:encoded><![CDATA[<p>Hi Darkshadow &#8211; it&#8217;s more of an insurance that the &#8220;roll back&#8221; will only be a day or two of work, in the worst case scenario. If I was to tear everything apart and hope for the best, I&#8217;d probably end up 2 or 3 weeks away from a stable product again. And yeah, chances are it would &#8220;all work out&#8221; eventually, but if it didn&#8217;t, I&#8217;d have to roll back 3 weeks!</p>
<p>Using the &#8220;incremental and almost never broken&#8221; technique, I just get a bit more security that I&#8217;m not breaking things terribly, as I go. I would be more likely to be adventurous with a product that I knew extremely well. In this case I have the added pleasure of a continuous reference for functionality. I don&#8217;t have to compare with the original product, to see if it behaves the same. I can constantly compare against my last checkin, to see if I busted anything.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Darkshadow</title>
		<link>http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support/comment-page-1#comment-59047</link>
		<dc:creator>Darkshadow</dc:creator>
		<pubDate>Tue, 20 Feb 2007 22:13:07 +0000</pubDate>
		<guid isPermaLink="false">http://www.red-sweater.com/blog/281/cocoa-java-porting-step-2-life-support#comment-59047</guid>
		<description>Interesting outlook, Daniel.  I tend to just go into my code and rip it apart at will, whether or not that&#039;ll keep it from working.  Which it tends not to.  In fact, I&#039;m going through a major rewrite of one of my apps (pretty much ground up), and it&#039;s just now getting back to where it mostly runs.

Is this more of an aesthetic thing for you?  I keep my code up to date in my svn repository in case I need to roll back, so it&#039;s not really a giant issue to me when I break things.</description>
		<content:encoded><![CDATA[<p>Interesting outlook, Daniel.  I tend to just go into my code and rip it apart at will, whether or not that&#8217;ll keep it from working.  Which it tends not to.  In fact, I&#8217;m going through a major rewrite of one of my apps (pretty much ground up), and it&#8217;s just now getting back to where it mostly runs.</p>
<p>Is this more of an aesthetic thing for you?  I keep my code up to date in my svn repository in case I need to roll back, so it&#8217;s not really a giant issue to me when I break things.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
