1 package org.ozoneDB.tools.OPP.srcgen.streamfactory; 9 10 import java.io.*; 11 12 16 public class FileOutputStreamFactory extends FileBasedStreamFactory implements OutputStreamFactory { 17 public FileOutputStreamFactory(File directory, String extension) { 18 super(directory, extension); 19 } 20 21 public OutputStream newInstance(String className) throws IOException { 22 File file = getFile(className); 23 file.getParentFile().mkdirs(); 24 return new FileOutputStream(file); 25 } 26 } 27 | Popular Tags |