Specifications

Sun Services
Java™ Programming Language
Module 6, slide 25 of 43
Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. Sun Services, Revision F
Overloading Constructors
As with methods, constructors can be overloaded.
An example is:
public Employee(String name, double salary, Date DoB)
public Employee(String name, double salary)
public Employee(String name, Date DoB)
Argument lists must differ.
You can use the this reference at the first line of a
constructor to call another constructor.