Class LineAnnotationValidator
- java.lang.Object
-
- org.apache.pdfbox.preflight.annotation.AnnotationValidator
-
- org.apache.pdfbox.preflight.annotation.LineAnnotationValidator
-
public class LineAnnotationValidator extends AnnotationValidator
Validation class for the LineAnnotation
-
-
Field Summary
Fields Modifier and Type Field Description protected PDAnnotationLinepdLinePDFBox object which wraps the annotation dictionary-
Fields inherited from class org.apache.pdfbox.preflight.annotation.AnnotationValidator
annotDictionary, ctx, pdAnnot
-
-
Constructor Summary
Constructors Constructor Description LineAnnotationValidator(PreflightContext ctx, COSDictionary annotDictionary)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected booleancheckIColors()Return true if the IC field is present in the Annotation dictionary and if the RGB profile is used in the DestOutputProfile of the OutputIntent dictionary.protected booleancheckSpecificMandatoryFields()Override this method to check the presence of specific fieldsbooleanvalidate()In addition of the AnnotationValidator.validate() method, this method executes the checkIColors method.-
Methods inherited from class org.apache.pdfbox.preflight.annotation.AnnotationValidator
checkActions, checkAP, checkCA, checkColors, checkFlags, checkMandatoryFields, checkPopup, searchRGBProfile, setFactory
-
-
-
-
Field Detail
-
pdLine
protected PDAnnotationLine pdLine
PDFBox object which wraps the annotation dictionary
-
-
Constructor Detail
-
LineAnnotationValidator
public LineAnnotationValidator(PreflightContext ctx, COSDictionary annotDictionary)
-
-
Method Detail
-
validate
public boolean validate() throws ValidationExceptionIn addition of the AnnotationValidator.validate() method, this method executes the checkIColors method.- Overrides:
validatein classAnnotationValidator- Returns:
- true if validation succeed, false otherwise.
- Throws:
ValidationException- See Also:
AnnotationValidator.validate()
-
checkIColors
protected boolean checkIColors() throws ValidationExceptionReturn true if the IC field is present in the Annotation dictionary and if the RGB profile is used in the DestOutputProfile of the OutputIntent dictionary.- Returns:
- the state of the IC field validation.
- Throws:
ValidationException
-
checkSpecificMandatoryFields
protected boolean checkSpecificMandatoryFields()
Description copied from class:AnnotationValidatorOverride this method to check the presence of specific fields- Overrides:
checkSpecificMandatoryFieldsin classAnnotationValidator- Returns:
- the presence of specific fields.
-
-