01: /*
02: * $Id: RawPackCompressor.java 2036 2008-02-09 11:14:05Z jponge $
03: * IzPack - Copyright 2001-2008 Julien Ponge, All Rights Reserved.
04: *
05: * http://izpack.org/
06: * http://izpack.codehaus.org/
07: *
08: * Copyright 2005 Klaus Bartz
09: *
10: * Licensed under the Apache License, Version 2.0 (the "License");
11: * you may not use this file except in compliance with the License.
12: * You may obtain a copy of the License at
13: *
14: * http://www.apache.org/licenses/LICENSE-2.0
15: *
16: * Unless required by applicable law or agreed to in writing, software
17: * distributed under the License is distributed on an "AS IS" BASIS,
18: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19: * See the License for the specific language governing permissions and
20: * limitations under the License.
21: */
22: package com.izforge.izpack.compressor;
23:
24: import java.io.BufferedOutputStream;
25: import java.io.OutputStream;
26:
27: /**
28: * IzPack will be able to support different compression methods for the
29: * packs included in the installation jar file.
30: * This class implements the PackCompressor for the compression format "raw".
31: *
32: * @author Klaus Bartz
33: */
34: public class RawPackCompressor extends PackCompressorBase {
35: private static final String[] THIS_FORMAT_NAMES = { "raw",
36: "uncompressed" };
37:
38: /**
39: *
40: */
41: public RawPackCompressor() {
42: super ();
43: formatNames = THIS_FORMAT_NAMES;
44: }
45:
46: /* (non-Javadoc)
47: * @see com.izforge.izpack.compressor.PackCompressor#getOutputStream(java.io.OutputStream)
48: */
49: public OutputStream getOutputStream(OutputStream os) {
50: // In this pack compressor we must not use reflection because
51: // the neede class will be always present (a base class of the VM).
52: return (new BufferedOutputStream(os));
53: }
54: }
|