Deprecation: #91001 - Various methods within GeneralUtility
See forge#91001
Description
The following methods within GeneralUtility have been marked as deprecated, as the native PHP methods can be used directly:
General
Utility:: IPv6Hex2Bin () General
Utility:: IPv6Bin2Hex () General
Utility:: compress IPv6 () General
Utility:: milliseconds ()
In addition, these methods are unused by Core and marked as deprecated as well:
General
Utility:: link This Url () General
Utility:: flush Directory ()
Impact
Calling any methods directly from PHP will trigger a PHP E_
error.
Affected Installations
TYPO3 installations with third-party extensions using any of these methods.
Migration
As the following methods are just wrappers around native PHP methods, it is recommended to switch to native PHP to speed up performance:
General
:Utility:: IPv6Hex2Bin ($hex) inet_
pton ($hex) General
:Utility:: IPv6Bin2Hex ($bin) inet_
ntop ($bin) General
:Utility:: compress IPv6 ($address) inet_
ntop (inet_ pton ($address)) General
:Utility:: milliseconds () round
(microtime (true) * 1000)
As for General
it is recommended to migrate to
PSR-7 (UriInterface).
The method General
uses a clearing
folder structure which is only used for caching to avoid race-conditioning. It
is recommended to use General
or implement the code
directly in the third-party extension.