Vicente de Rivera Iii

+ Follow
since Apr 23, 2009
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Vicente de Rivera Iii

thanks. this inspired me since I am fairly new to EJB as well. This also validates my direction on starting with EJB3 in Action.
Thanks a lot!
corrected Bates to Sierra

Greg Charles wrote:Yes, NumberFormatException is the exception that would be thrown, but IllegalArgumentException is its superclass, so catching that would also do the job. The word "appropriate" is somewhat subjective, but I'd argue both are appropriate here, though I might waffle a bit if catching Throwable would also be. From what I remember about SCJP though, it's not trying to trick you with fine points about programing style.

Note: it's Kathy Sierra. Kathy Bates is the one who bashed in James Caan's knees in Misery

From SCJP 6 study guide (kathy Sierra) cert book,

Chap 5#3


try { int x = Integer.parseInt("two"); }

Which could be used to create an appropriate catch block? (Choose all that apply.)
A. ClassCastException
B. IllegalStateException
C. NumberFormatException
D. IllegalArgumentException

The book's answer is C & D w/c I see is a legal catch.

My answer was C, I thought catching the most specific is appropriate. Am I wrong?

Thanks in advance! First time post here, I'll be taking the exam SCJP6 Next week
Making it synchronized won't hurt much right?

I just read this article,

I guess for simple apps, handling exceptions in one place is good. But for business apps, exceptions might be needed by the caller.
Any comment on this?

And any other great articles like these? Prior to reading these articles, I didn't even really consider writing my own Exceptions.
Or a book that guides you on developing a real-world Java app with with good practices such as designing your own Exceptions?
10 years ago

I've just read this article,
and it suggests that exceptions should be handled in one place.

My question is that, is handleException method be synchronized? Like in a Swing app where there a separate threads that do I/O.

10 years ago
Hi, I'm a novice Java programmer, since I did a lot of Swing apps, Wicket was the framework for me to use in our project just last semester then JDBC+a very helpful pattern from developer works.

For the defense, as usual, our professors was almost demanding that every thing should be unique, bank cheque stuffs and whole lots of other stuff. Problem is they didn't actually thought us how to develop a commercial-grade web app. They've just thought us SELECT statements and VB6!

Next sem, it will be having 'Web Technolgies' subject. This time I'd really want to make a professionally made application. Are there any books that focus on a real-world web application, guide in making a professional Java web app? Most books only provide a sample 'cheese store application' or some 'application that has a shopping cart' (but I'm not critizing them! definitely got no right to ).

I plan to use (learn first) hibernate this time and all those DAO that I've been seeing a lot lately.
11 years ago

Really cool (at least for the vids I've just watched). I've just finished a simple sample CRUD in Grails, great and easy. Since Grails is the talk of the town, I feel more biased with Grails. But Aribaweb is just awesome!

Anybody used aribaweb here? what do you say?
11 years ago
I googled for that error/warning, so I got here. Mine was more obvious, instead of

it should be

thanks for this post