Package com.itextpdf.kernel.pdf.tagutils
Class PdfAllowedTagRelations
java.lang.Object
com.itextpdf.kernel.pdf.tagutils.PdfAllowedTagRelations
This class defines the allowed parent-child relations for the PDF2.0 standard.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanisContentAllowedInRole(String parentRole) Checks if the given parent role allows content.booleanisRelationAllowed(String parentRole, String childRole) Checks if the given parent-child relation is allowed.normalizeRole(String role) Normalizes the role.
-
Field Details
-
NUMBERED_HEADER
- See Also:
-
ACTUAL_CONTENT
- See Also:
-
allowedParentChildRelations
-
-
Constructor Details
-
PdfAllowedTagRelations
public PdfAllowedTagRelations()Creates a new instance ofPdfAllowedTagRelations.
-
-
Method Details
-
isRelationAllowed
Checks if the given parent-child relation is allowed.- Parameters:
-
parentRole- The parent role. -
childRole- The child role. - Returns:
-
trueif the relation is allowed,falseotherwise.
-
isContentAllowedInRole
Checks if the given parent role allows content.- Parameters:
-
parentRole- The parent role. - Returns:
-
trueif the parent role allows content,falseotherwise.
-
normalizeRole
Normalizes the role.- Parameters:
-
role- The role to normalize. - Returns:
- The normalized role.
-