|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.qoppa.pdf.errors.PDFErrorHandling
public class PDFErrorHandling
This class is used to set different error handling options within the PDF library. With the methods in this class, the host application can tell the library whether to display an error in the rendering of a page or to abort the entire rendering operation. Additionally, The class has methods for the library to keep track of errors and for the host application to get the list of errors in the last rendering operation.
| Field Summary | |
|---|---|
static int |
EH_ABORT_RENDERING
Abort the entire rendering operation and throw an exception to the host application. |
static int |
EH_SHOW_ERROR_AND_CONTINUE
Display the error in the rendering of the page and continue rendering other pages. |
| Constructor Summary | |
|---|---|
PDFErrorHandling()
|
|
| Method Summary | |
|---|---|
static void |
addError(RenderError error)
Add an error to the list of errors accumulated. |
static void |
addError(Throwable t,
String prefixMsg)
Add an error to the list of errors accumulated. |
static void |
checkForErrors_UsePDFException(String errorMsg)
This is a convenience method that gets called by the library after a rendering. |
static void |
checkForErrors_UsePrinterException(String errorMsg)
This is a convenience method that gets called by the library after printing a page. |
static void |
clearErrors()
Clear any errors that have accumulated from previous pages. |
static int |
getErrorHandling()
Returns the current value of the error handling flag. |
static Vector |
getErrors()
Gets a list of errors in the last rendering. |
static boolean |
isThrowXFADynamicException()
Returns the value of the flag that controls whether or not an exception is thrown when trying to build a document with an AcroForm that has Adobe XML Forms Architecture (XFA) data, and is a Dynamic Form. |
static boolean |
isUseSubstituteFont()
Returns the value of the flag that controls font handling errors. |
static void |
setErrorHandling(int errorHandling)
Sets the value of the error handling flag. |
static void |
setThrowXFADynamicException(boolean throwDynamicXFAException)
When the flag is set to true (the default), the library will throw an error if the document being built has an AcroForm that has Adobe XML Forms Architecture (XFA) data, and is a Dynamic Form. |
static void |
setUseSubstituteFont(boolean useSubstituteFont)
Use substitute fonts when there is an error. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int EH_SHOW_ERROR_AND_CONTINUE
public static final int EH_ABORT_RENDERING
| Constructor Detail |
|---|
public PDFErrorHandling()
| Method Detail |
|---|
public static void clearErrors()
public static void addError(RenderError error)
error - The error.
public static void addError(Throwable t,
String prefixMsg)
t - The exception that was thrown.prefixMsg - A message to prefix to error string.public static Vector getErrors()
public static void checkForErrors_UsePrinterException(String errorMsg)
throws PrinterException
errorMsg - The error message to use in the PrinterException.
PrinterException
public static void checkForErrors_UsePDFException(String errorMsg)
throws PDFException
errorMsg - The error message to use in the PDFException.
PDFExceptionpublic static int getErrorHandling()
public static void setErrorHandling(int errorHandling)
errorHandling - The new value of the error handling flag.public static boolean isUseSubstituteFont()
public static void setUseSubstituteFont(boolean useSubstituteFont)
useSubstituteFont - The new value of the flag.public static boolean isThrowXFADynamicException()
public static void setThrowXFADynamicException(boolean throwDynamicXFAException)
throwDynamicXFAException - The new value of the flag.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||