Foxit PDF SDK
com.foxit.sdk.addon.accessibility.AccessibilityChecker Class Reference
Inheritance diagram for com.foxit.sdk.addon.accessibility.AccessibilityChecker:
com.foxit.sdk.common.Base

Public Member Functions

 AccessibilityChecker (AccessibilityChecker other)
 Constructor, with another checker object.
More...
 
 AccessibilityChecker (PDFDoc pdf_doc) throws com.foxit.sdk.PDFException
 Constructor.
More...
 
boolean canCheck () throws com.foxit.sdk.PDFException
 Check whether the current PDF document can be full checked.
More...
 
AccessibilityCheckResultItemData changeCheckStateInResultTree (AccessibilityCheckResultItemData root_data, AccessibilityCheckResultSubItemData sub_item_data, int new_check_state) throws com.foxit.sdk.PDFException
 Change check state in result tree.
More...
 
synchronized void delete ()
 Clean up related C++ resources immediately. More...
 
String getTagTreeNodeIDByCheckResultItemID (int page_index, String item_id) throws com.foxit.sdk.PDFException
 Get tag tree node ID by check result item ID.
More...
 
boolean isEmpty ()
 Check whether current object is empty or not.
More...
 
AccessibilityCheckResultItemData recheckResult (AccessibilityCheckOptions check_options, AccessibilityCheckResultItemData root_data) throws com.foxit.sdk.PDFException
 Recheck by result root.
More...
 
AccessibilityCheckResultItemData recheckResult (AccessibilityCheckOptions check_options, AccessibilityCheckResultItemData root_data, AccessibilityCheckResultSubItemData sub_item_data) throws com.foxit.sdk.PDFException
 Recheck by sub item.
More...
 
AccessibilityCheckResultItemData removeSkippedStateInResultTree (AccessibilityCheckOptions check_options, AccessibilityCheckResultItemData root_data, AccessibilityCheckResultSubItemData sub_item_data) throws com.foxit.sdk.PDFException
 Remove skipped state in result tree.
More...
 
Progressive startCheck (AccessibilityCheckOptions check_options, StreamCallback report_callback, AccessibilityCheckResultsCallback provider, PauseCallback pause) throws com.foxit.sdk.PDFException
 Start check for accessibility.
More...
 
boolean updateCheckResultReport () throws com.foxit.sdk.PDFException
 Update check result report.
More...
 
boolean updateCheckState (int rule_type, int check_state) throws com.foxit.sdk.PDFException
 Update check state for a specified rule.
More...
 

Detailed Description

This class represents an accessibility checker for a PDF document: run the full accessibility check, re-check parts of the result tree, change / remove check states and update the check result report. Before using any class or methods in this module, please ensure Foxit PDF SDK has been initialized successfully by function common.Library.initialize with a key including "Accessibility" module.

See also
com.foxit.sdk.common.Library

Constructor & Destructor Documentation

◆ AccessibilityChecker() [1/2]

com.foxit.sdk.addon.accessibility.AccessibilityChecker.AccessibilityChecker ( PDFDoc  pdf_doc) throws com.foxit.sdk.PDFException

Constructor.

Parameters
[in]pdf_docA valid PDF document object.

◆ AccessibilityChecker() [2/2]

com.foxit.sdk.addon.accessibility.AccessibilityChecker.AccessibilityChecker ( AccessibilityChecker  other)

Constructor, with another checker object.

Parameters
[in]otherAnother checker object.

Member Function Documentation

◆ canCheck()

boolean com.foxit.sdk.addon.accessibility.AccessibilityChecker.canCheck ( ) throws com.foxit.sdk.PDFException

Check whether the current PDF document can be full checked.

Returns
true means the document can be full checked, while false means not.

◆ changeCheckStateInResultTree()

AccessibilityCheckResultItemData com.foxit.sdk.addon.accessibility.AccessibilityChecker.changeCheckStateInResultTree ( AccessibilityCheckResultItemData  root_data,
AccessibilityCheckResultSubItemData  sub_item_data,
int  new_check_state 
) throws com.foxit.sdk.PDFException

Change check state in result tree.

