/** * Test if the component's execution is currently at one of the * given breakpoints. If yes, the component will be suspended by * the platform. * @param breakpoints An array of breakpoints. * @return True, when some breakpoint is triggered. */ public boolean isAtBreakpoint(String[] breakpoints) { boolean isatbreakpoint = false; Set<String> bps = new HashSet<String>(Arrays.asList(breakpoints)); // Todo: cache set across invocations for speed? for(Iterator<ProcessThread> it=context.getAllThreads().iterator(); !isatbreakpoint && it.hasNext(); ) { ProcessThread pt = (ProcessThread)it.next(); isatbreakpoint = bps.contains(pt.getActivity().getBreakpointId()); } return isatbreakpoint; }
for(Iterator it=getAllActivities().values().iterator(); it.hasNext(); ) names.add(((MActivity)it.next()).getBreakpointId());
/** * */ public ProcessThreadInfo createProcessThreadInfo(ProcessThread thread) { ProcessThreadInfo info = new ProcessThreadInfo(thread.getId(), thread.getActivity().getBreakpointId(), thread.getActivity().getPool()!=null ? thread.getActivity().getPool().getName() : null, thread.getActivity().getLane()!=null ? thread.getActivity().getLane().getName() : null, thread.getException()!=null ? thread.getException().toString() : "", thread.isWaiting(), thread.getData()!=null ? thread.getData().toString() : ""); return info; }