Class SequenceIdManager
- java.lang.Object
-
- com.itextpdf.commons.actions.sequence.SequenceIdManager
-
public final class SequenceIdManager extends java.lang.ObjectUtil class which is responsible for marking ofAbstractIdentifiableElementwith appropriateSequenceId.
-
-
Constructor Summary
Constructors Modifier Constructor Description privateSequenceIdManager()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static SequenceIdgetSequenceId(AbstractIdentifiableElement element)Gets an identifier of the element.static voidsetSequenceId(AbstractIdentifiableElement element, SequenceId sequenceId)Provides anAbstractIdentifiableElementwith aSequenceId.
-
-
-
Method Detail
-
setSequenceId
public static void setSequenceId(AbstractIdentifiableElement element, SequenceId sequenceId)
Provides anAbstractIdentifiableElementwith aSequenceId. Note that it is forbidden to override already existing identifier. If try to provide a new one then exception will be thrown.- Parameters:
element- is an identifiable elementsequenceId- is an identifier to set- Throws:
java.lang.IllegalStateException- if element already has an identifier
-
getSequenceId
public static SequenceId getSequenceId(AbstractIdentifiableElement element)
Gets an identifier of the element. If it was not provided will returnnull.- Parameters:
element- is an identifiable element- Returns:
- the identifier of the element if presented and
nullotherwise
-
-