List of all members.
Public Member Functions |
|
| __construct (&$CIFolder) |
| | init () |
| | run () |
| | setMapping ($mapping) |
| | cleanFilename ($filename) |
Public Attributes |
|
const | TASK_LABEL = 'Clean filenames' |
|
const | CONF_CLEAN_SOURCE = 'CLEAN_SOURCE' |
Static Public Attributes |
| static | $CHARS_UMLAUTS |
| static | $CHARS_ILLEGAL |
| static | $CHARS_WHITESPACE |
| static | $CHARS_SLASHES |
| static | $CHARS_BRACKETS |
| static | $CHARS_QUOTATION |
| static | $CHARS_QUOTATION2 |
| static | $CHARS_PICKY |
Protected Member Functions |
| | loadSettings () |
| | renameFile ($fileIn, $fileOut) |
Protected Attributes |
|
| $cleanSource |
Detailed Description
Cleans files/foldernames of the folder, applying certain replacement rules for 'non-safe' characters.
- Author:
- Peter Bubestinger-Steindl (pb@av-rd.com)
- Copyright:
- Copyright 2016, Peter Bubestinger-Steindl (License: GNU General Public License (v3))
- See also:
-
Member Function Documentation
Replaces possibly dangerous/problematic characters in $filename string. To be used for file- or foldernames.
Prepare everything so it's ready for processing.
- Returns:
- bool success True if init went fine, False if an error occurred.
Reimplemented from TaskFilesMatch.
Load settings from config that are relevant for this task.
Reimplemented from CITask.
Rename a file from $fileIn to $fileOut.
Perform the actual steps of this task.
Reimplemented from CITask.
Member Data Documentation
TaskCleanFilenames::$CHARS_BRACKETS [static] |
Initial value: array(
"(" => "_",
")" => "_",
"[" => "_",
"]" => "_",
"{" => "_",
"}" => "_",
"<" => "_",
">" => "_",
)
TaskCleanFilenames::$CHARS_ILLEGAL [static] |
Initial value: array(
"?" => "_",
"*" => "_",
":" => "_",
)
TaskCleanFilenames::$CHARS_PICKY [static] |
Initial value: array(
"#" => "_",
"," => "_",
";" => "_",
"&" => "and",
)
TaskCleanFilenames::$CHARS_QUOTATION [static] |
Initial value: array(
"„" => "\"",
"“" => "\"",
"´" => "'",
"`" => "'",
)
TaskCleanFilenames::$CHARS_QUOTATION2 [static] |
Initial value: array(
"„" => "_",
"“" => "_",
"´" => "_",
"`" => "_",
'"' => "_",
"'" => "_",
)
TaskCleanFilenames::$CHARS_SLASHES [static] |
Initial value: array(
"\\" => "_",
"/" => "_",
)
TaskCleanFilenames::$CHARS_UMLAUTS [static] |
Initial value: array(
"ä" => "ae",
"ü" => "ue",
"ö" => "oe",
"ß" => "ss",
"Ä" => "AE",
"Ü" => "UE",
"Ö" => "OE",
)
TaskCleanFilenames::$CHARS_WHITESPACE [static] |
The documentation for this class was generated from the following file:
- /media/storage_700/storage/F_Drive/JobsToDo/Das-Firma/owncloud/Development/avrd.git/projects/cinbox/bin/tasks/TaskCleanFilenames.php