GZip
extends ContainerAwareObject
in package
GZip utils functions Helper Class
Table of Contents
Properties
- $translators : array<string|int, mixed>
- $container : ContainerInterface
Methods
- __call() : mixed
- {@inheritdoc}
- __construct() : mixed
- constructor
- compress() : string
- Compress a single file into gzip format
- containerCall() : mixed
- call method through container
- containerMake() : mixed
- create object through container
- extract() : string
- Extract a gzip file to a target file
- getAdminRouter() : Admin
- gets admin service
- getAI() : Manager
- gets ai manager service
- getApp() : App
- gets app object
- getApplicationLogger() : Manager
- gets application_logger service
- getAppRouteInfo() : RouteInfo|null
- gets route info
- getAppWebsite() : Website|null
- gets current website
- getAssets() : Manager
- gets assets manager
- getAuth() : Manager
- gets auth manager service
- getCache() : Manager
- get cache manager
- getContainer() : ContainerInterface|Container
- gets container object
- getCrudRouter() : Crud
- gets crud service
- getDb() : Database|null
- gets db object
- getDebugbar() : StandardDebugBar
- gets debugbar object
- getEnvironment() : Manager
- gets environment manager service
- getEventManager() : SharedEventEmitter
- gets events manager service
- getGoogleAuthenticator() : PHPGangsta_GoogleAuthenticator
- gets google authenticator service
- getGuzzle() : Client
- gets guzzle service
- getGZip() : GZip
- gets gzip service
- getHtmlRenderer() : HtmlPartsRenderer
- gets html renderer service
- getIcons() : Icons
- gets icons service
- getImagine() : Imagine
- gets imagine service
- getLog() : Logger
- gets log object
- getMailer() : Mailer
- gets mailer service
- getPdo() : PDO|null
- gets PDO object
- getRedis() : Manager
- gets redis service
- getRouters() : array<string|int, mixed>
- gets routers
- getSchema() : Schema|null
- gets schema object
- getSearch() : Manager
- gets search service
- getSesMailer() : SesClient
- gets SES mailer service
- getSiteData() : SiteData
- gets site data service
- getSmtpMailer() : Swift_Mailer
- gets SMTP mailer service
- getTemplates() : Engine
- gets plates engine object
- getTranslator() : Translator
- gets translator
- getUtils() : Globals
- gets global utils service
- getWebhooksRouter() : Webhooks
- gets webhooks service
- getWebRouter() : Web
- gets routing service
- getZip() : Zip
- gets zip service
- requestUrl() : string|bool
- executes an http request
- getService() : mixed
- gets registered service
Properties
$translators
public
static array<string|int, mixed>
$translators
= []
translators
$container
protected
ContainerInterface
$container
Methods
__call()
{@inheritdoc}
public
__call(string $name, mixed $arguments) : mixed
Parameters
- $name : string
- $arguments : mixed
Tags
__construct()
constructor
public
__construct(ContainerInterface $container) : mixed
Parameters
- $container : ContainerInterface
compress()
Compress a single file into gzip format
public
compress(string $sourceFile[, string|null $targetFile = null ][, int $level = 9 ]) : string
Parameters
- $sourceFile : string
-
Path to the file to compress
- $targetFile : string|null = null
-
Optional target .gz file path (default: sourceFile.gz)
- $level : int = 9
-
Compression level 0-9 (default 9 = max)
Return values
string —Path to the created gzip file
containerCall()
call method through container
public
containerCall(callable $callable[, array<string|int, mixed> $arguments = [] ]) : mixed
Parameters
- $callable : callable
- $arguments : array<string|int, mixed> = []
containerMake()
create object through container
public
containerMake(string $className[, array<string|int, mixed> $arguments = [] ]) : mixed
Parameters
- $className : string
- $arguments : array<string|int, mixed> = []
extract()
Extract a gzip file to a target file
public
extract(string $gzipFile[, string|null $targetFile = null ]) : string
Parameters
- $gzipFile : string
-
Path to the .gz file
- $targetFile : string|null = null
-
Optional target file path (default: gzipFile without .gz)
Return values
string —Path to the extracted file
getAdminRouter()
gets admin service
public
getAdminRouter() : Admin
Tags
Return values
AdmingetAI()
gets ai manager service
public
getAI() : Manager
Tags
Return values
ManagergetApp()
gets app object
public
getApp() : App
Tags
Return values
AppgetApplicationLogger()
gets application_logger service
public
getApplicationLogger() : Manager
Tags
Return values
ManagergetAppRouteInfo()
gets route info
public
getAppRouteInfo() : RouteInfo|null
Return values
RouteInfo|nullgetAppWebsite()
gets current website
public
getAppWebsite() : Website|null
Return values
Website|nullgetAssets()
gets assets manager
public
getAssets() : Manager
Tags
Return values
ManagergetAuth()
gets auth manager service
public
getAuth() : Manager
Tags
Return values
ManagergetCache()
get cache manager
public
getCache() : Manager
Tags
Return values
ManagergetContainer()
gets container object
public
getContainer() : ContainerInterface|Container
Return values
ContainerInterface|ContainergetCrudRouter()
gets crud service
public
getCrudRouter() : Crud
Tags
Return values
CrudgetDb()
gets db object
public
getDb() : Database|null
Tags
Return values
Database|nullgetDebugbar()
gets debugbar object
public
getDebugbar() : StandardDebugBar
Tags
Return values
StandardDebugBargetEnvironment()
gets environment manager service
public
getEnvironment() : Manager
Tags
Return values
ManagergetEventManager()
gets events manager service
public
getEventManager() : SharedEventEmitter
Tags
Return values
SharedEventEmittergetGoogleAuthenticator()
gets google authenticator service
public
getGoogleAuthenticator() : PHPGangsta_GoogleAuthenticator
Tags
Return values
PHPGangsta_GoogleAuthenticatorgetGuzzle()
gets guzzle service
public
getGuzzle() : Client
Tags
Return values
ClientgetGZip()
gets gzip service
public
getGZip() : GZip
Tags
Return values
GZipgetHtmlRenderer()
gets html renderer service
public
getHtmlRenderer() : HtmlPartsRenderer
Tags
Return values
HtmlPartsRenderergetIcons()
gets icons service
public
getIcons() : Icons
Tags
Return values
IconsgetImagine()
gets imagine service
public
getImagine() : Imagine
Tags
Return values
ImaginegetLog()
gets log object
public
getLog() : Logger
Tags
Return values
LoggergetMailer()
gets mailer service
public
getMailer() : Mailer
Tags
Return values
MailergetPdo()
gets PDO object
public
getPdo() : PDO|null
Tags
Return values
PDO|nullgetRedis()
gets redis service
public
getRedis() : Manager
Tags
Return values
ManagergetRouters()
gets routers
public
getRouters() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed>getSchema()
gets schema object
public
getSchema() : Schema|null
Tags
Return values
Schema|nullgetSearch()
gets search service
public
getSearch() : Manager
Tags
Return values
ManagergetSesMailer()
gets SES mailer service
public
getSesMailer() : SesClient
Tags
Return values
SesClientgetSiteData()
gets site data service
public
getSiteData() : SiteData
Tags
Return values
SiteDatagetSmtpMailer()
gets SMTP mailer service
public
getSmtpMailer() : Swift_Mailer
Tags
Return values
Swift_MailergetTemplates()
gets plates engine object
public
getTemplates() : Engine
Tags
Return values
EnginegetTranslator()
gets translator
public
getTranslator([string|null $locale_code = null ]) : Translator
Parameters
- $locale_code : string|null = null
Tags
Return values
TranslatorgetUtils()
gets global utils service
public
getUtils() : Globals
Tags
Return values
GlobalsgetWebhooksRouter()
gets webhooks service
public
getWebhooksRouter() : Webhooks
Tags
Return values
WebhooksgetWebRouter()
gets routing service
public
getWebRouter() : Web
Tags
Return values
WebgetZip()
gets zip service
public
getZip() : Zip
Tags
Return values
ZiprequestUrl()
executes an http request
public
requestUrl(string $url[, string $method = 'GET' ][, array<string|int, mixed> $options = [] ]) : string|bool
Parameters
- $url : string
- $method : string = 'GET'
- $options : array<string|int, mixed> = []
Tags
Return values
string|boolgetService()
gets registered service
protected
getService(string $service_key) : mixed
Parameters
- $service_key : string