com.qoppa.preflight.results
Interface PreflightResults


public interface PreflightResults

Interface representing the results of a preflight operation on a document. The results contain information about the document, the preflight run and a list of ResultRecord objects that detail each issue found in the document. Also provides various forms of processing the results that include adding the results as annotations the the document, saving the results as a report, and appending the report to the document that was preflighted.

Author:
Qoppa Software

Method Summary
 void addResultAnnotations()
          Adds the ResultRecords as Annotations to the document that was preflighted.
 void appendPreflightReport(Dimension pageSize)
          Appends the Preflight report to the document that was preflighted.
 void echoResults()
          Echoes the result records to the console.
 void echoResults(PrintStream out)
          Echos the result records to a given print stream.
 DocumentInfo getDocumentInfo()
          Gets the information for the document that was preflighted.
 PreflightInfo getPFInfo()
          Returns a PreflightInfo object that holds information about the preflight run that created this results.
 Vector getResults()
          Gets a list of result records.
 boolean isSuccessful()
          Returns a boolean value indicating whether the document that was preflighted successfully passed the given Profile specification.
 void savePreflightReport(OutputStream outStream, Dimension pageSize)
          Saves a Preflight report as a PDF document to the OutputStream.
 void savePreflightReport(String fileName, Dimension pageSize)
          Saves this document to a file.
 

Method Detail

getResults

public Vector getResults()
Gets a list of result records. Objects in the list are of type ResultRecord.

Returns:
A list of result records.

echoResults

public void echoResults()
Echoes the result records to the console.


echoResults

public void echoResults(PrintStream out)
Echos the result records to a given print stream.

Parameters:
out - The output print stream to echo the results to.

getPFInfo

public PreflightInfo getPFInfo()
Returns a PreflightInfo object that holds information about the preflight run that created this results.

Returns:
A PreflightInfo object that provides information about the preflight engine.

getDocumentInfo

public DocumentInfo getDocumentInfo()
Gets the information for the document that was preflighted.

Returns:
The document information object.

isSuccessful

public boolean isSuccessful()
Returns a boolean value indicating whether the document that was preflighted successfully passed the given Profile specification.

Returns:
A boolean indicating the success of the preflight execution.

addResultAnnotations

public void addResultAnnotations()
                          throws PDFException
Adds the ResultRecords as Annotations to the document that was preflighted.

Throws:
PDFException

appendPreflightReport

public void appendPreflightReport(Dimension pageSize)
                           throws PDFException,
                                  IOException
Appends the Preflight report to the document that was preflighted.

Parameters:
pageSize - Dimension of the report document pages in 72dpi. For example, an 8.5 in x 11 in report document would be expressed as a Dimension with a width of 612 and a height of 792.
Throws:
IOException
PDFException

savePreflightReport

public void savePreflightReport(OutputStream outStream,
                                Dimension pageSize)
                         throws PDFException,
                                IOException
Saves a Preflight report as a PDF document to the OutputStream.

Parameters:
outStream - OutputStream where the report document will be written to.
pageSize - Dimension of the report document pages in 72dpi. For example, an 8.5 in x 11 in report document would be expressed as a Dimension with a width of 612 and a height of 792.
Throws:
IOException
PDFException

savePreflightReport

public void savePreflightReport(String fileName,
                                Dimension pageSize)
                         throws PDFException,
                                IOException
Saves this document to a file.

Parameters:
fileName - Name of the file to save the document.
pageSize - Dimension of the report document pages in 72dpi. For example, an 8.5 in x 11 in report document would be expressed as a Dimension with a width of 612 and a height of 792.
Throws:
IOException
PDFException