public PRTokeniser(String filename) throws IOException { file = new RandomAccessFileOrArray(filename); }
/** Reads and parses a PDF document. * @param url the URL of the document * @param ownerPassword the password to read the document * @throws IOException on error */ public PdfReader(URL url, byte ownerPassword[]) throws IOException { password = ownerPassword; tokens = new PRTokeniser(new RandomAccessFileOrArray(url)); readPdf(); }
EnumerateTTC(String ttcFile) throws DocumentException, IOException { fileName = ttcFile; rf = new RandomAccessFileOrArray(ttcFile); findNames(); }
EnumerateTTC(byte ttcArray[]) throws DocumentException, IOException { fileName = "Byte array TTC"; rf = new RandomAccessFileOrArray(ttcArray); findNames(); }
/** * Reads and parses a PDF document. * @param is the <CODE>InputStream</CODE> containing the document. The stream is read to the * end but is not closed * @param ownerPassword the password to read the document * @throws IOException on error */ public PdfReader(InputStream is, byte ownerPassword[]) throws IOException { password = ownerPassword; tokens = new PRTokeniser(new RandomAccessFileOrArray(is)); readPdf(); }
EnumerateTTC(byte ttcArray[]) throws DocumentException, IOException { fileName = "Byte array TTC"; rf = new RandomAccessFileOrArray(ttcArray); findNames(); }
EnumerateTTC(byte[] ttcArray) throws DocumentException, IOException { fileName = "Byte array TTC"; rf = new RandomAccessFileOrArray(ttcArray); findNames(); }
EnumerateTTC(String ttcFile) throws DocumentException, IOException { fileName = ttcFile; rf = new RandomAccessFileOrArray(ttcFile); findNames(); }
/** Reads and parses a PDF document. * @param url the URL of the document * @param ownerPassword the password to read the document * @throws IOException on error */ public PdfReader(URL url, byte ownerPassword[]) throws IOException { password = ownerPassword; tokens = new PRTokeniser(new RandomAccessFileOrArray(url)); readPdf(); }
EnumerateTTC(String ttcFile) throws DocumentException, IOException { fileName = ttcFile; rf = new RandomAccessFileOrArray(ttcFile); findNames(); }
/** * Reads and parses a PDF document. * @param is the <CODE>InputStream</CODE> containing the document. The stream is read to the * end but is not closed * @param ownerPassword the password to read the document * @throws IOException on error */ public PdfReader(InputStream is, byte ownerPassword[]) throws IOException { password = ownerPassword; tokens = new PRTokeniser(new RandomAccessFileOrArray(is)); readPdf(); }
public static void main(String[] args) { try { RandomAccessFileOrArray in = new RandomAccessFileOrArray(args[0]); OutputStream out = new FileOutputStream(args[1]); convert(in, out); in.close(); out.close(); } catch (Exception e) { e.printStackTrace(); } }
public static void main(String[] args) { try { RandomAccessFileOrArray in = new RandomAccessFileOrArray(args[0]); OutputStream out = new FileOutputStream(args[1]); convert(in, out); in.close(); out.close(); } catch (Exception e) { e.printStackTrace(); } }
@Override PdfReader openSource(PdfFileSource source) throws IOException { return new PdfReader(new RandomAccessFileOrArray(source.getSource().getAbsolutePath()), source.getPasswordBytes()); }
public static void main(String[] args) { try { RandomAccessFileOrArray in = new RandomAccessFileOrArray(args[0]); OutputStream out = new FileOutputStream(args[1]); convert(in, out); in.close(); out.close(); } catch (Exception e) { e.printStackTrace(); } }
@Override PdfReader openSource(PdfStreamSource source) throws IOException { return new PdfReader(new RandomAccessFileOrArray(source.getSource()), source.getPasswordBytes()); }
@Override PdfReader openSource(PdfURLSource source) throws IOException { return new PdfReader(new RandomAccessFileOrArray(source.getSource()), source.getPasswordBytes()); }
protected byte[] getFullFont() throws IOException { RandomAccessFileOrArray rf2 = null; try { rf2 = new RandomAccessFileOrArray(rf); rf2.reOpen(); byte b[] = new byte[rf2.length()]; rf2.readFully(b); return b; } finally { try {if (rf2 != null) {rf2.close();}} catch (Exception e) {} } }
protected byte[] getFullFont() throws IOException { RandomAccessFileOrArray rf2 = null; try { rf2 = new RandomAccessFileOrArray(rf); rf2.reOpen(); byte b[] = new byte[rf2.length()]; rf2.readFully(b); return b; } finally { try {if (rf2 != null) {rf2.close();}} catch (Exception e) {} } }
protected byte[] getFullFont() throws IOException { RandomAccessFileOrArray rf2 = null; try { rf2 = new RandomAccessFileOrArray(rf); rf2.reOpen(); byte[] b = new byte[rf2.length()]; rf2.readFully(b); return b; } finally { try {if (rf2 != null) {rf2.close();}} catch (Exception e) {} } }