Win a copy of Murach's MySQL this week in the JDBC and Relational Databases forum!

Pinkal Patel

Ranch Hand
+ Follow
since Jun 16, 2006
Merit badge: grant badges
For More
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 Pinkal Patel


I want to setup My Application on the Jboss.

My Test application is running fine on Jboss server with single WAR/EAR file. (Included EJB)

Now when I try to move Static files (Image, Docs, CSS) on apache. Application is not able to find That image path etc.

Can Any one guid me how to set this Apache with Jboss only for static files.

15 years ago

why these two are giving out put as true ?

System.out.println("Lessthan: " + (i1 <= i2));
System.out.println("Greaterthan: " + (i1 >= i2));

Here Auto Boxing come in picture and Integer wrapper class convert to normal int type and than compare two int variable so It will return True in this case.

What feature of language is being tested here ? Please help

Want to test calling of Constructor
When you are using new String("123");

Will create unother Object without cheaking the Pool.

and when unig s="123";

It will first check pool and create object if it is not found in the Pool

May be this will clear your doubt.
Chaging Priority will help you for the Next CPU time after moving to Ready to Run State
Could you please send me the SCJP 1.5 mock exam to

Will check in the Pool for the Availability of the Object
Here i2 will get it as i1

(i1==i2) will return try


Here We are calling Explicitly call new constructor so It will not look in the pool so it return false.
"Dan Hansen"
String is allready Created and Avilable in the Pool
So it just gave Ref. of it not new Object.

Will Gave Warning

Pls find Couase in Italics format

In the Program 1)

Assigned null to Actual value of the Array
but in the Program 2)

Will Null the Second Refference to Array Object

e.g Lets Change line


Meance Now
a1 -> OBJECT of Array
a2 -> OBJECT of Array
Both Reffer the Same object if you mack a2=null;
meance OBJECT of Array is not aloved for GC


Here c refferance of class CovariantTest
And Assigned the Object of SubCovariantTest

Meance Signature of the Method is

Runtime Method called from class SubCovariantTest

Now Return type B is Used fetured of Covariant returntype and convert this object to A.

So O/P is In B followed with 5.

Due to Calling Method of SubCovariantTest and return object is convert to Type A.

Here spb is Super type Reference Variable
So No definition find for as void method(Sub sb1)
But Super is display because you can pass Sun instead of Super...

If you Try above Code it will gave Method not fount Exception.....

Which will help you to understand Concepts.
It will depent on your implementation of the Collection class

If this return type will retuen some class which is implement List interface that answer is YES (e.g ArrayList)

But If return type will return some class which is implments Set interface thant answer is NO (e.g HashSet) will gave ClassCastException @ runtime
B.s1 Ref. Type is B and Hidding the variable A.s1
A.s2 Ref. Type is B and Extend from A
A.s1 Ref. Type is A
A.s2 Ref. Type is A