<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-174910063051315281</id><updated>2012-01-25T10:47:32.993-05:00</updated><category term='Java API'/><category term='Visual Studio'/><category term='control'/><category term='JPA'/><category term='final project'/><category term='web app'/><category term='package'/><category term='UNIX head'/><category term='static factory'/><category term='certifications'/><category term='topics'/><category term='String'/><category term='Java ME'/><category term='Java 7'/><category term='conversion'/><category term='iterative'/><category term='events'/><category term='JCurses'/><category term='XML markup'/><category term='interfaces'/><category term='parsing'/><category term='Windows'/><category term='Java programmers'/><category term='simplify'/><category term='applet'/><category term='algorithms'/><category term='listener'/><category term='upgrade'/><category term='RIA'/><category term='mainframe'/><category term='array'/><category term='EJB'/><category term='inheritance'/><category term='game development'/><category term='Internet Explorer 6'/><category term='thin driver'/><category term='TDD'/><category term='JButton'/><category term='configuration'/><category term='HashSet'/><category term='resources'/><category term='classes'/><category term='Java EE 6'/><category term='Apache'/><category term='precedence'/><category term='POJO'/><category term='method name'/><category term='work'/><category term='getMessage'/><category term='IBM'/><category term='packages'/><category term='HotSpot'/><category term='paint'/><category term='UML diagram'/><category term='Computer Science'/><category term='deprecated'/><category term='curve cryptography'/><category term='CSS'/><category term='Java EE'/><category term='Subversion'/><category term='refactor'/><category term='commit'/><category term='OracleDriver'/><category term='intro'/><category term='blocked content'/><category term='obsolete'/><category term='Criteria API'/><category term='graphics'/><category term='format'/><category term='StringBuffer'/><category term='memory'/><category term='NetBeans'/><category term='Word'/><category term='SDK'/><category term='Korn shell scripts'/><category term='GPL'/><category term='output'/><category term='problems'/><category term='bytes'/><category term='keyword this'/><category term='Oak'/><category term='VMware'/><category term='G1'/><category term='object oriented'/><category term='clean code'/><category term='javac'/><category term='Jat Web Start'/><category term='Eclipse'/><category term='optimization'/><category term='CMS'/><category term='stock'/><category term='OOP'/><category term='parameter'/><category term='electronic football'/><category term='network'/><category term='Internet Explorer'/><category term='structures'/><category term='sick'/><category term='DateFormat'/><category term='project'/><category term='love'/><category term='conferences'/><category term='talks'/><category term='compiler'/><category term='label'/><category term='this'/><category term='answers'/><category term='challenge'/><category term='loop'/><category term='support'/><category term='skills'/><category term='AWT'/><category term='list'/><category term='Cache'/><category term='ESB'/><category term='SQL*Net'/><category term='huge file'/><category term='hexadecimal'/><category term='time off'/><category term='Oracle'/><category term='Lisp'/><category term='SOA'/><category term='application'/><category term='delegation'/><category term='Java 1.0'/><category term='rows'/><category term='grid'/><category term='executable'/><category term='Swing'/><category term='veteran'/><category term='3rd party'/><category term='direct machine access'/><category term='buffer'/><category term='java.sql'/><category term='frameworks'/><category term='superclass'/><category term='compilation'/><category term='extends'/><category term='animation'/><category term='user interface'/><category term='relational mapping'/><category term='addActionListener'/><category term='byte code'/><category term='java.util.Date'/><category term='JSON'/><category term='UMLet'/><category term='comments'/><category term='update'/><category term='hardware'/><category term='driver'/><category term='JNI'/><category term='Jalapeno'/><category term='catch'/><category term='speed'/><category term='init'/><category term='roguelike'/><category term='cloud computing'/><category term='main'/><category term='GlassFish'/><category term='startup'/><category term='deployment'/><category term='special effects'/><category term='program'/><category term='modules'/><category term='size'/><category term='throw'/><category term='web services'/><category term='package private'/><category term='Statement'/><category term='Google'/><category term='question'/><category term='JDBC'/><category term='Set'/><category term='private'/><category term='databases'/><category term='queue'/><category term='Runnable'/><category term='PHP'/><category term='SDN'/><category term='DoD'/><category term='setActionCommand'/><category term='container'/><category term='Linux'/><category term='Weblogic'/><category term='server'/><category term='exception'/><category term='UNIX servers'/><category term='questions'/><category term='equals'/><category term='Ant'/><category term='libjcsi'/><category term='Silverlight'/><category term='Double'/><category term='templates'/><category term='appletViewer'/><category term='for loop'/><category term='display'/><category term='Java SE 6'/><category term='web'/><category term='registry'/><category term='concatentation'/><category term='Amazon'/><category term='PL/SQL'/><category term='mobile phones'/><category term='native Java'/><category term='JAX-RS'/><category term='projects'/><category term='functions'/><category term='JAAS'/><category term='BufferedString'/><category term='jar'/><category term='product'/><category term='presentation'/><category term='library'/><category term='verbosity'/><category term='test'/><category term='JSR-302'/><category term='Websphere'/><category term='Rational Rose'/><category term='Indonesia'/><category term='profiles'/><category term='JDK 7'/><category term='JDistro'/><category term='Java SE'/><category term='keyboard'/><category term='performance'/><category term='class file'/><category term='strings'/><category term='newline'/><category term='Oracle Corporation'/><category term='floppy disk'/><category term='Liquid Robotics'/><category term='contest'/><category term='MANIFEST.MF'/><category term='buttons'/><category term='stored procs'/><category term='jQuery'/><category term='connected'/><category term='select'/><category term='hasLine'/><category term='MySQL'/><category term='KeyListener'/><category term='refactoring'/><category term='controls'/><category term='arrays'/><category term='Jakarta'/><category term='security'/><category term='scope'/><category term='creator'/><category term='Sun Microsystems'/><category term='CVS'/><category term='Java code'/><category term='parameters'/><category term='college'/><category term='java.awt'/><category term='Math package'/><category term='school'/><category term='cloud'/><category term='game'/><category term='filter'/><category term='unboxing'/><category term='TCK'/><category term='case'/><category term='game programming'/><category term='dynamic typing'/><category term='protected'/><category term='JDK'/><category term='I/O'/><category term='struts'/><category term='footprint'/><category term='formal parameters'/><category term='color'/><category term='monsters'/><category term='PreparedStatement'/><category term='HTML'/><category term='Java 7 SE'/><category term='JSF'/><category term='middleware'/><category term='components'/><category term='JRockit'/><category term='testing'/><category term='JavaScript'/><category term='automation'/><category term='mortgage caclulator'/><category term='Builder pattern'/><category term='JApplet'/><category term='prototype'/><category term='recursion'/><category term='invisible'/><category term='java.util'/><category term='META-INF'/><category term='MVC'/><category term='class constructor'/><category term='DO-178C'/><category term='Date'/><category term='HashMap'/><category term='Facebook interview'/><category term='Joshua Bloch'/><category term='AJAX'/><category term='trademark'/><category term='instance variables'/><category term='map'/><category term='web development'/><category term='classpath'/><category term='directory'/><category term='collection'/><category term='JavaOne'/><category term='types'/><category term='switch'/><category term='C++'/><category term='setVisible'/><category term='console'/><category term='operator new'/><category term='repaint'/><category term='archive'/><category term='OCI'/><category term='technical sessions'/><category term='agile'/><category term='metrics'/><category term='enterprise'/><category term='ODMG'/><category term='class'/><category term='random numbers'/><category term='layout'/><category term='Curses'/><category term='managed'/><category term='observer pattern'/><category term='boxing'/><category term='traversal'/><category term='database'/><category term='incremental builds'/><category term='JVM'/><category term='JBoss'/><category term='LayoutManager'/><category term='JTable'/><category term='functionality'/><category term='REST'/><category term='Thread'/><category term='patterns'/><category term='override'/><category term='static'/><category term='sorting'/><category term='edge'/><category term='OTAP'/><category term='games'/><category term='JRE'/><category term='Java'/><category term='blog'/><category term='position'/><category term='constructor'/><category term='time'/><category term='containers'/><category term='source'/><category term='KPRB'/><category term='independent study'/><category term='beans'/><category term='implicit'/><category term='Maven'/><category term='exercises'/><category term='generics'/><category term='runtime'/><category term='icon'/><category term='pattern'/><category term='MyFaces'/><category term='Spring framework'/><category term='ODBC'/><category term='65C02'/><category term='mutators'/><category term='utilities'/><category term='money'/><title type='text'>Java Development</title><subtitle type='html'>I am a long time C++ programmer. The customer wants to go to the web. Time for me to learn Java.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default?start-index=101&amp;max-results=100'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>105</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7120276974096216659</id><published>2012-01-25T10:38:00.002-05:00</published><updated>2012-01-25T10:47:33.005-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='web development'/><category scheme='http://www.blogger.com/atom/ns#' term='EJB'/><category scheme='http://www.blogger.com/atom/ns#' term='MVC'/><category scheme='http://www.blogger.com/atom/ns#' term='JSF'/><category scheme='http://www.blogger.com/atom/ns#' term='JAAS'/><category scheme='http://www.blogger.com/atom/ns#' term='JPA'/><title type='text'>Acronym Hell</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/-uNkBe_Tk5Ps/TyAiJIxRRCI/AAAAAAAAAPU/dac_k5Q3uFo/s1600/JSF.gif"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 320px; height: 199px;" src="http://4.bp.blogspot.com/-uNkBe_Tk5Ps/TyAiJIxRRCI/AAAAAAAAAPU/dac_k5Q3uFo/s320/JSF.gif" border="0" alt=""id="BLOGGER_PHOTO_ID_5701594668619351074" /&gt;&lt;/a&gt;I just saw a massive blog post on developing a web app. Not only was the length of the blog post long, the list of related technologies was large. The post is going to hit JSF, CSS, EJB, DAO, JPA, JAAS, MVC, and MySQL. I have done a little bit of web application development. But I did not recognize all these terms. I guess you got to keep up.&lt;br /&gt;&lt;br /&gt;So far I have only checked out the first piece of this blog post. I plan to go through the whole thing. This just seems like a lot to take in to do web programming. Then again this makes web developers more in demand if the skill list is huge.&lt;br /&gt;&lt;br /&gt;The question I keep asking myself is whether I want to get into all this. The pain would be that the technologies would become obsolete or replaced just as soon as I master them. Such is life I guess.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7120276974096216659?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7120276974096216659/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2012/01/acronym-hell.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7120276974096216659'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7120276974096216659'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2012/01/acronym-hell.html' title='Acronym Hell'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/-uNkBe_Tk5Ps/TyAiJIxRRCI/AAAAAAAAAPU/dac_k5Q3uFo/s72-c/JSF.gif' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-1595988237009556422</id><published>2012-01-24T22:15:00.002-05:00</published><updated>2012-01-24T22:18:03.109-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='contest'/><category scheme='http://www.blogger.com/atom/ns#' term='school'/><category scheme='http://www.blogger.com/atom/ns#' term='sick'/><category scheme='http://www.blogger.com/atom/ns#' term='roguelike'/><title type='text'>Move to JavaScript</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/-UNrd1rTIIGw/Tx9z2Ce135I/AAAAAAAAAPI/ZtD2577u5KI/s1600/JavaScript.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 320px; height: 258px;" src="http://3.bp.blogspot.com/-UNrd1rTIIGw/Tx9z2Ce135I/AAAAAAAAAPI/ZtD2577u5KI/s320/JavaScript.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5701403025490698130" /&gt;&lt;/a&gt;I have been sick for the last few weeks. So my Java roguelike game engine has been put on hold. That's okay. I shall enter a contest around March of this year to develop a game with the engine. I suspect I shall be doing a massive amount of Java coding that week. The engine will get some bug fixes and updates as a results.&lt;br /&gt;&lt;br /&gt;The Spring school semester is just about to start up. I am taking an intro JavaScript course this time around. I plan to stop my Java learning for a few months to concentrate on the JavaScript. By summer I should be back in full swing with Java develoopment.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-1595988237009556422?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/1595988237009556422/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2012/01/move-to-javascript.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1595988237009556422'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1595988237009556422'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2012/01/move-to-javascript.html' title='Move to JavaScript'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/-UNrd1rTIIGw/Tx9z2Ce135I/AAAAAAAAAPI/ZtD2577u5KI/s72-c/JavaScript.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-1067347371703579180</id><published>2011-12-20T20:48:00.002-05:00</published><updated>2011-12-20T20:53:28.021-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='array'/><category scheme='http://www.blogger.com/atom/ns#' term='functionality'/><category scheme='http://www.blogger.com/atom/ns#' term='clean code'/><category scheme='http://www.blogger.com/atom/ns#' term='containers'/><category scheme='http://www.blogger.com/atom/ns#' term='simplify'/><title type='text'>Refactoring Complete</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/-jQeqTtwqAXg/TvE7LhnGo7I/AAAAAAAAAO8/eeO9VAyKJzc/s1600/Refactor.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 294px; height: 320px;" src="http://4.bp.blogspot.com/-jQeqTtwqAXg/TvE7LhnGo7I/AAAAAAAAAO8/eeO9VAyKJzc/s320/Refactor.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5688392873532629938" /&gt;&lt;/a&gt;I had previously coded up a bunch of library code for my roguelike game engine. My first idea was to hold all items in a big array. When the items were picked up and them wielded, the item state would change. Then I had a bunch of custom code that switched on the state.&lt;br /&gt;&lt;br /&gt;The problem was that most items get removed and regenerated during change of dungeon level. I did not want my players inventory and equipment to disappear when the dungeon level changed. So I needed a refactoring. I decided to create separate containers for the player inventory and the player equipment. Today I refactored all the code to use this new design.&lt;br /&gt;&lt;br /&gt;I was pleased to see that much code was simplified. Many functions were no longer even needed. The code was getting really clean. This must mean the redesign was a move in the positive direction. This shall also allow easy changes of inventory/equipment rules in the future.&lt;br /&gt;&lt;br /&gt;Not sure what I am going to do next. I am still riding a high of a good code refactoring. It is probably time to implement some more functionality in the dungeon.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-1067347371703579180?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/1067347371703579180/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/12/refactoring-complete.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1067347371703579180'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1067347371703579180'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/12/refactoring-complete.html' title='Refactoring Complete'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/-jQeqTtwqAXg/TvE7LhnGo7I/AAAAAAAAAO8/eeO9VAyKJzc/s72-c/Refactor.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-2181985269487188481</id><published>2011-12-19T23:57:00.002-05:00</published><updated>2011-12-20T00:01:21.125-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='array'/><category scheme='http://www.blogger.com/atom/ns#' term='library'/><category scheme='http://www.blogger.com/atom/ns#' term='container'/><category scheme='http://www.blogger.com/atom/ns#' term='list'/><category scheme='http://www.blogger.com/atom/ns#' term='refactoring'/><title type='text'>Storing Items</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/-EnGGnnK4yhA/TvAVzASZ6KI/AAAAAAAAAOw/hk6lne1ovmc/s1600/Equipment.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 268px; height: 193px;" src="http://4.bp.blogspot.com/-EnGGnnK4yhA/TvAVzASZ6KI/AAAAAAAAAOw/hk6lne1ovmc/s320/Equipment.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5688070295363643554" /&gt;&lt;/a&gt;I am building a library to help with the development of a roguelike game. Got the maze generation down pat. Next I added items such as weapon and armor to the maze. I implemented these items in a big array. The items knew where they started out in the dungeon.&lt;br /&gt;&lt;br /&gt;As the player picks up and wields the items, the items change their location. This was working like a champ. Then I realized the items were tied to the dungeon. The dungeon gets regenerated on each level as the player walks up and down the stairs. Ooops.&lt;br /&gt;&lt;br /&gt;I don't want the players to lose the items in their inventory or on their body when they navigate the dunegon levels. What I should have done is to separately manage the dungeon objects and the player inventory/equipment. Then I could move the items from each of these containers as the player picks up or discards the items.&lt;br /&gt;&lt;br /&gt;This design change will require some refactoring. While I am at it, I might as well change the containers from arrays to lists. That will make the adding and removing a whole lot easier.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-2181985269487188481?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/2181985269487188481/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/12/storing-items.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2181985269487188481'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2181985269487188481'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/12/storing-items.html' title='Storing Items'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/-EnGGnnK4yhA/TvAVzASZ6KI/AAAAAAAAAOw/hk6lne1ovmc/s72-c/Equipment.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-6536808566618734932</id><published>2011-12-14T23:56:00.002-05:00</published><updated>2011-12-15T00:03:52.134-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='contest'/><category scheme='http://www.blogger.com/atom/ns#' term='edge'/><category scheme='http://www.blogger.com/atom/ns#' term='BufferedString'/><category scheme='http://www.blogger.com/atom/ns#' term='buffer'/><category scheme='http://www.blogger.com/atom/ns#' term='roguelike'/><title type='text'>Maze Mechanics</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/-NrzlCMc-DPQ/Tul-REd6GPI/AAAAAAAAAOk/sLa8aMEM7ac/s1600/Wall.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 320px; height: 259px;" src="http://2.bp.blogspot.com/-NrzlCMc-DPQ/Tul-REd6GPI/AAAAAAAAAOk/sLa8aMEM7ac/s320/Wall.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5686214836254021874" /&gt;&lt;/a&gt;Every year I enter a contest to see if I can create a game in seven days. It must be a roguelike game. Usually I write it in a language that I am comfortable in such as C++. I only tried writing my game in Java once. It was disappointing to say the least.&lt;br /&gt;&lt;br /&gt;I learned a lot of Java over the past over the last few months. I am ready to try my hand at a Java roguelike again. But first I thought I would practice with some roguelike library code. You know. I need to knock out some mundane stuff to be proficient for the real game design.&lt;br /&gt;&lt;br /&gt;Right now I am wrapping up the basics of maze drawing. I got some rooms connected by halls. Good stuff. The only problem is that the user can navigate around the maze. When I get too close ot the side of the maze, I have some coding problems.&lt;br /&gt;&lt;br /&gt;The maze display is based on an array of BufferedString objects. I just index into them based on where the player is on the maze. I keep the player in the center of the screen. So when the player reaches the edge of the maze, we are faced with drawing cells that do not exist in the StringBuffer.&lt;br /&gt;&lt;br /&gt;Now an elegant solution would be to detect this and somehow append some virtual walls outside the edge of the maze. I might still opt for that grand solution. For now I am trying to hurry up and get stuff done. So I extend the edges of the maze in all directions to create an outside buffer. This ensures you can use the same dumb code to index into the BufferedStrings even when at the edge of the navigatable maze. Nice trick huh?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-6536808566618734932?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/6536808566618734932/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/12/maze-mechanics.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6536808566618734932'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6536808566618734932'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/12/maze-mechanics.html' title='Maze Mechanics'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/-NrzlCMc-DPQ/Tul-REd6GPI/AAAAAAAAAOk/sLa8aMEM7ac/s72-c/Wall.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-6406760717683282672</id><published>2011-12-14T13:05:00.004-05:00</published><updated>2011-12-14T13:11:05.160-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='final project'/><category scheme='http://www.blogger.com/atom/ns#' term='mortgage caclulator'/><category scheme='http://www.blogger.com/atom/ns#' term='electronic football'/><title type='text'>The Outstanding Breakout</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/-e3p2S40Wrz8/TujmsMx1s4I/AAAAAAAAAOY/xb99mCmEeJM/s1600/Breakout.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 320px; height: 214px;" src="http://4.bp.blogspot.com/-e3p2S40Wrz8/TujmsMx1s4I/AAAAAAAAAOY/xb99mCmEeJM/s320/Breakout.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5686048176574149506" /&gt;&lt;/a&gt;My advanced Java community college class did not have a final exam. Instead we needed to submit a final project. The instructor came up with a couple ideas for projects we could do. He also said he was open to other ideas upon his approvel.&lt;br /&gt;&lt;br /&gt;Initially I thought I might develop an electronic football game. Nothing like Madden. This would be a clone of the old Mattel hand held electronic football games from the 70's and 80's. Then I saw the idea of writing the arcade game Breakout and I knew I had to do it.&lt;br /&gt;&lt;br /&gt;The funny thing about the final is that most students opted to do the mortgage calculator. That has the advantage of being easy to do. The instructor provides the GUI and the equations to figure out mortgage payments. The student just needs to implement the equation and hook it up. Boring.&lt;br /&gt;&lt;br /&gt;The basic breakout game was pretty easy to implement. I had already coded some exercises with balls bouncing around the screen. I concentrated on my intro and game over screens. I alsmot used this game as a place for some demo graphics on those auxiliary screens. I also concentrated on game play. Another student was excited to play my game and give me UI feedback. In the end I spent a lot of time developing this game. My instructor called is amazing and outstanding.&lt;br /&gt;&lt;br /&gt;The real win from this game is the stuff I learned from doing it. It is now a part of my JAva portfolio. Yeah I could have done the mortgage calculator. But where's the glory in taking the easy way out and cheating myself?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-6406760717683282672?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/6406760717683282672/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/12/outstanding-breakout.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6406760717683282672'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6406760717683282672'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/12/outstanding-breakout.html' title='The Outstanding Breakout'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/-e3p2S40Wrz8/TujmsMx1s4I/AAAAAAAAAOY/xb99mCmEeJM/s72-c/Breakout.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-6113653242803667002</id><published>2011-12-13T13:03:00.003-05:00</published><updated>2011-12-13T13:07:30.351-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='array'/><category scheme='http://www.blogger.com/atom/ns#' term='StringBuffer'/><category scheme='http://www.blogger.com/atom/ns#' term='display'/><category scheme='http://www.blogger.com/atom/ns#' term='structures'/><title type='text'>Maze Design</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/-W5oHFDYdT-s/TueTma_wlVI/AAAAAAAAAOA/feaErNzDlWY/s1600/Design.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 308px; height: 320px;" src="http://3.bp.blogspot.com/-W5oHFDYdT-s/TueTma_wlVI/AAAAAAAAAOA/feaErNzDlWY/s320/Design.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5685675342869599570" /&gt;&lt;/a&gt;I am struggling on how to internally represent my roguelike maze. Currently I maintain a 2D array as well as an array of StringBuffers. The array is used for easy lookup of objects in the maze. The StringBuffer is used to quickly generate a string to draw on the screen. The problem is that I need to update both structure every time something moves in the maze.&lt;br /&gt;&lt;br /&gt;I could just keep the 2D array. Then I could generate the Strings on the fly as I need to display. However I do a lot of display updates (whenever the player moves). That might take a lot of time to generate an 80x25 worth of character Strings.&lt;br /&gt;&lt;br /&gt;Or I could just keep everything in the String array. Then I could index into it when I need to check different cells of the maze. That just does not feel as natural as the separate 2D array though.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-6113653242803667002?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/6113653242803667002/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/12/maze-design.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6113653242803667002'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6113653242803667002'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/12/maze-design.html' title='Maze Design'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/-W5oHFDYdT-s/TueTma_wlVI/AAAAAAAAAOA/feaErNzDlWY/s72-c/Design.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-8254421788772457569</id><published>2011-12-12T00:14:00.003-05:00</published><updated>2011-12-12T00:18:53.503-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='resources'/><category scheme='http://www.blogger.com/atom/ns#' term='special effects'/><category scheme='http://www.blogger.com/atom/ns#' term='hardware'/><category scheme='http://www.blogger.com/atom/ns#' term='intro'/><title type='text'>Breakout Performance</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/-s-_V4hyyp4s/TuWNvR81UoI/AAAAAAAAAN0/BI4UlfIRrW0/s1600/Breakout.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 58px;" src="http://2.bp.blogspot.com/-s-_V4hyyp4s/TuWNvR81UoI/AAAAAAAAAN0/BI4UlfIRrW0/s320/Breakout.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5685105948037042818" /&gt;&lt;/a&gt;I coded up an epic game of Breakout. Most of my effort was spent on my intro screen. I also spent a good deal of time on special effects for the high score screen. The thing rocks on my development machine. But I ran the same game on a laptop with limited hardware, and the results were disappointing.&lt;br /&gt;&lt;br /&gt;The intro screen draws a lot of random lines to produce a static effect. It also draws text in increasing font sizes that get really big. This screen works but is painfully slow on the laptop with limited hardware.&lt;br /&gt;&lt;br /&gt;Luckily the main game mechanics adjust themselves according to the amount of time it takes to render the game screen. So it plays well whether there is high power hardware, or limited resources. I should have done that with the intro screen as well.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-8254421788772457569?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/8254421788772457569/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/12/breakout-performance.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8254421788772457569'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8254421788772457569'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/12/breakout-performance.html' title='Breakout Performance'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/-s-_V4hyyp4s/TuWNvR81UoI/AAAAAAAAAN0/BI4UlfIRrW0/s72-c/Breakout.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-543243265291537454</id><published>2011-11-09T21:02:00.003-05:00</published><updated>2011-11-09T21:08:18.575-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='MySQL'/><category scheme='http://www.blogger.com/atom/ns#' term='JTable'/><category scheme='http://www.blogger.com/atom/ns#' term='Statement'/><category scheme='http://www.blogger.com/atom/ns#' term='PreparedStatement'/><title type='text'>JDBC to the Rescue</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/-7mIU86QUqwc/TrsyC5T6jpI/AAAAAAAAANo/_22kQqjLm_o/s1600/Books.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 100px;" src="http://3.bp.blogspot.com/-7mIU86QUqwc/TrsyC5T6jpI/AAAAAAAAANo/_22kQqjLm_o/s400/Books.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5673183180928749202" /&gt;&lt;/a&gt;I just read a chapter on the JDBC. This allows me to access databases from my Java code. Now I have the power to write CRUD apps. Yeah. So far I have written some code that uses Statements to do basic querying. I have also delved into PreparedStatements to insert and update.&lt;br /&gt;&lt;br /&gt;To test out and play with this capability, I downloaded and installed the latest MySQL database. It is taking a while to get used to MySQL database administration. I also got MySQL Connector/J so that my JDBC can talk to the MySQL database. So far it works like a charm.&lt;br /&gt;&lt;br /&gt;I have studied and modified a little bit of code that uses an AbstractTableModel and JTable. This seems to be quite the powerful combinatoin. It is also something that will take a while to learn. Now the world of databases it at my fingertips. Perhaps I shall try to connect to an &lt;a href="http://ora-pl-sql.blogspot.com/"&gt;Oracle&lt;/a&gt; database with JDBC as well.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-543243265291537454?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/543243265291537454/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/11/jdbc-to-rescue.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/543243265291537454'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/543243265291537454'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/11/jdbc-to-rescue.html' title='JDBC to the Rescue'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/-7mIU86QUqwc/TrsyC5T6jpI/AAAAAAAAANo/_22kQqjLm_o/s72-c/Books.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-5423136969241326505</id><published>2011-11-01T16:02:00.002-04:00</published><updated>2011-11-01T16:06:19.226-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='recursion'/><category scheme='http://www.blogger.com/atom/ns#' term='iterative'/><category scheme='http://www.blogger.com/atom/ns#' term='Facebook interview'/><title type='text'>Towers of Hanoi</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/-5iQo3dwpjpk/TrBQhS7N-0I/AAAAAAAAANQ/zAWobImeYW8/s1600/Hanoi.gif"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 320px; height: 320px;" src="http://1.bp.blogspot.com/-5iQo3dwpjpk/TrBQhS7N-0I/AAAAAAAAANQ/zAWobImeYW8/s320/Hanoi.gif" border="0" alt=""id="BLOGGER_PHOTO_ID_5670120463805578050" /&gt;&lt;/a&gt;In my Java class this semester, we went over the Towers of Hanoi problem during our study of recusion. The recusrive solution is elegant. It is also simpler than any iterative solution. We did not code a solution. We just studied one intently to understand the recursive nature of it.&lt;br /&gt;&lt;br /&gt;Recently I saw one of the sample problems you need to solve during a Facebook interview. One of them is the Towers of Hanoi problem. Nice. Facebook even let's you code the thing in Java. It has to work correctly. And you need to complete the thing in 45 minutes.&lt;br /&gt;&lt;br /&gt;Not sure if I can meet that metric. But at least I have seen the problem and solution before. I guess I could google the code. That would be cheating. I feel good about what my Java college class is teaching me.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-5423136969241326505?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/5423136969241326505/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/11/towers-of-hanoi.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5423136969241326505'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5423136969241326505'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/11/towers-of-hanoi.html' title='Towers of Hanoi'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/-5iQo3dwpjpk/TrBQhS7N-0I/AAAAAAAAANQ/zAWobImeYW8/s72-c/Hanoi.gif' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-3272978346776302663</id><published>2011-10-18T17:11:00.004-04:00</published><updated>2011-10-18T17:15:08.494-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='resources'/><category scheme='http://www.blogger.com/atom/ns#' term='repaint'/><category scheme='http://www.blogger.com/atom/ns#' term='Thread'/><category scheme='http://www.blogger.com/atom/ns#' term='Runnable'/><category scheme='http://www.blogger.com/atom/ns#' term='update'/><title type='text'>Multithreading</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/-Cw_aZLMlbu0/Tp3rfqVWZxI/AAAAAAAAAM8/QjgTmiyysjo/s1600/Balls.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 320px; height: 214px;" src="http://4.bp.blogspot.com/-Cw_aZLMlbu0/Tp3rfqVWZxI/AAAAAAAAAM8/QjgTmiyysjo/s320/Balls.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5664942835474261778" /&gt;&lt;/a&gt;I am just starting to learn multithreading. My second exercise was to put 20 balls on the screen. Each one is moved using a different thread. On the surface I was surprised what little computer resources the 20 threads used. My machine is dedicating 3 percent of its CPU to the bouncing balls app.&lt;br /&gt;&lt;br /&gt;I have some nice and smooth animation too. Every frame update causes the whole screen to be repainted. Right now I am using the basic Thread class to start up and Runnable. My main thread, which I assume is the event dispatch thread, updates the GUI on a timer (which happens to have its own thread).&lt;br /&gt;&lt;br /&gt;Next I should try a whole lot more threads. Or I could make the graphics more intense. I need to figure out where the performance bottleneck is, if any.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-3272978346776302663?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/3272978346776302663/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/10/multithreading.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3272978346776302663'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3272978346776302663'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/10/multithreading.html' title='Multithreading'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/-Cw_aZLMlbu0/Tp3rfqVWZxI/AAAAAAAAAM8/QjgTmiyysjo/s72-c/Balls.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-6221786273733919325</id><published>2011-10-13T11:58:00.002-04:00</published><updated>2011-10-13T12:03:12.540-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='KeyListener'/><category scheme='http://www.blogger.com/atom/ns#' term='JButton'/><category scheme='http://www.blogger.com/atom/ns#' term='events'/><category scheme='http://www.blogger.com/atom/ns#' term='listener'/><category scheme='http://www.blogger.com/atom/ns#' term='components'/><title type='text'>Eating the Keys</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/-yOywRiT2lVY/TpcK2oayjWI/AAAAAAAAAMw/d34cTNUc_as/s1600/Button.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 320px; height: 320px;" src="http://2.bp.blogspot.com/-yOywRiT2lVY/TpcK2oayjWI/AAAAAAAAAMw/d34cTNUc_as/s320/Button.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5663006990120684898" /&gt;&lt;/a&gt;I am learning about the finer points of GUI development with Java this week. It turns out there are some GUI basics in Java that I don't know about. So I am studying them first. One topic of interest is catching events. To practive, I started coding up an event viewer. It is supposed to get and print out events that fire based on a bunch of different GUI components.&lt;br /&gt;&lt;br /&gt;For the most part I can knock out the even viewer code. I am setting up listeners that log events to the screen. Then  I try to do a KeyListener. But my event handlers are not getting called. What the heck? Initially my text area control was displaying the keys. Okay. I disabled it. Still no keyboard events.&lt;br /&gt;&lt;br /&gt;I am a good debugger. I traced the issue down to the presence of a JButton on my GUI. If I remove the JButton, the keyboard events fire and I get the calls. What could be going on here? Is the JButton receiving and eating up the keyboard events? It looks like I am going to have to consult an expert here.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-6221786273733919325?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/6221786273733919325/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/10/eating-keys.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6221786273733919325'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6221786273733919325'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/10/eating-keys.html' title='Eating the Keys'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/-yOywRiT2lVY/TpcK2oayjWI/AAAAAAAAAMw/d34cTNUc_as/s72-c/Button.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-923335422012252338</id><published>2011-10-04T12:25:00.003-04:00</published><updated>2011-10-04T13:51:15.557-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='types'/><category scheme='http://www.blogger.com/atom/ns#' term='generics'/><category scheme='http://www.blogger.com/atom/ns#' term='templates'/><category scheme='http://www.blogger.com/atom/ns#' term='parameter'/><category scheme='http://www.blogger.com/atom/ns#' term='extends'/><title type='text'>The Need for Wildcards</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/-lWXr10cDwdY/ToszkHAheEI/AAAAAAAAAMo/gnjzBtIY43o/s1600/Wild.png"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 256px; height: 320px;" src="http://3.bp.blogspot.com/-lWXr10cDwdY/ToszkHAheEI/AAAAAAAAAMo/gnjzBtIY43o/s320/Wild.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5659674052170709058" /&gt;&lt;/a&gt;We are covering generics in my advanced Java community college class. The weak book has a tough time explaining concepts clearly. I get the main idea behind generics. Java gets to keep up with C++ templates. But then we get to something which does not seem right.&lt;br /&gt;&lt;br /&gt;Since the Integer class extends Number, you can pass in an Integer object when a function requires a Number parameter. That is clear. But when you use those types with a generic class such as Stack, things get weird. You cannot pass in an object of type Stack&lt;Integer&gt; when a function requires a Stack&lt;Number&gt; parameter. What the heck?&lt;br /&gt;&lt;br /&gt;Integer extends Number. The Stack is a Stack. Why can't Stack&lt;Integer&gt; act as a Stack&lt;Number&gt;. Makes no sense on the outside. The book cooked up some example to try to explain it away. I was still not convinced. Later I read about the use of wildcards to solve this problem. You get a Stack&lt;? extends Number&gt; argument type that can then receive a Stack&lt;Integer&gt;. But why do we need this new syntax in the first place. The textbook could not explain it. Time to dig deeper.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-923335422012252338?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/923335422012252338/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/10/need-for-wildcards.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/923335422012252338'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/923335422012252338'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/10/need-for-wildcards.html' title='The Need for Wildcards'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/-lWXr10cDwdY/ToszkHAheEI/AAAAAAAAAMo/gnjzBtIY43o/s72-c/Wild.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-5616102638920926628</id><published>2011-09-15T01:08:00.002-04:00</published><updated>2011-09-15T01:16:30.665-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='collection'/><category scheme='http://www.blogger.com/atom/ns#' term='map'/><category scheme='http://www.blogger.com/atom/ns#' term='Set'/><category scheme='http://www.blogger.com/atom/ns#' term='java.util'/><category scheme='http://www.blogger.com/atom/ns#' term='queue'/><category scheme='http://www.blogger.com/atom/ns#' term='list'/><title type='text'>Collections and Maps</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/-4yYRAwuVLt4/TnGIfpfP0_I/AAAAAAAAAMg/QvkdXqeIQNM/s1600/Collection.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 207px;" src="http://1.bp.blogspot.com/-4yYRAwuVLt4/TnGIfpfP0_I/AAAAAAAAAMg/QvkdXqeIQNM/s320/Collection.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5652449084620919794" /&gt;&lt;/a&gt;I have been studying up on the Java Collections Framework for the past week. It was hard to get a grasp on such a huge subject. Initially I had trouble figuring out what were the interfaces and what were the classes. With the help of Wikipedia and the Java API documentation, I think I am starting to understand it a little better.&lt;br /&gt;&lt;br /&gt;There are really two main things to get here - collections and maps. Collections is the bigger piece. The grandfather interface is Collection (from java.util.Collection). A couple important interfaces extend Collection. They are List, Queue, and Set. You then get a bunch of classes that implement these interfaces. Do not get confused by some base classes which are then extended to the classes you use on a daily bases.&lt;br /&gt;&lt;br /&gt;Maps are their own thing in that they store pairs of keys and values. Like the Collection interface, maps start with the Map interface. Then you have some classes that implement Map. Those classes are often extended to give you convenient classes to do your work.&lt;br /&gt;&lt;br /&gt;One thing that is common to all this is that you need to write some code to get a feel for using the collections and maps. When in doubt of the hierarchy, take a look at the UML diagrams from Wikipedia on &lt;a href="http://upload.wikimedia.org/wikipedia/commons/4/41/Collection_Classes.jpg"&gt;Collection&lt;/a&gt; and &lt;a href="http://upload.wikimedia.org/wikipedia/commons/1/1c/Map_Classes.jpg"&gt;Map&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-5616102638920926628?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/5616102638920926628/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/09/collections-and-maps.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5616102638920926628'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5616102638920926628'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/09/collections-and-maps.html' title='Collections and Maps'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/-4yYRAwuVLt4/TnGIfpfP0_I/AAAAAAAAAMg/QvkdXqeIQNM/s72-c/Collection.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-3473621650793625339</id><published>2011-09-12T00:17:00.002-04:00</published><updated>2011-09-12T00:25:48.415-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='map'/><category scheme='http://www.blogger.com/atom/ns#' term='HashMap'/><category scheme='http://www.blogger.com/atom/ns#' term='Set'/><category scheme='http://www.blogger.com/atom/ns#' term='HashSet'/><category scheme='http://www.blogger.com/atom/ns#' term='generics'/><title type='text'>Collections Framework</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/-PrTrgY_KLrM/Tm2IBuW0lNI/AAAAAAAAAMY/0u9eKRaWt1E/s1600/Collections.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 320px; height: 240px;" src="http://2.bp.blogspot.com/-PrTrgY_KLrM/Tm2IBuW0lNI/AAAAAAAAAMY/0u9eKRaWt1E/s320/Collections.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5651322670624838866" /&gt;&lt;/a&gt;This week my college class is doing the chapter on the Java Collections Framework. The textbook was very confusing. It looks like there are some interfaces to get familiar with. Then there are multiple classes that implement the interfaces. Other interfaces are involved as well. Initially I was overwhelmed. Now I am trying to focus on a few classes at a time.&lt;br /&gt;&lt;br /&gt;I found that Wikipedia has a good overview on the &lt;a href="http://en.wikipedia.org/wiki/Java_Collections"&gt;collections&lt;/a&gt;. The first class I got familiar with was the HashSet. This thing is a generic class. You need to pass in the type of the items that are stored in the collection. HasSet implements the Set interface. As such, it can only hold unique items in the collection. You add() items to the set. You can also check whether they are already ikn the set with a call to contains().&lt;br /&gt;&lt;br /&gt;The second class I played with is HashMap. Do you see a pattern forming here? This class implements the Map interface. You store key/value pairs with this thing. You need to specify the types of the key and value when you create the generic class. Then you put or get key/value pairs.&lt;br /&gt;&lt;br /&gt;Most of these collection-related items seems to be in java.util. Let's see if I can figure out all the other classes and interfaces. I am studying it hard.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-3473621650793625339?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/3473621650793625339/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/09/collections-framework.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3473621650793625339'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3473621650793625339'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/09/collections-framework.html' title='Collections Framework'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/-PrTrgY_KLrM/Tm2IBuW0lNI/AAAAAAAAAMY/0u9eKRaWt1E/s72-c/Collections.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-9104412875078048382</id><published>2011-09-01T09:21:00.003-04:00</published><updated>2011-09-01T09:26:12.114-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Liquid Robotics'/><category scheme='http://www.blogger.com/atom/ns#' term='Oracle'/><category scheme='http://www.blogger.com/atom/ns#' term='Google'/><title type='text'>James Gosling Makes a Move</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/-Ax8jI7Zr6k0/Tl-G6GgzNoI/AAAAAAAAAMQ/wycDYdekTLA/s1600/Gosling.png"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 142px; height: 197px;" src="http://1.bp.blogspot.com/-Ax8jI7Zr6k0/Tl-G6GgzNoI/AAAAAAAAAMQ/wycDYdekTLA/s320/Gosling.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5647380790484612738" /&gt;&lt;/a&gt;I just read a post about &lt;a href="http://nighthacks.com/roller/jag/entry/i_ve_moved_again"&gt;James Gosling&lt;/a&gt; quitting Google corporation. He has moved on to work at Liquid Robotics. What a name for a company. The guys is going to be chief architect there. This is surprising. I thought Google would have been keeping him happy and well paid. Perhaps sometimes you need to make a change, or work for the little guy.&lt;br /&gt;&lt;br /&gt;In the rare instance that you do not know, James Gosling is the inventor of the Java programming language. He did that back when he worked for Sun Microsystems (which has since been acquired by &lt;a href="http://ora-pl-sql.blogspot.com/"&gt;Oracle&lt;/a&gt;). Poor Google. Gosling only lasted 6 months there. Is there more to this story?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-9104412875078048382?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/9104412875078048382/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/09/james-gosling-makes-move.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/9104412875078048382'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/9104412875078048382'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/09/james-gosling-makes-move.html' title='James Gosling Makes a Move'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/-Ax8jI7Zr6k0/Tl-G6GgzNoI/AAAAAAAAAMQ/wycDYdekTLA/s72-c/Gosling.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-6599946669842337859</id><published>2011-08-02T22:14:00.002-04:00</published><updated>2011-08-02T22:19:28.692-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='recursion'/><category scheme='http://www.blogger.com/atom/ns#' term='college'/><category scheme='http://www.blogger.com/atom/ns#' term='class'/><title type='text'>Advanced Java</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/-Jg0M1czLMhU/TjivNRbY1TI/AAAAAAAAAMI/NoM9TksgUfk/s1600/Advanced.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 320px; height: 213px;" src="http://4.bp.blogspot.com/-Jg0M1czLMhU/TjivNRbY1TI/AAAAAAAAAMI/NoM9TksgUfk/s320/Advanced.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5636447576205612338" /&gt;&lt;/a&gt;I have been away from the Java programming language for almost the whole summer. There was an app I wanted to write. But I needed it to work quick. So I fell back to using C++. Now I want to get back into the Java swing of things (no pun intended). This week I signed up for a community college course on Advanced Java.&lt;br /&gt;&lt;br /&gt;I was a little shocked by the price of the class. It rang up to around $800. That does not even cover the cost of the book. I thought community college was supposed ot be inexpensive. It might be worth it though. We are supposed to cover topics such as collections, multithreading, generics, database programming, network programming, and Java Server Pages. Dang. That's quite a list.&lt;br /&gt;&lt;br /&gt;To get my Java skills back, I decided to read the first chapter from the class textbook. It is on recusion. The Java syntax for recursion is simple enough. Understanding the technique of generating a recursive algorithm to solve a problem is hard. With the new Java class coming up at the end of the month, I think I will  be more chatty on my blog about Java points of interest.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-6599946669842337859?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/6599946669842337859/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/08/advanced-java.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6599946669842337859'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6599946669842337859'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/08/advanced-java.html' title='Advanced Java'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/-Jg0M1czLMhU/TjivNRbY1TI/AAAAAAAAAMI/NoM9TksgUfk/s72-c/Advanced.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-2505357212867844046</id><published>2011-05-09T10:16:00.002-04:00</published><updated>2011-05-09T10:22:36.839-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='jar'/><category scheme='http://www.blogger.com/atom/ns#' term='applet'/><category scheme='http://www.blogger.com/atom/ns#' term='executable'/><category scheme='http://www.blogger.com/atom/ns#' term='JRE'/><category scheme='http://www.blogger.com/atom/ns#' term='Jat Web Start'/><title type='text'>Deployment Options</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/-tSJUwE2BEGo/Tcf3cxZqRLI/AAAAAAAAAL8/tWE0yZu3n-0/s1600/Deploy.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 300px; height: 300px;" src="http://3.bp.blogspot.com/-tSJUwE2BEGo/Tcf3cxZqRLI/AAAAAAAAAL8/tWE0yZu3n-0/s320/Deploy.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5604720334955234482" /&gt;&lt;/a&gt;I got a new idea for a computer program I want to write. First I need to walk the thing all the way through to completion. I need users to be able to run this program on their own machines. I am thinking about using Java for the coding, but want to ensure a smooth user experience.&lt;br /&gt;&lt;br /&gt;To run the Java bytecode on their machines, the users will need the Java Runtime Environment. What if they do not have it on their machine? Or what if they have the wrong version? I need my software to work the very first time, and every time after that.&lt;br /&gt;&lt;br /&gt;I did some research on the subject. I can package up my files as a jar. However this still requires the JRE to be installed. Or I could go the web way and use Java Web Start. That would require me to set up a web server to host the apps. Then they will get downloaded to the user machine. That might require too much infrastructure for me.&lt;br /&gt;&lt;br /&gt;I could also distribute the program as an applet. Then the whole thing runs in the browser. This also requires some infrastructure. But it will just be a web page. I do not have a lot of experience with applets using Java. That is a consideration.&lt;br /&gt;&lt;br /&gt;Finally there are some compilers that produce executables that run directly on the user's native machine. This is the next best thing to developing with a language like C++ and compiling a version for the target machine. I need to play with ohe of these programs that produces a stand alone Java executable before I make a final decision.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-2505357212867844046?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/2505357212867844046/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/05/deployment-options.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2505357212867844046'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2505357212867844046'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/05/deployment-options.html' title='Deployment Options'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/-tSJUwE2BEGo/Tcf3cxZqRLI/AAAAAAAAAL8/tWE0yZu3n-0/s72-c/Deploy.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-5458319891681903765</id><published>2011-05-03T15:42:00.002-04:00</published><updated>2011-05-03T15:47:22.676-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='class'/><category scheme='http://www.blogger.com/atom/ns#' term='skills'/><category scheme='http://www.blogger.com/atom/ns#' term='switch'/><category scheme='http://www.blogger.com/atom/ns#' term='utilities'/><category scheme='http://www.blogger.com/atom/ns#' term='label'/><title type='text'>Back to Java</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/-JrLeaAiQdqk/TcBazy-4E5I/AAAAAAAAAL0/zrxKtRf-jn8/s1600/Switch.JPG"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 317px; FLOAT: left; HEIGHT: 142px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5602577782354219922" border="0" alt="" src="http://2.bp.blogspot.com/-JrLeaAiQdqk/TcBazy-4E5I/AAAAAAAAAL0/zrxKtRf-jn8/s320/Switch.JPG" /&gt;&lt;/a&gt;I have been spending time learning JavaScript over the past year or so. However now it is time to return to Java. Later this year I plan to take an advanced Java class in school. However for now I am writing some small utlities in Java.&lt;br /&gt;&lt;br /&gt;I was surprised at how rusty I got. You need to use your skills to keep them current. I coded a simple switch statement. Being a good developer, I tried to use some constants in the labels of the switch statement. They did not work. Ooops. I forgot to make those constants "final".&lt;br /&gt;&lt;br /&gt;There was something that surprised me a bit. I put together a switch statement that initialized a variable. I included a default label in the switch clause. So all paths through would get the variable initialized. However the compiler still gave me a warning that the variable might not be initialized.&lt;br /&gt;&lt;br /&gt;It was a small thing. But I don't want any warnings in my code. So I had to blatantly initiallize my variable. Not so clean.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-5458319891681903765?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/5458319891681903765/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/05/back-to-java.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5458319891681903765'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5458319891681903765'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/05/back-to-java.html' title='Back to Java'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/-JrLeaAiQdqk/TcBazy-4E5I/AAAAAAAAAL0/zrxKtRf-jn8/s72-c/Switch.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-481916259135439607</id><published>2011-03-14T15:26:00.003-04:00</published><updated>2011-03-14T15:30:26.853-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='configuration'/><category scheme='http://www.blogger.com/atom/ns#' term='OTAP'/><category scheme='http://www.blogger.com/atom/ns#' term='Java ME'/><category scheme='http://www.blogger.com/atom/ns#' term='connected'/><title type='text'>Java Micro Edition</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/-_ofBec0I2SA/TX5r38HmbBI/AAAAAAAAALs/IvCUAZp5wHc/s1600/Micro.jpg"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 301px; FLOAT: left; HEIGHT: 312px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5584019196760976402" border="0" alt="" src="http://2.bp.blogspot.com/-_ofBec0I2SA/TX5r38HmbBI/AAAAAAAAALs/IvCUAZp5wHc/s320/Micro.jpg" /&gt;&lt;/a&gt;Oracle seems to be standing behind Java Micro Edition (Java ME). The mobile market relies heavy on Java. It is good for developers too since Java lends itself to cross platform development.&lt;br /&gt;&lt;br /&gt;There are three layers to Java ME: (1) configuration, (2) profile, and (3) packages. The configurations are further divided into two flavors. You have connected and connected limited &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;configs&lt;/span&gt;. The difference is how powerful the target device is.&lt;br /&gt;&lt;br /&gt;Java ME supports "over the air provisioning", or &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-error"&gt;OTAP&lt;/span&gt;. This allows you to install Java apps over the wireless network. Java ME also provides things such as security, &lt;span id="SPELLING_ERROR_2" class="blsp-spelling-error"&gt;UIs&lt;/span&gt;, and offline support.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-481916259135439607?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/481916259135439607/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/03/java-micro-edition.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/481916259135439607'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/481916259135439607'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/03/java-micro-edition.html' title='Java Micro Edition'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/-_ofBec0I2SA/TX5r38HmbBI/AAAAAAAAALs/IvCUAZp5wHc/s72-c/Micro.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-4317559110176141283</id><published>2011-03-10T14:52:00.004-05:00</published><updated>2011-03-10T14:57:59.821-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='select'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><category scheme='http://www.blogger.com/atom/ns#' term='game'/><title type='text'>JavaScript Forms</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/-Lre9E-ibxj0/TXksA83i_KI/AAAAAAAAALk/dbX3IsJLaEA/s1600/Form.png"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 320px; FLOAT: left; HEIGHT: 286px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5582541607953169570" border="0" alt="" src="http://1.bp.blogspot.com/-Lre9E-ibxj0/TXksA83i_KI/AAAAAAAAALk/dbX3IsJLaEA/s320/Form.png" /&gt;&lt;/a&gt;I am working on development a web app &lt;a href="http://legend-angband.blogspot.com/"&gt;game&lt;/a&gt;. It is being written in JavaScript. I had learned how to do forms, so I made the game use a form. The majority of the screen is a big select area. I was going crazy because my JavaScript code was generating errors. The browser &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-corrected"&gt;kept&lt;/span&gt; complaining that document.forms[0].mySelect was either NULL or not an object.&lt;br /&gt;&lt;br /&gt;This was troubling because I had coded &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-corrected"&gt;successful&lt;/span&gt; projects that used this technique. Googling the web also showed many examples of this working. To get by I &lt;a href="http://black-of-hat.blogspot.com/"&gt;hacked&lt;/a&gt; some &lt;span id="SPELLING_ERROR_2" class="blsp-spelling-error"&gt;getElementById&lt;/span&gt; calls instead. It still troubled my. I was running Internet Explorer 8. This stuff should have been working.&lt;br /&gt;&lt;br /&gt;Near the end of my game development cycle I had to add more items to the form such as a status message. That is when I found the root cause of the problem. The select element was not within the form tags in the HTML. Ouch. No wonder JavaScript could not access the select object. It was just not part of the form. Now I got an action item to go back and use the familiar technique to access the form data in JavaScript code.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-4317559110176141283?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/4317559110176141283/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/03/javascript-forms.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/4317559110176141283'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/4317559110176141283'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/03/javascript-forms.html' title='JavaScript Forms'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/-Lre9E-ibxj0/TXksA83i_KI/AAAAAAAAALk/dbX3IsJLaEA/s72-c/Form.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-2358622963906918556</id><published>2011-02-02T11:22:00.001-05:00</published><updated>2011-02-02T11:26:15.843-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='GlassFish'/><category scheme='http://www.blogger.com/atom/ns#' term='REST'/><category scheme='http://www.blogger.com/atom/ns#' term='JDBC'/><category scheme='http://www.blogger.com/atom/ns#' term='JBoss'/><category scheme='http://www.blogger.com/atom/ns#' term='Weblogic'/><title type='text'>Java Enterprise Edition is Dead</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/TUmE8-R2MxI/AAAAAAAAALU/CrQvVr9GdM8/s1600/Dead.jpg"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 320px; FLOAT: left; HEIGHT: 267px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5569128597265199890" border="0" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/TUmE8-R2MxI/AAAAAAAAALU/CrQvVr9GdM8/s320/Dead.jpg" /&gt;&lt;/a&gt;I am reading an opinion piece on Java &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;EE&lt;/span&gt;. It states that that there were two winners for application servers. There was &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-error"&gt;WebLogic&lt;/span&gt; which was best. And there was &lt;span id="SPELLING_ERROR_2" class="blsp-spelling-error"&gt;JBoss&lt;/span&gt; that was free. However web services and REST seemed to take away their steam.&lt;br /&gt;&lt;br /&gt;Do you actually need an app server? Maybe you can just get by with plain old &lt;span id="SPELLING_ERROR_3" class="blsp-spelling-error"&gt;JDBC&lt;/span&gt;. Here is the killer stat which might prove Java &lt;span id="SPELLING_ERROR_4" class="blsp-spelling-error"&gt;EE&lt;/span&gt; is a dead end. Nobody implements Java &lt;span id="SPELLING_ERROR_5" class="blsp-spelling-error"&gt;EE&lt;/span&gt; 6. There is only open source &lt;span id="SPELLING_ERROR_6" class="blsp-spelling-error"&gt;GlassFish&lt;/span&gt;. Ouch.&lt;br /&gt;&lt;br /&gt;Java is not dead. But Java Enterprise Edition may very well be. I am glad I did not spend too much time with Java &lt;span id="SPELLING_ERROR_7" class="blsp-spelling-error"&gt;EE&lt;/span&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-2358622963906918556?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/2358622963906918556/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/02/java-enterprise-edition-is-dead.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2358622963906918556'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2358622963906918556'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/02/java-enterprise-edition-is-dead.html' title='Java Enterprise Edition is Dead'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/TUmE8-R2MxI/AAAAAAAAALU/CrQvVr9GdM8/s72-c/Dead.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-3583034056848058690</id><published>2011-01-25T13:27:00.003-05:00</published><updated>2011-01-25T13:30:37.002-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='server'/><category scheme='http://www.blogger.com/atom/ns#' term='Sun Microsystems'/><category scheme='http://www.blogger.com/atom/ns#' term='middleware'/><category scheme='http://www.blogger.com/atom/ns#' term='trademark'/><title type='text'>Oracle Positioning Java for the Enterprise</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TT8WGflJMWI/AAAAAAAAALM/QfsC48ywkJU/s1600/Enterprise.jpg"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 320px; FLOAT: left; HEIGHT: 240px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5566191965265539426" border="0" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TT8WGflJMWI/AAAAAAAAALM/QfsC48ywkJU/s320/Enterprise.jpg" /&gt;&lt;/a&gt;I read a couple articles stating the Oracle is positioning Java for the enterprise market. Specifically they intend for it to be used mainly for enterprise &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;middleware&lt;/span&gt;. Thus Java will be poised to run on the server side.&lt;br /&gt;&lt;br /&gt;Oracle has the trademark to Java. They plan to use this influence to direct the future of Java. Their latest plans are in stark contrast to Sun &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-error"&gt;Microsystems&lt;/span&gt;, who had a more broad perspective on the application of Java.&lt;br /&gt;&lt;br /&gt;Personally I don't care what Oracle plans. Right now I am writing a program to run on my workstation (client). And it is being written in Java. The developers will truly shape how Java is going to be used. Don't worry where Oracle wants to take Java. They will come around.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-3583034056848058690?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/3583034056848058690/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2011/01/oracle-positioning-java-for-enterprise.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3583034056848058690'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3583034056848058690'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2011/01/oracle-positioning-java-for-enterprise.html' title='Oracle Positioning Java for the Enterprise'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TT8WGflJMWI/AAAAAAAAALM/QfsC48ywkJU/s72-c/Enterprise.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-430461830815826866</id><published>2010-11-08T11:31:00.002-05:00</published><updated>2010-11-08T11:34:41.655-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Sun Microsystems'/><category scheme='http://www.blogger.com/atom/ns#' term='JDK'/><category scheme='http://www.blogger.com/atom/ns#' term='database'/><title type='text'>Oracle in Charge</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TNgl7oLbZ5I/AAAAAAAAALA/DpUcvoaJTMo/s1600/Oracle.jpg"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 217px; FLOAT: left; HEIGHT: 320px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5537217448179885970" border="0" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TNgl7oLbZ5I/AAAAAAAAALA/DpUcvoaJTMo/s320/Oracle.jpg" /&gt;&lt;/a&gt;I needed to compile an applet I wrote a year or two ago. However I have this new laptop at home. No problem. I decided to download and install the latest Java Development Kit from Sun. &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;Ooops&lt;/span&gt;. They are not Sun &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-error"&gt;Microsystems&lt;/span&gt; any more. &lt;a href="http://ora-pl-sql.blogspot.com/"&gt;Oracle&lt;/a&gt; bought them out.&lt;br /&gt;&lt;br /&gt;It was clearly evident from the new install program. The &lt;span id="SPELLING_ERROR_2" class="blsp-spelling-error"&gt;JDK&lt;/span&gt; install prominently displayed Oracle Corporation on the screen. They are the new master now. It remains to be seen whether this is a good thing or not. I do know one fact. Oracle is not going anywhere in the near future. They got profits from their databases and other offerings.&lt;br /&gt;&lt;br /&gt;Maybe Oracle can take Java to the next level.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-430461830815826866?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/430461830815826866/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/11/oracle-in-charge.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/430461830815826866'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/430461830815826866'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/11/oracle-in-charge.html' title='Oracle in Charge'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TNgl7oLbZ5I/AAAAAAAAALA/DpUcvoaJTMo/s72-c/Oracle.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-4703446049254192806</id><published>2010-10-26T14:41:00.002-04:00</published><updated>2010-10-26T14:46:01.075-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='random numbers'/><category scheme='http://www.blogger.com/atom/ns#' term='parameters'/><category scheme='http://www.blogger.com/atom/ns#' term='game development'/><title type='text'>Guessing can be Hot</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/TMcg7Vs2UqI/AAAAAAAAAK4/x-0pIhcD4kQ/s1600/Guess.jpg"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 320px; FLOAT: left; HEIGHT: 216px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5532426871057568418" border="0" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/TMcg7Vs2UqI/AAAAAAAAAK4/x-0pIhcD4kQ/s320/Guess.jpg" /&gt;&lt;/a&gt;I read this blog entry by a seasoned game developer. He gives hints on how to practically come up to speed on game development. Strangely enough, he advises you to truly start at the beginning. Assignment number 1 is to write a number guessing game. My Java skills are a bit rusty. So I figured I would give it a go.&lt;br /&gt;&lt;br /&gt;Here is the stickler. I could not recall how to generate random numbers. Sure I can look it up with Google. But a strong Java developer knows this stuff by heart. I seemed to recall Math.random once I saw it. But that is for doubles. I needed some &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;ints&lt;/span&gt;. And the java.util.Random class was just what the doctor ordered.&lt;br /&gt;&lt;br /&gt;You can &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-corrected"&gt;instantiate&lt;/span&gt; the Random class without any parameters. Or you can pass a seed for the random number generated as a parameter to the constructor. Once you have a Random object, just call the &lt;span id="SPELLING_ERROR_2" class="blsp-spelling-error"&gt;nextInt&lt;/span&gt; method and you get a number between 0 and n-1 (n is the parameter you pass &lt;span id="SPELLING_ERROR_3" class="blsp-spelling-error"&gt;nextInt&lt;/span&gt;).&lt;br /&gt;&lt;br /&gt;Now I had my number guessing program working in no time. I decided to add a little spice to the program that was not required. No I don't have Guess jeans models popping up on the screen. I just let the user keep guessing until they arrive at the solution. And I throw in some taunts as responses when you guess is wrong. Good stuff.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-4703446049254192806?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/4703446049254192806/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/10/guessing-can-be-hot.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/4703446049254192806'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/4703446049254192806'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/10/guessing-can-be-hot.html' title='Guessing can be Hot'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/TMcg7Vs2UqI/AAAAAAAAAK4/x-0pIhcD4kQ/s72-c/Guess.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7878024869538581278</id><published>2010-09-26T00:07:00.002-04:00</published><updated>2010-09-26T00:10:58.170-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='web app'/><category scheme='http://www.blogger.com/atom/ns#' term='product'/><category scheme='http://www.blogger.com/atom/ns#' term='prototype'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><title type='text'>Java App Version One</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/TJ7G-xfB1qI/AAAAAAAAAKw/h0SPaj_MOU0/s1600/Blackboard.jpg"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 320px; FLOAT: left; HEIGHT: 230px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5521068974940477090" border="0" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/TJ7G-xfB1qI/AAAAAAAAAKw/h0SPaj_MOU0/s320/Blackboard.jpg" /&gt;&lt;/a&gt;It is about time for me to get down to business and code a prototype for my app ideas. Previously I had thought I needed a polished product. But version 1 does not need all that. It just needs to get done. Then I will try it out for myself and see what to change in version 2.&lt;br /&gt;&lt;br /&gt;Of &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-corrected"&gt;course&lt;/span&gt; I am going to use Java as the programming language. The eventual product will be a web app displayed in HTML. However the first version might even just be text based. We shall see. I will probably post a link to my alpha version when it is ready for distribution.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7878024869538581278?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7878024869538581278/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/09/java-app-version-one.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7878024869538581278'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7878024869538581278'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/09/java-app-version-one.html' title='Java App Version One'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/TJ7G-xfB1qI/AAAAAAAAAKw/h0SPaj_MOU0/s72-c/Blackboard.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7623761304298622211</id><published>2010-08-20T13:52:00.003-04:00</published><updated>2010-08-20T13:58:32.524-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='metrics'/><category scheme='http://www.blogger.com/atom/ns#' term='problems'/><category scheme='http://www.blogger.com/atom/ns#' term='refactor'/><title type='text'>SonarJ Architecture Review</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/_wOFRh11vB8g/TG7BBEEx5tI/AAAAAAAAAKg/QEIY51uKM6E/s1600/Sonar.gif"&gt;&lt;img id="BLOGGER_PHOTO_ID_5507551618338514642" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 318px; CURSOR: hand; HEIGHT: 273px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/TG7BBEEx5tI/AAAAAAAAAKg/QEIY51uKM6E/s320/Sonar.gif" border="0" /&gt;&lt;/a&gt;We have a relatively new developer on our project. He is a seasoned application developer. So you know he gets down into the trenches of our source code. It is funny how he is disturbed about how many things were done wrong in our system. Many of us know about these problems. But we are too busy or too worried about breaking things to fix them.&lt;br /&gt;&lt;br /&gt;There is a new version of a solution called &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;SonarJ&lt;/span&gt; that could assist with our problems. It analyzes code and detects your application architectures, and identifies things you have done wrong. You can get a clear view of how bad things are with their metric dashboard.&lt;br /&gt;&lt;br /&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;SonarJ&lt;/span&gt; goes even further by projecting the impact of refactoring your code. It does this without disrupting your code baseline. The tool can grab code from your &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;IDE&lt;/span&gt; or your build project. And if it was not clear from the name, the tool targets code written in the Java programming language.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7623761304298622211?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7623761304298622211/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/08/sonarj-architecture-review.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7623761304298622211'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7623761304298622211'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/08/sonarj-architecture-review.html' title='SonarJ Architecture Review'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/TG7BBEEx5tI/AAAAAAAAAKg/QEIY51uKM6E/s72-c/Sonar.gif' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-8495206995535445161</id><published>2010-08-11T12:42:00.003-04:00</published><updated>2010-08-11T12:47:59.327-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='interfaces'/><category scheme='http://www.blogger.com/atom/ns#' term='delegation'/><category scheme='http://www.blogger.com/atom/ns#' term='observer pattern'/><category scheme='http://www.blogger.com/atom/ns#' term='components'/><title type='text'>Event Based</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/TGLS_2pphRI/AAAAAAAAAKY/ye3-jYGfRDg/s1600/Event.png"&gt;&lt;img id="BLOGGER_PHOTO_ID_5504193689043961106" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/TGLS_2pphRI/AAAAAAAAAKY/ye3-jYGfRDg/s320/Event.png" border="0" /&gt;&lt;/a&gt;Java has always used event based programming to deal with user interfaces. Initially would generate events and send them to components. The component would information the system whether it processed the event. If so, that was the end of the processing. Otherwise the system would forward the event to another component, and so on until one did process the event.&lt;br /&gt;&lt;br /&gt;By the time Java 1.1 was released, event processing had changed. A new delegation model was adopted which implements the observer pattern. Any components interested in an event implement a listener interface. They register with the system to handle the event. This makes the system's job easier. When the event fires, all &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;listeners&lt;/span&gt; registered for that event get notified. More than one component can receive and process the event.&lt;br /&gt;&lt;br /&gt;If your component's event processing is going to take any real time, you should do the work in a separate worker thread to keep the system responsive for the user.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-8495206995535445161?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/8495206995535445161/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/08/event-based.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8495206995535445161'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8495206995535445161'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/08/event-based.html' title='Event Based'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/TGLS_2pphRI/AAAAAAAAAKY/ye3-jYGfRDg/s72-c/Event.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-2812560407529142305</id><published>2010-08-10T15:01:00.004-04:00</published><updated>2010-08-10T15:13:02.205-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='LayoutManager'/><category scheme='http://www.blogger.com/atom/ns#' term='java.awt'/><category scheme='http://www.blogger.com/atom/ns#' term='container'/><category scheme='http://www.blogger.com/atom/ns#' term='components'/><title type='text'>Abstract Window Toolkit</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/_wOFRh11vB8g/TGGiM5MDJrI/AAAAAAAAAKQ/etbZhm3XrSE/s1600/AWT.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5503858562016945842" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 313px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/TGGiM5MDJrI/AAAAAAAAAKQ/etbZhm3XrSE/s320/AWT.JPG" border="0" /&gt;&lt;/a&gt;I have read an intro chapter on the Abstract Window Toolkit (&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;AWT&lt;/span&gt;). It is implemented via the "java.&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;awt&lt;/span&gt;" package. The package provides a number of graphic user interface components. Examples are buttons, &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;scrollbars&lt;/span&gt;, and &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;checkboxes&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Two of the most useful components are the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;TextField&lt;/span&gt; and &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;TextArea&lt;/span&gt;. The &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_6"&gt;TextField&lt;/span&gt; is a single line of input from the user, while the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_7"&gt;TextArea&lt;/span&gt; is a multiple line edit control.&lt;br /&gt;&lt;br /&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_8"&gt;Checkboxes&lt;/span&gt; are components. They can be grouped using a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_9"&gt;CheckboxGroup&lt;/span&gt; class, which itself is not a component.&lt;br /&gt;&lt;br /&gt;A &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_10"&gt;LayoutManager&lt;/span&gt; interface has been defined to determine how components are placed on a screen. There are 5 different implementations of the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_11"&gt;LayoutManager&lt;/span&gt; provided to you by the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_12"&gt;AWT&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Let's talk about a few more &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_13"&gt;AWT&lt;/span&gt; concepts. A container is an area on the screen which holds other components. A windows is a top level one on the screen that has no menu bar or border. It is &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_14"&gt;used to&lt;/span&gt; create &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_15"&gt;popup&lt;/span&gt; messages. If the user provides input in a such a &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_16"&gt;window&lt;/span&gt;, it is then called a dialog. A frame, on the other hand, is a window that has a title, border, and buttons like maximize/minimize.&lt;br /&gt;&lt;br /&gt;The last idea which I shall expound upon later is that of events. The entire &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_18"&gt;AWT&lt;/span&gt; system is driven by events. &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_19"&gt;AWT&lt;/span&gt; manages these events, and sends them to interested components. For example, an event is generated when the user clicks the mouse button. The &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_20"&gt;AWT&lt;/span&gt; catches this, and sends the information to component(s) that had previously requested mouse press events.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-2812560407529142305?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/2812560407529142305/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/08/abstract-window-toolkit.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2812560407529142305'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2812560407529142305'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/08/abstract-window-toolkit.html' title='Abstract Window Toolkit'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/TGGiM5MDJrI/AAAAAAAAAKQ/etbZhm3XrSE/s72-c/AWT.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-5148722629599926404</id><published>2010-08-09T15:14:00.002-04:00</published><updated>2010-08-09T15:21:41.809-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Jakarta'/><category scheme='http://www.blogger.com/atom/ns#' term='Indonesia'/><category scheme='http://www.blogger.com/atom/ns#' term='components'/><title type='text'>Origins of Java</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TGBTzIAlwRI/AAAAAAAAAKI/6XrRc8gsO_Q/s1600/Indonesia.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5503490882435137810" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 214px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TGBTzIAlwRI/AAAAAAAAAKI/6XrRc8gsO_Q/s320/Indonesia.jpg" border="0" /&gt;&lt;/a&gt;A Java game programming book uses the &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;Abstract&lt;/span&gt; Window Toolkit. So I thought I would read up on it a bit. There are some free materials online that cover this older technology. I figure what I learn can also help in my learning of newer GUI frameworks.&lt;br /&gt;&lt;br /&gt;The book I read online claims that the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;AWT&lt;/span&gt; is crucial for Java programmers to learn. Initially there were major changes in &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;AWT&lt;/span&gt; before it stabilized. Here is a funny thing. Part of the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;AWT&lt;/span&gt; intro explained the origins of the word Java.&lt;br /&gt;&lt;br /&gt;Java is actually an island in Indonesia. It is not just any island. A whopping 124 million people live on the island. That is more than half the population of Indonesia. The capital of Java is Jakarta. This explains the naming for the Apache Jakarta project.&lt;br /&gt;&lt;br /&gt;Next time I will get into some of the components that the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;AWT&lt;/span&gt; has to offer.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-5148722629599926404?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/5148722629599926404/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/08/origins-of-java.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5148722629599926404'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5148722629599926404'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/08/origins-of-java.html' title='Origins of Java'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TGBTzIAlwRI/AAAAAAAAAKI/6XrRc8gsO_Q/s72-c/Indonesia.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-3527986799286101994</id><published>2010-08-06T10:28:00.002-04:00</published><updated>2010-08-06T10:28:00.157-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='classpath'/><category scheme='http://www.blogger.com/atom/ns#' term='java.sql'/><category scheme='http://www.blogger.com/atom/ns#' term='OracleDriver'/><category scheme='http://www.blogger.com/atom/ns#' term='deprecated'/><title type='text'>Accessing an Oracle Database</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TFl5MEvs2TI/AAAAAAAAAKA/K5boxmp7Uio/s1600/Oracle.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5501561668148975922" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 230px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TFl5MEvs2TI/AAAAAAAAAKA/K5boxmp7Uio/s320/Oracle.jpg" border="0" /&gt;&lt;/a&gt;I am using &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;JDBC&lt;/span&gt; to access an Oracle database using a Java program. To get up and running quick, I grabbed some code off the web. After importing java.sql.*, the thing compiled fine. However when I ran my program, I got some exceptions.&lt;br /&gt;&lt;br /&gt;The first exception was that the class "oracle.jdbc.driver.OracleDriver" was not found. &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;Ooops&lt;/span&gt;. Then I found out that this class had been deprecated. Fine. I replaced it with "oracle.jdbc.OracleDriver". That also generated an exception. There was also exceptions when I tried to make a database connection. The were due to there not being a driver. I figured that I needed to solve the root problem before proceeding.&lt;br /&gt;&lt;br /&gt;There were a number of web pages that said I needed the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;JDBC&lt;/span&gt; driver installed on my system. I grabbed the "&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;ojdbc&lt;/span&gt;14.jar" file and stuck it in a number of lib folders on my machine. No luck. I thought it might be due to the fact that I had a later version of the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;JRE&lt;/span&gt; and &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;JDK&lt;/span&gt;. Turns out I needed the jar file in my &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_6"&gt;classpath&lt;/span&gt;. Once I did that, the program worked fine. Now I am inserting a lot of database in my database. Maybe later I will post some code snippets.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-3527986799286101994?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/3527986799286101994/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/08/accessing-oracle-database.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3527986799286101994'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3527986799286101994'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/08/accessing-oracle-database.html' title='Accessing an Oracle Database'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TFl5MEvs2TI/AAAAAAAAAKA/K5boxmp7Uio/s72-c/Oracle.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-6562738621136340936</id><published>2010-08-05T10:16:00.003-04:00</published><updated>2010-08-05T10:16:00.333-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='thin driver'/><category scheme='http://www.blogger.com/atom/ns#' term='ODBC'/><category scheme='http://www.blogger.com/atom/ns#' term='KPRB'/><category scheme='http://www.blogger.com/atom/ns#' term='OCI'/><category scheme='http://www.blogger.com/atom/ns#' term='SQL*Net'/><title type='text'>JDBC Drivers</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/_wOFRh11vB8g/TFl2TrHEoUI/AAAAAAAAAJ4/0IyeJplN4QY/s1600/Driver.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5501558500171751746" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 186px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/TFl2TrHEoUI/AAAAAAAAAJ4/0IyeJplN4QY/s320/Driver.jpg" border="0" /&gt;&lt;/a&gt;I am using the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;JDBC&lt;/span&gt; technology to access an Oracle database from a Java program. This technology requires you to use one of its drivers to do the access. There are different categories of drivers you can use to access Oracle.&lt;br /&gt;&lt;br /&gt;One driver category is a thin driver. It has its own version of &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;SQL&lt;/span&gt;*Net. In other words, you do not also need an Oracle client installed on your machine in addition to the driver. This category of driver is written in the Java programming language itself. There is also an &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;OCI&lt;/span&gt; category or driver, that uses Oracle's Oracle Call Interface (&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;OCI&lt;/span&gt;). The final category is a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;KPRB&lt;/span&gt; driver used for writing stored procedures and triggers in Java.&lt;br /&gt;&lt;br /&gt;Besides the categories of drivers, there are also different levels of drivers. The first type is a bridge, where &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;JDBC&lt;/span&gt; makes use of &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_6"&gt;ODBC&lt;/span&gt; installed on your machine. &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_7"&gt;ODBC&lt;/span&gt; is a generic database access technology. Other types are differentiated by whether the drivers themselves are written in Java, and how the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_8"&gt;SQL&lt;/span&gt; code is translated and sent to the database.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-6562738621136340936?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/6562738621136340936/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/08/jdbc-drivers.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6562738621136340936'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6562738621136340936'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/08/jdbc-drivers.html' title='JDBC Drivers'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/TFl2TrHEoUI/AAAAAAAAAJ4/0IyeJplN4QY/s72-c/Driver.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-3873279280268381772</id><published>2010-08-04T10:11:00.003-04:00</published><updated>2010-08-04T10:15:19.488-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='databases'/><category scheme='http://www.blogger.com/atom/ns#' term='package'/><category scheme='http://www.blogger.com/atom/ns#' term='commit'/><category scheme='http://www.blogger.com/atom/ns#' term='Java SE 6'/><category scheme='http://www.blogger.com/atom/ns#' term='driver'/><title type='text'>JDBC Data Access</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TFl1H9OVH3I/AAAAAAAAAJw/hkdE6ftcSbA/s1600/JDBC.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5501557199363972978" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 240px; CURSOR: hand; HEIGHT: 240px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TFl1H9OVH3I/AAAAAAAAAJw/hkdE6ftcSbA/s320/JDBC.jpg" border="0" /&gt;&lt;/a&gt;I have been talking about this new project I am working on. There are a lot of URLs that I want to scrape. The first task is to put the list into a database. I have decided to use &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;JDBC&lt;/span&gt; to access the database from my Java program.&lt;br /&gt;&lt;br /&gt;Java Standard Edition 6 comes with the "java.&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;sql&lt;/span&gt;" package. You should import all the classes in that package. &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;JDBC&lt;/span&gt; requires a driver to run. You load the driver in your code with a Class.&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;forName&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Any &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;SQL&lt;/span&gt; can be sent to the database using &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;JDBC&lt;/span&gt;. By default, the objects used to connect to the database automatically commit after each statement. You should use the close method on the connection object to free database resources.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-3873279280268381772?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/3873279280268381772/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/08/jdbc-data-access.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3873279280268381772'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3873279280268381772'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/08/jdbc-data-access.html' title='JDBC Data Access'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TFl1H9OVH3I/AAAAAAAAAJw/hkdE6ftcSbA/s72-c/JDBC.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-6890738089325840395</id><published>2010-08-02T15:01:00.003-04:00</published><updated>2010-08-02T15:04:55.428-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='huge file'/><category scheme='http://www.blogger.com/atom/ns#' term='databases'/><category scheme='http://www.blogger.com/atom/ns#' term='UNIX head'/><category scheme='http://www.blogger.com/atom/ns#' term='JDBC'/><title type='text'>Scanner Comes Through</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TFcWBGH61iI/AAAAAAAAAJo/KHGV9yAJhFo/s1600/Head.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5500889677935859234" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TFcWBGH61iI/AAAAAAAAAJo/KHGV9yAJhFo/s320/Head.jpg" border="0" /&gt;&lt;/a&gt;I have a new project I am hacking on. The goal is to process a huge file of URLs. Then I want to crawl those web sites and extract information to a database. I will provide some more specifics in the future.&lt;br /&gt;&lt;br /&gt;The first task at hand was to deal with &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;this&lt;/span&gt; huge file. It was 10 gigabytes large. Most text editors could not handle it. I wanted to see if my Java classes could deal with it. So I coded up a UNIX head program. It lists of the first 10 lines from the file.&lt;br /&gt;&lt;br /&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;Bamm&lt;/span&gt;. It worked. The Scanner class could read the first 10 lines with ease. The first time it did so there was a small pause. But I could read and process the first 10 lines. It seems to reason I can process the next 10 lines, and so on.&lt;br /&gt;&lt;br /&gt;I will keep you posted on the progress of my little project. Next step is to figure out how to do database access with Java. I am thinking &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;JDBC&lt;/span&gt;. But there may be better or more interesting technologies to try out.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-6890738089325840395?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/6890738089325840395/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/08/scanner-comes-through.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6890738089325840395'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6890738089325840395'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/08/scanner-comes-through.html' title='Scanner Comes Through'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TFcWBGH61iI/AAAAAAAAAJo/KHGV9yAJhFo/s72-c/Head.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7998415480944217525</id><published>2010-07-19T13:25:00.000-04:00</published><updated>2010-07-19T13:25:00.372-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='invisible'/><category scheme='http://www.blogger.com/atom/ns#' term='paint'/><category scheme='http://www.blogger.com/atom/ns#' term='icon'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><category scheme='http://www.blogger.com/atom/ns#' term='appletViewer'/><title type='text'>Window Pane Management</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/TECWMPo214I/AAAAAAAAAJY/i9w8lsa4AJw/s1600/Menu.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5494556682492499842" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 250px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/TECWMPo214I/AAAAAAAAAJY/i9w8lsa4AJw/s320/Menu.JPG" border="0" /&gt;&lt;/a&gt;I have been creating buttons that have no text on them. They only have a graphic icon loaded from an image file. I noticed that the button size grows to &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;accommodate&lt;/span&gt; larger pictures. This leads to different sized buttons and a messy user interface. There must be a way to keep a uniform button size, shrinking icon images as needed.&lt;br /&gt;&lt;br /&gt;Another problem I have is when a control such as a button is invisible. The other controls rearrange during the paint() so as to obscure the &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_1"&gt;position&lt;/span&gt; where the invisible control would be. I don't like this &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_2"&gt;reshuffling&lt;/span&gt; of the screen when a control goes invisible. There should be a way to reserve space on the screen for a control that may become visible in the future. However this is not the default behavior.&lt;br /&gt;&lt;br /&gt;I normally use &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;appletViewer&lt;/span&gt; to test out my applets in development. But I found out that this tool only displays the embedded applet in an HTML page. It does not render any of the other &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_4"&gt;HTML&lt;/span&gt; elements. Weird.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7998415480944217525?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7998415480944217525/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/window-pane-management.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7998415480944217525'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7998415480944217525'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/window-pane-management.html' title='Window Pane Management'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/TECWMPo214I/AAAAAAAAAJY/i9w8lsa4AJw/s72-c/Menu.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-8592334818628083243</id><published>2010-07-18T18:57:00.002-04:00</published><updated>2010-07-18T18:57:00.269-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='addActionListener'/><category scheme='http://www.blogger.com/atom/ns#' term='setActionCommand'/><category scheme='http://www.blogger.com/atom/ns#' term='events'/><category scheme='http://www.blogger.com/atom/ns#' term='buttons'/><title type='text'>Button Action Command</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/_wOFRh11vB8g/TD-SmAyAjHI/AAAAAAAAAJQ/nJDTgQ-CDII/s1600/Menu.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5494271252157729906" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 250px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/TD-SmAyAjHI/AAAAAAAAAJQ/nJDTgQ-CDII/s320/Menu.JPG" border="0" /&gt;&lt;/a&gt;Normally you have your applet listen for actions from your controls like the buttons in your applet. The event handler gets the action command. That command is normally the text on the button itself.&lt;br /&gt;&lt;br /&gt;Recently I have been creating buttons that have no text. They just display an image that I loaded as the icon of the button. How does the applet know which control generated the event?&lt;br /&gt;&lt;br /&gt;It turns out that you can call &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;setActionCommand&lt;/span&gt; and pass it a String. This String is when the applet will get when it tries to get the command. It puts you back in control for the event processing.&lt;br /&gt;&lt;br /&gt;Here is a tip I discovered the hard way. Make sure you &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;addActionListener&lt;/span&gt;(this) on the button you want to handle events for. Otherwise the applet will never get a notification that your button was clicked. This might be obvious. But it is painful to debug when you forget to make the call.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-8592334818628083243?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/8592334818628083243/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/button-action-command.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8592334818628083243'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8592334818628083243'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/button-action-command.html' title='Button Action Command'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/TD-SmAyAjHI/AAAAAAAAAJQ/nJDTgQ-CDII/s72-c/Menu.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-999758570737658609</id><published>2010-07-17T22:18:00.002-04:00</published><updated>2010-07-17T22:18:00.626-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='DateFormat'/><category scheme='http://www.blogger.com/atom/ns#' term='Date'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><category scheme='http://www.blogger.com/atom/ns#' term='size'/><category scheme='http://www.blogger.com/atom/ns#' term='presentation'/><title type='text'>Applets and Web Pages</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/_wOFRh11vB8g/TD5v8xdqppI/AAAAAAAAAJA/qfBt8DvnigQ/s1600/BMIweb.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5493951685299185298" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 312px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/TD5v8xdqppI/AAAAAAAAAJA/qfBt8DvnigQ/s320/BMIweb.JPG" border="0" /&gt;&lt;/a&gt;So far I have been concentrating on applets. The applet is normally the entire web page. The HTML for the web page is merely to name the applet, and give it a size. However this is not normal. You usually have some other presentation in the HTML page. Therefore I did a more realistic project that integrated applet output with the markup from the HTML source.&lt;br /&gt;&lt;br /&gt;I had an exercise from my textbook dealing with times. In Java, you can get the number of milliseconds since 1970. This feature has been encapsulated with the Date class. The default constructor of Date initializes the object to the current date and time. Use &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;DateFormat&lt;/span&gt; to choose how you want to show the date. Even though the class is abstract, you can still call the static members.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-999758570737658609?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/999758570737658609/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/applets-and-web-pages.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/999758570737658609'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/999758570737658609'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/applets-and-web-pages.html' title='Applets and Web Pages'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/TD5v8xdqppI/AAAAAAAAAJA/qfBt8DvnigQ/s72-c/BMIweb.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-1520095404437625147</id><published>2010-07-16T19:41:00.001-04:00</published><updated>2010-07-16T19:41:00.213-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='format'/><category scheme='http://www.blogger.com/atom/ns#' term='layout'/><category scheme='http://www.blogger.com/atom/ns#' term='setVisible'/><category scheme='http://www.blogger.com/atom/ns#' term='controls'/><title type='text'>What Time is it?</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/_wOFRh11vB8g/TD5LN9EPmOI/AAAAAAAAAI4/hQJatS-WZqA/s1600/Timer.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5493911298541328610" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 211px" alt="" src="http://3.bp.blogspot.com/_wOFRh11vB8g/TD5LN9EPmOI/AAAAAAAAAI4/hQJatS-WZqA/s320/Timer.JPG" border="0" /&gt;&lt;/a&gt;Here are some leftover tips from a textbook project I did recently. The format() function is a static one from the String class. It helps your output look good. Call it like this: String.format(...).&lt;br /&gt;&lt;br /&gt;You can hide controls in an applet by using the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;setVisible&lt;/span&gt; function, passing in the parameter false. Here is something weird though. Hidden controls are removed from the user interface layout. There is no reserved space on the screen where the hidden control is supposed to be. The output looks as if the control was never there. Other controls will be placed over top of the region where the hidden control belongs.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-1520095404437625147?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/1520095404437625147/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/what-time-is-it.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1520095404437625147'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1520095404437625147'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/what-time-is-it.html' title='What Time is it?'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/TD5LN9EPmOI/AAAAAAAAAI4/hQJatS-WZqA/s72-c/Timer.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7369593598530299530</id><published>2010-07-16T15:34:00.002-04:00</published><updated>2010-07-16T15:38:51.646-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='blocked content'/><category scheme='http://www.blogger.com/atom/ns#' term='Internet Explorer 6'/><category scheme='http://www.blogger.com/atom/ns#' term='pattern'/><title type='text'>Applets and Browsers</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/_wOFRh11vB8g/TEC0TYqWPBI/AAAAAAAAAJg/oUaj3w8AlMY/s1600/Hex.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5494589790522588178" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 170px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/TEC0TYqWPBI/AAAAAAAAAJg/oUaj3w8AlMY/s320/Hex.JPG" border="0" /&gt;&lt;/a&gt;Sometimes I need to see how my applet looks in a browser. My browser of choice is Internet Explorer 6. Yes I know this is an ancient version. I tried installing version 8 but had some problems.&lt;br /&gt;&lt;br /&gt;My IE6 blocks the applet from running by default on a web page. This is probably related to my security settings, and not my specific browser. I still need to click to "allow blocked content" before the browser will run my applet.&lt;br /&gt;&lt;br /&gt;I am starting to see a pattern with applet GUI programming. Create a label, text field, and button. Add them all to the content pane. Then you make sure the applet can get the events from the button. This is all happening in my &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;init&lt;/span&gt;() function. It is almost boilerplate code for me now.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7369593598530299530?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7369593598530299530/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/applets-and-browsers.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7369593598530299530'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7369593598530299530'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/applets-and-browsers.html' title='Applets and Browsers'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/TEC0TYqWPBI/AAAAAAAAAJg/oUaj3w8AlMY/s72-c/Hex.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7979934544051206858</id><published>2010-07-15T20:42:00.002-04:00</published><updated>2010-07-15T20:42:00.377-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Double'/><category scheme='http://www.blogger.com/atom/ns#' term='conversion'/><category scheme='http://www.blogger.com/atom/ns#' term='boxing'/><category scheme='http://www.blogger.com/atom/ns#' term='unboxing'/><category scheme='http://www.blogger.com/atom/ns#' term='implicit'/><title type='text'></title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TD0H-4rRN_I/AAAAAAAAAIw/lV_x6TSBJV0/s1600/Bmi.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5493555897409026034" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 211px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TD0H-4rRN_I/AAAAAAAAAIw/lV_x6TSBJV0/s320/Bmi.JPG" border="0" /&gt;&lt;/a&gt;Like most things, I find that writing the code for an applet is easiest if you start out with a working applet to modify. Now let's get back to some Java basics. Previously I had recalled how to convert a String to an int. Now I needed to do the same for a double. The tried and true design worked well.&lt;br /&gt;&lt;br /&gt;You create a Double object. Pass the String into the constructor of the Double. Then you can assign the value of the Double to a double variable. The conversion works well. Actually I think this is implicitly calling a member of Double that returns a double. Is this what they call boxing? Or maybe it is &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;unboxing&lt;/span&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7979934544051206858?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7979934544051206858/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/like-most-things-i-find-that-writing.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7979934544051206858'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7979934544051206858'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/like-most-things-i-find-that-writing.html' title=''/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TD0H-4rRN_I/AAAAAAAAAIw/lV_x6TSBJV0/s72-c/Bmi.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-43951455777940040</id><published>2010-07-15T09:08:00.003-04:00</published><updated>2010-07-15T09:13:27.999-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='repaint'/><category scheme='http://www.blogger.com/atom/ns#' term='paint'/><category scheme='http://www.blogger.com/atom/ns#' term='icon'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><category scheme='http://www.blogger.com/atom/ns#' term='JApplet'/><title type='text'>Button Behavior</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/_wOFRh11vB8g/TD8ISEXRNHI/AAAAAAAAAJI/XLqyW_iuTPs/s1600/Geometry.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5494119176917300338" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 308px; CURSOR: hand; HEIGHT: 269px" alt="" src="http://3.bp.blogspot.com/_wOFRh11vB8g/TD8ISEXRNHI/AAAAAAAAAJI/XLqyW_iuTPs/s320/Geometry.JPG" border="0" /&gt;&lt;/a&gt;You size an applet in the HTML page that hosts it. I find that you need to size the applet area carefully to allows your controls to be &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;layed&lt;/span&gt; out as expected on the screen.&lt;br /&gt;&lt;br /&gt;The general pattern I use when user input drives the display is to have a member variable of my &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;JApplet&lt;/span&gt; &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_2"&gt;derived&lt;/span&gt; class. There is conditional logic in the paint() method that depends on this variable. When a user action changes the variable state, repaint() is called to redraw the screen.&lt;br /&gt;&lt;br /&gt;I've been doing a lot with buttons that have no text on them. They only have an icon image on them. I have encountered some problems with transparency. I would like the button background color to bleed through any white portion of my image. However does not seem to be the default behavior of the button class. Maybe I need to set some unknown options. I hope I do not need to code or draw my own button face.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-43951455777940040?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/43951455777940040/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/button-behavior.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/43951455777940040'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/43951455777940040'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/button-behavior.html' title='Button Behavior'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/TD8ISEXRNHI/AAAAAAAAAJI/XLqyW_iuTPs/s72-c/Geometry.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-211814255785968605</id><published>2010-07-14T20:37:00.000-04:00</published><updated>2010-07-14T20:37:00.412-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='applet'/><category scheme='http://www.blogger.com/atom/ns#' term='control'/><category scheme='http://www.blogger.com/atom/ns#' term='rows'/><category scheme='http://www.blogger.com/atom/ns#' term='Swing'/><category scheme='http://www.blogger.com/atom/ns#' term='newline'/><title type='text'>The JTextArea</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/_wOFRh11vB8g/TD0G-B9PRdI/AAAAAAAAAIo/Hnzqo5j9-U8/s1600/Length.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5493554783208818130" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 172px" alt="" src="http://3.bp.blogspot.com/_wOFRh11vB8g/TD0G-B9PRdI/AAAAAAAAAIo/Hnzqo5j9-U8/s320/Length.JPG" border="0" /&gt;&lt;/a&gt;I started using the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;JTextArea&lt;/span&gt; control in my applets. Seems all the good controls are in the "&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;javax&lt;/span&gt;.swing" package. You pass in the height to the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;JTextArea&lt;/span&gt; constructor. However it seems that the thing will allow more than that many rows in the control. The control seems only bounded by the applet window size. What the heck?&lt;br /&gt;&lt;br /&gt;You use newlines in the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;JTextArea&lt;/span&gt; text to make the thing jump to the next row in the control. One thing is strange though. The default behavior does not seem to provide anything other than the text in the control. There is no border or &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;scrollbar&lt;/span&gt; or anything. Maybe there is some other control that is more like the Windows control I am used to.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-211814255785968605?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/211814255785968605/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/jtextarea.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/211814255785968605'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/211814255785968605'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/jtextarea.html' title='The JTextArea'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/TD0G-B9PRdI/AAAAAAAAAIo/Hnzqo5j9-U8/s72-c/Length.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-8543216222564144236</id><published>2010-07-14T01:02:00.001-04:00</published><updated>2010-07-14T01:02:00.530-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Ant'/><category scheme='http://www.blogger.com/atom/ns#' term='CVS'/><category scheme='http://www.blogger.com/atom/ns#' term='Subversion'/><category scheme='http://www.blogger.com/atom/ns#' term='Linux'/><category scheme='http://www.blogger.com/atom/ns#' term='Maven'/><category scheme='http://www.blogger.com/atom/ns#' term='jQuery'/><title type='text'>Eclipse User Trends</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TDvzcLySUrI/AAAAAAAAAIg/o4dwGm9TBWY/s1600/Eclipse.jpg"&gt;&lt;img style="TEXT-ALIGN: center; MARGIN: 0px auto 10px; WIDTH: 320px; DISPLAY: block; HEIGHT: 240px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5493251836034044594" border="0" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TDvzcLySUrI/AAAAAAAAAIg/o4dwGm9TBWY/s320/Eclipse.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;p&gt;Let's briefly look at the trends of Eclipse users. You could say they are comparable to the general Java development community. For starters they are using Subversion as the configuration management tool of choice. They also are using the Linux operating system for desktop development. These developers continually download and use the latest version of Eclipse.&lt;/p&gt;&lt;p&gt;&lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;CVS&lt;/span&gt; use is on the decline for configuration management. ANT is the build tools of choice. Maven is trying to catch up. Some are just using Eclipse itself to control builds. Web development is done using &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-error"&gt;jQuery&lt;/span&gt; (I just got a book on &lt;span id="SPELLING_ERROR_2" class="blsp-spelling-error"&gt;jQuery&lt;/span&gt;, so I will be sharing what I learn). The majority of Eclipse users do not contribute to open source. That last statistic surprises me.&lt;/p&gt;&lt;p&gt;I hope I can get my hands on some survey data for Java developers as a whole.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-8543216222564144236?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/8543216222564144236/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/eclipse-user-trends.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8543216222564144236'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8543216222564144236'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/eclipse-user-trends.html' title='Eclipse User Trends'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TDvzcLySUrI/AAAAAAAAAIg/o4dwGm9TBWY/s72-c/Eclipse.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-1240839791865981263</id><published>2010-07-13T00:33:00.003-04:00</published><updated>2010-07-13T00:38:50.486-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='repaint'/><category scheme='http://www.blogger.com/atom/ns#' term='conversion'/><category scheme='http://www.blogger.com/atom/ns#' term='init'/><category scheme='http://www.blogger.com/atom/ns#' term='paint'/><category scheme='http://www.blogger.com/atom/ns#' term='Math package'/><title type='text'>Wish Upon a Star</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TDvsnTktQFI/AAAAAAAAAIY/xgYGpqKrRYU/s1600/Star.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5493244330521739346" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 211px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TDvsnTktQFI/AAAAAAAAAIY/xgYGpqKrRYU/s320/Star.JPG" border="0" /&gt;&lt;/a&gt;I am moving on to writing more applets. These are simple programs to get my bearings. The most important methods in &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;JApplet&lt;/span&gt; are &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;init&lt;/span&gt;() and paint(). You add items or objects to the screen in the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;init&lt;/span&gt;() function. And you draw things such as labels and buttons in the paint() function.&lt;br /&gt;&lt;br /&gt;If you handle some GUI events like button clicks, the pattern is to call repaint() to get the screen updated based on the user input. It is funny how quickly I forget my Java basics when I do not code for a long time. These rules have not been committed to heart.&lt;br /&gt;&lt;br /&gt;For example, I had to rediscover how to convert a String to an int. You create an Integer object, passing the String into the constructor. Then you can assign the resulting Integer to a variable of type int. Also you need to qualify Math package functions with "Math." to get your Java to compile.&lt;br /&gt;&lt;br /&gt;Some topics are universal. Break down complex routines into multiple subroutines (functions). Make use of constants instead of magic numbers. In Java this is done with public static final variables. I will say I am starting to get some bearings on how to do drawing on the Canvas. The upper left hand corner of the screen has coordinates (0,0). Increasing x goes to the right. Increasing y goes down.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-1240839791865981263?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/1240839791865981263/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/wish-upon-star.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1240839791865981263'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1240839791865981263'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/wish-upon-star.html' title='Wish Upon a Star'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TDvsnTktQFI/AAAAAAAAAIY/xgYGpqKrRYU/s72-c/Star.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7006316026878349612</id><published>2010-07-12T15:33:00.002-04:00</published><updated>2010-07-12T15:40:17.932-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Internet Explorer'/><category scheme='http://www.blogger.com/atom/ns#' term='init'/><category scheme='http://www.blogger.com/atom/ns#' term='Swing'/><category scheme='http://www.blogger.com/atom/ns#' term='security'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><title type='text'>My First Applet</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/TDtuEB97CHI/AAAAAAAAAIQ/Ztly0w1SPJI/s1600/Applet.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5493105186035140722" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 232px; CURSOR: hand; HEIGHT: 167px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/TDtuEB97CHI/AAAAAAAAAIQ/Ztly0w1SPJI/s320/Applet.JPG" border="0" /&gt;&lt;/a&gt;Here I am in my full week of training. This is an independent &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;study&lt;/span&gt; for me. My goal is to learn applet programing. Read a couple chapters in my school textbook. We always skipped the applet and other GUI sections. Unfortunately the applet chapter requires you to read the big Java Swing chapter. I have skipped it. So I am going to be having some troubles.&lt;br /&gt;&lt;br /&gt;Applets do not have a main function. Instead they have an &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;init&lt;/span&gt;. They close when the web page that contains them closes. The containing web page is written in HTML. The applet itself runs on the client machine. There are some security restrictions like an applet cannot run a program, read a file, or write a file. You should test your applets on many browsers including multiple versions of the same browser.&lt;br /&gt;&lt;br /&gt;The older class for applets is Applet. Go figure. You cannot use Swing with this old style class. You also cannot do icons or menus. Use buttons instead. I found that I could load an HTML page which referenced an applet. However when I recoded and recompiled the applet, an Internet Explorer 6 refresh would not run the new version of the applet. That was annoying. Instead I decided to use &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;appletviewer&lt;/span&gt;. Here is another strange thing. The reload function in &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;appletviewer&lt;/span&gt; causes the window to disappear and the viewer to freeze. Another funny thing was that I tried to use Graphics2D in my paint method. It compiled but just output a light blue screen. All my graphics were gone. I guess I can make do with the normal Graphics class.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7006316026878349612?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7006316026878349612/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/my-first-applet.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7006316026878349612'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7006316026878349612'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/my-first-applet.html' title='My First Applet'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/TDtuEB97CHI/AAAAAAAAAIQ/Ztly0w1SPJI/s72-c/Applet.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-89058141814153025</id><published>2010-07-08T22:16:00.003-04:00</published><updated>2010-07-08T22:24:15.108-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='game programming'/><category scheme='http://www.blogger.com/atom/ns#' term='Oracle'/><category scheme='http://www.blogger.com/atom/ns#' term='independent study'/><title type='text'>Applet Time</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/TDaGphV6kUI/AAAAAAAAAII/k1R8jvR2BTE/s1600/Applet.png"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 284px; FLOAT: left; HEIGHT: 320px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5491724843507945794" border="0" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/TDaGphV6kUI/AAAAAAAAAII/k1R8jvR2BTE/s320/Applet.png" /&gt;&lt;/a&gt;In my college Java class, we skipped over most of the information on applets. I wanted to learn more about them though. There was a whole chapter in the text that covered applets. I also have a lot of information on my latest book about applets for &lt;a href="http://enableassertions.blogspot.com/2010/06/game-programming.html"&gt;game&lt;/a&gt; programming in Java.&lt;br /&gt;&lt;br /&gt;It is time for me to learn applets. I convinced my employer to let me spend a week in independent study on Java. I need some program to keep me busy to really learn practical applet programming. Initially I thought I would write a copy of an arcade classic such as &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;Pacman&lt;/span&gt;. However I think I will need more than a week to get deep into applet programming.&lt;br /&gt;&lt;br /&gt;My new plan is to actually try to duplicate the main program we have on our project at work. It is a client/server C++ Windows application that connects to an &lt;a href="http://ora-pl-sql.blogspot.com/"&gt;Oracle&lt;/a&gt; database. This might be a good sized program to implement as an applet. The thing is over 2o0k lines of code. This will keep me busy for quite some time. I figure I can work on it in the office, and not get too much attention on my sideline activities.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-89058141814153025?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/89058141814153025/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/applet-time.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/89058141814153025'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/89058141814153025'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/applet-time.html' title='Applet Time'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/TDaGphV6kUI/AAAAAAAAAII/k1R8jvR2BTE/s72-c/Applet.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-2260598253353552829</id><published>2010-07-01T14:54:00.005-04:00</published><updated>2010-07-01T14:58:42.291-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='class'/><category scheme='http://www.blogger.com/atom/ns#' term='package private'/><category scheme='http://www.blogger.com/atom/ns#' term='precedence'/><category scheme='http://www.blogger.com/atom/ns#' term='functions'/><title type='text'>Access Modifiers</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TCzkdegAwCI/AAAAAAAAAIA/JuzXd6nPR6o/s1600/Access.png"&gt;&lt;img id="BLOGGER_PHOTO_ID_5489013240912461858" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TCzkdegAwCI/AAAAAAAAAIA/JuzXd6nPR6o/s320/Access.png" border="0" /&gt;&lt;/a&gt;Just read a rant about a developer that likes to use parentheses to make the order of operations explicit. He does not want a reader of his code to need to know the operator precedence rules. As an extension, he also &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;explicitly&lt;/span&gt; declares the access modifier for any java function that he writes.&lt;br /&gt;&lt;br /&gt;This started a big discussion on what it means to not specify an access modifier for a Java function. In C++ it is easy. C++ class members without an access modifier are private. C++ structure members without an access modifier are public. However in Java, not specifying an access modifier means the function is package private.&lt;br /&gt;&lt;br /&gt;Package private has no keyword. It is the access allowed when you do not specify a &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_1"&gt;modifier&lt;/span&gt;. This causes the function to only be accessible by other members in the package. This is different than public, private, or protected. I am sure I learned this some time ago in my Java college class. However today it was solidified.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-2260598253353552829?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/2260598253353552829/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/07/access-modifiers.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2260598253353552829'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2260598253353552829'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/07/access-modifiers.html' title='Access Modifiers'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TCzkdegAwCI/AAAAAAAAAIA/JuzXd6nPR6o/s72-c/Access.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-9087427651675693269</id><published>2010-06-30T21:11:00.002-04:00</published><updated>2010-06-30T21:17:54.370-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='MyFaces'/><category scheme='http://www.blogger.com/atom/ns#' term='beans'/><category scheme='http://www.blogger.com/atom/ns#' term='JSF'/><category scheme='http://www.blogger.com/atom/ns#' term='struts'/><category scheme='http://www.blogger.com/atom/ns#' term='XML markup'/><title type='text'>Web Frameworks</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TCvrWQbFOLI/AAAAAAAAAH4/7FMvEWn69VA/s1600/Frame.jpg"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 264px; FLOAT: left; HEIGHT: 320px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5488739338479286450" border="0" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TCvrWQbFOLI/AAAAAAAAAH4/7FMvEWn69VA/s320/Frame.jpg" /&gt;&lt;/a&gt;I found this free e-book which describes some web development frameworks for Java developers. These frameworks are like those of event driven GUI applications. However they sometimes have steep learning curves. Java provides some web technology. But it does not provide a web application framework. So these third party frameworks have come about to help you with the low level tasks.&lt;br /&gt;&lt;br /&gt;Struts is the most well known framework. It is well documented and has a large following. A drawback of using struts are the big configuration files. You need to use a lot of XML markup files for forms and rendering. I hear that developers are moving away from this framework in general.&lt;br /&gt;&lt;br /&gt;Java Server Faces (&lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;JSF&lt;/span&gt;) is another framework. It runs on an application server like &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-error"&gt;WebSphere&lt;/span&gt;. It strives to decouple the components and the view. The most frequently used implementation of &lt;span id="SPELLING_ERROR_2" class="blsp-spelling-error"&gt;JSF&lt;/span&gt; is Apache's &lt;span id="SPELLING_ERROR_3" class="blsp-spelling-error"&gt;MyFaces&lt;/span&gt;. &lt;span id="SPELLING_ERROR_4" class="blsp-spelling-error"&gt;JSF&lt;/span&gt; uses a managed bean to store user info. The bean classes contains the logic. This technology is backed by big companies like the former Sun &lt;span id="SPELLING_ERROR_5" class="blsp-spelling-error"&gt;Microsystems&lt;/span&gt;. A few years back I did hear that &lt;span id="SPELLING_ERROR_6" class="blsp-spelling-error"&gt;JSF&lt;/span&gt; might not be appropriate for mission critical applications. Not sure whether this opinion has since changed yet.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-9087427651675693269?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/9087427651675693269/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/06/web-frameworks.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/9087427651675693269'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/9087427651675693269'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/06/web-frameworks.html' title='Web Frameworks'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TCvrWQbFOLI/AAAAAAAAAH4/7FMvEWn69VA/s72-c/Frame.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7928122661529391126</id><published>2010-06-26T21:27:00.003-04:00</published><updated>2010-06-26T21:27:00.364-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='network'/><category scheme='http://www.blogger.com/atom/ns#' term='animation'/><category scheme='http://www.blogger.com/atom/ns#' term='Swing'/><category scheme='http://www.blogger.com/atom/ns#' term='OOP'/><category scheme='http://www.blogger.com/atom/ns#' term='arrays'/><category scheme='http://www.blogger.com/atom/ns#' term='AWT'/><title type='text'>Game Programming</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TCVXlyHNPcI/AAAAAAAAAHw/b8lh8NcJP1c/s1600/Game.jpg"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 300px; FLOAT: left; HEIGHT: 310px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5486888027639594434" border="0" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TCVXlyHNPcI/AAAAAAAAAHw/b8lh8NcJP1c/s320/Game.jpg" /&gt;&lt;/a&gt;I just started reading The Black Art of Java Game Programming. And I tell you what. I already have a good feeling about this book. Sure it was written in 1996 when Java 1 just came out. However by chapter 2 we are already learning about animation. Damn.&lt;br /&gt;&lt;br /&gt;One thing that struck me as odd was that the authors of the book are young. Or more precisely they are still in school. One of these is an undergrad, and the other a grad. That does not mean they are junior. They seemed to be on the cutting edge of Java right when it came out.&lt;br /&gt;&lt;br /&gt;This book does specialize in teaching you how to code network games. The authors believe that object oriented programming is the way to go for creating games. They are going to teach me a lot about &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;AWT&lt;/span&gt; (since Swing has not been invented I guess).&lt;br /&gt;&lt;br /&gt;Chapter 1 already got me into a lot of Java syntax. It also highly recommends you use arrays instead of lists for speed. Back in 1996, Java ran a lot slower than compiled C or C++. I also learned some basic stuff I was never taught in my Java college class. The import statement allows you to reference classes in packages. However you can still access those classes without an import by using the classes fully qualified name. I did not know that. I am excited about getting into the meat of this book. Who knows? I might be turning out some cool games in no time.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7928122661529391126?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7928122661529391126/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/06/game-programming.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7928122661529391126'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7928122661529391126'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/06/game-programming.html' title='Game Programming'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TCVXlyHNPcI/AAAAAAAAAHw/b8lh8NcJP1c/s72-c/Game.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7950619372371319430</id><published>2010-06-25T10:30:00.002-04:00</published><updated>2010-06-25T10:38:32.825-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='EJB'/><category scheme='http://www.blogger.com/atom/ns#' term='REST'/><category scheme='http://www.blogger.com/atom/ns#' term='profiles'/><category scheme='http://www.blogger.com/atom/ns#' term='Java EE'/><category scheme='http://www.blogger.com/atom/ns#' term='NetBeans'/><title type='text'>Java Enterprise Edition 6</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/_wOFRh11vB8g/TCS9rjyCVdI/AAAAAAAAAHo/u4hVP9kScIo/s1600/JavaEE.png"&gt;&lt;img id="BLOGGER_PHOTO_ID_5486718802081240530" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 256px; CURSOR: hand; HEIGHT: 256px" alt="" src="http://3.bp.blogspot.com/_wOFRh11vB8g/TCS9rjyCVdI/AAAAAAAAAHo/u4hVP9kScIo/s320/JavaEE.png" border="0" /&gt;&lt;/a&gt;I read an article on the good things coming in Java &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;EE&lt;/span&gt; version 6. There is a new &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;API&lt;/span&gt; for &lt;a href="http://xmlhome.blogspot.com/2008/08/representational-state-transfer.html"&gt;REST&lt;/a&gt;. There is a web profile, meaning you can use a scaled down version of the previously bloated enterprise edition. In the tools department, there is a new version of &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;NetBeans&lt;/span&gt; being released.&lt;br /&gt;&lt;br /&gt;Enterprise Java Beans has been updated. Things have gotten much simpler with it. The beans are "light". Complexities such as requirements for frameworks are gone. This is in line with the scaled down profile version of the Java &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;EE&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Right now I am still concentrating on learning Java Standard Edition. Some Java friends keep asking me whether I am up to speed on Java &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;EE&lt;/span&gt;. It might be time to start learning it. Looks like I will have access to a new updated version, which is actually simpler than previous ones.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7950619372371319430?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7950619372371319430/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/06/java-enterprise-edition-6.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7950619372371319430'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7950619372371319430'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/06/java-enterprise-edition-6.html' title='Java Enterprise Edition 6'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/TCS9rjyCVdI/AAAAAAAAAHo/u4hVP9kScIo/s72-c/JavaEE.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-3977461150965866411</id><published>2010-06-19T02:40:00.002-04:00</published><updated>2010-06-19T02:45:49.144-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='games'/><category scheme='http://www.blogger.com/atom/ns#' term='obsolete'/><category scheme='http://www.blogger.com/atom/ns#' term='Java 1.0'/><category scheme='http://www.blogger.com/atom/ns#' term='Amazon'/><title type='text'>Java Game Programming</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/TBxmoI4Z3mI/AAAAAAAAAHg/zdxGmcjiOCk/s1600/Java.jpg"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 300px; FLOAT: left; HEIGHT: 300px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5484371285995282018" border="0" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/TBxmoI4Z3mI/AAAAAAAAAHg/zdxGmcjiOCk/s320/Java.jpg" /&gt;&lt;/a&gt;I read a blog post about hiring for &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;startups&lt;/span&gt; (or something like that). It was written very well. So I checked out the author's bio. Turns out he was one of the authors of an old book called The Black Art of Java Game Programming. When I say old, I mean it was published in the 1990's for Java 1.0.&lt;br /&gt;&lt;br /&gt;Normally books like these get obsolete immediately. And this book seems to have code that became obsolete with Java 1.1. However a number of comments on Amazon indicate the book still has a lot of merits. Well it warrants a read by me &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-corrected"&gt;even&lt;/span&gt; though the book might be 25 years old. I placed an order with Amazon today.&lt;br /&gt;&lt;br /&gt;I will let you know what I learn. Things are looking good for my Java development. I took a college class last year. This year I plan to take a week off from work and complete the remaining chapter in my college class textbook. I had though I might learn some more HTML programming (including JavaScript) later this year. However I might change direction and get deeper into Java. If so you will be hearing about it with some more frequent posts on this blog. Stay tuned.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-3977461150965866411?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/3977461150965866411/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/06/java-game-programming.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3977461150965866411'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3977461150965866411'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/06/java-game-programming.html' title='Java Game Programming'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/TBxmoI4Z3mI/AAAAAAAAAHg/zdxGmcjiOCk/s72-c/Java.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-4408416673157744710</id><published>2010-05-28T15:41:00.000-04:00</published><updated>2010-05-28T15:41:00.350-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='JDistro'/><category scheme='http://www.blogger.com/atom/ns#' term='Swing'/><category scheme='http://www.blogger.com/atom/ns#' term='JDBC'/><category scheme='http://www.blogger.com/atom/ns#' term='floppy disk'/><category scheme='http://www.blogger.com/atom/ns#' term='65C02'/><category scheme='http://www.blogger.com/atom/ns#' term='AWT'/><title type='text'>Java Running on Apple II c</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5476037340793528418" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 262px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/S_7K8rrF4GI/AAAAAAAAAHY/yz8z6Bz1uME/s320/AppleIIc.jpg" border="0" /&gt;I just heard that a subset of Java can now run on the Apple &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;IIc&lt;/span&gt; computer. &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;Bamm&lt;/span&gt;. Of course there are some limitations. You need a real Apple II c with the 65C02 microprocessor. That means Apple II e computers don't work with this port.&lt;br /&gt;&lt;br /&gt;The good news is that some of Swing is available. No &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;AWT&lt;/span&gt; or &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;JDBC&lt;/span&gt; is supported yet. The eventual goal is to port all of Java to the Apple. Right now there is also a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;JDistro&lt;/span&gt; available. This is a desktop which is written in Java Swing. &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;JDistro&lt;/span&gt; is a limited version too that can only run 1 app at a time.&lt;br /&gt;&lt;br /&gt;The whole thing fits on 3 floppies. Source code will be made public. This seems pretty hard core as the Apple II is some hardware from yesteryear. Now we just need Java ported to the Tandy Coco III, and I will be complete.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-4408416673157744710?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/4408416673157744710/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/05/java-running-on-apple-ii-c.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/4408416673157744710'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/4408416673157744710'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/05/java-running-on-apple-ii-c.html' title='Java Running on Apple II c'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/S_7K8rrF4GI/AAAAAAAAAHY/yz8z6Bz1uME/s72-c/AppleIIc.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-4898249247795594348</id><published>2010-05-27T12:27:00.002-04:00</published><updated>2010-05-27T12:27:00.624-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='performance'/><category scheme='http://www.blogger.com/atom/ns#' term='compilation'/><category scheme='http://www.blogger.com/atom/ns#' term='optimization'/><title type='text'>Making the JVM Fast</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/S_1MFx95WnI/AAAAAAAAAHQ/CjeZjZEZAZg/s1600/Fast.gif"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 320px; FLOAT: left; HEIGHT: 182px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5475616384148396658" border="0" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/S_1MFx95WnI/AAAAAAAAAHQ/CjeZjZEZAZg/s320/Fast.gif" /&gt;&lt;/a&gt;Java was a very slow performer when it first came out. Then it started becoming a contender for other compiled languages like C and C++. In fact, Java is faster than C++ in some cases. But in general it is a little slower.&lt;br /&gt;&lt;br /&gt;All code is interpreted by the Java Virtual Machine. However for methods that are used very frequently, the &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;JVM&lt;/span&gt; compiles the code and then you get really good performance. The trick is that the &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-error"&gt;JVM&lt;/span&gt; can see how the code is used many times. Then it has the knowledge needed to optimize the compilation.&lt;br /&gt;&lt;span id="SPELLING_ERROR_2" class="blsp-spelling-error"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;With the default options, code written in smaller sized methods runs faster. The reason for this is the the &lt;span id="SPELLING_ERROR_3" class="blsp-spelling-error"&gt;JVM&lt;/span&gt; will not compile methods that are too large. You can modify this behavior with some options. In fact you can even force the &lt;span id="SPELLING_ERROR_4" class="blsp-spelling-error"&gt;JVM&lt;/span&gt; to compile everything. While this might seem to be best, it is not. You should let the &lt;span id="SPELLING_ERROR_5" class="blsp-spelling-error"&gt;JVM&lt;/span&gt; interpret the code first. Only after interpreting a method many times can it make the best optimizations for compilation.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-4898249247795594348?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/4898249247795594348/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/05/making-jvm-fast.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/4898249247795594348'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/4898249247795594348'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/05/making-jvm-fast.html' title='Making the JVM Fast'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/S_1MFx95WnI/AAAAAAAAAHQ/CjeZjZEZAZg/s72-c/Fast.gif' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-9132859022773633368</id><published>2010-05-26T17:24:00.002-04:00</published><updated>2010-05-26T17:24:00.131-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='agile'/><category scheme='http://www.blogger.com/atom/ns#' term='SOA'/><category scheme='http://www.blogger.com/atom/ns#' term='containers'/><category scheme='http://www.blogger.com/atom/ns#' term='Websphere'/><category scheme='http://www.blogger.com/atom/ns#' term='Apache'/><title type='text'>J2EE to Tomcat Port</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/_wOFRh11vB8g/S_xADT-W7DI/AAAAAAAAAHI/0_NajeZR7x8/s1600/Tomcat.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5475321672621288498" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 240px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/S_xADT-W7DI/AAAAAAAAAHI/0_NajeZR7x8/s320/Tomcat.jpg" border="0" /&gt;&lt;/a&gt;There is a movement in the enterprise to port J2&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;EE&lt;/span&gt; applications to lightweight Java containers such as Tomcat. This is part of the Agile development movement. There are many ways to tackle this port. You can just code some services up in lightweight Java. Or you could just write the new stuff in lightweight Java.&lt;br /&gt;&lt;br /&gt;Techniques such as &lt;a href="http://xmlhome.blogspot.com/2010/02/service-oriented-architecture.html"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;SOA&lt;/span&gt;&lt;/a&gt; are complex. Java frameworks now offer a lot, but have a small code footprint. There are multiple lightweight Java containers. &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;Tomcat&lt;/span&gt; from Apache happens to be a free and popular one. This may be the way of the future. Developers are tired of running under app servers like &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;WebSphere&lt;/span&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-9132859022773633368?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/9132859022773633368/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/05/j2ee-to-tomcat-port.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/9132859022773633368'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/9132859022773633368'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/05/j2ee-to-tomcat-port.html' title='J2EE to Tomcat Port'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/S_xADT-W7DI/AAAAAAAAAHI/0_NajeZR7x8/s72-c/Tomcat.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-6076763094341163041</id><published>2010-05-25T15:37:00.000-04:00</published><updated>2010-05-25T15:37:01.027-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='JavaScript'/><category scheme='http://www.blogger.com/atom/ns#' term='Subversion'/><category scheme='http://www.blogger.com/atom/ns#' term='GPL'/><category scheme='http://www.blogger.com/atom/ns#' term='native Java'/><title type='text'>Servoy Library</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_wOFRh11vB8g/S_rVeKOZICI/AAAAAAAAAG4/BhyZOiLkh40/s1600/Servoy.bmp"&gt;&lt;img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer; width: 172px; height: 57px;" src="http://2.bp.blogspot.com/_wOFRh11vB8g/S_rVeKOZICI/AAAAAAAAAG4/BhyZOiLkh40/s320/Servoy.bmp" alt="" id="BLOGGER_PHOTO_ID_5474923011139772450" border="0" /&gt;&lt;/a&gt;  &lt;p class="MsoNormal"&gt;&lt;span style="font-size: 10pt; font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;;"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;Servoy&lt;/span&gt; Corporation is &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_1"&gt;releasing&lt;/span&gt; its libraries under a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;GPL&lt;/span&gt; license. They provide access to Java function within JavaScript. The solution uses native Java code. You can think of this as JavaScript wrapping Java objects. &lt;/span&gt;&lt;span style=""&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;    &lt;p class="MsoNormal"&gt;&lt;span style="font-size: 10pt; font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;;"&gt;This solution is aimed at web developers. &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;Servoy&lt;/span&gt; will release the source code on their own hosted Subversion servers. The &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;GPL&lt;/span&gt; license requires that users of their libraries in turn make their source code available to the public free of charge.&lt;/span&gt;&lt;span style=""&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-6076763094341163041?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/6076763094341163041/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/05/servoy-library.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6076763094341163041'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6076763094341163041'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/05/servoy-library.html' title='Servoy Library'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/S_rVeKOZICI/AAAAAAAAAG4/BhyZOiLkh40/s72-c/Servoy.bmp' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-660108737013371123</id><published>2010-05-24T15:39:00.000-04:00</published><updated>2010-05-24T15:40:58.670-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='DO-178C'/><category scheme='http://www.blogger.com/atom/ns#' term='JSR-302'/><category scheme='http://www.blogger.com/atom/ns#' term='DoD'/><category scheme='http://www.blogger.com/atom/ns#' term='object oriented'/><title type='text'>Mission Critical Java Apps</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_wOFRh11vB8g/S_rWBwe8QWI/AAAAAAAAAHA/UZSBLiB6-bU/s1600/Critical.jpg"&gt;&lt;img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer; width: 320px; height: 240px;" src="http://4.bp.blogspot.com/_wOFRh11vB8g/S_rWBwe8QWI/AAAAAAAAAHA/UZSBLiB6-bU/s320/Critical.jpg" alt="" id="BLOGGER_PHOTO_ID_5474923622705152354" border="0" /&gt;&lt;/a&gt;  &lt;p class="MsoNormal"&gt;&lt;span style="font-size: 10pt; font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;;"&gt;Department of Defense standard DO-178C defines methods to verify object oriented systems for critical uses. In the past, Java has not been normally used for mission critical applications. All that may be changing now.&lt;/span&gt;&lt;span style=""&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;    &lt;p class="MsoNormal"&gt;&lt;span style="font-size: 10pt; font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;;"&gt;Java now has &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;JSR&lt;/span&gt;-302 which addressed safety critical Java. Safety critical apps are mostly the domain of large scale &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;DoD&lt;/span&gt; sponsored programs with big money backing them. This is a good move for the Java world.&lt;/span&gt;&lt;span style=""&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-660108737013371123?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/660108737013371123/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/05/mission-critical-java-apps.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/660108737013371123'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/660108737013371123'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/05/mission-critical-java-apps.html' title='Mission Critical Java Apps'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/S_rWBwe8QWI/AAAAAAAAAHA/UZSBLiB6-bU/s72-c/Critical.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-2384992901475994432</id><published>2010-05-24T15:33:00.003-04:00</published><updated>2010-05-24T15:35:06.989-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Spring framework'/><category scheme='http://www.blogger.com/atom/ns#' term='VMware'/><category scheme='http://www.blogger.com/atom/ns#' term='cloud computing'/><title type='text'>Java on the Cloud</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_wOFRh11vB8g/S_rUrDB1LNI/AAAAAAAAAGw/jUmN50XtzOg/s1600/Cloud.jpg"&gt;&lt;img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer; width: 320px; height: 222px;" src="http://2.bp.blogspot.com/_wOFRh11vB8g/S_rUrDB1LNI/AAAAAAAAAGw/jUmN50XtzOg/s320/Cloud.jpg" alt="" id="BLOGGER_PHOTO_ID_5474922133034708178" border="0" /&gt;&lt;/a&gt;  &lt;p class="MsoNormal"&gt;&lt;span style="font-size: 10pt; font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;;"&gt;A bunch of companies are working on a Java based solution to cloud computing. It will be using the Spring framework. It will run on &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;vSphere&lt;/span&gt; from &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;VMware&lt;/span&gt;. And it will be hosted on the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;Salesforce&lt;/span&gt;.com servers. This beat will be called &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;VMforce&lt;/span&gt;. I guess that means that &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;VMware&lt;/span&gt; is the main company behind it.&lt;/span&gt;&lt;span style=""&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;    &lt;p class="MsoNormal"&gt;&lt;span style="font-size: 10pt; font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;;"&gt;This solution will be able to host any Java application in the cloud. There are around 6 million Java developers out there. Cloud computing is supposed to boost their productivity. So if this works, this may have a big impact on their productivity. Look for &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;VMforce&lt;/span&gt; to be available later this year.&lt;/span&gt;&lt;span style=""&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-2384992901475994432?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/2384992901475994432/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/05/java-on-cloud.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2384992901475994432'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2384992901475994432'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/05/java-on-cloud.html' title='Java on the Cloud'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/S_rUrDB1LNI/AAAAAAAAAGw/jUmN50XtzOg/s72-c/Cloud.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7691124794651958887</id><published>2010-05-13T14:50:00.002-04:00</published><updated>2010-05-13T14:54:06.501-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='direct machine access'/><category scheme='http://www.blogger.com/atom/ns#' term='startup'/><category scheme='http://www.blogger.com/atom/ns#' term='footprint'/><category scheme='http://www.blogger.com/atom/ns#' term='JVM'/><category scheme='http://www.blogger.com/atom/ns#' term='JNI'/><title type='text'>Java Performance</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/S-xJ9PsOd_I/AAAAAAAAAGg/holE_ORpsPw/s1600/Java.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5470828963881187314" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 261px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/S-xJ9PsOd_I/AAAAAAAAAGg/holE_ORpsPw/s320/Java.jpg" border="0" /&gt;&lt;/a&gt;In the old days, there was much concern that Java programs were slow and could not complete with C or C++ programs. It seems that this is not as true any more. I just read a huge discussion on the topic. Here are some interesting points I came out with.&lt;br /&gt;&lt;br /&gt;C has a small footprint. So if that is required, choose C. Java has a long &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;startup&lt;/span&gt; time. This is the time it takes for the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;JVM&lt;/span&gt; to load and initialize. We are talking on the order of seconds here.&lt;br /&gt;&lt;br /&gt;Direct machine access can be done with Java using &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;JNI&lt;/span&gt;. However it is clunky. In C, direct machine access is natural. However garbage collection in Java is easier than C's &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;malloc&lt;/span&gt;/free. Java also make parallel programming easier.&lt;br /&gt;&lt;br /&gt;Be careful when you are comparing speed between Java and C programs. You must ensure both programs are using the same algorithm. You also need accurate stats to make a good comparison. As an aside, C# will normally be a little bit slower than Java.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7691124794651958887?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7691124794651958887/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/05/java-performance.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7691124794651958887'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7691124794651958887'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/05/java-performance.html' title='Java Performance'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/S-xJ9PsOd_I/AAAAAAAAAGg/holE_ORpsPw/s72-c/Java.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-845581817500762698</id><published>2010-05-07T02:41:00.003-04:00</published><updated>2010-05-07T02:41:00.597-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='strings'/><category scheme='http://www.blogger.com/atom/ns#' term='curve cryptography'/><category scheme='http://www.blogger.com/atom/ns#' term='JVM'/><category scheme='http://www.blogger.com/atom/ns#' term='G1'/><title type='text'>Java 7</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/S-JWs650DBI/AAAAAAAAAGY/OD33UUpSGN0/s1600/Java7.png"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 300px; FLOAT: left; HEIGHT: 256px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5468028227307179026" border="0" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/S-JWs650DBI/AAAAAAAAAGY/OD33UUpSGN0/s320/Java7.png" /&gt;&lt;/a&gt;Java 7 is big. The Java Virtual Machine will support dynamic &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-corrected"&gt;languages&lt;/span&gt;. Strings can be used in a switch statement. The &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-error"&gt;JVM&lt;/span&gt; performance has been improved. A new garbage collector called the G1 is the source of the speed up.&lt;br /&gt;&lt;br /&gt;There are other niche additions to Java in Java 7. For example, in the &lt;a href="http://black-of-hat.blogspot.com/"&gt;security&lt;/a&gt; world, there will be support for curve cryptography. Personally I care little about &lt;span id="SPELLING_ERROR_2" class="blsp-spelling-error"&gt;JVM&lt;/span&gt; support for dynamic languages. Java with its static typing is fine for me.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-845581817500762698?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/845581817500762698/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/05/java-7.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/845581817500762698'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/845581817500762698'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/05/java-7.html' title='Java 7'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/S-JWs650DBI/AAAAAAAAAGY/OD33UUpSGN0/s72-c/Java7.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-3099465697400977717</id><published>2010-05-06T01:36:00.002-04:00</published><updated>2010-05-06T01:40:07.692-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='time off'/><category scheme='http://www.blogger.com/atom/ns#' term='Oracle'/><category scheme='http://www.blogger.com/atom/ns#' term='JavaOne'/><category scheme='http://www.blogger.com/atom/ns#' term='creator'/><title type='text'>Gosling is Gone</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/_wOFRh11vB8g/S-JVd6_vfUI/AAAAAAAAAGQ/eribr7ok0LU/s1600/Gosling.jpg"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 320px; FLOAT: left; HEIGHT: 213px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5468026870122380610" border="0" alt="" src="http://3.bp.blogspot.com/_wOFRh11vB8g/S-JVd6_vfUI/AAAAAAAAAGQ/eribr7ok0LU/s320/Gosling.jpg" /&gt;&lt;/a&gt;James Gosling, creator of Java, has quit from Oracle. He announced this on his blog. Strangely enough, his blog has disappeared. I guess they chop your blog at Oracle when you leave.&lt;br /&gt;&lt;br /&gt;Gosling did not provide a reason for leaving. Hello? Can you say &lt;a href="http://ora-pl-sql.blogspot.com/"&gt;Oracle&lt;/a&gt; acquisition? He is going to take some time off.&lt;br /&gt;&lt;br /&gt;Word on the street is that the Java faithful were taken by surprise. Does this mean that Gosling will not be present at &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;JavaOne&lt;/span&gt;? You got to go and find out.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-3099465697400977717?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/3099465697400977717/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/05/gosling-is-gone.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3099465697400977717'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3099465697400977717'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/05/gosling-is-gone.html' title='Gosling is Gone'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/S-JVd6_vfUI/AAAAAAAAAGQ/eribr7ok0LU/s72-c/Gosling.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-1576444402914771773</id><published>2010-04-05T20:43:00.003-04:00</published><updated>2010-04-05T20:49:41.459-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='JRockit'/><category scheme='http://www.blogger.com/atom/ns#' term='HotSpot'/><category scheme='http://www.blogger.com/atom/ns#' term='Java SE'/><category scheme='http://www.blogger.com/atom/ns#' term='JavaOne'/><category scheme='http://www.blogger.com/atom/ns#' term='Java ME'/><category scheme='http://www.blogger.com/atom/ns#' term='JVM'/><title type='text'>Oracle Plans</title><content type='html'>&lt;a href="http://ora-pl-sql.blogspot.com/"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 240px; FLOAT: left; HEIGHT: 320px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5456818717673476114" border="0" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/S7qDtlahUBI/AAAAAAAAAGI/VmGFdTWaY_U/s320/Oracle.jpg" /&gt;Oracle&lt;/a&gt; Corporation has a number of plans for the future of Java. They plan to merge the &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;HotSpot&lt;/span&gt; and &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-error"&gt;JRockit&lt;/span&gt; &lt;span id="SPELLING_ERROR_2" class="blsp-spelling-error"&gt;JVMs&lt;/span&gt; into one product next year. They also will be supporting languages other than Java in the &lt;span id="SPELLING_ERROR_3" class="blsp-spelling-error"&gt;JVM&lt;/span&gt;. These will include Ruby and Python.&lt;br /&gt;&lt;br /&gt;There is also talk that the Java SE and Java ME platforms will merge into one. Perhaps that means that mobile apps are becoming common. It is either that or mobile apps are not as important any more.&lt;br /&gt;&lt;br /&gt;The &lt;span id="SPELLING_ERROR_4" class="blsp-spelling-error"&gt;JavaOne&lt;/span&gt; conference is going to be held in tandem with the &lt;span id="SPELLING_ERROR_5" class="blsp-spelling-error"&gt;OpenWorld&lt;/span&gt; conference. You can register and attend events at both conferences. &lt;span id="SPELLING_ERROR_6" class="blsp-spelling-error"&gt;JavaOne&lt;/span&gt; will now be held in the September &lt;span id="SPELLING_ERROR_7" class="blsp-spelling-corrected"&gt;time frame&lt;/span&gt;. I guess Oracle has decided what has the &lt;span id="SPELLING_ERROR_8" class="blsp-spelling-corrected"&gt;precedence&lt;/span&gt;. At least they are not ending &lt;span id="SPELLING_ERROR_9" class="blsp-spelling-error"&gt;JavaOne&lt;/span&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-1576444402914771773?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/1576444402914771773/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/04/oracle-plans.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1576444402914771773'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1576444402914771773'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/04/oracle-plans.html' title='Oracle Plans'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/S7qDtlahUBI/AAAAAAAAAGI/VmGFdTWaY_U/s72-c/Oracle.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-1289804094582506624</id><published>2010-03-17T20:18:00.000-04:00</published><updated>2010-03-17T20:19:17.177-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='relational mapping'/><category scheme='http://www.blogger.com/atom/ns#' term='Jalapeno'/><category scheme='http://www.blogger.com/atom/ns#' term='Cache'/><category scheme='http://www.blogger.com/atom/ns#' term='RIA'/><category scheme='http://www.blogger.com/atom/ns#' term='POJO'/><category scheme='http://www.blogger.com/atom/ns#' term='ODMG'/><title type='text'>Object Database</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_wOFRh11vB8g/S6FxVAz7g6I/AAAAAAAAAGA/kBm-vF_OT2U/s1600-h/Object.png"&gt;&lt;img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer; width: 315px; height: 320px;" src="http://3.bp.blogspot.com/_wOFRh11vB8g/S6FxVAz7g6I/AAAAAAAAAGA/kBm-vF_OT2U/s320/Object.png" alt="" id="BLOGGER_PHOTO_ID_5449761629904012194" border="0" /&gt;&lt;/a&gt;  &lt;p class="MsoNormal" style=""&gt;&lt;span style="font-size: 10pt; font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;;"&gt;I saw an advertisement while perusing a technical magazine. It was for an object database created by &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;InterSystems&lt;/span&gt;. The product was called Cache. What caught my eye was the claim that it had technology to persist Java objects with a relational mapper.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p class="MsoNormal" style=""&gt;&lt;span style="font-size: 10pt; font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;;"&gt;The object model for Cache is based on the Object Database Management Group (&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;ODMG&lt;/span&gt;) standards. It works with C++ and .NET as well as Java. The marketing boasts 5x the speed of normal relational databases. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p class="MsoNormal" style=""&gt;&lt;span style="font-size: 10pt; font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;;"&gt;Cache is meant for Rich Internet Application development. It uses an application server. However there are multiple ways to make use of the object database. You can use &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;templated&lt;/span&gt; classes. There are also lightweight &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;API&lt;/span&gt; calls for direct database access. Finally there is the Jalapeno technology.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p class="MsoNormal" style=""&gt;&lt;span style="font-size: 10pt; font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;;"&gt;Jalapeno stands for &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;JAva&lt;/span&gt; &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;LAnguage&lt;/span&gt; &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_6"&gt;PErsistence&lt;/span&gt; with NO mapping. You create your Plain Old Java Objects (&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_7"&gt;POJO&lt;/span&gt;) first. Then you use Cache to generate a schema to work with those objects. Cache has a library class to deal with the database. You can apparently just focus on your &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_8"&gt;POJOs&lt;/span&gt;, and Cache will do the rest like magic.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-1289804094582506624?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/1289804094582506624/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/03/object-database.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1289804094582506624'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1289804094582506624'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/03/object-database.html' title='Object Database'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/S6FxVAz7g6I/AAAAAAAAAGA/kBm-vF_OT2U/s72-c/Object.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-5129463491443252830</id><published>2010-01-25T16:24:00.004-05:00</published><updated>2010-01-25T16:31:13.029-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='jar'/><category scheme='http://www.blogger.com/atom/ns#' term='archive'/><category scheme='http://www.blogger.com/atom/ns#' term='applet'/><category scheme='http://www.blogger.com/atom/ns#' term='META-INF'/><category scheme='http://www.blogger.com/atom/ns#' term='JRE'/><category scheme='http://www.blogger.com/atom/ns#' term='MANIFEST.MF'/><title type='text'>Deploying Programs</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/_wOFRh11vB8g/S14MKCtCLJI/AAAAAAAAAF4/1rWWvfywClo/s1600-h/Jar.jpg"&gt;&lt;img style="MARGIN: 0px 10px 10px 0px; WIDTH: 213px; FLOAT: left; HEIGHT: 320px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5430791567319379090" border="0" alt="" src="http://3.bp.blogspot.com/_wOFRh11vB8g/S14MKCtCLJI/AAAAAAAAAF4/1rWWvfywClo/s320/Jar.jpg" /&gt;&lt;/a&gt;I checked out Java in Easy Steps from the local public library. After scanning the table of contents, I jumped straight to the chapter on deploying programs. This is an area of weakness for me in Java development. There are two ways to distribute Java programs. You can do so as a desktop application, which will require the Java &lt;span id="SPELLING_ERROR_0" class="blsp-spelling-error"&gt;Runtime&lt;/span&gt; Environment to be installed. Or you can do so as a web page applet. The second option will require the browser to have a Java &lt;span id="SPELLING_ERROR_1" class="blsp-spelling-error"&gt;plugin&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;When rolling out a Java program, like any other installation, you need to make sure the resources required by the program are installed. The main way to include all the files you need is with a jar. Jar is a utility included in the Java &lt;span id="SPELLING_ERROR_2" class="blsp-spelling-error"&gt;SDK&lt;/span&gt;. You can find the program in the Java bin directory. This program has a command line interface.&lt;br /&gt;&lt;br /&gt;The output of the jar utility is an archive file. You can run the program contained in the archive using the Java interpreter. Here is an example to create a jar file:&lt;br /&gt;&lt;br /&gt;&lt;em&gt;jar cf &lt;span id="SPELLING_ERROR_3" class="blsp-spelling-error"&gt;dL&lt;/span&gt;1.jar &lt;span id="SPELLING_ERROR_4" class="blsp-spelling-error"&gt;dL&lt;/span&gt;1.class.&lt;br /&gt;&lt;/em&gt;&lt;br /&gt;Once you have the archive, you can inspect its contents using the following command:&lt;br /&gt;&lt;br /&gt;&lt;em&gt;jar &lt;span id="SPELLING_ERROR_5" class="blsp-spelling-error"&gt;tf&lt;/span&gt; &lt;span id="SPELLING_ERROR_6" class="blsp-spelling-error"&gt;dL&lt;/span&gt;1.jar&lt;br /&gt;&lt;/em&gt;&lt;br /&gt;You can extract the full contents of the jar file like this:&lt;br /&gt;&lt;br /&gt;&lt;em&gt;jar &lt;span id="SPELLING_ERROR_7" class="blsp-spelling-error"&gt;xf&lt;/span&gt; &lt;span id="SPELLING_ERROR_8" class="blsp-spelling-error"&gt;dL&lt;/span&gt;1.jar&lt;br /&gt;&lt;/em&gt;&lt;br /&gt;Jar creates a META-INF directory. Within that directory is the MANIFEST.&lt;span id="SPELLING_ERROR_9" class="blsp-spelling-error"&gt;MF&lt;/span&gt; file, also created by jar. You need to manually add the entry point for the program on the bottom line of that file as so:&lt;br /&gt;&lt;br /&gt;&lt;em&gt;Main-class: &lt;span id="SPELLING_ERROR_10" class="blsp-spelling-error"&gt;dL&lt;/span&gt;1&lt;br /&gt;&lt;/em&gt;&lt;br /&gt;To run the program contained in the jar, you can execute the following command:&lt;br /&gt;&lt;br /&gt;&lt;em&gt;java –jar &lt;span id="SPELLING_ERROR_11" class="blsp-spelling-error"&gt;dL&lt;/span&gt;1.jar &lt;/em&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-5129463491443252830?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/5129463491443252830/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/01/deploying-programs.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5129463491443252830'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5129463491443252830'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/01/deploying-programs.html' title='Deploying Programs'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/S14MKCtCLJI/AAAAAAAAAF4/1rWWvfywClo/s72-c/Jar.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-1988679290095987168</id><published>2010-01-20T00:20:00.002-05:00</published><updated>2010-01-20T00:21:37.758-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Ant'/><category scheme='http://www.blogger.com/atom/ns#' term='Java programmers'/><category scheme='http://www.blogger.com/atom/ns#' term='Maven'/><category scheme='http://www.blogger.com/atom/ns#' term='Korn shell scripts'/><title type='text'>Build Tools</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/S1aStBUXBgI/AAAAAAAAAFw/SoJFFkf3hq8/s1600-h/Build.png"&gt;&lt;img id="BLOGGER_PHOTO_ID_5428687702987310594" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 315px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/S1aStBUXBgI/AAAAAAAAAFw/SoJFFkf3hq8/s320/Build.png" border="0" /&gt;&lt;/a&gt;When I first joined our project, our build scripts were written in the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;Korn&lt;/span&gt; shell. Our &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;Korn&lt;/span&gt; shell programmer quit after I joined the team. Thus began our build script Hell. The scripts worked fine when everything was as expected. However they would bomb at the slightest disturbance. We needed a full time guy to baby sit this fragile set of &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;Korn&lt;/span&gt; shell scripts.&lt;br /&gt;&lt;br /&gt;Eventually a bunch of Java programmers joined the team. They decided the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;Korn&lt;/span&gt; shell scripts had to go. Being Java guys, they turned to Ant to do the builds. The result was a bit more reliable.&lt;br /&gt;&lt;br /&gt;The Java guys got bored after a while. They started looking for ways to improve the build scripts. Maven was cited as a cool build tool. There was talk about redoing the build scripts again. However the Java guys left the project before any progress was made on that front.&lt;br /&gt;&lt;br /&gt;It might be a blessing that we never ported our builds to Maven. I just read a rant describing Maven as pure evil. The author recommends you code your own build tool from scratch. He advises you to use Rake or Ant if you want to utilize a package. However he abhors Maven.&lt;br /&gt;&lt;br /&gt;Here are the reasons to avoid Maven. It has the worst configuration syntax. The documentation is bad or incomplete. Maven is not flexible. It also has a broken dependency management subsystem. Exercise extreme caution if somebody tries to port your build scripts to Maven.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-1988679290095987168?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/1988679290095987168/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2010/01/build-tools.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1988679290095987168'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1988679290095987168'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2010/01/build-tools.html' title='Build Tools'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/S1aStBUXBgI/AAAAAAAAAFw/SoJFFkf3hq8/s72-c/Build.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-2433014282975503903</id><published>2009-12-10T20:51:00.003-05:00</published><updated>2009-12-10T20:58:18.478-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='AJAX'/><category scheme='http://www.blogger.com/atom/ns#' term='profiles'/><category scheme='http://www.blogger.com/atom/ns#' term='Criteria API'/><category scheme='http://www.blogger.com/atom/ns#' term='JAX-RS'/><category scheme='http://www.blogger.com/atom/ns#' term='JPA'/><title type='text'>J2EE Version 6</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5413790365080570114" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 264px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/SyGlp08PSQI/AAAAAAAAAFo/prrga43neAg/s320/EE.jpg" border="0" /&gt;Sun &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;Microsystems&lt;/span&gt; is coming out with the next edition of the Java 2 Enterprise Edition. I read a lengthy article about the new features in this &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_1"&gt;framework&lt;/span&gt;. Here are some of the goodies that Sun says is in J2&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;EE&lt;/span&gt; 6.&lt;br /&gt;&lt;br /&gt;There are profiles which support a subset of the J2&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;EE&lt;/span&gt; standard, allowing for lean deployments. Next is the idea of extensibility. &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_4"&gt;Basically&lt;/span&gt; they are providing a way to include &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;plugins&lt;/span&gt; into the system.&lt;br /&gt;&lt;br /&gt;There is a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_6"&gt;JAX&lt;/span&gt;-RS &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_7"&gt;API&lt;/span&gt; which helps you develop &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_8"&gt;&lt;a href="http://xmlhome.blogspot.com/2008/08/representational-state-transfer.html"&gt;REST&lt;/a&gt;ful&lt;/span&gt; web services. There is also bean validation. This is a standard mechanism to perform data validation before saving to a database.&lt;br /&gt;&lt;br /&gt;Asynchronous processing of beans is built in now. J2&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_9"&gt;EE&lt;/span&gt; will also now support &lt;a href="http://xmlhome.blogspot.com/2008/08/asynchronous-javascript-and-xml.html"&gt;AJAX&lt;/a&gt;. There is a scaled down Enterprise Java Beans release called &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_10"&gt;EJB&lt;/span&gt; lite.&lt;br /&gt;&lt;br /&gt;Another technology is &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_11"&gt;JPA&lt;/span&gt;, which stands for Java Persistence &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_12"&gt;API&lt;/span&gt;. Finally there is a Criteria &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_13"&gt;API&lt;/span&gt; which is a way to query objects. I myself do not have any experience with J2&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_14"&gt;EE&lt;/span&gt;. However the Java dudes consider it essential. So you know I will be learning the basics soon.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-2433014282975503903?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/2433014282975503903/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/12/j2ee-version-6.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2433014282975503903'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2433014282975503903'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/12/j2ee-version-6.html' title='J2EE Version 6'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/SyGlp08PSQI/AAAAAAAAAFo/prrga43neAg/s72-c/EE.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-6724732041195105908</id><published>2009-12-09T19:29:00.003-05:00</published><updated>2009-12-09T19:34:35.810-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='class'/><category scheme='http://www.blogger.com/atom/ns#' term='CSS'/><category scheme='http://www.blogger.com/atom/ns#' term='CMS'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><category scheme='http://www.blogger.com/atom/ns#' term='veteran'/><title type='text'>Disappointing Advice</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/_wOFRh11vB8g/SyBBB_o1SAI/AAAAAAAAAFg/_67f_Vuni4U/s1600-h/CMS.gif"&gt;&lt;img id="BLOGGER_PHOTO_ID_5413398254617708546" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 301px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://3.bp.blogspot.com/_wOFRh11vB8g/SyBBB_o1SAI/AAAAAAAAAFg/_67f_Vuni4U/s320/CMS.gif" border="0" /&gt;&lt;/a&gt;This &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;semester&lt;/span&gt; I am taking a web development class in school. We are learning HTML and Cascading Style Sheets (&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;CSS&lt;/span&gt;). However next semester I shall take an advanced Java programming class. I thought I had better brush up on my Java programming since I had not done any since my intro to Java class.&lt;br /&gt;&lt;br /&gt;I thought I could combine what I learned in web development with some Java code to produce a Content Management System (&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;CMS&lt;/span&gt;). It would take user input and spit out a blog site in HTML. This seemed doable in a month or two if I kept the app simple.&lt;br /&gt;&lt;br /&gt;Today I read an advice column from a developer claiming to be a veteran who was in the know. He started out by recommending that developers do not create &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;CMS&lt;/span&gt; systems. &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;Ooops&lt;/span&gt;. He went on to say that developers should not code in Java. Ouch. That was the double whammy.&lt;br /&gt;&lt;br /&gt;The reasons for this advice were twofold. First there are too many existing &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;CMS&lt;/span&gt; solutions on the market. Second he said users just don't use Java apps. Well that might make sense if I was trying to start up a business with my product. But I am just trying to write a throw away app to gain some experience. So I think I am okay with my idea. It just won't turn into some money making opportunity. Or will it?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-6724732041195105908?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/6724732041195105908/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/12/disappointing-advice.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6724732041195105908'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6724732041195105908'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/12/disappointing-advice.html' title='Disappointing Advice'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/SyBBB_o1SAI/AAAAAAAAAFg/_67f_Vuni4U/s72-c/CMS.gif' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-3390031439289811064</id><published>2009-11-25T00:44:00.003-05:00</published><updated>2009-11-25T00:48:55.635-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Ant'/><category scheme='http://www.blogger.com/atom/ns#' term='incremental builds'/><category scheme='http://www.blogger.com/atom/ns#' term='cloud'/><category scheme='http://www.blogger.com/atom/ns#' term='Maven'/><category scheme='http://www.blogger.com/atom/ns#' term='Java 7'/><title type='text'>Build Speed</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/SwzEQFNZNsI/AAAAAAAAAFY/SZ3WXBxLuwk/s1600/Build.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5407913033120429762" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 211px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/SwzEQFNZNsI/AAAAAAAAAFY/SZ3WXBxLuwk/s320/Build.jpg" border="0" /&gt;&lt;/a&gt;What is hot in the world of Java right now? Well they are determining the contents of Java 7. However an article I just read focused on how Java build are getting fast.&lt;br /&gt;&lt;br /&gt;The most frequently used build tools are Maven and Ant. That comes as no surprise. The Java guys I know recommend these tools.&lt;br /&gt;&lt;br /&gt;Incremental builds bring build time down to 30 seconds or so. Incremental means you only rebuild what is &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;needed&lt;/span&gt; due to recent changes in code.&lt;br /&gt;&lt;br /&gt;Here is something I have only remotely heard about. Automatic builds triggered by code &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;checkin&lt;/span&gt; are on the rise. I know some frustrated developers on my project wish we had that. Builds are &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_2"&gt;getting&lt;/span&gt; painful on my project.&lt;br /&gt;&lt;br /&gt;One build idea that has just not taken off is building using &lt;a href="http://xmlhome.blogspot.com/2009/01/cloud-computing-overview.html"&gt;cloud computing&lt;/a&gt;. I guess a lot of the cloud is just some hype and marketing. You can trust a technology unless it is being used in the trenches to solve real problems.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-3390031439289811064?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/3390031439289811064/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/11/build-speed.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3390031439289811064'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3390031439289811064'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/11/build-speed.html' title='Build Speed'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/SwzEQFNZNsI/AAAAAAAAAFY/SZ3WXBxLuwk/s72-c/Build.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-8514216734266335221</id><published>2009-09-11T01:45:00.002-04:00</published><updated>2009-09-11T01:50:32.943-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='certifications'/><category scheme='http://www.blogger.com/atom/ns#' term='Eclipse'/><category scheme='http://www.blogger.com/atom/ns#' term='OOP'/><category scheme='http://www.blogger.com/atom/ns#' term='conferences'/><title type='text'></title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5380081915289173410" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 240px; CURSOR: hand; HEIGHT: 240px" alt="" src="http://3.bp.blogspot.com/_wOFRh11vB8g/Sqnj_z9QfaI/AAAAAAAAAFQ/FFvcQBAH9v8/s320/Java.JPG" border="0" /&gt;Previously I had written about some &lt;a href="http://enableassertions.blogspot.com/2009/09/benefits-of-java.html"&gt;benefits&lt;/a&gt; of the Java programming language. However some people just love writing code in Java. I have worked with many of these people. They will invent up projects just to write some Java. They work extra hours as long as the app is written in Java. Craziness I tell you.&lt;br /&gt;&lt;br /&gt;Well I read up on some reasons why people love Java. One is that there is industry standard certifications you can learn. You can tell whether somebody has a least a little Java &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;knowledge&lt;/span&gt; by the certification they possess.&lt;br /&gt;&lt;br /&gt;Java is also a popular language. You can always find a Java developer for your project. And you can find some &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_1"&gt;supporters&lt;/span&gt; for Java in any group of developers out there. &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_2"&gt;Although&lt;/span&gt; I have not personally experienced this, I hear Java gives good conferences.&lt;br /&gt;&lt;br /&gt;The Java programming language is easy to learn, especially if you know an object oriented language like C++. It is a general purpose language which can fit many needs. And there is one final reason to love Java that can be summed up in one word - Eclipse. Now I won't say that I love Java just yet. But I am slowly warming up to it. I need to write some enterprise application before the final verdict is in for me.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-8514216734266335221?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/8514216734266335221/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/09/previously-i-had-written-about-some.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8514216734266335221'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8514216734266335221'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/09/previously-i-had-written-about-some.html' title=''/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/Sqnj_z9QfaI/AAAAAAAAAFQ/FFvcQBAH9v8/s72-c/Java.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-3391084438245590304</id><published>2009-09-09T00:18:00.002-04:00</published><updated>2009-09-09T00:23:19.117-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='deployment'/><category scheme='http://www.blogger.com/atom/ns#' term='speed'/><category scheme='http://www.blogger.com/atom/ns#' term='money'/><category scheme='http://www.blogger.com/atom/ns#' term='love'/><title type='text'>Benefits of Java</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5379317395204451730" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 238px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/Sqcsq4s9rZI/AAAAAAAAAFI/veyfI2iAmvg/s320/DDG.gif" border="0" /&gt;Recently I blogged about some people &lt;a href="http://enableassertions.blogspot.com/2009/09/dont-be-hatin.html"&gt;hate&lt;/a&gt; Java. However there is another side to the story. For every person who dislikes Java, there are probably 5 who love it. I just read a discussion on what people like most about Java. I found the results to be most interesting.&lt;br /&gt;&lt;br /&gt;A key factor in people liking Java is the run anywhere capability. To my surprise, some people also said they liked Java because it is fast. I am not sure if that referred to a fast run-time experience. Or maybe it had to do with rapid application development.&lt;br /&gt;&lt;br /&gt;Deployment is easy with Java says some folks. I found that not to be true. However my limited experience with Java may have skewed my feelings. People also love that the libraries are well documented.&lt;br /&gt;&lt;br /&gt;Here is something I can appreciate. Java programming makes good money. You can't argue with that. Let's hope this environment is also &lt;a href="http://susops.blogspot.com/"&gt;sustainable&lt;/a&gt;. Many programmers know Java. You can write Java code and expect people to be able to maintain the code.&lt;br /&gt;&lt;br /&gt;Well there is much more love out there. I will pick up with this list in my next post.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-3391084438245590304?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/3391084438245590304/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/09/benefits-of-java.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3391084438245590304'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3391084438245590304'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/09/benefits-of-java.html' title='Benefits of Java'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/Sqcsq4s9rZI/AAAAAAAAAFI/veyfI2iAmvg/s72-c/DDG.gif' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7724963360392508455</id><published>2009-09-04T16:44:00.002-04:00</published><updated>2009-09-04T16:50:10.272-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Oak'/><category scheme='http://www.blogger.com/atom/ns#' term='EJB'/><category scheme='http://www.blogger.com/atom/ns#' term='JDBC'/><category scheme='http://www.blogger.com/atom/ns#' term='web services'/><category scheme='http://www.blogger.com/atom/ns#' term='JDK'/><category scheme='http://www.blogger.com/atom/ns#' term='Java 7'/><title type='text'>Java History</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/SqF8NWeksII/AAAAAAAAAFA/AxFEzLzOrjg/s1600-h/Oak.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5377715998871040130" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 291px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/SqF8NWeksII/AAAAAAAAAFA/AxFEzLzOrjg/s320/Oak.jpg" border="0" /&gt;&lt;/a&gt;I started learning how to code in Java this year. It is like I arrived very late to the party. I just hope the party is not over. Now it is not like I never heard about Java over the years. I just did not get into it until now.&lt;br /&gt;&lt;br /&gt;I read a humorous post that reflected back on Java from the beginnings. There is a lot to the history. However I found many of the milestones were events that I heard about.&lt;br /&gt;&lt;br /&gt;Java actually started out as the Oak programming language. The name was switched to Java. The Java 1 developer's conference had a mighty turn out. Version 1.1 of the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;JDK&lt;/span&gt; had &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;JDBC&lt;/span&gt; for database connectivity.&lt;br /&gt;&lt;br /&gt;Java 2.0 came out. Then there was Enterprise Java beans. I recall the C++ programmers on my project getting excited about &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;EJBs&lt;/span&gt; when they first came out. Then the excitement died down. To tell the truth, I don't really know much about &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;EJBs&lt;/span&gt;. I assume they are a way to store data you get from the DB.&lt;br /&gt;&lt;br /&gt;Web services got hot in the Java world. I also recall the craze where every team on my project wanted to publish some web services. That was short lived though. I saw a metric that 75% of developers used Java back in 2003. I wonder if the number still hold true.&lt;br /&gt;&lt;br /&gt;Another metric I spied was that 4.5M developers use Java today. That's a heck of a lot of people. What is the future of Java? I read an article every now and then about problems with Java 7. Time to get familiar with the new Java landscape. Perhaps this party has really only just begun.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7724963360392508455?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7724963360392508455/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/09/java-history.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7724963360392508455'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7724963360392508455'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/09/java-history.html' title='Java History'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/SqF8NWeksII/AAAAAAAAAFA/AxFEzLzOrjg/s72-c/Oak.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-494121093984805619</id><published>2009-09-03T01:28:00.002-04:00</published><updated>2009-09-03T01:34:35.056-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='performance'/><category scheme='http://www.blogger.com/atom/ns#' term='frameworks'/><category scheme='http://www.blogger.com/atom/ns#' term='patterns'/><category scheme='http://www.blogger.com/atom/ns#' term='verbosity'/><title type='text'>Don't Be Hatin</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5377108963071763986" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 274px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/Sp9UHN52JhI/AAAAAAAAAE4/yOJafUIUw5s/s320/Hate.jpg" border="0" /&gt;I read a whole discussion on why people hate the Java programming language. This was strange. Normally I hear people saying they hate things like C++. Most of the hard core programmers I know actually like Java. So I thought I would expose some of the hate themes.&lt;br /&gt;&lt;br /&gt;A common complaint about Java is that it is verbose. I can understand this perspective as the new hot functional languages seem to get a lot done in a one liner. There is also the age old complaint about poor Java based performance.&lt;br /&gt;&lt;br /&gt;One particular complaint is one that I share. Java is all about many frameworks. I don't like it because you need to learn all the frameworks before you can call yourself a real Java programmer. The language is also associated with rampant design pattern abuse. &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;Nuff&lt;/span&gt; said on that.&lt;br /&gt;&lt;br /&gt;Here is something I found odd, and that others hate about Java. You are limited to one class per file. &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;WTF&lt;/span&gt;? Shouldn't the programmer be able to make that decision? Another drawback is that you don't produce &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;executables&lt;/span&gt; with Java. That is both a love and a hate I would guess. The consensus is that Java is poised to keep the enterprise market locked up. If you work for a big company, or more importantly you work on a big project, chances are you will code in Java.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-494121093984805619?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/494121093984805619/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/09/dont-be-hatin.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/494121093984805619'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/494121093984805619'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/09/dont-be-hatin.html' title='Don&apos;t Be Hatin'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/Sp9UHN52JhI/AAAAAAAAAE4/yOJafUIUw5s/s72-c/Hate.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-9116295150912842644</id><published>2009-08-04T18:46:00.002-04:00</published><updated>2009-08-04T18:49:20.314-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='javac'/><category scheme='http://www.blogger.com/atom/ns#' term='hexadecimal'/><category scheme='http://www.blogger.com/atom/ns#' term='class file'/><category scheme='http://www.blogger.com/atom/ns#' term='bytes'/><title type='text'>Java Trivia</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/Sni6V7VHMDI/AAAAAAAAAEw/BdgvPh2aqds/s1600-h/Hex.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5366243841878208562" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 240px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/Sni6V7VHMDI/AAAAAAAAAEw/BdgvPh2aqds/s320/Hex.jpg" border="0" /&gt;&lt;/a&gt;I saw an old timer ask what the first four bytes of a Java class file are. Who knows? Who cares? It turns our the answer is 0&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;xCAFEBABE&lt;/span&gt;. I tell you what. That does not seem to be a very important fact, unless you are trying to clone &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;javac&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Well this random piece of trivia does not seem relevant to the world of Java programming. However it is a neat way to identify Java class files (aside from the .class extension). Perhaps this is more of use to file scanners and such.&lt;br /&gt;&lt;br /&gt;Perhaps this is an invitation to break out a hex file view and see what is really in those .class files.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-9116295150912842644?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/9116295150912842644/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/08/java-trivia.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/9116295150912842644'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/9116295150912842644'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/08/java-trivia.html' title='Java Trivia'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/Sni6V7VHMDI/AAAAAAAAAEw/BdgvPh2aqds/s72-c/Hex.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-569202841965010164</id><published>2009-07-30T22:14:00.004-04:00</published><updated>2009-07-30T22:23:17.705-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='program'/><category scheme='http://www.blogger.com/atom/ns#' term='I/O'/><category scheme='http://www.blogger.com/atom/ns#' term='filter'/><category scheme='http://www.blogger.com/atom/ns#' term='hasLine'/><category scheme='http://www.blogger.com/atom/ns#' term='TDD'/><title type='text'>Scanner Troubles</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5364441975957149490" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 214px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/SnJTjhse1zI/AAAAAAAAAEo/2CVmINFxtbE/s320/Scanner.jpg" border="0" /&gt;I got &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;ahold&lt;/span&gt; of this text file that was the content of the &lt;a href="http://black-of-hat.blogspot.com/2009/07/zero-for-owned.html"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;ZF&lt;/span&gt;05&lt;/a&gt; zine. My goal was to write a program to extract the good parts of the zine for me to read quickly. Of course I was writing my program in Java.&lt;br /&gt;&lt;br /&gt;My process was to do some &lt;a href="http://verifcation-and-validation.blogspot.com/2009/06/time-for-tdd.html"&gt;Test Driven Development&lt;/a&gt;. So before I wrote the complex algorithms to do smart filters, I decided to write some simple I/O operations first. To do this I employed the Scanner class in Java. That &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_2"&gt;should&lt;/span&gt; be easy. You pass the Scanner constructor a File object. Then you keep calling &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;nextLine&lt;/span&gt;() as long as there is a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;hasLine&lt;/span&gt;().&lt;br /&gt;&lt;br /&gt;My first TDD exercise was to write a copy program. It should just take a file and duplicate its contents to a second file. That sounds easy. My first attempt compiled quickly. But when it ran, it only copied part of the file. I thought perhaps it was some type of buffer overflow. However no exceptions were through. The program ended gracefully. I put my debugger hat on. Then I determined how far the copy was getting in the source &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_5"&gt;file&lt;/span&gt;. That when I discovered some strange characters in the source file. They seemed to be causing &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_6"&gt;hasLine&lt;/span&gt;() to return FALSE prematurely. It is going to take some digging into the Scanner class to figure out why I was getting this false positive. For now I will just give you some lines around the place where &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_7"&gt;hasLine&lt;/span&gt;() choked. See if you can see why it is failing:&lt;br /&gt;&lt;br /&gt;-&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_8"&gt;rw&lt;/span&gt;-r--r--    1 &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_9"&gt;thalakan&lt;/span&gt;  &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_10"&gt;thalakan&lt;/span&gt;         386 Jan  5  2006 &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_11"&gt;zeller&lt;/span&gt;.&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_12"&gt;cd&lt;/span&gt;&lt;br /&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_13"&gt;rwxr&lt;/span&gt;-&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_14"&gt;xr&lt;/span&gt;-x    2 &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_15"&gt;thalakan&lt;/span&gt;  &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_16"&gt;thalakan&lt;/span&gt;         512 Jun 22  2006 Ã£ÂÂ‹Ã£Â&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_17"&gt;ÂŸÃ&lt;/span&gt;£ÂÂ‹Ã£ï¿½ls&lt;br /&gt;$ cat watcher.pl&lt;br /&gt;#!/&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_18"&gt;usr&lt;/span&gt;/bin/&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_19"&gt;perl&lt;/span&gt; -w&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-569202841965010164?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/569202841965010164/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/07/scanner-troubles.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/569202841965010164'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/569202841965010164'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/07/scanner-troubles.html' title='Scanner Troubles'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/SnJTjhse1zI/AAAAAAAAAEo/2CVmINFxtbE/s72-c/Scanner.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7306823712282767098</id><published>2009-07-29T18:15:00.002-04:00</published><updated>2009-07-29T18:19:56.538-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='byte code'/><category scheme='http://www.blogger.com/atom/ns#' term='Lisp'/><category scheme='http://www.blogger.com/atom/ns#' term='dynamic typing'/><category scheme='http://www.blogger.com/atom/ns#' term='JVM'/><title type='text'>Java Virtual Machine</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/SnDKIRdRP_I/AAAAAAAAAEg/9B4gsKnwUoo/s1600-h/JVM.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5364009399672193010" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 226px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/SnDKIRdRP_I/AAAAAAAAAEg/9B4gsKnwUoo/s320/JVM.jpg" border="0" /&gt;&lt;/a&gt;I just read this blurb that the Java Virtual Machine will support languages with dynamic languages. Huh? Is Sun saying that Java will have dynamic typing. If so, why don't they come out and say so instead of talking about the JVM?&lt;br /&gt;&lt;br /&gt;The truth behind this strange statement is that the JVM is not the same as Java. The JVM is a program which executes byte code. Java is a programming language. Now it just so happens that Java gets translated down into bytecode, and the JVM runs that code. However the key is that other languages can be translated into bytecode as well.&lt;br /&gt;&lt;br /&gt;I understand that a flavor of Lisp has a compiler which translates the source into bytecode. It currently runs fine in the default JVM from Sun. Who knows? Maybe Sun Microsystems is looking to release some other important programming language. For now I am concentrating on Java.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7306823712282767098?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7306823712282767098/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/07/java-virtual-machine.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7306823712282767098'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7306823712282767098'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/07/java-virtual-machine.html' title='Java Virtual Machine'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/SnDKIRdRP_I/AAAAAAAAAEg/9B4gsKnwUoo/s72-c/JVM.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-2114198764582266358</id><published>2009-07-07T21:30:00.003-04:00</published><updated>2009-07-07T21:34:00.734-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='stored procs'/><category scheme='http://www.blogger.com/atom/ns#' term='support'/><category scheme='http://www.blogger.com/atom/ns#' term='PL/SQL'/><category scheme='http://www.blogger.com/atom/ns#' term='Oracle Corporation'/><title type='text'>Larry Ellison Drops By</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5355895591945786930" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 216px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/SlP2qgQCVjI/AAAAAAAAAEY/7YqHYGDBfJI/s320/Ellison.jpg" border="0" /&gt;Have you heard the latest news? Larry Ellison, CEO of Oracle Corporation, dropped by to address the crowd at &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;JavaOne&lt;/span&gt; this year. He assured Java developers that Oracle will support Java. There is just one problem with that. Can you trust Larry Ellison? I mean we are not talking about Larry Page here.&lt;br /&gt;&lt;br /&gt;I do believe Oracle actually uses Java though. Originally you would code stored procedures in their proprietary &lt;a href="http://ora-pl-sql.blogspot.com/"&gt;PL/&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;SQL&lt;/span&gt; &lt;/a&gt;programming language. However as the Internet and Java got hot, Oracle added the ability to code stored &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;procs&lt;/span&gt; in Java. Nice touch. I still don't trust them.&lt;br /&gt;&lt;br /&gt;Scott &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;McNealy&lt;/span&gt;, chairman of the Sun &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;Microsystems&lt;/span&gt; board of directors, concurred that Oracle has spent a lot of money on Java. In fact he stated that Oracle spends more money on Java than any other company. Perhaps they shall protect their investment. The hard part in buying all this is that the Oracle database is Oracle &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;Corporation's&lt;/span&gt; true investment, not the Java programming language.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-2114198764582266358?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/2114198764582266358/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/07/larry-ellison-drops-by.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2114198764582266358'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2114198764582266358'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/07/larry-ellison-drops-by.html' title='Larry Ellison Drops By'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/SlP2qgQCVjI/AAAAAAAAAEY/7YqHYGDBfJI/s72-c/Ellison.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-4317597225184661660</id><published>2009-07-06T01:01:00.003-04:00</published><updated>2009-07-06T01:07:46.647-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='blog'/><category scheme='http://www.blogger.com/atom/ns#' term='technical sessions'/><category scheme='http://www.blogger.com/atom/ns#' term='contest'/><category scheme='http://www.blogger.com/atom/ns#' term='SDN'/><category scheme='http://www.blogger.com/atom/ns#' term='JavaOne'/><title type='text'>JavaOne Contest Dud</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5355208064019135794" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 142px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/SlGFXHIq_TI/AAAAAAAAAEQ/6PXlFMKSxjI/s320/Sun.png" border="0" /&gt;Sun &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;Microsystems&lt;/span&gt; hosted a contest that turned out sour for me. You had to blog about &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;JavaOne&lt;/span&gt; 2009 technical sessions. I did not attend &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;JavaOne&lt;/span&gt;. This was not supposed to be a problem as they post the technical sessions online.&lt;br /&gt;&lt;br /&gt;I opted to view the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;JavaOne&lt;/span&gt; technical sessions as &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;PDF&lt;/span&gt; documents. Sun makes you sign up for their Sun Developer Network (&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;SDN&lt;/span&gt;) to view the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_6"&gt;PDFs&lt;/span&gt;. This seemed like a hassle. But it was free so I decided to go through the motions. I created a new account. The directions told me to respond to an e-mail to confirm my address.&lt;br /&gt;&lt;br /&gt;Here's the thing. I never received the e-mail. It is bad enough that I had to go through these hoops to access the technical content. But some glitch resulted in the process not working. Yeah I could try again. Why should I? This is going to take some time and might not even work again. My time is worth money. Now I don't want to blog about &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_7"&gt;JavaOne&lt;/span&gt; technical info. Fail.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-4317597225184661660?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/4317597225184661660/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/07/javaone-contest-dud.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/4317597225184661660'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/4317597225184661660'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/07/javaone-contest-dud.html' title='JavaOne Contest Dud'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/SlGFXHIq_TI/AAAAAAAAAEQ/6PXlFMKSxjI/s72-c/Sun.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-8817496060720743966</id><published>2009-05-31T00:22:00.002-04:00</published><updated>2009-05-31T00:28:56.585-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='case'/><category scheme='http://www.blogger.com/atom/ns#' term='concatentation'/><category scheme='http://www.blogger.com/atom/ns#' term='comments'/><category scheme='http://www.blogger.com/atom/ns#' term='equals'/><category scheme='http://www.blogger.com/atom/ns#' term='String'/><title type='text'>Solving Puzzles</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5341838779142677858" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 239px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/SiIGET40pWI/AAAAAAAAAEI/1EuOJiu7pCw/s320/Puzzlers.jpg" border="0" /&gt;Today I read another chapter from a free &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;PDF&lt;/span&gt; &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;downloadable&lt;/span&gt; book, whose chapters are all from other books for sale. Nice marketing tactic. This chapter was from a book called Java Puzzlers by Joshua Bloch. There were a number of words of wisdom contained inside.&lt;br /&gt;&lt;br /&gt;For example, the + operator means string concatenation only when at least one of the operands is itself a String. Otherwise you get addition.&lt;br /&gt;&lt;br /&gt;Here is another example stressed by my Java programming class instructor. The == operator tests whether two object references refer to the same object. It does not test whether the two objects contain an equivalent String. To do that requires the equals method.&lt;br /&gt;&lt;br /&gt;We really did not get down to how the Java compiler works in my class or the book I read. However I found out that there are multiple passes. One of the first passes is translation of escape sequences. After that &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;tokenization&lt;/span&gt; takes place.&lt;br /&gt;&lt;br /&gt;Let me end with some tips that are not specific to the Java programming language. One is to not leave code commented out. Just delete it to prevent comprehension problems. The other is to avoid case statements within a switch statement to fall through to the next case. That is just bad practice.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-8817496060720743966?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/8817496060720743966/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/05/solving-puzzles.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8817496060720743966'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8817496060720743966'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/05/solving-puzzles.html' title='Solving Puzzles'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/SiIGET40pWI/AAAAAAAAAEI/1EuOJiu7pCw/s72-c/Puzzlers.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-2498458348760546598</id><published>2009-05-29T01:15:00.003-04:00</published><updated>2009-05-29T01:24:47.874-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='protected'/><category scheme='http://www.blogger.com/atom/ns#' term='Joshua Bloch'/><category scheme='http://www.blogger.com/atom/ns#' term='Builder pattern'/><category scheme='http://www.blogger.com/atom/ns#' term='static factory'/><title type='text'>Effective Java</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/Sh9vaSqF6GI/AAAAAAAAAEA/IeMwm9itW3E/s1600-h/EffectiveJava.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5341110180560365666" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 254px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/Sh9vaSqF6GI/AAAAAAAAAEA/IeMwm9itW3E/s320/EffectiveJava.jpg" border="0" /&gt;&lt;/a&gt;While browsing around the net, I came across this free Java book. It was a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;PDF&lt;/span&gt; whose chapters each contain samples from other books. One such sample chapter was from Effective Java by Joshua Bloch. The second edition of this book came out last year. The first edition was from back in 2001.&lt;br /&gt;&lt;br /&gt;Although Bloch now works for Google, he came from Sun &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;Microsystems&lt;/span&gt;. This is why he is intimately familiar with Java and the Java &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;API&lt;/span&gt;. The book has a list price of $49.99 like the first edition. How you can find discounts at many places like Amazon dot com.&lt;br /&gt;&lt;br /&gt;Here are some interesting ideas I got from Chapter 2 of the book. The first is that of a static factory method. This is a method which is static. It returns an instance of the class. This technique has a number of advantages over a normal constructor. This is not to be confused with the Factory Method design pattern.&lt;br /&gt;&lt;br /&gt;One thing I found surprising was talk about the protected access modifier. When I learned Java, I was only taught about public and private. However now that I think back upon it, someone in my class who already knew some Java asked whether "protected" had been removed from Java. &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_3"&gt;Unfortunately&lt;/span&gt; the instructor did not know the answer.&lt;br /&gt;&lt;br /&gt;Another pattern described is the Builder pattern. This is a three part process to initialize objects with a subset of all possible parameters. First you get a builder object. You then call setters on this object for the optional parameter you wish to set. Then you call the build object which uses the properties you set, and generates an object for you.&lt;br /&gt;&lt;br /&gt;Finally there is a call for developers to remember to null out references to objects that are obsolete. This is essential to prevent memory leaks. Yes there is potential for memory leaks in Java, especially when you are managing your own objects as in a stack.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-2498458348760546598?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/2498458348760546598/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/05/effective-java.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2498458348760546598'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2498458348760546598'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/05/effective-java.html' title='Effective Java'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/Sh9vaSqF6GI/AAAAAAAAAEA/IeMwm9itW3E/s72-c/EffectiveJava.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-5857873900618108216</id><published>2009-05-25T23:30:00.002-04:00</published><updated>2009-05-25T23:33:29.761-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Java code'/><category scheme='http://www.blogger.com/atom/ns#' term='color'/><category scheme='http://www.blogger.com/atom/ns#' term='prototype'/><category scheme='http://www.blogger.com/atom/ns#' term='position'/><category scheme='http://www.blogger.com/atom/ns#' term='size'/><title type='text'>Code Viewers</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/ShtiZjgMtFI/AAAAAAAAAD4/rT-ogjC0SRU/s1600-h/Code.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5339969974344397906" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 229px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/ShtiZjgMtFI/AAAAAAAAAD4/rT-ogjC0SRU/s320/Code.jpg" border="0" /&gt;&lt;/a&gt;I just a neat blog entry by &lt;a href="http://www.blogger.com/profile/05555159518106911714"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;SteveChy&lt;/span&gt;&lt;/a&gt; on an alternative way to display Java code. Check out the example image he provided. Better yet, read the post yourself at his &lt;a href="http://free-idea-monoid.blogspot.com/2009/05/code-layout-experiements.html?showComment=1243308549127#c7072616850366646182"&gt;Free &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;Ideo&lt;/span&gt; &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;Monoid&lt;/span&gt;&lt;/a&gt; blog yourself.&lt;br /&gt;&lt;br /&gt;The general idea is to avoid colorization to specify things in your code. Instead he will use size and positioning to convey meaning. Some of the ideas looked good.&lt;br /&gt;&lt;br /&gt;It appears that this is just a prototype. Let's hope this guy follows through and releases an app to view and maybe even edit Java code. Good stuff.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-5857873900618108216?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/5857873900618108216/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/05/code-viewers.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5857873900618108216'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5857873900618108216'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/05/code-viewers.html' title='Code Viewers'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/ShtiZjgMtFI/AAAAAAAAAD4/rT-ogjC0SRU/s72-c/Code.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7268620633344378024</id><published>2009-05-22T22:49:00.002-04:00</published><updated>2009-05-22T22:55:10.743-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='college'/><category scheme='http://www.blogger.com/atom/ns#' term='parsing'/><category scheme='http://www.blogger.com/atom/ns#' term='classes'/><category scheme='http://www.blogger.com/atom/ns#' term='Computer Science'/><title type='text'>File Parsing</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5338846210879186114" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 212px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/ShdkV6Xk5MI/AAAAAAAAADw/cT916I8Unio/s320/College.jpg" border="0" /&gt;I have an idea for a new Java program which requires information about my colleges schedule of classes. Specifically I want to know what all the Computer Science classes are, and what the prerequisites for each are. This information is readily available in the latest schedule of classes. The chore is to get that information into my program. How do you do that? You write a program of course.&lt;br /&gt;&lt;br /&gt;To start with, the schedule of classes is a huge &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;PDF&lt;/span&gt; file. I used Adobe Acrobat to export this file to plain ASCII text. Then I wrote a small Java program to read in the file one line at a time. I coded in some rules to parse the lines to figure out which ones were computer science courses. So far I can detect all the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;CIS&lt;/span&gt; courses fine. For now I have the code just grabbing the text of the prerequisites for each class.&lt;br /&gt;&lt;br /&gt;The next step is for me to build some structure which can easily represent the relationship between classes. Perhaps this is a big tree. I don't know. I do know that I must first read in all the information. Then I can make the connections in my tree. I already have a Java class called Course. And I have coded most of the logic into my Java class Parser. There are a lot more Java class before I have all the information that I want.&lt;br /&gt;&lt;br /&gt;Sorry I have been a little cryptic about my eventual application which will require all this information. Perhaps when I am done I will upload the application here. For now I am keeping it on the down low. I am finding it hard to schedule time to work on my Java programming. As soon as my Java college class ended, there was nothing else driving me to code. And get this. The university does not offer a Java Programming 2 class. Go figure.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7268620633344378024?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7268620633344378024/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/05/file-parsing.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7268620633344378024'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7268620633344378024'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/05/file-parsing.html' title='File Parsing'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/ShdkV6Xk5MI/AAAAAAAAADw/cT916I8Unio/s72-c/College.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-9084701729585434229</id><published>2009-05-06T20:20:00.002-04:00</published><updated>2009-05-06T20:20:59.675-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='constructor'/><category scheme='http://www.blogger.com/atom/ns#' term='superclass'/><category scheme='http://www.blogger.com/atom/ns#' term='inheritance'/><category scheme='http://www.blogger.com/atom/ns#' term='override'/><title type='text'>The Use of super()</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/_wOFRh11vB8g/SgIpUNn-gLI/AAAAAAAAADo/2DS3l8PyFDU/s1600-h/Super.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5332870335991546034" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://3.bp.blogspot.com/_wOFRh11vB8g/SgIpUNn-gLI/AAAAAAAAADo/2DS3l8PyFDU/s320/Super.jpg" border="0" /&gt;&lt;/a&gt;This week I wrap up my college class on Java programming. We spent a lot of time on some basic Java concepts in class. That meant we had to rush through a lot of the final chapters in the book. Unfortunately we rushed through inheritance, and skipped many sections. One such section we skipped was the use of super() to reach up to a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;superclass&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;On first glass, I assumed you had to &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;prepend&lt;/span&gt; any methods of the base class when you call them from a child class. However that is not normally the case. You can just call a method. If it is defined in the super class, Java will know what code to execute normally. That is because subclasses are extensions of the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;superclass&lt;/span&gt;. That is, they have access to the same public methods defined in the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;superclass&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;There are two exceptions which require the use of super. One of them is the constructor of the child class. If you do nothing special in this constructor, Java will call the default constructor of the parent class for you. However if you want to call one of the other constructors of the parent class, you must make that call with super().&lt;br /&gt;&lt;br /&gt;The other occasion when you need to use super is when you have a method that is overridden in the child class. If you make a call to an overridden method in the child class, Java chooses the overridden method to execute. You might want to execute the code for the overridden method in the base class. To do that, you have to put the super keyword before the method name.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-9084701729585434229?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/9084701729585434229/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/05/use-of-super.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/9084701729585434229'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/9084701729585434229'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/05/use-of-super.html' title='The Use of super()'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/SgIpUNn-gLI/AAAAAAAAADo/2DS3l8PyFDU/s72-c/Super.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-6716918096480526696</id><published>2009-04-29T16:56:00.002-04:00</published><updated>2009-04-29T17:00:17.075-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='throw'/><category scheme='http://www.blogger.com/atom/ns#' term='catch'/><category scheme='http://www.blogger.com/atom/ns#' term='getMessage'/><category scheme='http://www.blogger.com/atom/ns#' term='exception'/><category scheme='http://www.blogger.com/atom/ns#' term='C++'/><title type='text'>Exceptions</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5330220109442402050" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 155px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/Sfi-8uX1RwI/AAAAAAAAADg/5nRPeA7uiZo/s320/Exception.jpg" border="0" /&gt;I am nearing the end of the Spring college semester. This semester I am taking a Java programming class. There was one chapter near the end of the course on exceptions. We did not spend much time on it because there is not much time left. However I am still trying hard to wrap my hands around the concept.&lt;br /&gt;&lt;br /&gt;Exceptions are not unique to the Java programming language. I know C++ has them. And I would guess many other languages have them as well. It is straight forward how to throw and catch an Exception object. You are just passing a message. However I have still not yet found a great reason to create my own exception classes. I guess I could use them to ensure the caller can separate exceptions with different catch blocks. But aren't they all going to just call &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;getMessage&lt;/span&gt;() on my object?&lt;br /&gt;&lt;br /&gt;Here is one thing I have determined about exceptions. This also applies to any classes you write. You should not name the class with too long of a name. It gets tiring to type all those characters. Yes I know you can cut and paste. But if there is a misspelling, and there are a million characters in the name, it takes a long time to figure out where I went wrong. I am going to do a bunch of programming projects where I throw and catch exceptions. Perhaps after that I will have a better feel for them.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-6716918096480526696?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/6716918096480526696/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/04/exceptions.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6716918096480526696'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6716918096480526696'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/04/exceptions.html' title='Exceptions'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/Sfi-8uX1RwI/AAAAAAAAADg/5nRPeA7uiZo/s72-c/Exception.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-2294131716382838161</id><published>2009-04-17T16:01:00.003-04:00</published><updated>2009-04-17T16:07:59.820-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='projects'/><category scheme='http://www.blogger.com/atom/ns#' term='exercises'/><category scheme='http://www.blogger.com/atom/ns#' term='class'/><category scheme='http://www.blogger.com/atom/ns#' term='arrays'/><category scheme='http://www.blogger.com/atom/ns#' term='questions'/><title type='text'>Good or Great</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5325753052011954146" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 298px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/SejgLwqf_-I/AAAAAAAAADY/gaD2QRONv5I/s320/Great.jpg" border="0" /&gt;I have finished reading the chapter on arrays in Java. This is for my college class. In addition to the reading, I have completed each Self-Test question from the chapter. I have written Java programs to solve all the exercises at the end of the chapter. You could say that I have achieved a good understanding of the material.&lt;br /&gt;&lt;br /&gt;Here comes the hard part. There are also a bunch of programming projects at the end of the chapter. However there are so many other things I would rather be doing. We are behind at work. I could catch up with this week's list of tasks to be completed. It is nice outside. I can do some necessary yard work. The weather also lends itself to me taking a bike ride with friends. The girlfriend wants to see a bunch of movies. She is also hungry and wants to go out to eat.&lt;br /&gt;&lt;br /&gt;It is easy in the middle of the night to spend some time learning Java. The hard part is now when I really don't want to do any more Java programming. After all, I have reached a good enough level of understanding. What is there to gain by going further? The answer is that there is greatness to be attained. Now I am not saying that I will be a great Java developer. But in order to have a chance at greatness, I must push on now. It is absolutely required to do each and every one of the programming projects in the back of the &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;book&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;To tell the truth, greatness will also require going beyond the projects in the book. I need to code up some other programs using Java. You know. I need to implement some non trivial application using the Java programming language. Only then will I have a slight chance at possessing great Java programming skills. Let's see where this takes me.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-2294131716382838161?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/2294131716382838161/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/04/good-or-great.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2294131716382838161'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2294131716382838161'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/04/good-or-great.html' title='Good or Great'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/SejgLwqf_-I/AAAAAAAAADY/gaD2QRONv5I/s72-c/Great.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-9137707554785863593</id><published>2009-04-10T07:38:00.003-04:00</published><updated>2009-04-10T07:41:56.448-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='algorithms'/><category scheme='http://www.blogger.com/atom/ns#' term='traversal'/><category scheme='http://www.blogger.com/atom/ns#' term='sorting'/><category scheme='http://www.blogger.com/atom/ns#' term='arrays'/><title type='text'>Selection Sort</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5323025716221898146" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 215px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/Sd8vr7Gs7aI/AAAAAAAAADQ/a378E06ad7E/s320/Sort.jpg" border="0" /&gt;I have been reading ahead in my textbook. The next chapter is on arrays. To help learn arrays well, the textbook goes over a number of sorting algorithms. One exercise just had me implement selection sort.&lt;br /&gt;&lt;br /&gt;Selection sort is one of the easiest sort methods. It is an in-place algorithm, requiring no extra space in a array other than one temporary variable to do &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;swaps&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;The way selection sort works is to traverse the array, and swap the current element with the smallest value from the rest of the array. It could not get any simpler. However this technique has poor performance if you have many elements in the array.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-9137707554785863593?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/9137707554785863593/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/04/selection-sort.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/9137707554785863593'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/9137707554785863593'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/04/selection-sort.html' title='Selection Sort'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/Sd8vr7Gs7aI/AAAAAAAAADQ/a378E06ad7E/s72-c/Sort.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-1142840111949470224</id><published>2009-04-01T16:53:00.003-04:00</published><updated>2009-04-01T16:57:57.073-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='operator new'/><category scheme='http://www.blogger.com/atom/ns#' term='class constructor'/><category scheme='http://www.blogger.com/atom/ns#' term='keyword this'/><category scheme='http://www.blogger.com/atom/ns#' term='method name'/><title type='text'>Constructor Calling Constructor</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/SdPUm40Q1TI/AAAAAAAAADI/f8HD503INvA/s1600-h/Constructor.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5319829349406397746" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 177px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/SdPUm40Q1TI/AAAAAAAAADI/f8HD503INvA/s320/Constructor.jpg" border="0" /&gt;&lt;/a&gt;We just started learning about class constructors in my Java programming class. In the past, we just did the new operator without knowing what was going on. Now we are getting a little more information on the subject. There is one specific constructor issue of interest to me. That is the case where a constructor calls another constructor. My book instructed me to use the “this” keyword to accomplish it as so:&lt;br /&gt;&lt;br /&gt;public Class Pet&lt;br /&gt;{&lt;br /&gt;&lt;blockquote&gt;public Pet()&lt;br /&gt;{&lt;br /&gt;// default constructor code&lt;br /&gt;}&lt;br /&gt;&lt;/blockquote&gt;&lt;blockquote&gt;public Pet(String name)&lt;br /&gt;{&lt;br /&gt;// call the default constructor&lt;br /&gt;this();&lt;br /&gt;}&lt;br /&gt;&lt;/blockquote&gt;}&lt;br /&gt;&lt;br /&gt;I found this syntax to be a little strange. Yes I understand the “this” keyword refers to the current object. But we are talking about making a call to a method in the class. Why not use the name of the method like so:&lt;br /&gt;&lt;br /&gt;public Class Pet&lt;br /&gt;{&lt;br /&gt;&lt;blockquote&gt;public Pet()&lt;br /&gt;{&lt;br /&gt;// default constructor code&lt;br /&gt;}&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;blockquote&gt;public Pet(String name)&lt;br /&gt;{&lt;br /&gt;Pet(); // This does not work!&lt;br /&gt;}&lt;br /&gt;&lt;/blockquote&gt;}&lt;br /&gt;&lt;br /&gt;It seems logical to use the actual method name when making a call to it. However the Java designers must not have agreed with me. Calling the constructor by its name results in a compile time error. Oh well. It was worth a try.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-1142840111949470224?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/1142840111949470224/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/04/constructor-calling-constructor.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1142840111949470224'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1142840111949470224'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/04/constructor-calling-constructor.html' title='Constructor Calling Constructor'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/SdPUm40Q1TI/AAAAAAAAADI/f8HD503INvA/s72-c/Constructor.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-1399465883808234240</id><published>2009-03-31T21:54:00.003-04:00</published><updated>2009-03-31T21:59:18.638-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='application'/><category scheme='http://www.blogger.com/atom/ns#' term='registry'/><category scheme='http://www.blogger.com/atom/ns#' term='Windows'/><category scheme='http://www.blogger.com/atom/ns#' term='time'/><title type='text'>Rapid Application Development</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5319535519207044754" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 261px; CURSOR: hand; HEIGHT: 119px" alt="" src="http://3.bp.blogspot.com/_wOFRh11vB8g/SdLJXuBotpI/AAAAAAAAADA/9pc7p2OghzI/s320/TaskCtrl.jpg" border="0" /&gt;I had a little free time at work. So I decided to quickly code up a small application to do some work on Windows. I wanted to showcase this application on the &lt;a href="http://black-of-hat.blogspot.com/"&gt;Black of Hat&lt;/a&gt; blog.&lt;br /&gt;&lt;br /&gt;These days my goal is to write all new applications in Java. This will give me some good practice. However I had some strict requirements for this latest application. It needed to have a graphical user interface. It needed to interact with the Microsoft Windows Registry. Finally it needed to by done quickly.&lt;br /&gt;&lt;br /&gt;Unfortunately I fell back to my C++ programming skills. The result was the &lt;a href="http://black-of-hat.blogspot.com/2009/03/new-program-taskctrl.html"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;TaskCtrl&lt;/span&gt;&lt;/a&gt; program. To tell the truth, I am not sure if Java is even able to update the Microsoft Windows registry. I have the feeling that it cannot modify the state of the file system for security reasons. Therefore I guessed that it could also not deal with the Windows registry.&lt;br /&gt;&lt;br /&gt;Who knows? Maybe by the end of the college semester I will be able to write Java programs with graphic users interfaces. And I will be able to knock out the code quickly as well.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-1399465883808234240?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/1399465883808234240/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/rapid-application-development.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1399465883808234240'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/1399465883808234240'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/rapid-application-development.html' title='Rapid Application Development'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/SdLJXuBotpI/AAAAAAAAADA/9pc7p2OghzI/s72-c/TaskCtrl.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-512502859147975184</id><published>2009-03-30T20:39:00.002-04:00</published><updated>2009-03-30T20:42:43.769-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='map'/><category scheme='http://www.blogger.com/atom/ns#' term='college'/><category scheme='http://www.blogger.com/atom/ns#' term='work'/><category scheme='http://www.blogger.com/atom/ns#' term='topics'/><category scheme='http://www.blogger.com/atom/ns#' term='game'/><title type='text'>2D Arrays</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/SdFmWig6pxI/AAAAAAAAAC4/x4rDPCR7AoU/s1600-h/Array.gif"&gt;&lt;img id="BLOGGER_PHOTO_ID_5319145172309288722" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 223px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/SdFmWig6pxI/AAAAAAAAAC4/x4rDPCR7AoU/s320/Array.gif" border="0" /&gt;&lt;/a&gt;My Java college class is moving painfully slow. I have decided to read ahead to get to the topics I need for real work. The current chapter is on arrays. I have a game which is run on a two dimensional map. This is a perfect application to two dimensional arrays.&lt;br /&gt;&lt;br /&gt;So far my textbook has been concentrating on one dimensional arrays. There is not that much to them. It is only a little involved if you have an array of references to objects. You have to create the array. Then you have to create the objects themselves that are referenced by the array elements.&lt;br /&gt;&lt;br /&gt;The next chapter is called Two Dimensional Arrays. That should give me exactly what I need for the game. Right now I am using the actual graphics screen to store things in my game. That is very slow. It is also difficult to do anything complex with the displays. I need 2D arrays to get my business done.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-512502859147975184?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/512502859147975184/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/2d-arrays.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/512502859147975184'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/512502859147975184'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/2d-arrays.html' title='2D Arrays'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/SdFmWig6pxI/AAAAAAAAAC4/x4rDPCR7AoU/s72-c/Array.gif' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-5687359194644770259</id><published>2009-03-27T17:25:00.001-04:00</published><updated>2009-03-27T17:27:20.249-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='package'/><category scheme='http://www.blogger.com/atom/ns#' term='exercises'/><category scheme='http://www.blogger.com/atom/ns#' term='class'/><category scheme='http://www.blogger.com/atom/ns#' term='directory'/><category scheme='http://www.blogger.com/atom/ns#' term='compiler'/><title type='text'>Setting the CLASSPATH</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/_wOFRh11vB8g/Sc1EqPMyfUI/AAAAAAAAACw/TPtcFUvwRmo/s1600-h/Classpath.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5317982227419790658" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 226px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/Sc1EqPMyfUI/AAAAAAAAACw/TPtcFUvwRmo/s320/Classpath.jpg" border="0" /&gt;&lt;/a&gt;I continue to read ahead in my Java class textbook. Reading alone does not make the concepts sink in. So I try to do each and every exercise in the book. Today I had some free time at work. I decided to try one of the exercises from the section I was reading. The exercise instructed me to use a class that had a source listing in the book.&lt;br /&gt;&lt;br /&gt;My instructor provided me with the source code for the listings in the book. This helped so I did not need to type in the code. I compiled the class provided to me by the book. Then I coded up a simple second class in another file which made use of the class from the book. However the Java compiler complained that it did not know the other class name.&lt;br /&gt;&lt;br /&gt;This was very strange. I had already compiled the other class. Everything was in the same directory. I was at a loss. I tried to import the other class. That did not work. The other class was not in a package. I could have sworn that this worked before. If the other class is in the same directory you can use it.&lt;br /&gt;&lt;br /&gt;Then it dawned on my. I bet there was something wrong with the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;CLASSPATH&lt;/span&gt;. I checked out the system variables and found that the current directory (.) was not a part of the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;CLASSPATH&lt;/span&gt;. I quickly added it to the beginning of the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;CLASSPATH&lt;/span&gt;. Now this makes sense. Java won’t consider code in the current directory unless that directory is part of the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;CLASSPATH&lt;/span&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-5687359194644770259?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/5687359194644770259/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/setting-classpath.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5687359194644770259'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5687359194644770259'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/setting-classpath.html' title='Setting the CLASSPATH'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/Sc1EqPMyfUI/AAAAAAAAACw/TPtcFUvwRmo/s72-c/Classpath.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-6606045531183778357</id><published>2009-03-26T20:56:00.002-04:00</published><updated>2009-03-26T20:59:58.400-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='loop'/><category scheme='http://www.blogger.com/atom/ns#' term='output'/><category scheme='http://www.blogger.com/atom/ns#' term='question'/><category scheme='http://www.blogger.com/atom/ns#' term='for loop'/><category scheme='http://www.blogger.com/atom/ns#' term='test'/><category scheme='http://www.blogger.com/atom/ns#' term='answers'/><title type='text'>Trick Question</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/ScwkMb-BYxI/AAAAAAAAACo/nj0Oj9oFUcY/s1600-h/Trick.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5317665056102638354" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 317px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/ScwkMb-BYxI/AAAAAAAAACo/nj0Oj9oFUcY/s320/Trick.jpg" border="0" /&gt;&lt;/a&gt;Today at school we went over the answers of the test we took last time. There was one questions I got totally wrong. A couple people including myself grumbled that it was a trick question. The instructor said it came straight out of the book.&lt;br /&gt;&lt;br /&gt;Here is the question: What does the following code snippet output:&lt;br /&gt;&lt;br /&gt;int n=0;&lt;br /&gt;for (n=4; n &gt; 0; n--);&lt;br /&gt;{&lt;br /&gt;    System.out.println(n);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;Here is a hint. There is only one line in the output. At first I protested. Surely this code should have 4 lines of output. The loop iterates through four times after all.&lt;br /&gt;&lt;br /&gt;The trick was that there was a &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;semicolon&lt;/span&gt; directly after the for loop. Therefore the loop has a body which was empty. After the loop finished, n equals 0. Then the program executes one &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;println&lt;/span&gt; statement. Yeah. That's an evil question. Now I know better. Watch out for the tricks.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-6606045531183778357?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/6606045531183778357/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/trick-question.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6606045531183778357'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/6606045531183778357'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/trick-question.html' title='Trick Question'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/ScwkMb-BYxI/AAAAAAAAACo/nj0Oj9oFUcY/s72-c/Trick.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-8051367282779887066</id><published>2009-03-24T16:30:00.002-04:00</published><updated>2009-03-24T16:31:14.559-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='stock'/><category scheme='http://www.blogger.com/atom/ns#' term='mainframe'/><category scheme='http://www.blogger.com/atom/ns#' term='IBM'/><category scheme='http://www.blogger.com/atom/ns#' term='talks'/><category scheme='http://www.blogger.com/atom/ns#' term='TCK'/><category scheme='http://www.blogger.com/atom/ns#' term='UNIX servers'/><title type='text'>Sun Buyout</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/SclC991SlNI/AAAAAAAAACg/6CBG53LQbXU/s1600-h/IBM.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5316854467425113298" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 240px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/SclC991SlNI/AAAAAAAAACg/6CBG53LQbXU/s320/IBM.jpg" border="0" /&gt;&lt;/a&gt;There have been some big rumors about IBM buying Sun &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;Microsystems&lt;/span&gt;. This has resulted in Sun’s stock rocketing up 80%. Officially IBM and Sun are in talks. Word on the street is that IBM is talking about a $10 per share buyout of Sun. Since Sun is the inventor of the Java Programming Language, I wonder what effects this transaction might have on the world of Java.&lt;br /&gt;&lt;br /&gt;IBM already owns the mainframe computer business. Obtaining Sun would give it a majority of the UNIX server market. That is what most people are focusing on. This is being described as a merger of two hardware companies.&lt;br /&gt;&lt;br /&gt;Java has already been released as open source. However Sun keeps a watchful eye over the technology. For example, there are still some issues of Sun licensing Java for other implementations of the Java environment.&lt;br /&gt;&lt;br /&gt;Sun provides the Technology Compatibility Kit (&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;TCK&lt;/span&gt;). It verifies whether something is compliant to the Java specification. Currently there seems to be some controversy over Sun’s management of the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;TCK&lt;/span&gt;. With an IBM purchase, these reins may be loosened.&lt;br /&gt;&lt;br /&gt;These are two large companies. So it might take a long time for a merger to complete and actually have an effect on anything. Still I wonder what kind of world it would be like if it turned into IBM Java. It might be time to call up some of my Java developer buddies to gauge their opinion.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-8051367282779887066?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/8051367282779887066/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/sun-buyout.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8051367282779887066'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8051367282779887066'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/sun-buyout.html' title='Sun Buyout'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/SclC991SlNI/AAAAAAAAACg/6CBG53LQbXU/s72-c/IBM.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-8151032956228036623</id><published>2009-03-23T21:42:00.002-04:00</published><updated>2009-03-23T21:42:55.420-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='UMLet'/><category scheme='http://www.blogger.com/atom/ns#' term='UML diagram'/><category scheme='http://www.blogger.com/atom/ns#' term='Eclipse'/><category scheme='http://www.blogger.com/atom/ns#' term='Rational Rose'/><category scheme='http://www.blogger.com/atom/ns#' term='Visual Studio'/><category scheme='http://www.blogger.com/atom/ns#' term='Word'/><title type='text'>UMLet</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/_wOFRh11vB8g/Scg6i8bpb0I/AAAAAAAAACY/Im8wPM75kcI/s1600-h/UMLet.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5316563732122922818" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 155px; CURSOR: hand; HEIGHT: 114px" alt="" src="http://3.bp.blogspot.com/_wOFRh11vB8g/Scg6i8bpb0I/AAAAAAAAACY/Im8wPM75kcI/s320/UMLet.jpg" border="0" /&gt;&lt;/a&gt;I had an assignment from class to include a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;UML&lt;/span&gt; diagram. This was supposed to be pasted into a Microsoft Word file. Now I did not want to scribble a diagram on a piece of paper and scan it in. I also did not want to try to draw the diagram using Microsoft Word drawing tools. The best technique would be to use a tool that knew that &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;UML&lt;/span&gt; was I thought.&lt;br /&gt;&lt;br /&gt;So I looked around in Eclipse. I could not figure out how to generate a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;UML&lt;/span&gt; diagram. Now I know this is a tool for writing code. However I thought it would have such a tool. Then I checked out the latest Visual Studio that I had. This was the professional edition. But even this tool did not seem to be able to knock out a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;UML&lt;/span&gt; diagram.&lt;br /&gt;&lt;br /&gt;Normally I use Rational Rose to bust out &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;UML&lt;/span&gt; diagrams. But I did not have access to my computer which has Rational rose installed. I did not feel like searching for a free Rational Rose install as I figured it would be huge.&lt;br /&gt;&lt;br /&gt;It was time to Google the web to see what tools were out there. My goal was to find something easy and free. One of the first hits I found was &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;UMLet&lt;/span&gt;. Here are some hints on using it. You select an item on the left pane. Then the bottom right hand corner is the free form text that is drawn with that item.&lt;br /&gt;&lt;br /&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_6"&gt;UMLet&lt;/span&gt; turned out to be just the thing I was looking for. Later I was happy that I decided against using a graphics tool to draw the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_7"&gt;UML&lt;/span&gt; diagram. I had to add some more items to my class. Then I needed to update my diagram based on error I found. This was trivial with the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_8"&gt;UMLet&lt;/span&gt; tool. A big thank you goes out to the authors of this software. You helped me get an A on this assignment.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-8151032956228036623?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/8151032956228036623/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/umlet.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8151032956228036623'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8151032956228036623'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/umlet.html' title='UMLet'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/Scg6i8bpb0I/AAAAAAAAACY/Im8wPM75kcI/s72-c/UMLet.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-8063756793061333199</id><published>2009-03-20T22:34:00.001-04:00</published><updated>2009-03-20T22:35:46.087-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='mutators'/><category scheme='http://www.blogger.com/atom/ns#' term='classes'/><category scheme='http://www.blogger.com/atom/ns#' term='instance variables'/><category scheme='http://www.blogger.com/atom/ns#' term='formal parameters'/><category scheme='http://www.blogger.com/atom/ns#' term='this'/><title type='text'>Name Clash</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/ScRSXihIVFI/AAAAAAAAACQ/a6hZTeIRsoo/s1600-h/Name.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5315464024560260178" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/ScRSXihIVFI/AAAAAAAAACQ/a6hZTeIRsoo/s320/Name.jpg" border="0" /&gt;&lt;/a&gt;In my Java programming college class, we are learning more and more about classes. Specifically we are learning about access modifiers for instance variables and methods. One thing that is pretty clear is that if you have an instance variable in a class, and the variable name is &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;myVar&lt;/span&gt;, then you cannot have another instance variable in the same class with the same variable name.&lt;br /&gt;&lt;br /&gt;Within the class, you can reference an instance variable with just its name. You can optionally &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;prepend&lt;/span&gt; the variable name with the keyword “this”. However in this scenario, “this” which represents the current object is already implied. So for most if not all of the time, the “this” keyword is omitted.&lt;br /&gt;&lt;br /&gt;We are also learning about &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;accessors&lt;/span&gt; and &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;mutators&lt;/span&gt; in our programming class. &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;Mutators&lt;/span&gt;, or setters, take an argument and set the instance variable to the value of that argument. Here is where some confusion in class came up. Support we have an instance variable in our class named “email”. What should we name the formal parameter of the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;setEmail&lt;/span&gt; method?&lt;br /&gt;&lt;br /&gt;Most of the time, the simplest and most obvious variable name is the best one. So I thought I would name the formal argument to the &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_6"&gt;mutator&lt;/span&gt; &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_7"&gt;setEmail&lt;/span&gt; to be just “email”. But here is the problem and question. Does the local variable email, which is the formal parameter to the method in the class, clash with the instance variable of the same name?&lt;br /&gt;&lt;br /&gt;The best way to answer questions like this is to try it out. It compile fine. So it must be &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_8"&gt;ok&lt;/span&gt;. The only tricky part comes when you must set the instance variable to the formal parameter passed into the method. How do you do that if they are named the same? The trick is to qualify the instance variable with the “this” keyword. Then you get code that looks like this (no pun intended):&lt;br /&gt;&lt;br /&gt;public void &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_9"&gt;setEmail&lt;/span&gt;(String email)&lt;br /&gt;{&lt;br /&gt;            this.email = email;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;Now this may not be the best practice, as there might be some ambiguity as to which variable the name email refers to. So our instructor insisted that we name the formal parameter &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_10"&gt;newEmail&lt;/span&gt;, or something else distinct from the instance variable name. That sounds logical. It was still cool to find out you could have two variables of the same name within the class.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-8063756793061333199?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/8063756793061333199/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/name-clash.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8063756793061333199'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8063756793061333199'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/name-clash.html' title='Name Clash'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/ScRSXihIVFI/AAAAAAAAACQ/a6hZTeIRsoo/s72-c/Name.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-3860137232839866413</id><published>2009-03-18T20:17:00.001-04:00</published><updated>2009-03-18T20:18:45.997-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='program'/><category scheme='http://www.blogger.com/atom/ns#' term='Java'/><category scheme='http://www.blogger.com/atom/ns#' term='class'/><category scheme='http://www.blogger.com/atom/ns#' term='runtime'/><category scheme='http://www.blogger.com/atom/ns#' term='JRE'/><category scheme='http://www.blogger.com/atom/ns#' term='Windows'/><category scheme='http://www.blogger.com/atom/ns#' term='source'/><title type='text'>Software Distribution</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/ScGPQz5SeiI/AAAAAAAAACI/vlHf9F8tYJk/s1600-h/Distribution.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5314686554245069346" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 247px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/ScGPQz5SeiI/AAAAAAAAACI/vlHf9F8tYJk/s320/Distribution.jpg" border="0" /&gt;&lt;/a&gt;I coded up a cool quiz program on Oracle PL/&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;SQL&lt;/span&gt; questions. It was aimed at helping me study for an Oracle certification exam. Now I wanted to release this program to other people to use. I did not want to just send out some Java source code. From what I gather, you can ship the Java class files. However this requires a certain version of the Java &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_1"&gt;run time&lt;/span&gt;,&lt;br /&gt;&lt;br /&gt;How do commercial shops roll out their software? Do they include the class files with an install that checks and optionally installs the Java &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_2"&gt;Run time&lt;/span&gt; Environment? I come from a C++ Windows background. So my instinct is to somehow turn this thing into a self contained executable file that I distribute. However it seems this is not the Java way to go.&lt;br /&gt;&lt;br /&gt;Maybe there are not that many users who code and ship Java applications. Or maybe there are not many desktop applications that are developed and shipped like this. It is easier if the program only needs to run on the server. In that case, you can ensure the correct version of the Java &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_3"&gt;run time&lt;/span&gt; is installed there. You can also deploy just the class files to the correct locations. Users can then just access the program through web pages viewed in their browser.&lt;br /&gt;&lt;br /&gt;Development in the Java world appears to be a new paradigm. I am not sure if I like it. But first I need to get with the program as far as software deliveries go. After I have tried it for a while, I may have a better perspective if it works, and whether it is a good way to go for development and delivery.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-3860137232839866413?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/3860137232839866413/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/software-distribution.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3860137232839866413'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/3860137232839866413'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/software-distribution.html' title='Software Distribution'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/ScGPQz5SeiI/AAAAAAAAACI/vlHf9F8tYJk/s72-c/Distribution.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-8810004115440925549</id><published>2009-03-17T00:27:00.002-04:00</published><updated>2009-03-17T00:32:26.571-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='monsters'/><category scheme='http://www.blogger.com/atom/ns#' term='challenge'/><category scheme='http://www.blogger.com/atom/ns#' term='class'/><category scheme='http://www.blogger.com/atom/ns#' term='main'/><category scheme='http://www.blogger.com/atom/ns#' term='game'/><title type='text'>Game Success</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_wOFRh11vB8g/Sb8m4Fout5I/AAAAAAAAACA/SsIgtC_BgUQ/s1600-h/dL1.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5314008830348015506" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 247px; CURSOR: hand; HEIGHT: 213px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/Sb8m4Fout5I/AAAAAAAAACA/SsIgtC_BgUQ/s320/dL1.JPG" border="0" /&gt;&lt;/a&gt;Good news. I successfully created a simple Java game within 7 days. This was in response to a challenge posted on a Usenet news group. You can find a link to the program on the &lt;a href="http://legend-angband.blogspot.com/2009/03/roguelike-challenge-completed.html"&gt;Legend of &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;Angband&lt;/span&gt;&lt;/a&gt; web site.&lt;br /&gt;&lt;br /&gt;The emphasis on my development for this game was to knock out something quick. As a result, I only had two classes. There was the driver program which had my main() method. And then there was a Monster class housed in its own file.&lt;br /&gt;&lt;br /&gt;This was a Dungeons and Dragons style two dimensional game. There was no rocket science here. I drew a maze. Then I put some gold in that maze. And I added some monsters. The monsters fight you when you attack them. They follow you if you try to flee. Yeah it does not sound like much. I am still a Java novice and it has been a busy week. Download it and give it a try already.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-8810004115440925549?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/8810004115440925549/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/game-success.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8810004115440925549'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/8810004115440925549'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/game-success.html' title='Game Success'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/Sb8m4Fout5I/AAAAAAAAACA/SsIgtC_BgUQ/s72-c/dL1.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-5875460009665426148</id><published>2009-03-09T23:04:00.003-04:00</published><updated>2009-03-09T23:08:32.048-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='program'/><category scheme='http://www.blogger.com/atom/ns#' term='static'/><category scheme='http://www.blogger.com/atom/ns#' term='class'/><category scheme='http://www.blogger.com/atom/ns#' term='OOP'/><category scheme='http://www.blogger.com/atom/ns#' term='main'/><category scheme='http://www.blogger.com/atom/ns#' term='functions'/><title type='text'>Once You Go Static...</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5311389791023445874" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/SbXY372Wt3I/AAAAAAAAAB4/XuLy1eIJiQo/s320/Static.jpg" border="0" /&gt;I am on a 7 Day Quest to write a game in Java. That's a tall order since I am only half way through a college Java class. But I am learning a lot.&lt;br /&gt;&lt;br /&gt;For example, I am trying to conserve time due to the quick deadline. Therefore I am putting all my code in one class. This class has a static main function to run the program. Guess what? That function can only call other static functions in this class. That's not too object oriented.&lt;br /&gt;&lt;br /&gt;Well perhaps the &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;optimistic&lt;/span&gt; way of looking at this is that I have an object. But it is the only one of its kind. There is only one main. So the class with that has main must be a singleton. I am keeping some data in static variables. And I am breaking up functionality into static methods. But it still feels a little clunky.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-5875460009665426148?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/5875460009665426148/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/once-you-go-static.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5875460009665426148'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5875460009665426148'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/once-you-go-static.html' title='Once You Go Static...'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/SbXY372Wt3I/AAAAAAAAAB4/XuLy1eIJiQo/s72-c/Static.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-795211428864114414</id><published>2009-03-09T17:13:00.004-04:00</published><updated>2009-03-09T17:20:45.323-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='libjcsi'/><category scheme='http://www.blogger.com/atom/ns#' term='keyboard'/><category scheme='http://www.blogger.com/atom/ns#' term='output'/><category scheme='http://www.blogger.com/atom/ns#' term='graphics'/><category scheme='http://www.blogger.com/atom/ns#' term='console'/><title type='text'>Libjcsi to the Rescue</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5311299332164065826" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 100px" alt="" src="http://2.bp.blogspot.com/_wOFRh11vB8g/SbWGmiVomiI/AAAAAAAAABw/V4iLmAPsleA/s320/Libjcsi.png" border="0" /&gt;I have previously written about my recent exploits in the game development field. To make sure I gain Java programming skills during this &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;exercise&lt;/span&gt;, I am writing the whole game in Java. So far I tried rolling my own graphics drawing code. That turned out to be difficult. Some output looked &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;ok&lt;/span&gt;. Other graphics were slightly off. This was painful.&lt;br /&gt;&lt;br /&gt;Another developer recommended that I use their graphics package &lt;a href="http://slashie.net/libjcsi/"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;libjcsi&lt;/span&gt;&lt;/a&gt;. This package covers simplifies console output for you. I tried compiling their sample program. In 10 minutes I had a graphical user interface up and running. In an hour I had a bare bones screen of my game going. I was pleasantly surprised that this package also handled keyboard input. So I quickly coded up user input to control the direction of the main character. I now got a guy running around my simple screen. Life is good.&lt;br /&gt;&lt;br /&gt;Next I think I will try to place objects on the screen that represent gold. Then if the user walks over top the gold, I want to register that the user picked the gold up. These all seem like baby steps. But once I get the basics down, I can rocket into more complex ideas I have about my game. I will say that I still do not have the hang of Java packages. &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_3"&gt;Perhaps&lt;/span&gt; by the time I complete my game, I will have them nailed down.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-795211428864114414?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/795211428864114414/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/libjcsi-to-rescue.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/795211428864114414'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/795211428864114414'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/libjcsi-to-rescue.html' title='Libjcsi to the Rescue'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wOFRh11vB8g/SbWGmiVomiI/AAAAAAAAABw/V4iLmAPsleA/s72-c/Libjcsi.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7003790485043965031</id><published>2009-03-08T23:56:00.003-04:00</published><updated>2009-03-09T00:01:26.877-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Curses'/><category scheme='http://www.blogger.com/atom/ns#' term='exception'/><category scheme='http://www.blogger.com/atom/ns#' term='JCurses'/><category scheme='http://www.blogger.com/atom/ns#' term='grid'/><category scheme='http://www.blogger.com/atom/ns#' term='user interface'/><title type='text'>Screen Output</title><content type='html'>&lt;a href="http://1.bp.blogspot.com/_wOFRh11vB8g/SbSTh9pHQ2I/AAAAAAAAABo/orNr69WTuO0/s1600-h/Curses.jpg"&gt;&lt;img id="BLOGGER_PHOTO_ID_5311032072268628834" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 222px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/SbSTh9pHQ2I/AAAAAAAAABo/orNr69WTuO0/s320/Curses.jpg" border="0" /&gt;&lt;/a&gt;I am writing a game in Java called &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;dL&lt;/span&gt;1. And I need to display a two dimensional grid for the user interface. After Googling the subject, I thought I would try to use the Curses library to do the output. There is a &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;JCurses&lt;/span&gt; package for Java which seemed easy.&lt;br /&gt;&lt;br /&gt;After I got into &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;JCurses&lt;/span&gt;, it took a while to get the test code from the package compiled. However I could never get the test to run without aborting with an exception. I only have 7 days to complete my game for a programming contest. So I decided to roll my own graphics code.&lt;br /&gt;&lt;br /&gt;This is a monumental task. However I already have an applet which is displaying some text. Now I need to get my vertical and horizontal positioning down. And I also need to learn how to erase graphics on my screen. But at least I have something to show for it. You can see a screen shot of my first try on my &lt;a href="http://legend-angband.blogspot.com/2009/03/dl1-screen-shot.html"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;Angband&lt;/span&gt;&lt;/a&gt; blog page.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7003790485043965031?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7003790485043965031/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/screen-output.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7003790485043965031'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7003790485043965031'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/screen-output.html' title='Screen Output'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/SbSTh9pHQ2I/AAAAAAAAABo/orNr69WTuO0/s72-c/Curses.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-7023006782991042769</id><published>2009-03-08T21:20:00.003-04:00</published><updated>2009-03-08T21:25:29.318-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='packages'/><category scheme='http://www.blogger.com/atom/ns#' term='class'/><category scheme='http://www.blogger.com/atom/ns#' term='3rd party'/><category scheme='http://www.blogger.com/atom/ns#' term='I/O'/><category scheme='http://www.blogger.com/atom/ns#' term='arrays'/><title type='text'>Missing Arrays</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5310991865924864034" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 229px" alt="" src="http://1.bp.blogspot.com/_wOFRh11vB8g/SbRu9pVwyCI/AAAAAAAAABg/zGVZPgR9guQ/s320/Array.jpg" border="0" /&gt;I am halfway through my college class on Java. There are a number of topics we have not covered yet. Normally that is fine, as we will eventually get to them. However I just entered a programming contest to write a Java game in 7 days. My game will be called &lt;a href="http://legend-angband.blogspot.com/2009/03/challenge-accepted.html"&gt;&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;dL&lt;/span&gt;1&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;We have yet to cover packages, arrays, or file input/output. That is a bummer. My game will be on a two dimensional grid. That's where arrays would really come in handy. My plan is to &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_1"&gt;substitute&lt;/span&gt; objects that references each other for arrays.&lt;br /&gt;&lt;br /&gt;I was hoping to use some third party code to do the actual drawing for my game. So I cannot wait any more. I am reading ahead in my course book to see how to use packages. As of last night, I still had not mastered the topic. I really need to get a move on it. The contest ends in 7 days and I have one Java file which does not compile. May the Force be with me.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-7023006782991042769?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/7023006782991042769/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/missing-arrays.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7023006782991042769'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/7023006782991042769'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/missing-arrays.html' title='Missing Arrays'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_wOFRh11vB8g/SbRu9pVwyCI/AAAAAAAAABg/zGVZPgR9guQ/s72-c/Array.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-2901140590711360146</id><published>2009-03-07T00:26:00.002-05:00</published><updated>2009-03-07T00:34:11.610-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='managed'/><category scheme='http://www.blogger.com/atom/ns#' term='scope'/><category scheme='http://www.blogger.com/atom/ns#' term='automation'/><category scheme='http://www.blogger.com/atom/ns#' term='testing'/><category scheme='http://www.blogger.com/atom/ns#' term='memory'/><title type='text'>Garbage Collection</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5310313006165688898" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 234px" alt="" src="http://4.bp.blogspot.com/_wOFRh11vB8g/SbIFizqkgkI/AAAAAAAAABY/N6ZbxtPWOq0/s320/Garbage.jpg" border="0" /&gt;I read the magazine Software Test and Performance. This is because formal testing plays a large role in the project I work on. The development team does unit testing. An internal team does integration, functional, and regression testing. A customer team conducts software acceptance testing. I need to keep up with the world of testing.&lt;br /&gt;&lt;br /&gt;A recent article in the magazine talked about the Java environment. Specifically they referred to it as managed. To me that sounds like &lt;a href="http://micro-soft-dot-net.blogspot.com/"&gt;Dot Net&lt;/a&gt;. They were referring to Garbage Collection. And they thought that it was a danger.&lt;br /&gt;&lt;br /&gt;Yes the garbage collector looks after memory in the Java environment. However Java programmers just assume the garbage collector will do its job. Objects which go out of scope are supposed to be cleaned up. However if the garbage collector does not know about an object, or can't determine that we are done with it, the memory will remain unclaimed.&lt;br /&gt;&lt;br /&gt;Some industry experts were consulted. One of them said that inefficient code leads to memory problems, even in Java. The recommendation was to be proactive in testing Java applications. The use of automation in testing was also suggested. It was stressed that any Test Driven Development cover all paths in the software.&lt;br /&gt;&lt;br /&gt;Here I thought the garbage collection idea was a nice one. I come from the land of C and C++. It is a lot of work to manually &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_0"&gt;control&lt;/span&gt; the allocation and freeing of memory. Java is actually a fresh perspective on memory &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_1"&gt;reallocation&lt;/span&gt;. But with most things, you can get in trouble if something or someone other than you takes care of the hard tasks. I have learned that by dealing with frameworks for a number of years.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-2901140590711360146?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/2901140590711360146/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/garbage-collection.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2901140590711360146'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/2901140590711360146'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/garbage-collection.html' title='Garbage Collection'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_wOFRh11vB8g/SbIFizqkgkI/AAAAAAAAABY/N6ZbxtPWOq0/s72-c/Garbage.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-174910063051315281.post-5421905351520779282</id><published>2009-03-06T15:27:00.003-05:00</published><updated>2009-03-06T15:32:22.262-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='mobile phones'/><category scheme='http://www.blogger.com/atom/ns#' term='applet'/><category scheme='http://www.blogger.com/atom/ns#' term='RIA'/><category scheme='http://www.blogger.com/atom/ns#' term='Java ME'/><category scheme='http://www.blogger.com/atom/ns#' term='SDK'/><title type='text'>Java FX Mobile</title><content type='html'>&lt;img id="BLOGGER_PHOTO_ID_5310174213856295106" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; WIDTH: 320px; CURSOR: hand; HEIGHT: 320px" alt="" src="http://3.bp.blogspot.com/_wOFRh11vB8g/SbGHUCBX-MI/AAAAAAAAABQ/iAHi3nuEkTw/s320/FX.png" border="0" /&gt;Sun &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;Microsystems&lt;/span&gt; has released Java &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;FX&lt;/span&gt; Mobile. It is for development of Rich Internet Applications (&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_2"&gt;RIAs&lt;/span&gt;). Java &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;FX&lt;/span&gt; Mobile is based on Java Micro Edition (Java ME). As you would expect, it is similar to the desktop version of Java &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;FX&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Java &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;FX&lt;/span&gt; Mobile can run as an applet in a browser, on the desktop, or on a mobile phone. You know it is going to be targeted to mobile phones. However the beauty of it is that it also works elsewhere.&lt;br /&gt;&lt;br /&gt;Java &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_6"&gt;FX&lt;/span&gt; itself comes with a lot of default behavior built in. That means it should be easy for developers to produce applications which immediately fall back to defaults which work well. This is unlike plain Java, where you need to roll a lot of your own code from scratch.&lt;br /&gt;&lt;br /&gt;There is a Java &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_7"&gt;FX&lt;/span&gt; software development kit (&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_8"&gt;SDK&lt;/span&gt;)  available. I know that as soon as I get a handle on Java basics, I am going to want to be trying different frameworks and &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_9"&gt;APIs&lt;/span&gt; in the Java world. Perhaps I may take Java &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_10"&gt;FX&lt;/span&gt; Mobile for a spin.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/174910063051315281-5421905351520779282?l=enableassertions.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://enableassertions.blogspot.com/feeds/5421905351520779282/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://enableassertions.blogspot.com/2009/03/java-fx-mobile.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5421905351520779282'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/174910063051315281/posts/default/5421905351520779282'/><link rel='alternate' type='text/html' href='http://enableassertions.blogspot.com/2009/03/java-fx-mobile.html' title='Java FX Mobile'/><author><name>Mister Bah</name><uri>http://www.blogger.com/profile/11735506939987403506</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='23' src='http://4.bp.blogspot.com/_wOFRh11vB8g/SZ8p7HJS7rI/AAAAAAAAAAg/e6OGVuGkAwM/S220/BAH.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_wOFRh11vB8g/SbGHUCBX-MI/AAAAAAAAABQ/iAHi3nuEkTw/s72-c/FX.png' height='72' width='72'/><thr:total>0</thr:total></entry></feed>
