Helper
Table of Contents
Constants
- CONFIGURATION_FILE_EXTENSION = '.json'
- DEFAULT_ARCHIVE_FILE_EXTENSIONS = 'zip'
- DEFAULT_ARCHIVE_NAME = 'configuration'
- MODE_EXPORT = 'EXPORT'
- MODE_IMPORT = 'IMPORT'
- MODE_ROLLBACK = 'ROLLBACK'
- STRUCTURE_FILES_NAME = 'files'
- STRUCTURE_SMALL_FILES_NAME = 'small_files'
- TYPE_SECTION_TOTAL = 'total'
Methods
- checkAccessManifest() : bool
- deleteBasicApp() : bool
- enabledZipMod() : bool
- Enable or not main option zip_mode nginx
- getBasicApp() : bool|string
- getBasicAppList() : array<string|int, mixed>
- getContextAction() : string
- Context uses action
- getContextUser() : string
- getInstance() : Helper
- getMaxFileSize() : int
- getStorageBackup() : mixed
- getStorageBackupParam() : mixed
- isBasicManifest() : bool
- sanitize() : string
- Sanitize bad value.
- sendStatistic() : bool
- sendStatisticAgent() : string
- Every day send statistic basic configuration app
- setBasicApp() : bool
Constants
CONFIGURATION_FILE_EXTENSION
public
mixed
CONFIGURATION_FILE_EXTENSION
= '.json'
DEFAULT_ARCHIVE_FILE_EXTENSIONS
public
mixed
DEFAULT_ARCHIVE_FILE_EXTENSIONS
= 'zip'
DEFAULT_ARCHIVE_NAME
public
mixed
DEFAULT_ARCHIVE_NAME
= 'configuration'
MODE_EXPORT
public
mixed
MODE_EXPORT
= 'EXPORT'
MODE_IMPORT
public
mixed
MODE_IMPORT
= 'IMPORT'
MODE_ROLLBACK
public
mixed
MODE_ROLLBACK
= 'ROLLBACK'
STRUCTURE_FILES_NAME
public
mixed
STRUCTURE_FILES_NAME
= 'files'
STRUCTURE_SMALL_FILES_NAME
public
mixed
STRUCTURE_SMALL_FILES_NAME
= 'small_files'
TYPE_SECTION_TOTAL
public
mixed
TYPE_SECTION_TOTAL
= 'total'
Methods
checkAccessManifest()
public
static checkAccessManifest(array<string|int, mixed> $params[, array<string|int, mixed> $uses = [] ]) : bool
use Manifest::isEntityAvailable()
check Event manifest[USES] intersect current entity[USES]
Parameters
- $params : array<string|int, mixed>
-
all event parameters
- $uses : array<string|int, mixed> = []
-
all access uses in current entity
Return values
booldeleteBasicApp()
public
deleteBasicApp(mixed $manifestCode) : bool
Parameters
- $manifestCode : mixed
-
string
Return values
boolenabledZipMod()
Enable or not main option zip_mode nginx
public
enabledZipMod() : bool
Return values
boolgetBasicApp()
public
getBasicApp(mixed $manifestCode) : bool|string
Parameters
- $manifestCode : mixed
-
string
Return values
bool|stringgetBasicAppList()
public
getBasicAppList() : array<string|int, mixed>
Return values
array<string|int, mixed> —[ manifestCode => appCode ]
getContextAction()
Context uses action
public
getContextAction([int $appId = 0 ]) : string
Parameters
- $appId : int = 0
Return values
string —context
getContextUser()
public
getContextUser(mixed $postfix) : string
Parameters
- $postfix : mixed
-
string a-zA-Z0-9_
Return values
stringgetInstance()
public
static getInstance() : Helper
Return values
HelpergetMaxFileSize()
public
getMaxFileSize() : int
Return values
intgetStorageBackup()
public
getStorageBackup() : mixed
getStorageBackupParam()
public
getStorageBackupParam() : mixed
isBasicManifest()
public
isBasicManifest(mixed $code) : bool
Parameters
- $code : mixed
-
string
Return values
boolsanitize()
Sanitize bad value.
public
sanitize(string $value[, bool &$bad = false ][, string $splitter = ' ' ]) : string
Parameters
- $value : string
-
Bad value.
- $bad : bool = false
-
Return true, if value is bad.
- $splitter : string = ' '
-
Splitter for bad content.
Return values
string —Good value.
sendStatistic()
public
sendStatistic() : bool
Return values
boolsendStatisticAgent()
Every day send statistic basic configuration app
public
static sendStatisticAgent() : string
Return values
stringsetBasicApp()
public
setBasicApp(mixed $manifestCode, mixed $appCode) : bool
Parameters
- $manifestCode : mixed
-
string
- $appCode : mixed
-
string