SortedBugCollection result = null; BugHistory bugHistory = new BugHistory(origCollection, newCollection); bugHistory.setUseFuzzyComparator(useFuzzyComparator);  if (op.equals("-new") || op.equals("-added")) { result = bugHistory.performSetOperation(ADDED_WARNINGS); } else if (op.equals("-fixed") || op.equals("-removed")) { result = bugHistory.performSetOperation(REMOVED_WARNINGS); } else if (op.equals("-retained")) { result = bugHistory.performSetOperation(RETAINED_WARNINGS); } else throw new IllegalArgumentException("Unknown operation: " + op);  result.writeXML(System.out, project);
BugHistory bugHistory = new BugHistory(origCollection, newCollection); bugHistory.setUseFuzzyComparator(commandLine.isFuzzy());  SortedBugCollection result = bugHistory.performSetOperation(commandLine.getSetOp());  if (commandLine.isCount()) { System.out.println("Delta is " +result.getCollection().size()); } else { result.writeXML(System.out, project); }
	public static void main(String[] argv) throws Exception {		if (argv.length < 3) {			printUsage();		}		Project project = new Project();				boolean useFuzzyComparator = false;		int argCount = 0;		if (argv[argCount].equals("-fuzzy")) {			if (argv.length < 4) {				printUsage();			}			useFuzzyComparator = true;			++argCount;		}		String op = argv[argCount++];		SortedBugCollection origCollection = readCollection(argv[argCount++], project);		SortedBugCollection newCollection = readCollection(argv[argCount++], new Project());		SortedBugCollection result = null;		BugHistory bugHistory = new BugHistory(origCollection, newCollection); 		bugHistory.setUseFuzzyComparator(useFuzzyComparator);		if (op.equals("-new") || op.equals("-added")) {			result = bugHistory.performSetOperation(ADDED_WARNINGS);		} else if (op.equals("-fixed") || op.equals("-removed")) {			result = bugHistory.performSetOperation(REMOVED_WARNINGS);		} else if (op.equals("-retained")) {			result = bugHistory.performSetOperation(RETAINED_WARNINGS);		} else			throw new IllegalArgumentException("Unknown operation: " + op);		result.writeXML(System.out, project);	}