Topic: EJB高手看过来? (如何将ejbstore方法中的错误抛出) |
Print this page |
1.EJB高手看过来? (如何将ejbstore方法中的错误抛出) | Copy to clipboard |
Posted by: dottrue Posted on: 2003-10-31 18:05 在entityBean中,如何将ejbstore方法中的错误抛出给客户段啊?? 小弟用sessionBean,更新数据,J2EE容器自动调用EJBSTORE()方法,但是这里很有可能会出错,比如数据类型,插入的值对于列过大等SQLerror,这些错误都必须传给客户段的错误,高手们是怎么作的啊?? |
2.Re:EJB高手看过来? [Re: dottrue] | Copy to clipboard |
Posted by: zyzhang Posted on: 2003-10-31 21:21 Client can get message using RemoteException.getMessage(); Ejb container can only throw ejbexception which is remoteexception.you have to wrap your specific exception(sql exception) passed and rethrow ejbexception. This is the basic question on ejb. |
Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1 客服电话 18559299278 客服信箱 714923@qq.com 客服QQ 714923 |