Exception 2005-10-03 - By SUBSCRIBE EJB-INTEREST anonymous
Back Hi, Is there any drawback if I perform the below.I throw DataException from B's method, but, didn't catch it explictly in A's method.I am just catching Exception,base class of DataException.
public class A{
public String getData(){ String data = null; try{ B b = new B(); data = b. getData(); } catch(Exception ex){}
return data; }
public class B{
public String getData(){ String strData = null; try{ //get the data and return it } catch(DataException exp) { throw exp; } return strData; } }
=========================================================================== To unsubscribe, send email to listserv@(protected) and include in the body of the message "signoff J2EE-INTEREST". For general help, send email to listserv@(protected) and include in the body of the message "help".
|
|