ExecutionAdministration ea = Shark.getInstance().getAdminInterface().getExecutionAdministration();
ea.connect(userName, password, engineName, null);
// parentProcId 为父流程序号, 且parentActivityId是创建子流程的活动序号
WfActivity wfa = ea.getActivity(parentProcId, parentActivityId);
WfProcess[] performers = wfa.get_sequence_performer(0);
if ( performers != null && performers.length > 0 )
{
// subProcId为子流程序号
subProcId = performers[0].key();
}
ea.connect(userName, password, engineName, null);
// parentProcId 为父流程序号, 且parentActivityId是创建子流程的活动序号
WfActivity wfa = ea.getActivity(parentProcId, parentActivityId);
WfProcess[] performers = wfa.get_sequence_performer(0);
if ( performers != null && performers.length > 0 )
{
// subProcId为子流程序号
subProcId = performers[0].key();
}
博客展示了一段代码,通过Shark实例获取执行管理对象,连接指定引擎,根据父流程序号和活动序号获取活动对象,进而获取序列执行者,最终得到子流程序号。
2071

被折叠的 条评论
为什么被折叠?



