// Path: de.tubs.variantsync.core/src/de/tubs/variantsync/core/managers/persistence/FeatureContextFormat.java
// public class FeatureContextFormat extends AXMLFormat<List<FeatureContext>> {
// 
// 	private static final String ID = "FeatureContexts";
// 	private static final String FEATURE_CONTEXTS = "contexts";
// 	private static final String FEATURE_CONTEXT = "context";
// 	private static final Pattern CONTENT_REGEX = Pattern.compile("\\A\\s*(<[?]xml\\s.*[?]>\\s*)?<" + FEATURE_CONTEXTS + "[\\s>]");
// 
// 	public static final String FILENAME = ".contexts.xml";
// 
// 	@Override
// 	public APersistentFormat<List<FeatureContext>> getInstance() {
// 		return new FeatureContextFormat();
// 	}
// 
// 	@Override
// 	public boolean supportsRead() {
// 		return true;
// 	}
// 
// 	@Override
// 	public boolean supportsWrite() {
// 		return true;
// 	}
// 
// 	@Override
// 	public String getId() {
// 		return ID;
// 	}
// 
// 	@Override
// 	protected void readDocument(Document doc, List<Problem> warnings) throws UnsupportedModelException {
// 		object.clear();
// 		for (final Element e : getElements(doc.getDocumentElement().getChildNodes())) {
// 			FeatureContext fe = new FeatureContext(e.getAttribute("name"), FeatureColor.getColor(e.getAttribute("highlighter")));
// 			object.add(fe);
// 		}
// 
// 	}
// 
// 	@Override
// 	protected void writeDocument(Document doc) {
// 		final Element root = doc.createElement(FEATURE_CONTEXTS);
// 
// 		Element e;
// 		for (FeatureContext fe : object) {
// 			e = doc.createElement(FEATURE_CONTEXT);
// 			e.setAttribute("name", fe.name);
// 			e.setAttribute("highlighter", fe.highlighter.getColorName());
// 			root.appendChild(e);
// 		}
// 		doc.appendChild(root);
// 	}
// 
// 	@Override
// 	public boolean supportsContent(CharSequence content) {
// 		return supportsRead() && CONTENT_REGEX.matcher(content).find();
// 	}
// 
// 	@Override
// 	public String getName() {
// 		return "FeatureContexts";
// 	}
// 
// }


import java.io.File;
import java.io.IOException;
import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IFolder;
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IResourceDelta;
import de.ovgu.featureide.core.builder.ComposerExtensionClass;
import de.ovgu.featureide.fm.core.configuration.Configuration;
import de.tubs.variantsync.core.managers.persistence.FeatureContextFormat;
package de.tubs.variantsync.core;




public class VariantSyncComposer extends ComposerExtensionClass {

	@Override
	public void performFullBuild(IFile config) {
		VariantSyncPlugin.getConfigurationProjectManager().reinitialize();
	}

	@Override
	public void addCompiler(IProject project, String sourcePath, String configPath, String buildPath) {
// Path: de.tubs.variantsync.core/src/de/tubs/variantsync/core/managers/persistence/FeatureContextFormat.java
// public class FeatureContextFormat extends AXMLFormat<List<FeatureContext>> {
// 
// 	private static final String ID = "FeatureContexts";
// 	private static final String FEATURE_CONTEXTS = "contexts";
// 	private static final String FEATURE_CONTEXT = "context";
// 	private static final Pattern CONTENT_REGEX = Pattern.compile("\\A\\s*(<[?]xml\\s.*[?]>\\s*)?<" + FEATURE_CONTEXTS + "[\\s>]");
// 
// 	public static final String FILENAME = ".contexts.xml";
// 
// 	@Override
// 	public APersistentFormat<List<FeatureContext>> getInstance() {
// 		return new FeatureContextFormat();
// 	}
// 
// 	@Override
// 	public boolean supportsRead() {
// 		return true;
// 	}
// 
// 	@Override
// 	public boolean supportsWrite() {
// 		return true;
// 	}
// 
// 	@Override
// 	public String getId() {
// 		return ID;
// 	}
// 
// 	@Override
// 	protected void readDocument(Document doc, List<Problem> warnings) throws UnsupportedModelException {
// 		object.clear();
// 		for (final Element e : getElements(doc.getDocumentElement().getChildNodes())) {
// 			FeatureContext fe = new FeatureContext(e.getAttribute("name"), FeatureColor.getColor(e.getAttribute("highlighter")));
// 			object.add(fe);
// 		}
// 
// 	}
// 
// 	@Override
// 	protected void writeDocument(Document doc) {
// 		final Element root = doc.createElement(FEATURE_CONTEXTS);
// 
// 		Element e;
// 		for (FeatureContext fe : object) {
// 			e = doc.createElement(FEATURE_CONTEXT);
// 			e.setAttribute("name", fe.name);
// 			e.setAttribute("highlighter", fe.highlighter.getColorName());
// 			root.appendChild(e);
// 		}
// 		doc.appendChild(root);
// 	}
// 
// 	@Override
// 	public boolean supportsContent(CharSequence content) {
// 		return supportsRead() && CONTENT_REGEX.matcher(content).find();
// 	}
// 
// 	@Override
// 	public String getName() {
// 		return "FeatureContexts";
// 	}
// 
// }


// Path: de.tubs.variantsync.core/src/de/tubs/variantsync/core/VariantSyncComposer.java
import java.io.File;
import java.io.IOException;
import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IFolder;
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IResourceDelta;
import de.ovgu.featureide.core.builder.ComposerExtensionClass;
import de.ovgu.featureide.fm.core.configuration.Configuration;
import de.tubs.variantsync.core.managers.persistence.FeatureContextFormat;

package de.tubs.variantsync.core;




public class VariantSyncComposer extends ComposerExtensionClass {

	@Override
	public void performFullBuild(IFile config) {
		VariantSyncPlugin.getConfigurationProjectManager().reinitialize();
	}

	@Override
	public void addCompiler(IProject project, String sourcePath, String configPath, String buildPath) {
		File featureContextFile = new File(project.getFile(FeatureContextFormat.FILENAME).getLocationURI());