public class WorkbookProtection extends Object
Properties in this class are simply written to Excel file and have no effect on the behavior of this library. For more information on workbook protection, consult Microsoft Excel documentation.
Modifier and Type | Method and Description |
---|---|
int |
getPasswordHash()
Gets the password hash for protected workbook.
|
boolean |
isProtectStructure()
Gets if workbook structure is protected.
|
boolean |
isProtectWindows()
Gets if workbook window is protected.
|
void |
setPassword(String password)
Sets the password for protected workbook.
|
void |
setPasswordHash(int passwordHash)
Sets the password hash for protected workbook.
|
void |
setProtectStructure(boolean protectStructure)
Sets if workbook structure is protected.
|
void |
setProtectWindows(boolean protectWindows)
Sets if workbook window is protected.
|
public int getPasswordHash()
public boolean isProtectStructure()
false
.public boolean isProtectWindows()
false
.public void setPassword(String password)
password
- The password.public void setPasswordHash(int passwordHash)
This field needs to be set to value smaller than Short.MAX_VALUE * 2.
For setting password it can be also used setPassword(java.lang.String)
method.
public void setProtectStructure(boolean protectStructure)
false
.public void setProtectWindows(boolean protectWindows)
false
.© GemBox Ltd. — All rights reserved.