//Auto-generated by kalyptus. DO NOT EDIT.
package org.trinitydesktop.koala;

import org.trinitydesktop.qt.TQt;
import org.trinitydesktop.qt.TQMetaObject;
import org.trinitydesktop.qt.QtSupport;
import org.trinitydesktop.qt.TQIODevice;
import org.trinitydesktop.qt.TQIODeviceInterface;
import org.trinitydesktop.qt.TQObject;

/**

 This is the base class for compression filters
 such as gzip and bzip2. It's pretty much internal.
 Don't use directly, use KFilterDev instead.
 		@short    This is the base class for compression filters  such as gzip and bzip2.

*/
public class KFilterBase extends TQObject  {
	protected KFilterBase(Class dummy){super((Class) null);}
	/**	 \internal 		@short   \internal
	*/
	public static final int OK = 0;
	public static final int END = 1;
	public static final int ERROR = 2;

	public native TQMetaObject metaObject();
	public native String className();
	/**
		 Sets the device on which the filter will work
			@param dev the device on which the filter will work
			@param autodelete if true, <code>dev</code> is deleted when the filter is deleted
		     		@short    Sets the device on which the filter will work
	*/
	public native void setDevice(TQIODeviceInterface dev, boolean autodelete);
	public native void setDevice(TQIODeviceInterface dev);
	/**
		 Returns the device on which the filter will work.
				@return the device on which the filter will work

		@short    Returns the device on which the filter will work.
	*/
	public native TQIODeviceInterface device();
	/**	 \internal 		@short   \internal
	*/
	public native void init(int mode);
	/**	 \internal 		@short   \internal
	*/
	public native int mode();
	/**	 \internal 		@short   \internal
	*/
	public native void terminate();
	/**	 \internal 		@short   \internal
	*/
	public native void reset();
	/**	 \internal 		@short   \internal
	*/
	public native boolean readHeader();
	/**	 \internal 		@short   \internal
	*/
	public native boolean writeHeader(String filename);
	/**	 \internal 		@short   \internal
	*/
	public native void setOutBuffer(String data, int maxlen);
	/**	 \internal 		@short   \internal
	*/
	public native void setInBuffer(String data, int size);
	/**	 \internal 		@short   \internal
	*/
	public native boolean inBufferEmpty();
	/**	 \internal 		@short   \internal
	*/
	public native int inBufferAvailable();
	/**	 \internal 		@short   \internal
	*/
	public native boolean outBufferFull();
	/**	 \internal 		@short   \internal
	*/
	public native int outBufferAvailable();
	/**	 \internal 		@short   \internal
	*/
	public native int uncompress();
	/**	 \internal 		@short   \internal
	*/
	public native int compress(boolean finish);
	/**
		 Call this to create the appropriate filter for the file
		 named <code>fileName.</code>
			@param fileName the name of the file to filter
				@return the filter for the <code>fileName</code>, or 0 if not found

		@short    Call this to create the appropriate filter for the file  named <code>fileName.</code>
	*/
	public static native KFilterBase findFilterByFileName(String fileName);
	/**
		 Call this to create the appropriate filter for the mimetype
		 <code>mimeType.</code> For instance application/x-gzip.
			@param mimeType the mime type of the file to filter
				@return the filter for the <code>mimeType</code>, or 0 if not found

		@short    Call this to create the appropriate filter for the mimetype  <code>mimeType.</code>
	*/
	public static native KFilterBase findFilterByMimeType(String mimeType);
}
