|
dolibarr 25.0.0-alpha
|
Immutable outcome of a permissions sync run. More...
Public Member Functions | |
| __construct (int $updatedLines=0, int $skipped=0, array $conflicts=array(), array $warnings=array()) | |
| hasConflicts () | |
| Whether a blocking problem prevented the write. | |
| hasWarnings () | |
| Whether something was normalized while still writing. | |
| isNoop () | |
| Whether the sync produced no permission line. | |
| toLegacyReturnCode () | |
| Map the report onto the historical reWriteAllPermissions() return code. | |
Immutable outcome of a permissions sync run.
Conflicts and warnings are two distinct severities and must not be merged: a non-empty $conflicts means NO write was performed, while $warnings means the write was performed and something was normalized on the way.
Definition at line 31 of file SyncReport.class.php.
| SyncReport::__construct | ( | int | $updatedLines = 0, |
| int | $skipped = 0, | ||
| array | $conflicts = array(), | ||
| array | $warnings = array() ) |
| int | $updatedLines | Number of lines written into the permissions block |
| int | $skipped | Number of operations deliberately skipped |
| string[] | $conflicts | Blocking problems, in plain English |
| string[] | $warnings | Non-blocking problems, in plain English |
Definition at line 51 of file SyncReport.class.php.
| SyncReport::hasConflicts | ( | ) |
Whether a blocking problem prevented the write.
Definition at line 64 of file SyncReport.class.php.
Referenced by toLegacyReturnCode().
| SyncReport::hasWarnings | ( | ) |
Whether something was normalized while still writing.
Definition at line 74 of file SyncReport.class.php.
| SyncReport::isNoop | ( | ) |
Whether the sync produced no permission line.
This is not the same as "the file was left untouched": removing the last right of a module writes an empty block, which changes the file while producing zero lines.
Definition at line 87 of file SyncReport.class.php.
| SyncReport::toLegacyReturnCode | ( | ) |
Map the report onto the historical reWriteAllPermissions() return code.
Definition at line 97 of file SyncReport.class.php.
References hasConflicts().