4 * This file is part of the Symfony package.
6 * (c) Fabien Potencier <fabien@symfony.com>
8 * For the full copyright and license information, please view the LICENSE
9 * file that was distributed with this source code.
12 use Symfony\Component\Intl\Globals\IntlGlobals
;
14 if (!function_exists('intl_is_failure')) {
17 * Stub implementation for the {@link intl_is_failure()} function of the intl
20 * @author Bernhard Schussek <bschussek@gmail.com>
22 * @param integer $errorCode The error code returned by intl_get_error_code().
24 * @return Boolean Whether the error code indicates an error.
26 * @see \Symfony\Component\Intl\Globals\StubIntlGlobals::isFailure
28 function intl_is_failure($errorCode)
30 return IntlGlobals
::isFailure($errorCode);
34 * Stub implementation for the {@link intl_get_error_code()} function of the
37 * @author Bernhard Schussek <bschussek@gmail.com>
39 * @return Boolean The error code of the last intl function call or
40 * IntlGlobals::U_ZERO_ERROR if no error occurred.
42 * @see \Symfony\Component\Intl\Globals\StubIntlGlobals::getErrorCode
44 function intl_get_error_code()
46 return IntlGlobals
::getErrorCode();
50 * Stub implementation for the {@link intl_get_error_code()} function of the
53 * @author Bernhard Schussek <bschussek@gmail.com>
55 * @return Boolean The error message of the last intl function call or
56 * "U_ZERO_ERROR" if no error occurred.
58 * @see \Symfony\Component\Intl\Globals\StubIntlGlobals::getErrorMessage
60 function intl_get_error_message()
62 return IntlGlobals
::getErrorMessage();
66 * Stub implementation for the {@link intl_error_name()} function of the intl
69 * @param integer $errorCode The error code.
71 * @return string The name of the error code constant.
73 * @see \Symfony\Component\Intl\Globals\StubIntlGlobals::getErrorName
75 function intl_error_name($errorCode)
77 return IntlGlobals
::getErrorName($errorCode);