public interface CompoundExtractor
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
KEY_COMMENT
key for entry comment.
|
static java.lang.String |
KEY_COMPOUNDS
key for the compound list.
|
static java.lang.String |
KEY_COMPRESSED_SIZE
key for entry compressed size.
|
static java.lang.String |
KEY_FILE_NAME
key for entry name.
|
static java.lang.String |
KEY_IS_COMPOUND
key to mark compounds.
|
static java.lang.String |
KEY_IS_ROOT_COMPOUND_RECORD
key for the base compound record flag.
|
static java.lang.String |
KEY_SIZE
key for entry size.
|
static java.lang.String |
KEY_TIME
key for entry time.
|
Modifier and Type | Method and Description |
---|---|
boolean |
canExtract(java.io.File file)
Can the file be extracted by the CompoundExtractor service?
|
boolean |
canExtract(java.lang.String fileName,
java.lang.String mimeType)
Can the file be extracted by the CompoundExtractor service?
|
boolean |
canExtract(java.net.URL url,
java.lang.String mimeType)
Can the file be extracted by the CompoundExtractor service?
|
java.util.Iterator<Record> |
extract(java.io.InputStream compoundInputStream,
java.lang.String fileName,
java.lang.String contentAttachmentName)
Extract the compounds (recursively) and return an iterator over the resulting records that have been created from
the extracted compound.
|
java.util.Iterator<Record> |
extract(java.io.InputStream compoundInputStream,
java.lang.String fileName,
java.lang.String mimeType,
java.lang.String contentAttachmentName)
Extract the compounds (recursively) and return an iterator over the resulting records that have been created from
the extracted compound.
|
static final java.lang.String KEY_SIZE
static final java.lang.String KEY_TIME
static final java.lang.String KEY_COMPRESSED_SIZE
static final java.lang.String KEY_COMMENT
static final java.lang.String KEY_FILE_NAME
static final java.lang.String KEY_IS_COMPOUND
static final java.lang.String KEY_COMPOUNDS
static final java.lang.String KEY_IS_ROOT_COMPOUND_RECORD
boolean canExtract(java.io.File file)
true
result does not guarantee, that the file may be
extracted without any exceptions.file
- the file in question.true
if the given file can be extracted, false
if not.boolean canExtract(java.net.URL url, java.lang.String mimeType)
true
result does not
guarantee, that the file may be extracted without any exceptions.url
- URL in questionmimeType
- mimetype (if any could be determined)boolean canExtract(java.lang.String fileName, java.lang.String mimeType)
true
result does not
guarantee, that the file may be extracted without any exceptions.fileName
- the name of the file in question.mimeType
- mimetype (if any could be determined)java.util.Iterator<Record> extract(java.io.InputStream compoundInputStream, java.lang.String fileName, java.lang.String contentAttachmentName) throws CompoundExtractorException
compoundInputStream
- the input stream of the compound object.fileName
- the name of the file in question.contentAttachmentName
- name of attachment to store content of extracted elements in.CompoundExtractorException
- on errors while extracting the compound.java.util.Iterator<Record> extract(java.io.InputStream compoundInputStream, java.lang.String fileName, java.lang.String mimeType, java.lang.String contentAttachmentName) throws CompoundExtractorException
compoundInputStream
- the input stream of the compound object.fileName
- the name of the file in question.mimeType
- mimetype (if any could be determined)contentAttachmentName
- name of attachment to store content of extracted elements in.CompoundExtractorException
- on errors while extracting the compound.