public class DigestGenerator
extends java.lang.Object
implements java.lang.Runnable
Modifier and Type | Field and Description |
---|---|
protected com.lf.commons.task.BackgroundTask |
bgTask
The associated background task, may be
null . |
protected byte[] |
buffer
The buffer for reading.
|
protected int |
calculatedCount
Number of calculated digests since targets may be ignored.
|
protected long |
calculatedLength
Overall file/URL size processed so far.
|
protected boolean |
checkBoxAbsPath
A generate option (required).
|
protected boolean |
checkBoxBSDDir
A generate option (required).
|
protected boolean |
checkBoxBSDTarget
A generate option (required).
|
protected boolean |
checkBoxGNUDir
A generate option (required).
|
protected boolean |
checkBoxGNUTarget
A generate option (required).
|
protected boolean |
checkBoxIgnoreDigests
A generate option (required).
|
protected boolean |
checkBoxMD2
A generate option (required).
|
protected boolean |
checkBoxMD4
A generate option (required).
|
protected boolean |
checkBoxMD5
A generate option (required).
|
protected boolean |
checkBoxOverwrite
A generate option (required).
|
protected boolean |
checkBoxPGPTarget
A generate option (required).
|
protected boolean |
checkBoxRefreshIgnoreMissing
A generate option (required).
|
protected boolean |
checkBoxRefreshRemoveArtifacts
A generate option (required).
|
protected boolean |
checkBoxRefreshRemoveOther
A generate option (required).
|
protected boolean |
checkBoxResults
A generate option (required).
|
protected boolean |
checkBoxRIPEMD128
A generate option (required).
|
protected boolean |
checkBoxRIPEMD160
A generate option (required).
|
protected boolean |
checkBoxRIPEMD256
A generate option (required).
|
protected boolean |
checkBoxRIPEMD320
A generate option (required).
|
protected boolean |
checkBoxSHA1
A generate option (required).
|
protected boolean |
checkBoxSHA224
A generate option (required).
|
protected boolean |
checkBoxSHA256
A generate option (required).
|
protected boolean |
checkBoxSHA384
A generate option (required).
|
protected boolean |
checkBoxSHA512
A generate option (required).
|
protected boolean |
checkBoxSkipEntrySizeXML
A generate option (required).
|
protected boolean |
checkBoxSkipEntryTimestampXML
A generate option (required).
|
protected boolean |
checkBoxSkipTimestampGNUBSD
A generate option (required).
|
protected boolean |
checkBoxSkipTimestampPGP
A generate option (required).
|
protected boolean |
checkBoxSkipTimestampXML
A generate option (required).
|
protected boolean |
checkBoxSubdirs
A generate option (required).
|
protected boolean |
checkBoxTiger
A generate option (required).
|
protected boolean |
checkBoxTimestamp
A generate option (required).
|
protected boolean |
checkBoxURL
A generate option (required).
|
protected boolean |
checkBoxWhirlpool
A generate option (required).
|
protected boolean |
checkBoxXMLDir
A generate option (required).
|
protected boolean |
checkBoxXMLPGP
A generate option (required).
|
protected boolean |
checkBoxXMLPGPeMail
A generate option (required).
|
protected boolean |
checkBoxXMLPGPID
A generate option (required).
|
protected boolean |
checkBoxXMLPGPName
A generate option (required).
|
protected boolean |
checkBoxXMLPGPURL
A generate option (required).
|
protected boolean |
checkBoxXMLTarget
A generate option (required).
|
protected java.util.Vector<java.lang.String> |
checkextensions
Pre-processed
CheckOptionsWindow extensions. |
protected com.lf.commons.config.Configuration |
checkoptions
The check options from
CheckOptionsWindow . |
protected java.lang.String |
comboBoxDigestFormat
A generate option (required).
|
protected java.lang.String |
comboBoxExpStarting
A generate option (required).
|
protected java.lang.String |
comboBoxHexCase
A generate option (required).
|
protected com.lf.commons.crypto.CryptoManager |
cryptoManager
A generate option (optional).
|
protected int |
expMax
Maximum number of intermediate digests.
|
protected long |
expStarting
Create intermediate digest starting from 2 pow (s+n), n=0,1,2,...
|
protected boolean |
failonerror
Stop working if an error occurs?
|
protected com.lf.commons.docking.filesys.FileSystemWindow |
fswindow
The parental component.
|
protected int |
intermediateCount
Number of intermediate digests.
|
protected long |
linearBytes
Create intermediate digest every n bytes.
|
protected int |
linearMax
Maximum number of intermediate digests.
|
protected long |
maxurlsize
The maximum size to add URLs to cache.
|
protected com.lf.commons.config.Configuration |
options
The generate options from
GenerateOptionsWindow (required). |
protected boolean |
radioButtonExponential
A generate option (required).
|
protected boolean |
radioButtonFiles
A generate option (required).
|
protected boolean |
radioButtonLinear
A generate option (required).
|
protected boolean |
radioButtonPGPASCII
A generate option (required).
|
protected boolean |
radioButtonPGPBinary
A generate option (required).
|
protected boolean |
radioButtonRefreshAllFormats
A generate option (required).
|
protected boolean |
radioButtonRefreshWriteFormats
A generate option (required).
|
protected boolean |
refresh
Refresh only?
|
protected com.lf.commons.docking.tabbed.TabbedWindow |
resultsWindow
The docking window for generation results.
|
protected com.didisoft.pgp.KeyPairInformation[] |
signKeys
A generate option (optional).
|
protected java.util.Hashtable<java.lang.String,java.lang.String> |
signKeyURLs
A generate option (optional).
|
protected java.io.File[] |
targetFiles
The actively selected entries to be calculated (required).
|
protected org.apache.commons.vfs2.FileObject[] |
targetURLs
The URLs to be downloaded and checked (optional).
|
protected java.lang.String |
templateID
The identifier for the processed template (required).
|
protected java.lang.String |
textFieldExpMax
A generate option (required).
|
protected java.lang.String |
textFieldIgnore
A generate option (required).
|
protected java.lang.String |
textFieldInclude
A generate option (required).
|
protected java.lang.String |
textFieldLinearBytes
A generate option (required).
|
protected java.lang.String |
textFieldLinearMax
A generate option (required).
|
protected java.lang.String |
textFieldMD2
A generate option (required).
|
protected java.lang.String |
textFieldMD4
A generate option (required).
|
protected java.lang.String |
textFieldMD5
A generate option (required).
|
protected java.lang.String |
textFieldPGPExtension
A generate option (required).
|
protected java.lang.String |
textFieldPGPVersion
A generate option (required).
|
protected java.lang.String |
textFieldRIPEMD128
A generate option (required).
|
protected java.lang.String |
textFieldRIPEMD160
A generate option (required).
|
protected java.lang.String |
textFieldRIPEMD256
A generate option (required).
|
protected java.lang.String |
textFieldRIPEMD320
A generate option (required).
|
protected java.lang.String |
textFieldSHA1
A generate option (required).
|
protected java.lang.String |
textFieldSHA224
A generate option (required).
|
protected java.lang.String |
textFieldSHA256
A generate option (required).
|
protected java.lang.String |
textFieldSHA384
A generate option (required).
|
protected java.lang.String |
textFieldSHA512
A generate option (required).
|
protected java.lang.String |
textFieldSummary
A generate option (required).
|
protected java.lang.String |
textFieldTiger
A generate option (required).
|
protected java.lang.String |
textFieldURL
A generate option (required).
|
protected java.lang.String |
textFieldWhirlpool
A generate option (required).
|
protected java.lang.String |
textFieldXMLComment
A generate option (required).
|
protected java.lang.String |
textFieldXMLExtension
A generate option (required).
|
protected long |
totalLengthFiles
Overall file size in bytes that must be processed.
|
protected long |
totalLengthURLs
Overall URL size in bytes that must be processed.
|
protected java.util.TreeMap<org.apache.commons.vfs2.FileObject,byte[]> |
urlcache
The cache for digest file contents (optional).
|
protected boolean |
verbose
Create verbose messages?
|
protected com.lf.vfslib.net.VFSConnection |
vfsConn
The parental component.
|
protected com.lf.commons.docking.vfs.VFSSessionWindow |
vfswindow
The parental component.
|
protected int |
writtenCountFiles
Number of written digest files since targets may be ignored.
|
protected int |
writtenCountURLs
Number of written URL files since targets may be ignored.
|
Constructor and Description |
---|
DigestGenerator()
The constructor method for the generator.
|
Modifier and Type | Method and Description |
---|---|
static com.lf.commons.task.BackgroundTask |
createBackgroundTask(javax.swing.Icon icon,
java.io.File[] targetfiles,
java.lang.String templateid,
com.lf.commons.config.Configuration options,
com.lf.commons.docking.tabbed.TabbedWindow results,
com.lf.commons.docking.filesys.FileSystemWindow fswindow,
boolean logmessages,
boolean failonerror,
boolean refresh,
com.lf.commons.config.Configuration checkoptions,
org.apache.commons.vfs2.FileObject[] targeturls,
java.util.TreeMap<org.apache.commons.vfs2.FileObject,byte[]> urlcache,
long maxurlsize,
com.lf.commons.docking.vfs.VFSSessionWindow vfswindow,
com.didisoft.pgp.KeyPairInformation[] signkeys,
java.util.Hashtable<java.lang.String,java.lang.String> signkeyurls,
com.lf.commons.crypto.CryptoManager cryptomanager,
com.lf.vfslib.net.VFSConnection vfsconn)
Convenience method to get a pre-configured background task.
|
protected void |
finalize()
Clean-up method to help the gc.
|
void |
run()
Execution code.
|
protected com.lf.commons.task.BackgroundTask bgTask
null
.protected java.io.File[] targetFiles
protected java.lang.String templateID
protected org.apache.commons.vfs2.FileObject[] targetURLs
protected com.lf.commons.config.Configuration options
GenerateOptionsWindow
(required).protected com.lf.commons.config.Configuration checkoptions
CheckOptionsWindow
.protected java.util.Vector<java.lang.String> checkextensions
CheckOptionsWindow
extensions.protected com.lf.commons.docking.tabbed.TabbedWindow resultsWindow
protected com.lf.commons.docking.filesys.FileSystemWindow fswindow
protected com.lf.commons.docking.vfs.VFSSessionWindow vfswindow
protected com.lf.vfslib.net.VFSConnection vfsConn
protected byte[] buffer
protected int calculatedCount
protected int writtenCountFiles
protected int writtenCountURLs
protected long totalLengthFiles
protected long totalLengthURLs
protected long calculatedLength
protected int intermediateCount
protected long linearBytes
protected int linearMax
protected long expStarting
protected int expMax
protected boolean verbose
protected boolean failonerror
protected boolean refresh
protected java.util.TreeMap<org.apache.commons.vfs2.FileObject,byte[]> urlcache
protected long maxurlsize
protected boolean checkBoxMD2
protected boolean checkBoxMD4
protected boolean checkBoxMD5
protected boolean checkBoxRIPEMD128
protected boolean checkBoxRIPEMD160
protected boolean checkBoxRIPEMD256
protected boolean checkBoxRIPEMD320
protected boolean checkBoxSHA1
protected boolean checkBoxSHA224
protected boolean checkBoxSHA256
protected boolean checkBoxSHA384
protected boolean checkBoxSHA512
protected boolean checkBoxTiger
protected boolean checkBoxWhirlpool
protected java.lang.String textFieldMD2
protected java.lang.String textFieldMD4
protected java.lang.String textFieldMD5
protected java.lang.String textFieldRIPEMD128
protected java.lang.String textFieldRIPEMD160
protected java.lang.String textFieldRIPEMD256
protected java.lang.String textFieldRIPEMD320
protected java.lang.String textFieldSHA1
protected java.lang.String textFieldSHA224
protected java.lang.String textFieldSHA256
protected java.lang.String textFieldSHA384
protected java.lang.String textFieldSHA512
protected java.lang.String textFieldTiger
protected java.lang.String textFieldWhirlpool
protected java.lang.String comboBoxHexCase
protected boolean radioButtonFiles
protected boolean checkBoxGNUTarget
protected boolean checkBoxGNUDir
protected boolean checkBoxBSDTarget
protected boolean checkBoxBSDDir
protected boolean checkBoxPGPTarget
protected boolean checkBoxXMLTarget
protected boolean checkBoxXMLDir
protected boolean checkBoxOverwrite
protected boolean checkBoxTimestamp
protected boolean checkBoxResults
protected java.lang.String textFieldXMLExtension
protected java.lang.String textFieldXMLComment
protected java.lang.String textFieldSummary
protected java.lang.String comboBoxDigestFormat
protected java.lang.String textFieldInclude
protected java.lang.String textFieldIgnore
protected boolean checkBoxIgnoreDigests
protected boolean checkBoxSubdirs
protected boolean radioButtonPGPASCII
protected boolean radioButtonPGPBinary
protected java.lang.String textFieldPGPExtension
protected java.lang.String textFieldPGPVersion
protected com.didisoft.pgp.KeyPairInformation[] signKeys
protected java.util.Hashtable<java.lang.String,java.lang.String> signKeyURLs
protected com.lf.commons.crypto.CryptoManager cryptoManager
protected boolean checkBoxAbsPath
protected boolean checkBoxURL
protected java.lang.String textFieldURL
protected boolean checkBoxXMLPGP
protected boolean checkBoxXMLPGPID
protected boolean checkBoxXMLPGPName
protected boolean checkBoxXMLPGPeMail
protected boolean checkBoxXMLPGPURL
protected boolean radioButtonLinear
protected boolean radioButtonExponential
protected java.lang.String textFieldLinearBytes
protected java.lang.String textFieldLinearMax
protected java.lang.String comboBoxExpStarting
protected java.lang.String textFieldExpMax
protected boolean radioButtonRefreshWriteFormats
protected boolean radioButtonRefreshAllFormats
protected boolean checkBoxRefreshRemoveOther
protected boolean checkBoxRefreshRemoveArtifacts
protected boolean checkBoxRefreshIgnoreMissing
protected boolean checkBoxSkipTimestampGNUBSD
protected boolean checkBoxSkipTimestampPGP
protected boolean checkBoxSkipTimestampXML
protected boolean checkBoxSkipEntrySizeXML
protected boolean checkBoxSkipEntryTimestampXML
public DigestGenerator()
protected void finalize() throws java.lang.Throwable
finalize
in class java.lang.Object
java.lang.Throwable
- Error indicationpublic void run()
run
in interface java.lang.Runnable
public static com.lf.commons.task.BackgroundTask createBackgroundTask(javax.swing.Icon icon, java.io.File[] targetfiles, java.lang.String templateid, com.lf.commons.config.Configuration options, com.lf.commons.docking.tabbed.TabbedWindow results, com.lf.commons.docking.filesys.FileSystemWindow fswindow, boolean logmessages, boolean failonerror, boolean refresh, com.lf.commons.config.Configuration checkoptions, org.apache.commons.vfs2.FileObject[] targeturls, java.util.TreeMap<org.apache.commons.vfs2.FileObject,byte[]> urlcache, long maxurlsize, com.lf.commons.docking.vfs.VFSSessionWindow vfswindow, com.didisoft.pgp.KeyPairInformation[] signkeys, java.util.Hashtable<java.lang.String,java.lang.String> signkeyurls, com.lf.commons.crypto.CryptoManager cryptomanager, com.lf.vfslib.net.VFSConnection vfsconn)
icon
- The icon representing the tasktargetfiles
- The actively selected entriestemplateid
- The name of the templateoptions
- The generate options from GenerateOptionsWindow
results
- The docking window for generation resultsfswindow
- The parental component (optional)logmessages
- Shall messages be logged sequentially (optional)?failonerror
- Stop on errors (Ant task)?refresh
- Refresh only?checkoptions
- The check options from CheckOptionsWindow
targeturls
- The URLs to be checkedurlcache
- The cache for digest file contents (optional)maxurlsize
- The maximum size for URLs to be cachedvfswindow
- The parental component (optional)signkeys
- The PGP keys to create signatures (optional)signkeyurls
- The PGP key URLs (optional)cryptomanager
- The crypto manager (optional)vfsconn
- The connection to use (optional)Copyright © 2005-2015 Leisenfels UG. All rights reserved.