KyaPoocha.com

Huge Collection of Interview Questions


How can I handle a constructor that fails? 

Throw an exception. Constructors don’t have a return type, so it’s not possible to use
return codes. The best way to signal constructor failure is therefore to throw an exception.



If you liked this question/asnwer, make sure you
Subscribe to KyaPoocha.com RSS feed!


BOOKMARK THIS : BlinkList | del.icio.us | Digg it | Furl | reddit | StumbleUpon | Yahoo MyWeb |