Class PermissionProviderStandard
- java.lang.Object
-
- com.adobe.internal.pdftoolkit.core.permissionprovider.PermissionProviderStandard
-
- All Implemented Interfaces:
PermissionProvider
,BitwiseOperandEvaluator
public class PermissionProviderStandard extends java.lang.Object implements PermissionProvider, BitwiseOperandEvaluator
This class implements the Encryption PermissionProvider.
-
-
Constructor Summary
Constructors Constructor Description PermissionProviderStandard(int perms)
constructor for PermissionProviderStandard.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
evaluate(java.lang.String operandVar)
This is the callback from the BitwiseExpressionEvaluator which is called for each Pemission Param.int
getPermissionBits()
This method returns an integer whose bits represent different permissions allowed or disallowed.boolean
isPermitted(ObjectOperations objOpr)
Determines whether the given object operation combination is permitted on a given document.static PermissionProviderStandard
newInstance(PermissionProvider provider)
Constructs a new instance ofPermissionProviderStandard
with the same permissions allowed in passed provider here.
-
-
-
Method Detail
-
newInstance
public static PermissionProviderStandard newInstance(PermissionProvider provider) throws PDFUnableToCompleteOperationException
Constructs a new instance ofPermissionProviderStandard
with the same permissions allowed in passed provider here.
-
getPermissionBits
public int getPermissionBits()
This method returns an integer whose bits represent different permissions allowed or disallowed.
-
isPermitted
public boolean isPermitted(ObjectOperations objOpr)
Determines whether the given object operation combination is permitted on a given document.- Specified by:
isPermitted
in interfacePermissionProvider
- Parameters:
objOpr
- a valid combination of object/operations available in Acrobat 7.0 Professional.- Returns:
- boolean Only the valid object operations are allowed as input paramater.
-
evaluate
public boolean evaluate(java.lang.String operandVar) throws InvalidOperandException
This is the callback from the BitwiseExpressionEvaluator which is called for each Pemission Param.- Specified by:
evaluate
in interfaceBitwiseOperandEvaluator
- Throws:
InvalidOperandException
- See Also:
BitwiseOperandEvaluator.evaluate(java.lang.String)
-
-