PROTECTION_INHERIT
PROTECTION_INHERIT = 'inherit'
Protection styles
$isSupervisor : bool
Supervisor?
$parent : \PhpOffice\PhpSpreadsheet\Spreadsheet|\PhpOffice\PhpSpreadsheet\Style\Style
Parent. Only used for supervisor.
$parentPropertyName : null|string
Parent property name.
$locked : string
Locked.
$hidden : string
Hidden.
__construct(bool $isSupervisor = false, bool $isConditional = false) : mixed
Create a new Protection.
bool | $isSupervisor | Flag indicating if this is a supervisor or not Leave this value at default unless you understand exactly what its ramifications are |
bool | $isConditional | Flag indicating if this is a conditional style or not Leave this value at default unless you understand exactly what its ramifications are |
bindParent(\PhpOffice\PhpSpreadsheet\Spreadsheet|\PhpOffice\PhpSpreadsheet\Style\Style $parent, null|string $parentPropertyName = null) : \PhpOffice\PhpSpreadsheet\Style\Supervisor
Bind parent. Only used for supervisor.
\PhpOffice\PhpSpreadsheet\Spreadsheet|\PhpOffice\PhpSpreadsheet\Style\Style | $parent | |
null|string | $parentPropertyName |
applyFromArray(array $pStyles) : \PhpOffice\PhpSpreadsheet\Style\Protection
Apply styles from array.
$spreadsheet->getActiveSheet()->getStyle('B2')->getLocked()->applyFromArray(
[
'locked' => TRUE,
'hidden' => FALSE
]
);
array | $pStyles | Array containing style information |