JavaScriptAction
Overview
JavaScriptAction is a class in Aspose.PDF FOSS for Java.
Inherits from: PdfAction.
JavaScript action — stores a JavaScript script (ISO 32000-1:2008, §12.6.4.16).
This class provides 8 methods for working with JavaScriptAction objects in Java programs.
Available methods include: JavaScriptAction, fromDictionary, getNext, getPdfDictionary, getScript, getType, setScript.
All public members are accessible to any Java application after installing the Aspose.PDF FOSS for Java package.
Properties: next, pdfDictionary, script, type.
Properties
| Name | Type | Access | Description |
|---|---|---|---|
script | String | Read | Returns the JavaScript source code. |
pdfDictionary | PdfDictionary | Read | Returns the underlying action dictionary. |
type | String | Read | Returns the action type (/S entry). |
next | PdfAction | Read | Returns the next action (/Next), if any. |
Methods
| Signature | Description |
|---|---|
JavaScriptAction(dict: PdfDictionary) | Parses a JavaScriptAction from an existing dictionary. |
JavaScriptAction(script: String) | Creates a JavaScriptAction with the given script. |
getScript() → String | Returns the JavaScript source code. |
setScript(script: String) | Sets the JavaScript source code (as a text string). |
getPdfDictionary() → PdfDictionary | Returns the underlying action dictionary. |
getType() → String | Returns the action type (/S entry). |
getNext() → PdfAction | Returns the next action (/Next), if any. |
fromDictionary(dict: PdfDictionary, doc: Document) → PdfAction | Factory: creates the appropriate PdfAction subclass from a dictionary. |