Java

When to use checked exceptions and when not to

Tagged:

I guess there would be three groups of Java developers out there - those who know about exceptions but have never heard of checked and unchecked exceptions, those who know what it is but do not understand them and those who truly know and understand them. My educated guess is that most people fall in the former two categories. This article will try and explain the differences between the two kinds of exceptions, as well as when to use which.

Validating user input

Tagged:

When should you perform input validation, and how thorough should you be? This is a question many developers are struggling with.

When to return null and when to throw an Exception?

Tagged:

I am pretty sure once you transcend the youth phase of software development, and you start thinking about what you are actually doing whilst writing code, you'll start running into tough decisions such as when to throw an exception, and when to return null.

DOM vs SAX

Tagged:

I always knew DOM and XPath were not as fast as SAX, but I have never realized exactly how slow they are when applied to a huge XML document.