// Copyright 2002-2005, FreeHEP.
package org.freehep.aid;
import java.io.File;
import java.io.IOException;
import java.util.Properties;
import org.freehep.rtti.Generator;
import org.freehep.rtti.IClass;
import org.freehep.util.UserProperties;
import org.freehep.util.io.IndentPrintWriter;
/**
* @author Mark Donszelmann
* @version $Id: AbstractGenerator.java 8584 2006-08-10 23:06:37Z duns $
*/
public abstract class AbstractGenerator implements Generator {
protected UserProperties properties = new UserProperties();
public AbstractGenerator() {
}
public Properties getProperties() {
return properties;
}
protected void warning(IndentPrintWriter out) {
// first line to signal our files!
out.println("// AID-GENERATED");
out.println("// =========================================================================");
out.println("// This class was generated by AID - Abstract Interface Definition ");
out.println("// DO NOT MODIFY, but use the org.freehep.aid.Aid utility to regenerate it. ");
out.println("// =========================================================================");
}
public String directory(IClass clazz) {
return "";
}
public abstract String filename(IClass clazz);
// return true if we want to stop writing
public abstract boolean print(File file, IClass clazz) throws IOException;
}