Class PdfUA2AnnotationChecker
- java.lang.Object
-
- com.itextpdf.pdfua.checkers.utils.ua2.PdfUA2AnnotationChecker
-
public final class PdfUA2AnnotationChecker extends java.lang.Object
Class that provides methods for checking PDF/UA-2 compliance of annotations.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
PdfUA2AnnotationChecker.PdfUA2AnnotationHandler
Handler for checking annotation elements in the tag tree.
-
Field Summary
Fields Modifier and Type Field Description private static java.util.Set<PdfName>
markupAnnotationTypes
-
Constructor Summary
Constructors Modifier Constructor Description private
PdfUA2AnnotationChecker()
Creates a new instance of thePdfUA2AnnotationChecker
.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description (package private) static void
checkAnnotation(PdfDictionary annotation, PdfStructElem parent)
Checks PDF/UA-2 compliance of the annotation.static void
checkAnnotation(PdfDictionary annotation, PdfUAValidationContext context)
Checks PDF/UA-2 compliance of the annotation.private static void
checkAnnotationFlags(PdfDictionary annotation)
static void
checkAnnotations(PdfDocument pdfDocument)
Checks PDF/UA-2 compliance of the annotations.private static void
checkMarkupAnnotations(PdfDictionary annotation, PdfName parentRole)
Checks the PDF/UA-2 8.9.2.3 Markup annotations requirements.(package private) static java.lang.String
getRichTextStringValue(PdfObject rv)
private static java.lang.String
parseRichText(org.w3c.dom.Node node)
-
-
-
Field Detail
-
markupAnnotationTypes
private static final java.util.Set<PdfName> markupAnnotationTypes
-
-
Constructor Detail
-
PdfUA2AnnotationChecker
private PdfUA2AnnotationChecker()
Creates a new instance of thePdfUA2AnnotationChecker
.
-
-
Method Detail
-
checkAnnotations
public static void checkAnnotations(PdfDocument pdfDocument)
Checks PDF/UA-2 compliance of the annotations.- Parameters:
pdfDocument
-PdfDocument
to check annotations for
-
checkAnnotation
public static void checkAnnotation(PdfDictionary annotation, PdfUAValidationContext context)
Checks PDF/UA-2 compliance of the annotation.- Parameters:
annotation
- the annotation dictionary to checkcontext
-PdfUAValidationContext
used to find the structure node enclosing the annotation using itsStructParent
value
-
checkAnnotation
static void checkAnnotation(PdfDictionary annotation, PdfStructElem parent)
Checks PDF/UA-2 compliance of the annotation.- Parameters:
annotation
- the annotation dictionary to checkparent
- the parent structure element
-
checkMarkupAnnotations
private static void checkMarkupAnnotations(PdfDictionary annotation, PdfName parentRole)
Checks the PDF/UA-2 8.9.2.3 Markup annotations requirements.- Parameters:
annotation
- the markup annotationsparentRole
- the parent role
-
getRichTextStringValue
static java.lang.String getRichTextStringValue(PdfObject rv)
-
parseRichText
private static java.lang.String parseRichText(org.w3c.dom.Node node)
-
checkAnnotationFlags
private static void checkAnnotationFlags(PdfDictionary annotation)
-
-