01: /**
02: * $Id: NetFileCompress.java,v 1.8 2005/11/30 11:26:34 ss150821 Exp $
03: * Copyright 2002 Sun Microsystems, Inc. All
04: * rights reserved. Use of this product is subject
05: * to license terms. Federal Acquisitions:
06: * Commercial Software -- Government Users
07: * Subject to Standard License Terms and
08: * Conditions.
09: *
10: * Sun, Sun Microsystems, the Sun logo, and Sun ONE
11: * are trademarks or registered trademarks of Sun Microsystems,
12: * Inc. in the United States and other countries.
13: */package com.sun.portal.netfile.servlet.java1;
14:
15: import java.io.*;
16: import com.sun.portal.log.common.PortalLogger;
17: import java.util.zip.Deflater;
18:
19: public interface NetFileCompress {
20:
21: public void setCompressLevel(int i);
22:
23: public void setCompressMethod(String s);
24:
25: public void setBufferSize(int i);
26:
27: /*
28: * Call the setter methods to set compression level and buffer size
29: * before calling the doZipCompress and doGZipCompress methods.
30: * If this is not done default compression level and buffer size is used.
31: */
32: public void doCompress(InputStream istream, OutputStream ostream,
33: Object obj) throws IOException;
34:
35: public void doZipCompress(InputStream ist, OutputStream ost,
36: String entry) throws IOException;
37:
38: public void doGZipCompress(InputStream ist, OutputStream ost,
39: Deflater deflater) throws IOException;
40: }
|