1 51 package org.apache.fop.apps; 52 53 import org.xml.sax.InputSource ; 55 import org.xml.sax.XMLReader ; 56 57 import java.io.File ; 59 import java.net.URL ; 60 61 64 public class FOInputHandler extends InputHandler { 65 66 File fofile = null; 67 URL foURL = null; 68 public FOInputHandler (File fofile) { 69 this.fofile = fofile; 70 } 71 72 public FOInputHandler (URL url) { 73 this.foURL = url; 74 } 75 76 public InputSource getInputSource () { 77 if (fofile != null) 78 return super.fileInputSource(fofile); 79 return super.urlInputSource(foURL); 80 } 81 82 public XMLReader getParser() throws FOPException { 83 return super.createParser(); 84 } 85 86 public void run(Driver driver) throws FOPException { 87 throw new FOPException("not implemented: FOInputHandler.run(Driver)"); 88 } 89 90 } 91 92 | Popular Tags |