Shravan Payasam

Greenhorn
+ Follow
since Nov 16, 2012
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
1
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Shravan Payasam

It looks like you want to mimic the server behavior(forwarding to the other JSP) in the AJAX callback method.
The data that you will have in the call back function is either html(response from the server as a result of the JSP execution) or xml depending on the response type which you can use to update the page.
You may be able to potentially redirect the request in the callback function since it is just javascript possibly using window.location.href.
You need to be diligent about any request data to the other URL.

But yeah, the exact scenario needs to be explained

Bear Bibeault wrote:

Shravan Payasam wrote:I can change the method this way.


And you feel that is acceptable?



By changing the method that way, what I meant is, I know that it will be break with that kind of input.
But I wanted to get more differences like the one that Winston cited.

@Winston: I guess, I'm convinced with your answer. But what did you mean by

Your second class's method could be easily written in terms of its others.


Would you mind explaining with an example?

Also, you said, both are flawed, I'm curious to know what is wrong with the Approach 2? What am I missing?

Thanks in advance
Shravan
10 years ago

Rob Spoor wrote:Since when is 5 / 0 equal to 0? Just return Double.NaN for doubles and let the ArithmeticException be thrown for ints.



Point taken.

Although that is not the subject of the question.
10 years ago
I can change the method this way. Other than poorly documented method signature, is there any other difference?

10 years ago
@sriman roop : Its a question that generated interest to all the important people of Javaranch ;-) Why did you ask this question? Were you just curious?

If that's a cause for concern to you, don't worry.
I don't believe java is going anywhere in the near future.

And even if a new language has to come on to the stage, it will probably be based on java itself ... LOL

And just because Apple says its not going to use java doesn't kill Java. Probably Apple itself will die facing lawsuits from others.
10 years ago
Approach 1:




Approach 2:



Are there any real advantages of choosing one over the other?
10 years ago
@CRMK: ha ha ha... I'm ROTFL. You are driving everyone nuts here
11 years ago
I'm using jdk logging and i've the below in the logging.properties:



The log file soap_0.log and lck file are getting created , however, I don't see any log.fine(msg) entries in the log file. Since I've set the FileHandler level to FINEST, it should override the global INFO level, shouldn't it?

I'm java 1.6 u15. What am I doing wrong?
11 years ago