org.icepdf.ri.common.utility.signatures
Class SigVerificationTask

java.lang.Object
  extended by org.icepdf.ri.common.utility.signatures.SigVerificationTask

public class SigVerificationTask
extends java.lang.Object

This class is a utility for verifying signature annotations off the AWT thread. The are two main sub classes VerifyAllSignatures and VerifySignature. The RI uses both of these methods for validating all signatures and refreshing an individual signature annotation state.


Constructor Summary
SigVerificationTask(SignaturesPanel signaturesPanel, SwingController controller, java.util.ResourceBundle messageBundle)
          Creates a new instance of the SigVerificationTask.
 
Method Summary
 int getCurrent()
          Gets the signature number that is currently being validated by this task.
 int getLengthOfTask()
          Number of signatures that has tobe validated.
 java.lang.String getMessage()
          Returns the most recent dialog message, or null if there is no current dialog message.
 boolean isCurrentlyVerifying()
           
 boolean isDone()
          Find out if the task has completed.
 void stop()
          Stop the task.
 void verifyAllSignatures()
          Start the task, start verifying all the signatures annotations.
 void verifySignature(org.icepdf.core.pobjects.annotations.SignatureWidgetAnnotation signatureWidgetAnnotation, SignatureTreeNode signatureTreeNode)
          Start the task, verify the specified signature annotation.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SigVerificationTask

public SigVerificationTask(SignaturesPanel signaturesPanel,
                           SwingController controller,
                           java.util.ResourceBundle messageBundle)
Creates a new instance of the SigVerificationTask.

Parameters:
signaturesPanel - parent signature panel that start this task via an action
controller - root controller object
messageBundle - message bundle used for dialog text.
Method Detail

verifyAllSignatures

public void verifyAllSignatures()
Start the task, start verifying all the signatures annotations.


verifySignature

public void verifySignature(org.icepdf.core.pobjects.annotations.SignatureWidgetAnnotation signatureWidgetAnnotation,
                            SignatureTreeNode signatureTreeNode)
Start the task, verify the specified signature annotation.


getLengthOfTask

public int getLengthOfTask()
Number of signatures that has tobe validated.

Returns:
returns max number of signatures that need validation.

getCurrent

public int getCurrent()
Gets the signature number that is currently being validated by this task.

Returns:
current page being processed.

stop

public void stop()
Stop the task.


isDone

public boolean isDone()
Find out if the task has completed.

Returns:
true if task is done, false otherwise.

isCurrentlyVerifying

public boolean isCurrentlyVerifying()

getMessage

public java.lang.String getMessage()
Returns the most recent dialog message, or null if there is no current dialog message.

Returns:
current message dialog text.