package org.strategoxt.imp.metatooling.building;

import org.metaborg.runtime.task.TaskEngine;
import org.metaborg.runtime.task.TaskManager;
import org.spoofax.interpreter.library.index.IIndex;
import org.spoofax.interpreter.library.index.IndexManager;
import org.spoofax.interpreter.library.index.notification.NotificationCenter;

public class AntResetProject {
	public static void main(String[] args) {
		final String projectPath = args[0];

		final TaskManager taskManager = TaskManager.getInstance();
		final TaskEngine taskEngine = taskManager.getTaskEngine(projectPath);
		if(taskEngine != null)
			taskEngine.reset();

		final IndexManager indexManager = IndexManager.getInstance();
		final IIndex index = indexManager.getIndex(args[0]);
		if(index != null)
			index.clearAll();

		NotificationCenter.notifyNewProject(indexManager.getProjectURIFromAbsolute(projectPath));
	}
}

@@ -72,24 +72,25 @@
 untime.task.
+I
 TaskEngine;%0A
@@ -503,24 +503,25 @@
 ();%0A%09%09final 
+I
 TaskEngine t

Use ITaskManager instead of TaskManager.