how to return different class instance, if at one time one object is present

Printable View