No it doesn't. Java doesn't support default arguments in
any function; constructors
included.
What you can do though is
define public Shape(int v, int e)
and also a default
constructor
public
Shape()
{
this(1,
2);
}
Note the special
syntax here to delegate the construction to the two-argument
constructor.
No comments:
Post a Comment