This week's giveaway is in the Testing forum.
We're giving away four copies of TDD for a Shopping Website LiveProject and have Steven Solomon on-line!
See this thread for details.
Win a copy of TDD for a Shopping Website LiveProject this week in the Testing forum!

Tonguc Koc

+ Follow
since Sep 17, 2012
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 Tonguc Koc

Ok finally I settled down the discussion. Oracle Turkey web-site doesn't support credit card option so we need to go with cash option. The sent me a form to fill out. (I'll upload it when I go home)

I was informed that local taxes should be added to the price on the web shown in Turkey web site, which makes around 500TL(~230$). Hence the price is close to US and cheaper than VUE option.
Ok, good to know that one voucher bought from one country cannot be used in another one. This might have caused some headaches later on.

I'm still in communication with customer service of both Turkey and US, insisting on buying a voucher from Oracle University in my own currency. It would be great if I can get the most affordable one, otherwise I'll take the exam in Argentina($150 in Pearson VUE, cheaper than mine own currency)during my business trip.
Hi all,

I was recently approaching the end of my studies and decided to register for the exam.

Firstly I tried to get a exam voucher over the Oracle Education website, however credit card option didn't appear when I tried to checkout.
Exam Voucher: Oracle Certification Proctored Exam TRY 426.00 (is around US$193.46)

When I changed my country as U.S, credit card option appear and the price has changed to
Exam Voucher: Oracle Certification Proctored Exam US$ 245 (50$ higher than first option)

Finally I decided to call one of the local office and the told me to visit the Pearson Vue website. In Pearson Vue, the price is independent of the country whether Turkey or U.S:
Exam Voucher: Oracle Certification Proctored Exam 165 GBP (600TRY=US$275) (whoo! 75$ higher than first option)

I'm totally confused about this variance in prices. Also dunno why the credit card option does not appear when I select Turkey as country in Oracle website.

What is the way to proceed here? Can I buy a voucher from another country and use it in my home country?

Any recommendation very welcomed.

Good point,

I also wonder whether we should know all the possible alternatives or not.
Hi Roel,

I'll keep with your answer as the JLS also uses the same terminology.

The book is Mala Gupta's OCA Java SE7 Certification guide.

Answer: c, d
Option (a) is a true statement. A checked exception is a subclass of java.lang
.Exception, and a runtime exception is a subclass of java.lang.RuntimeException.
java.lang.RuntimeException is a subclass of java.lang.Exception, and java.lang
.Exception is a subclass of java.lang.Throwable. Hence, all the exceptions are subclasses
of java.lang.Throwable.
Option (b) is also a true statement. Unchecked exceptions are subclasses of class
java.lang.RuntimeException, which itself is a subclass of java.lang.Exception.
Hence, a class can be a subclass of class java.lang.Exception and either a checked
or an unchecked exception.
Option (c) is a false statement. Error is not an exception. It does not subclass
Option (d) is also a false statement. Error need not be part of a method signature,
but checked exceptions must be a part of the method signatures.
Well I'm pretty confident on what should be "caught or declared" in code questions, however these type of "wording" issues are really wasting my energy. You never know what the author has in his/her mind

For example for the question concerned, the answer in book is C&D, which I went for only D.

Q7-6. Select the incorrect statement(s):
a java.lang.Throwable is the base class of all type of exceptions.
b If a class is a subclass of java.lang.Exception, it may or may not be a checked
c Error is an unchecked exception.
d Error and checked exceptions need not be part of a method signature.
Hi Jeanne,

I was checking the JLS and found the following:

"The unchecked exception classes are the run-time exception classes and the error classes.

The checked exception classes are all exception classes other than the unchecked exception classes. That is, the checked exception classes are all subclasses of Throwable other than RuntimeException and its subclasses and Error and its subclasses."

So isn't an error a unchecked exception by this definition? (Getting more confused...)
Hi all,

I'd like to ask you about a terminology confusion which I've faced recently. I hope you wouldn't mind about this basic "wording" stuff.

Q7-6. Select the incorrect statement(s):
a java.lang.Throwable is the base class of all type of exceptions.
b If a class is a subclass of java.lang.Exception, it may or may not be a checked
c Error is an unchecked exception.
d Error and checked exceptions need not be part of a method signature.

Is Error an unchecked exception? In Java Tutorial page I see the following explanation in bold, which makes me to think that an Error is unchecked exception. On the other hand I know that Error is a subclass of Throwable and doesn't inherit from Exception. Or should we say Error is an unchecked Throwable?

From Java Tutorials (
Because the Java programming language does not require methods to catch or to specify unchecked exceptions (RuntimeException, Error, and their subclasses), programmers may be tempted to write code that throws only unchecked exceptions or to make all their exception subclasses inherit from RuntimeException. Both of these shortcuts allow programmers to write code without bothering with compiler errors and without bothering to specify or to catch any exceptions. Although this may seem convenient to the programmer, it sidesteps the intent of the catch or specify requirement and can cause problems for others using your classes.

Another resource which causes confusion taken from an arbitrary website:

Hi all,

I'm having difficulty in understanding the example below where the former one doesn't compile whereas the latter does.
What is the reason behind it?

Having just finished reading Gupta's book I can say that it is pretty good in terms of the clarity and flow of the topic. It focuses where it should focus and don't mess up with the OCPJP topics.
Ok, it is pretty clear now.

BTW thanks Tina for the correction. I noticed that I'm using the wording "package-protected" instead of "package private".
Hi all,

having no professional experience on Java, I decided to prepare for the OCA7 exam 2 weeks ago. I've a doubt about the following example, I hope you can help me to clarify:

This code piece in file compiles fine and runs without any problem and prints "JavaRanch". Here in this example, main method is in a package protected class. Can we say that there is no such rule which mandates the main method to be in a public class? On the other hand I'm not sure how java finds the main class and executes it successfully.
Hi all,

I've recently started working on a tool project which will parse some trace files and show the protocol messages to the user like the following:

Doing the parsing part is not very difficult, however I've no idea about how I can create the sequence diagram flows in UI.

I also would like to add some additional features such that if user clicks to a message line all the message content will be shown.

Can you recommend some java libraries which can speed up the development?

Any ideas and tips is appreciated.

Thanks in advance

8 years ago