Defines methods used to work with actions in PDF documents, some of which are named in the Adobe PDF Specification.
Initialize with string. Will parse action, set to
PSPDFNamedActionTypeUnknownif not recognized or nil.
- (nonnull instancetype)initWithActionNamedString: (nullable NSString *)actionNameString;
init(actionNamedString actionNameString: String?)
Returns the target page for certain named actions.
The named actions supported by this method are
lastPage. For other types this will return
NSNotFound. This also returns
NSNotFoundif the provided current page is out of bounds or if the target page would be out of bounds. This will not resolve the target page index for
goForwardactions because the navigation history is part of the UI rather than part of the model. It will return
- (PSPDFPageIndex)pageIndexWithCurrentPage:(PSPDFPageIndex)currentPage fromDocument:(nonnull PSPDFDocument *)document;
The target page, or
NSNotFoundif there is no target page.