Owner: Little Tutorials URL:http://www.littletutorials.com Join Date: Tue, 13 May 2008 22:53:36 -0500 Rating:0 Site Description: Programming opinions and tutorials mainly about Java language and technologies. Code samples that work. Site statistics:Click here
Script Thy Java App 2008-05-10 16:05:04 Let’s imagine a very simple scenario. You are writing an application which would benefit from some user specific customization after deployment. Maybe some of your customers have specific algorithms to be executed in the context of your application. Maybe your application doesn’t solve just one problem but it is designed to solve a class of [...]
Exceptional Java - Checked exceptions are priceless… For everything else there is the RuntimeException 2008-05-06 11:34:57 The fact that I find flaws in the design of the Java exceptions class hierarchy doesn’t mean I think there is no value in the whole system. Checked exceptions have a positive impact in development. The positive comes from the proactive nature of checked exceptions. They demand attention! And I think this is as much [...] Read more:Exceptional
Exceptional Java - Less than perfect exceptions hierarchy 2008-05-05 14:17:25 As I said before, I am a supporter of checked exceptions in Java. I think they are a great idea that supports serious software development in the real world. I also think Java’s huge success can be attributed in part to checked exceptions. But this doesn’t mean I like everything about how the Java’s exception [...] Read more:Exceptional
Exceptional Java - Some exceptions are more equal than others 2008-05-01 12:56:33 Is there something wrong with Java exceptions? Does Java need a fundamental change in this area? Is the proposal to make all exceptions in Java runtime exceptions a solution to a real problem? What if this proposal is the solution to the wrong problem?
While reading about this conflict I started to ask myself questions like [...] Read more:Exceptional
Stop! Show me your build number! 2008-04-29 00:44:08 Every project that aspires to glory has some kind of regular build process that takes the code out of the code repositories (CVS and the like), compiles it and, hopefully, goes as far as possible towards creating a deliverable entity like an installation kit. In the rest of the post I will assume an installation [...]
Exceptional Java - Thoughts on Java exceptions 2008-04-27 04:23:01 Dealing with exceptions is hard. For a while now in the Java world there are two camps. One considers the initial design of the Java exceptions system a sensible one, a feature that contributed greatly to Java’s success. A new camp has also formed in Java world and this new camp considers the original design [...] Read more:Exceptional
More desktop integration: the system tray 2008-04-24 09:35:00 One more nice touch in the Java 6 offensive to the desktop is giving Java applications the ability to add icons to the system tray in a pretty consistent way across platforms. Of course differences exist and they will show up to some degree in the code but at least now the framework exists and [...] Read more:integration
Desktop integration with Java 6 2008-03-30 00:59:40 Java 6 tries hard to make Java applications easier to integrate in the desktop environment of various platforms. One of such welcome attempts is the new java.awt.Desktop
class adapted from JDIC (JDesktop Integration Components). This API allows access to this functionality:
Start the host’s default web browser and load a specified URI
Start the default email client [...] Read more:integration
Locating resources in Java 2008-03-26 22:33:10 A resource is a file situated somewhere in the class path. It can be a file in a package folder, in the classes folder or in a jar file. Resources are usually needed at runtime and they can be properties files, images and so on. The ClassLoader and Class classes provide methods to find the [...]
Logging garbage collector activity 2008-03-23 18:16:22 An easy low cost method to check the activity of the garbage collector in the JVM is to tell the JVM to create an activity log. This is achieved for Sun JVMs using the non-standard command line option “-Xloggc:file_name“. This will tell the JVM to create a log file with a content similar with this:
0.806: [...]
13 reasons for UML’s descent into darkness 2008-05-15 16:51:46 UML lost the programmers. There is no doubt about it… in my mind. And when a software design technology loses the programmers it fades away no matter what the academia thinks. This happened because UML was pushed in a direction that most code writers don’t like: it started to look a lot like bureaucratic paper [...]
Exceptional Java - Design the failure case - Part 2 2008-05-22 10:39:25 While developing complex systems lots of failure
situations require handling and without proper planning chaos can conquer your code.
A number of simple principles can create order and reduce complexity. And the result can be real software quality.
Read the first part of this post…
Design with exceptions
When designing exception handling there are two kinds of situations. Utility [...] Read more:Exceptional
Exceptional Java - Design the failure case - Part 1 2008-05-21 20:59:42 Good exception handling doesn’t happen by chance. It is designed and planned and when done properly it is one of the main roads to the software “Holy Grail” - quality and reliability.
But leave it to chance and soon all hell breaks loose.
Exceptions are a fact of life
Any non trivial application will encounter error conditions. It [...] Read more:Exceptional
, failure
Exceptional Java - Exception design relativity 2008-05-23 12:44:04 Designing the error path in the code is not the most entertaining part of a programmer’s job. We are focused on coding the solution, the success path, and the damn exceptions stand in the way pretending to be handled. What makes it even harder and murkier is the lack of well established rules for what [...] Read more:Exceptional
, design
13 reasons why Ruby, Python and the gang will push Java to die… of old age 2008-05-28 01:50:00 Lately I seem to find everywhere lots of articles about the imminent dismissal of Java and its replacement with the scripting language of the day or sometimes with other compiled languages.
No, that is not gonna happen. Java is gonna die eventually of old age many many years from now.
I will share the reasoning behind my [...] Read more:Python
Script Your Scala Application with JRuby, Jython, Groovy and JavaScript 2008-06-12 19:36:48 This tutorial shows how you can script a Scala
application using the Java 6 scripting engines features (JSR 223 Scripting APIs). It also proves the level of power Scala gets from running on the JVM and from being able to use Java APIs. Along with a syntax that tries hard not to alienate Java and [...] Read more:Application
, Groovy
, JavaScript
The Creators of 30 Programming Languages: pages, biographies, blogs, interviews 2008-06-15 19:54:53 Behind any programming language there is a creator or sometimes a small team. Each language has a story and a philosophy and each creator had a motivation, a problem to solve.
Programming
languages influence and sometimes determine the way programmers solve problems and the way problems can be solved. They gain supporters, make enemies and cause [...] Read more:Languages
The Agile 800 Pounds Gorilla 2008-06-24 06:43:20 I woke up this morning and I was Agile
. We are all Agile now. Or we are gonna become Agile. Soon. No doubt about it. It is an order. And orders are not to be discussed, just executed.
The Enterprise goes Agile! With the elegance of the huge battleship being pulled across a desert between oceans [...] Read more:Pounds
, Gorilla
No, inheritance is not the way to achieve code reuse! 2008-06-23 10:34:32 Every once in a while I interview a new computer science graduate for a developer position. I prefer to ask the kind of questions that will let me see how they think about programming, if they think for themselves and if they are passionate about it.
Usually when I get to object oriented programming and I [...]
36 steps to success as technical lead 2008-07-07 11:14:48 The “tech lead” role can be treacherous at times. While the name implies “leadership“, most of the times it doesn’t come with implied authority like a manager role for example. It often happens that this role is in a no-man’s-land where it brings a lot of responsibility but not enough formal authority. In order to [...] Read more:steps
Code review - The meaningless ritual 2008-07-19 18:34:58 Most of the time code review
s are a meaningless
ritual. Everybody pays lip service to the importance of code reviews and a lot of people, especially in the management, are convinced that code reviews very effectively reduce the number of shipped bugs.
The problem is… most developers hate code reviews and avoid them like the plague. [...]
StringBuffer vs. StringBuilder performance comparison 2008-07-16 10:18:17 Even if the StringBuilder was around for a while now, many people still use StringBuffer in single threaded applications. The main difference is stated in the StringBuffer comments:
“As of release JDK 5, this class has been supplemented with an equivalent class designed for use by a single thread, {StringBuilder}. The StringBuilder class should generally [...] Read more:comparison
The 10 minutes “Getting started with RMI” tutorial 2008-07-14 15:35:49 Since Java 5 working with RMI (Remote Method Invocation) is very easy. You don’t need the rmic compiler unless you work with legacy RMI clients. Now stubs are generated automatically at runtime. Let’s see a very minimalistic example.
Our scenario will have a server sharing an object via RMI and a client calling the shared instance.
First [...] Read more:minutes