So, In java program, if we create objects of the class with parameters then the respective overloaded constructor will be called . i.e. Employee e1 = new Employee(); //object e1 will call Employee()constructor. Employee e2 = new Employee(123); //object e2 will call Employee(int id)constructor.