KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > mule > util > compression > CompressionStrategy


1 /*
2  * $Id: CompressionStrategy.java 3798 2006-11-04 04:07:14Z aperepel $
3  * --------------------------------------------------------------------------------------
4  * Copyright (c) MuleSource, Inc. All rights reserved. http://www.mulesource.com
5  *
6  * The software in this package is published under the terms of the MuleSource MPL
7  * license, a copy of which has been included with this distribution in the
8  * LICENSE.txt file.
9  */

10
11 package org.mule.util.compression;
12
13 import java.io.IOException JavaDoc;
14
15 /**
16  * <code>CompressionStrategy</code> is a base interface for Different compression
17  * strategies
18  *
19  * @author <a HREF="mailto:ross.mason@symphonysoft.com">Ross Mason</a>
20  * @version $Revision: 3798 $
21  */

22 public interface CompressionStrategy
23 {
24     /**
25      * The fully qualified class name of the fallback
26      * <code>CompressionStrategy</code> implementation class to use, if no other
27      * can be found. the default is
28      * <code>org.mule.util.compression.GZipCompression</code>
29      */

30     String JavaDoc COMPRESSION_DEFAULT = "org.mule.util.compression.GZipCompression";
31
32     /**
33      * JDK1.3+ 'Service Provider' specification (
34      * http://java.sun.com/j2se/1.3/docs/guide/jar/jar.html )
35      */

36     String JavaDoc SERVICE_ID = "META-INF/services/org.mule.util.compression.CompressionStrategy";
37
38     byte[] compressByteArray(byte[] bytes) throws IOException JavaDoc;
39
40     byte[] uncompressByteArray(byte[] bytes) throws IOException JavaDoc;
41
42     boolean isCompressed(byte[] bytes) throws IOException JavaDoc;
43 }
44
Popular Tags