de.tudarmstadt.ukp.wikipedia.mwdumper.importer.SqlFileStream Maven / Gradle / Ivy
package de.tudarmstadt.ukp.wikipedia.mwdumper.importer;
import java.io.IOException;
import java.io.OutputStream;
import java.io.PrintStream;
public class SqlFileStream implements SqlStream {
protected PrintStream stream;
public SqlFileStream(OutputStream output) throws IOException {
this.stream = new PrintStream(output, false, "UTF-8");
}
public void writeComment(CharSequence sql) {
stream.println(sql.toString());
}
public void writeStatement(CharSequence sql) {
stream.print(sql.toString());
stream.println(';');
}
public void close() {
stream.flush();
stream.close();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy