PDFDocumentByteWriterFactory.java 1.87 KB
/*
 * Decompiled with CFR 0_118.
 * 
 * Could not load the following classes:
 *  com.adobe.internal.io.ByteWriter
 *  com.adobe.internal.io.ByteWriterFactory
 *  com.adobe.internal.io.ByteWriterFactory$EncryptionStatus
 *  com.adobe.internal.io.ByteWriterFactory$Fixed
 *  com.adobe.internal.io.ByteWriterFactory$Longevity
 *  com.adobe.pdfg.logging.PDFGLogger
 */
package com.adobe.pdfg.postprocess;

import com.adobe.internal.io.ByteWriter;
import com.adobe.internal.io.ByteWriterFactory;
import com.adobe.pdfg.logging.PDFGLogger;
import java.io.IOException;

public class PDFDocumentByteWriterFactory
implements ByteWriterFactory {
    private static final int MAX_INLINE_SIZE = 8192;
    private static PDFGLogger pdfgLogger = PDFGLogger.getPDFGLogger(PDFDocumentByteWriterFactory.class);

    public void closeByteWriter(ByteWriter byteWriter) throws IOException {
        if (byteWriter != null) {
            try {
                byteWriter.close();
            }
            catch (Exception thr) {
                pdfgLogger.trace(thr.getMessage(), null, (Throwable)thr);
            }
        }
    }

    public void closeFactory() throws IOException {
    }

    public ByteWriter getByteWriter(ByteWriterFactory.Longevity longevity, ByteWriterFactory.EncryptionStatus encryption, ByteWriterFactory.Fixed fixed, long size, boolean fast) throws IOException {
        return this.getByteWriter();
    }

    public ByteWriter[] getByteWriter(ByteWriterFactory.Longevity longevity, ByteWriterFactory.EncryptionStatus encryption, ByteWriterFactory.Fixed fixed, long[] size, boolean fast) throws IOException {
        ByteWriter[] byteWriters = new ByteWriter[size.length];
        for (int i = 0; i < size.length; ++i) {
            byteWriters[i] = this.getByteWriter();
        }
        return byteWriters;
    }

    private ByteWriter getByteWriter() throws IOException {
        return null;
    }
}