Parameters
[in]root_dataThe root data of check result tree.
[in]sub_item_dataThe sub item data.
[in]new_check_stateThe new check state.
Returns
The updated check result item data.

◆ delete()

synchronized void com.foxit.sdk.addon.accessibility.AccessibilityChecker.delete ( )

Clean up related C++ resources immediately.

Returns
None.
Note
Once this function is called, current object cannot be used anymore.

Reimplemented from com.foxit.sdk.common.Base.

◆ getTagTreeNodeIDByCheckResultItemID()

String com.foxit.sdk.addon.accessibility.AccessibilityChecker.getTagTreeNodeIDByCheckResultItemID ( int  page_index,
String  item_id 
) throws com.foxit.sdk.PDFException

Get tag tree node ID by check result item ID.

Parameters
[in]page_indexThe page index.
[in]item_idThe check result item ID.
Returns
The tag tree node ID.

◆ isEmpty()

boolean com.foxit.sdk.addon.accessibility.AccessibilityChecker.isEmpty ( )

Check whether current object is empty or not.

When the current object is empty, that means current object is useless.

Returns
true means current object is empty, while false means not.

◆ recheckResult() [1/2]

AccessibilityCheckResultItemData com.foxit.sdk.addon.accessibility.AccessibilityChecker.recheckResult ( AccessibilityCheckOptions  check_options,
AccessibilityCheckResultItemData  root_data 
) throws com.foxit.sdk.PDFException

Recheck by result root.

Parameters
[in]check_optionsThe check options.
[in]root_dataThe root data of check result tree.
Returns
The updated check result item data.

◆ recheckResult() [2/2]

AccessibilityCheckResultItemData com.foxit.sdk.addon.accessibility.AccessibilityChecker.recheckResult ( AccessibilityCheckOptions  check_options,
AccessibilityCheckResultItemData  root_data,
AccessibilityCheckResultSubItemData  sub_item_data 
) throws com.foxit.sdk.PDFException

Recheck by sub item.

Parameters
[in]check_optionsThe check options.
[in]root_dataThe root data of check result tree.
[in]sub_item_dataThe sub item data of check result tree.
Returns
The updated check result item data.

◆ removeSkippedStateInResultTree()

AccessibilityCheckResultItemData com.foxit.sdk.addon.accessibility.AccessibilityChecker.removeSkippedStateInResultTree ( AccessibilityCheckOptions  check_options,
AccessibilityCheckResultItemData  root_data,
AccessibilityCheckResultSubItemData  sub_item_data 
) throws com.foxit.sdk.PDFException

Remove skipped state in result tree.

Parameters
[in]check_optionsThe check options.
[in]root_dataThe root data of check result tree.
[in]sub_item_dataThe sub item data.
Returns
The updated check result item data.

◆ startCheck()

Progressive com.foxit.sdk.addon.accessibility.AccessibilityChecker.startCheck ( AccessibilityCheckOptions  check_options,
StreamCallback  report_callback,
AccessibilityCheckResultsCallback  provider,
PauseCallback  pause 
) throws com.foxit.sdk.PDFException

Start check for accessibility.

Parameters
[in]check_optionsThe check options. Please refer to AccessibilityCheckOptions .
[in]report_callbackA stream callback object for report output. This can be null.
[in]providerAn AccessibilityCheckResultsCallback object for check results.
[in]pauseA pause object. This can be null.
Returns
A progressive object.

◆ updateCheckResultReport()

boolean com.foxit.sdk.addon.accessibility.AccessibilityChecker.updateCheckResultReport ( ) throws com.foxit.sdk.PDFException

Update check result report.

Returns
true means success, while false means not.

◆ updateCheckState()

boolean com.foxit.sdk.addon.accessibility.AccessibilityChecker.updateCheckState ( int  rule_type,
int  check_state 
) throws com.foxit.sdk.PDFException

Update check state for a specified rule.

Parameters
[in]rule_typeThe check rule type. Please refer to values starting from addon::accessibility::e_RuleTypeDocPermission and this should be one of these values.
[in]check_stateThe check state. Please refer to values starting from addon::accessibility::e_CheckStateNone and this should be one of these values.
Returns
true means success, while false means not.