Class MagicMimeTypeFileItem

java.lang.Object
org.hippoecm.frontend.plugins.yui.upload.MagicMimeTypeFileItem
All Implemented Interfaces:
org.apache.commons.fileupload2.core.FileItem<MagicMimeTypeFileItem>, org.apache.commons.fileupload2.core.FileItemHeadersProvider<MagicMimeTypeFileItem>

public class MagicMimeTypeFileItem extends Object implements org.apache.commons.fileupload2.core.FileItem<MagicMimeTypeFileItem>
A file item that resolves the mime-type using Apache Tika. It is named after content type detection based on magic bytes, i.e. type-specific patterns near the beginning of the document input stream, see Tika's MagicDetector. This class is a decorator for a FileItem. It also keeps track of the opening input/output streams to close them when the temporary file is deleted.