passList.add(pass);
	private void buildPassList(ConstraintGraph constraintGraph)			throws OrderingConstraintException {		while (constraintGraph.getNumVertices() > 0) {			List<DetectorNode> inDegreeZeroList = new LinkedList<DetectorNode>();			// Get all of the detectors nodes with in-degree 0.			// These have no unsatisfied prerequisites, and thus can			// be chosen for the current pass.			int inDegreeZeroCount = 0;			for (Iterator<DetectorNode> i = constraintGraph.vertexIterator(); i.hasNext(); ) {				DetectorNode node = i.next();				if (constraintGraph.getNumIncomingEdges(node) == 0) {					++inDegreeZeroCount;					inDegreeZeroList.add(node);				}			}			if (inDegreeZeroCount == 0)				throw new OrderingConstraintException("Cycle in inter-pass ordering constraints");			// Remove all of the chosen detectors from the constraint graph.			for (Iterator<DetectorNode> i = inDegreeZeroList.iterator(); i.hasNext(); ) {				DetectorNode node = i.next();				constraintGraph.removeVertex(node);			}			// Create analysis pass and add detector factories.			AnalysisPass pass = new AnalysisPass();			for (Iterator<DetectorNode> i = inDegreeZeroList.iterator(); i.hasNext(); ) {				DetectorNode node = i.next();				pass.addDetectorFactory(node.getFactory());				assignedToPassSet.add(node.getFactory());			}			// Add pass to list of passes in the execution plan.			passList.add(pass);		}	}