{
…………………
}
wtcHome=(WtcInstanceHome)javax.rmi.PortableRemoteObject.narrow(obj, WtcInstanceHome.class);
try
{
wtcRemote = wtcHome.create();
}
catch (Exception e)
{
………….
}
callTestService(service_name);
try
{
wtcRemote.remove();
}
catch (Exception e)
{
………………
}
}
函数callTestService
public String callTestService (String service_name)
{
CallDescriptor tuxRtn = null;
TypedFML32 inParams = null, tuxResult = null;
try
{
//创建fml32缓冲区java描述类的实例
inParams = new TypedFML32(new student_fld());
//填写输入参数:学号
inParams.Fchg(student_fld.student_id , 0, getStudentId());
}
catch (Ferror e)
{
……
}
try
{ //异步调用tuxedo service.
tuxRtn = wtcRemote.Tpacall(service_name, inParams);
}
catch (Exception e)
{
………
}
try
{ //等待异步调用的service返回结果.
tuxResult = wtcRemote.Tpgetrply(tuxRtn);
}
catch (Exception e)
{
………
}
try
{
//得到学生的姓名和年龄…
stuName = (String)tuxResult.Fget(student_fld.student_name, 0);
stuAge = (Integer) tuxResult.Fget(student_fld.student_age, 0);
}
catch (Ferror e)
{
………
}
………
}
百度搜索“77cn”或“免费范文网”即可找到本站免费阅读全部范文。收藏本站方便下次阅读,免费范文网,提供经典小说综合文库通过wtc使tuxedo与weblogic通信开发(6)在线全文阅读。
相关推荐: