Why is Double different from new Double()

From: Bob Sparks (Bobsparks_at_excite.com)
Date: 12/30/04


Date: 30 Dec 2004 08:44:33 -0800

I have a method that requires a Number as an argument

If I do this

Double x = new Double("2");

numberMethod(x);

It doesn't compile with a not found error
nor does
numberMethod((Number)x);

where as

numberMethod(new Double(x));

does compile. Can any one explain it?

Bob