Package com.itextpdf.layout.tagging
Class TaggingDummyElement
- java.lang.Object
-
- com.itextpdf.layout.tagging.TaggingDummyElement
-
- All Implemented Interfaces:
IPropertyContainer,IAccessibleElement
public class TaggingDummyElement extends java.lang.Object implements IAccessibleElement, IPropertyContainer
Instances of the class are used forTaggingHintKeywhich don't have model element e.g. TR or THEAD in the table. Nobody will callLayoutTaggingHelper.finishTaggingHint(IPropertyContainer)for them, it is why they should be handled separately.
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.Objectidprivate DefaultAccessibilityPropertiesproperties
-
Constructor Summary
Constructors Constructor Description TaggingDummyElement(java.lang.String role)Instantiate a newTaggingDummyElementinstance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddeleteOwnProperty(int property)Deletes the own property of this entity.AccessibilityPropertiesgetAccessibilityProperties()Gets theaccessibility properties.<T1> T1getDefaultProperty(int property)Gets the default property from this entity.<T1> T1getOwnProperty(int property)Gets own property from this entity.<T1> T1getProperty(int property)Gets the property from this entity.booleanhasOwnProperty(int property)Checks if this entity has the specified property, i.e.booleanhasProperty(int property)Checks if this entity has the specified property.voidsetProperty(int property, java.lang.Object value)Sets a property for this entity.
-
-
-
Field Detail
-
properties
private DefaultAccessibilityProperties properties
-
id
private java.lang.Object id
-
-
Constructor Detail
-
TaggingDummyElement
public TaggingDummyElement(java.lang.String role)
Instantiate a newTaggingDummyElementinstance.- Parameters:
role- the role.
-
-
Method Detail
-
getAccessibilityProperties
public AccessibilityProperties getAccessibilityProperties()
Gets theaccessibility properties. See alsoIAccessibleElement.- Specified by:
getAccessibilityPropertiesin interfaceIAccessibleElement- Returns:
- an interface that allows to specify properties of a tagged element in Tagged PDF.
-
getProperty
public <T1> T1 getProperty(int property)
Gets the property from this entity. Compared toIPropertyContainer.getOwnProperty(int), this method can check parent's properties, styles, etc, depending on the origin of the instance- Specified by:
getPropertyin interfaceIPropertyContainer- Type Parameters:
T1- the return type associated with the property- Parameters:
property- the property to be retrieved- Returns:
- the value of the given property.
nullwill be returned if the property value was not found
-
setProperty
public void setProperty(int property, java.lang.Object value)Sets a property for this entity.- Specified by:
setPropertyin interfaceIPropertyContainer- Parameters:
property- the property to be setvalue- the value of the property
-
hasProperty
public boolean hasProperty(int property)
Checks if this entity has the specified property. Compared toIPropertyContainer.hasOwnProperty(int), this method can check parent's properties, styles, etc, depending on the origin of the instance- Specified by:
hasPropertyin interfaceIPropertyContainer- Parameters:
property- the property to be checked- Returns:
trueif this instance has given property,falseotherwise
-
hasOwnProperty
public boolean hasOwnProperty(int property)
Checks if this entity has the specified property, i.e. if it was set to this very element earlier- Specified by:
hasOwnPropertyin interfaceIPropertyContainer- Parameters:
property- the property to be checked- Returns:
trueif this instance has given own property,falseotherwise
-
getOwnProperty
public <T1> T1 getOwnProperty(int property)
Gets own property from this entity. The property must have been set earlier to this entity. If the property is not found,nullwill be returned.- Specified by:
getOwnPropertyin interfaceIPropertyContainer- Type Parameters:
T1- the return type associated with the property- Parameters:
property- the property to be retrieved- Returns:
- the value of the given own property.
nullwill be returned if the property value was not found
-
getDefaultProperty
public <T1> T1 getDefaultProperty(int property)
Gets the default property from this entity.- Specified by:
getDefaultPropertyin interfaceIPropertyContainer- Type Parameters:
T1- the return type associated with the property- Parameters:
property- the property to be retrieved- Returns:
- the default property value. If the default property is not defined,
nullwill be returned
-
deleteOwnProperty
public void deleteOwnProperty(int property)
Deletes the own property of this entity.- Specified by:
deleteOwnPropertyin interfaceIPropertyContainer- Parameters:
property- the property to be deleted
-
-